/*
Theme Name: MatBaoWS
Description: This is a child theme for Flatsome Theme
Author: MatBaoWS Team
Template: flatsome
Version: 4.0
*/
/*************** ADD CUSTOM CSS HERE.   ***************/

.equal-height-row > .col {
    display: flex !important;
}
.equal-height-row > .col > .col-inner {
    flex: 1 !important;
    display: flex !important;
    flex-direction: column !important;
    height: 100% !important;
}

/* Styling for Giấy đăng ký kinh doanh card */
.gpkd-card-wrapper {
    background-color: #fff;
    border: 1px solid #e5e5e5;
    border-radius: 12px;
    padding: 15px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.05);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    overflow: hidden;
    display: inline-block;
    width: 100%;
}
.gpkd-card-wrapper:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1);
}
.gpkd-img img {
    border-radius: 8px;
    display: block;
    width: 100%;
    height: auto;
}

/* Responsive Legal Info List */
.legal-info-list {
    margin-bottom: 25px;
}
.legal-info-item {
    display: flex;
    padding: 12px 0;
    border-bottom: 1px solid #f0f0f0;
}
.legal-info-item:last-child {
    border-bottom: none;
}
.legal-info-label {
    flex: 0 0 35%;
    font-weight: bold;
    color: #333;
    padding-right: 15px;
}
.legal-info-value {
    flex: 1;
    color: #555;
}
.legal-info-value.highlight-blue {
    color: #0056b3 !important; /* Primary Blue color for MS doanh nghiệp */
    font-weight: bold;
    font-size: 1.1em;
}

/* Custom Blue Button */
.btn-blue {
    background-color: #0056b3 !important;
    border-color: #0056b3 !important;
    color: #ffffff !important;
}
.btn-blue:hover {
    background-color: #004085 !important;
    border-color: #004085 !important;
}

/* Mobile responsive layout */
@media (max-width: 767px) {
    .legal-info-item {
        flex-direction: column;
        padding: 8px 0;
    }
    .legal-info-label {
        margin-bottom: 3px;
        width: 100%;
    }
}

/* CTA Button Styling */
.btn-cta-brand {
    background-color: #c74735 !important;
    border-color: #c74735 !important;
    color: #ffffff !important;
    font-weight: bold !important;
    letter-spacing: 1px !important;
    box-shadow: 0 4px 15px rgba(199, 71, 53, 0.4) !important;
    transition: transform 0.3s ease, box-shadow 0.3s ease, background-color 0.3s ease !important;
}
.btn-cta-brand:hover {
    background-color: #a83222 !important;
    border-color: #a83222 !important;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(199, 71, 53, 0.6) !important;
}



/* Áp dụng hiệu ứng mờ xám và đường viền chân xám cho Slider chính ở Trang chủ */
.slider-wrapper.home-top-slider {
    position: relative;
    z-index: 10;
    border-bottom: 8px solid rgb(220, 220, 220); /* Viền màu xám dưới chân slider */
}

.slider-wrapper.home-top-slider::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: 50px; /* Giảm chiều cao xuống 50px để không đè lên chữ và icon */
    background: linear-gradient(
        to bottom,
        rgba(220, 220, 220, 0) 0%,
        rgba(220, 220, 220, 0.4) 40%,
        rgba(220, 220, 220, 0.85) 75%,
        rgba(220, 220, 220, 1) 100%
    );
    -webkit-backdrop-filter: blur(1px); /* Giảm độ nhòe xuống 1px để chữ rõ hơn */
    backdrop-filter: blur(1px);
    pointer-events: none;
    z-index: 9;
}

/* Certificate Showcase Styles */
.certificate-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 30px;
    justify-content: center;
    margin-top: 40px;
    max-width: 1200px;
    margin-left: auto;
    margin-right: auto;
    padding: 0 15px;
}

.certificate-card {
    background: #ffffff;
    border-radius: 16px;
    border: 1px solid #eef2f6;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.04);
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    width: calc(50% - 15px);
    max-width: 540px;
}

@media (max-width: 767px) {
    .certificate-card {
        width: 100%;
    }
}

.certificate-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.08);
    border-color: #d1d9e6;
}

.certificate-card-header {
    padding: 24px 24px 16px 24px;
    border-bottom: 1px solid #f0f4f8;
    background: linear-gradient(to bottom, #fcfdfe, #ffffff);
}

.certificate-tag {
    display: inline-block;
    font-size: 0.75em;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: #c74735;
    margin-bottom: 8px;
}

.certificate-card-title {
    font-size: 1.1em;
    font-weight: 700;
    color: #0b2545;
    line-height: 1.4;
    margin: 0;
}

.certificate-image-container {
    padding: 20px;
    background-color: #f8fafc;
    display: flex;
    align-items: center;
    justify-content: center;
    height: 320px;
    overflow: hidden;
    position: relative;
}

.certificate-image-container img {
    max-height: 100%;
    max-width: 100%;
    object-fit: contain;
    transition: transform 0.4s ease;
    border: 1px solid #e2e8f0;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.03);
    border-radius: 4px;
}

.certificate-card:hover .certificate-image-container img {
    transform: scale(1.03);
}

.certificate-details {
    padding: 20px 24px;
    flex-grow: 1;
    background: #ffffff;
}

.certificate-meta-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.certificate-meta-item {
    display: flex;
    justify-content: space-between;
    font-size: 0.88em;
    padding: 8px 0;
    border-bottom: 1px dashed #eef2f6;
    color: #4a5568;
}

.certificate-meta-item:last-child {
    border-bottom: none;
}

.certificate-meta-label {
    font-weight: 600;
    color: #718096;
}

.certificate-meta-value {
    font-weight: 500;
    color: #1a202c;
    text-align: right;
}

.certificate-card-footer {
    padding: 20px 24px 24px 24px;
    border-top: 1px solid #f0f4f8;
    background-color: #fcfdfe;
    text-align: center;
}

.btn-certificate-view {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background-color: #0b2545;
    color: #ffffff !important;
    font-weight: 700;
    font-size: 0.9em;
    padding: 10px 24px;
    border-radius: 30px;
    text-decoration: none;
    transition: all 0.2s ease;
    border: none;
    box-shadow: 0 4px 10px rgba(11, 37, 73, 0.15);
    width: 100%;
}

.btn-certificate-view:hover {
    background-color: #c74735;
    box-shadow: 0 6px 15px rgba(199, 71, 53, 0.25);
    transform: translateY(-1px);
}

/* Hover effects for clean certificate layout */
.certificate-preview-box:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.08) !important;
    border-color: #c74735 !important;
}

.certificate-preview-box:hover .cert-img {
    transform: scale(1.025);
}

/* Responsive Brochure Iframe for Homepage */
.brochure-wrapper {
    max-width: 1200px !important;
    margin: 0 auto;
    padding: 0 15px;
}

.brochure-iframe {
    width: 100%;
    height: 750px;
    border: none;
    border-radius: 12px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.06);
    display: block;
}

@media (max-width: 991px) {
    .brochure-iframe {
        height: 600px;
    }
}

@media (max-width: 767px) {
    .brochure-iframe {
        height: 450px;
    }
}

/* --- Organizational Chart (SVG + Absolute Layout) --- */
.sodo-wrap {
    width: 100% !important;
    max-width: 960px !important;
    margin: 0 auto !important;
    overflow-x: auto !important;
    padding: 40px 0 60px !important;
    background: #f8fafc !important;
    box-sizing: border-box !important;
}
.sodo-title {
    text-align: center !important;
    font-size: 20px !important;
    font-weight: 800 !important;
    color: #0b2545 !important;
    text-transform: uppercase !important;
    letter-spacing: 1.5px !important;
    margin: 0 0 36px 0 !important;
    padding: 0 !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 16px !important;
    line-height: 1.3 !important;
}
.sodo-title::before,
.sodo-title::after {
    content: '' !important;
    display: inline-block !important;
    width: 55px !important;
    height: 2px !important;
    background: #0056b3 !important;
    flex-shrink: 0 !important;
}
.sodo-inner {
    position: relative !important;
    width: 900px !important;
    margin: 0 auto !important;
}
.sodo-svg {
    position: absolute !important;
    top: 0 !important;
    left: 0 !important;
    width: 900px !important;
    pointer-events: none !important;
    overflow: visible !important;
    z-index: 1 !important;
}
/* Node cards */
.sd-node {
    position: absolute !important;
    display: flex !important;
    flex-direction: row !important;
    align-items: stretch !important;
    border-radius: 5px !important;
    overflow: hidden !important;
    box-shadow: 0 3px 10px rgba(0,0,0,0.12) !important;
    border: 2px solid #0056b3 !important;
    box-sizing: border-box !important;
    height: 46px !important;
    z-index: 2 !important;
    transition: transform 0.2s, box-shadow 0.2s !important;
    text-decoration: none !important;
}
.sd-node:hover {
    transform: translateY(-2px) !important;
    box-shadow: 0 6px 18px rgba(0,86,179,0.2) !important;
}
.sd-node .sd-icon {
    width: 42px !important;
    min-width: 42px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    background: #0056b3 !important;
    color: #fff !important;
    font-size: 15px !important;
    flex-shrink: 0 !important;
}
.sd-node .sd-text {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    padding: 4px 10px !important;
    font-weight: 700 !important;
    font-size: 11px !important;
    text-transform: uppercase !important;
    letter-spacing: 0.4px !important;
    color: #0b2545 !important;
    background: #fff !important;
    text-align: center !important;
    line-height: 1.35 !important;
    flex: 1 !important;
}
/* Primary: Đại hội đồng cổ đông */
body .sd-node.primary { border-color: #003b85 !important; }
body .sd-node.primary .sd-icon { background: #003b85 !important; }
body .sd-node.primary .sd-text { background: #0056b3 !important; color: #fff !important; }
/* Section: Văn phòng / Bộ phận - solid blue, no gradient to avoid override */
body .sd-node.section { border-color: #003b85 !important; background: #003b85 !important; }
body .sd-node.section .sd-icon { background: #0056b3 !important; color: #fff !important; border-right: 1px solid rgba(255,255,255,0.2) !important; }
body .sd-node.section .sd-text { background: #003b85 !important; color: #fff !important; font-weight: 800 !important; }
/* Leaf child nodes */
.sd-node.leaf {
    border: 1.5px solid #b8cce4 !important;
    border-left: 3px solid #0056b3 !important;
    box-shadow: 0 2px 6px rgba(0,0,0,0.08) !important;
    height: 64px !important;
}
.sd-node.leaf .sd-icon {
    background: #f0f5fb !important;
    color: #0056b3 !important;
    font-size: 13px !important;
    width: 36px !important;
    min-width: 36px !important;
    border-right: 1px solid #d0dff0 !important;
}
body .sd-node.leaf .sd-text {
    background: #fff !important;
    font-weight: 600 !important;
    font-size: 10.5px !important;
    color: #334155 !important;
    text-transform: none !important;
}
@media (max-width: 920px) {
    .sodo-inner { transform-origin: top left !important; }
    .sodo-wrap { overflow-x: auto !important; }
}
.org-chart-title {
    font-size: 1.8em !important;
    font-weight: 700 !important;
    color: #0b2545 !important;
    text-align: center !important;
    margin-bottom: 50px !important;
    text-transform: uppercase !important;
    letter-spacing: 1px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 15px !important;
}
.org-chart-title::before,
.org-chart-title::after {
    content: '' !important;
    display: block !important;
    width: 60px !important;
    height: 2px !important;
    background-color: #0056b3 !important;
}
.org-tree-new,
.tree-row,
.vertical-line,
.tree-branches-row,
.tree-branch,
.branch-children,
.leaf-item {
    margin: 0 !important;
    padding: 0 !important;
    box-sizing: border-box !important;
}
.org-tree-new {
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    width: 100% !important;
    min-width: 1100px !important;
    max-width: 1200px !important;
    margin: 0 auto !important;
    font-family: inherit !important;
}
.tree-row {
    display: flex !important;
    justify-content: center !important;
    align-items: center !important;
    width: 100% !important;
    position: relative !important;
}
.vertical-line {
    width: 2px !important;
    height: 30px !important;
    background-color: #0056b3 !important;
}

/* Side node: Ban kiểm soát position and loop lines */
.relative-row {
    position: relative !important;
}
.side-node.left-side {
    position: absolute !important;
    right: calc(50% + 145px) !important;
    top: 50% !important;
    transform: translateY(-50%) !important;
}

/* Dashed loop lines for Ban kiểm soát using pseudo elements of .side-node.left-side */
.side-node.left-side::before {
    content: '' !important;
    position: absolute !important;
    bottom: calc(50% + 24px) !important;
    left: 50% !important;
    right: -145px !important;
    height: 30px !important;
    border-left: 2px dashed #0056b3 !important;
    border-top: 2px dashed #0056b3 !important;
    pointer-events: none !important;
}
.side-node.left-side::after {
    content: '' !important;
    position: absolute !important;
    top: calc(50% + 24px) !important;
    left: 50% !important;
    right: -145px !important;
    height: 30px !important;
    border-left: 2px dashed #0056b3 !important;
    border-bottom: 2px dashed #0056b3 !important;
    pointer-events: none !important;
}

/* Branches container */
.tree-branches-row {
    display: flex !important;
    justify-content: center !important;
    width: 100% !important;
    position: relative !important;
    margin-top: 0 !important;
}

/* Center vertical line going to each branch */
.tree-branch {
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    width: 50% !important;
    position: relative !important;
    padding-top: 25px !important;
}

.tree-branch::before {
    content: '' !important;
    position: absolute !important;
    top: 0 !important;
    left: 50% !important;
    width: 2px !important;
    height: 25px !important;
    background-color: #0056b3 !important;
}

.tree-branches-row::before {
    content: '' !important;
    position: absolute !important;
    top: 0 !important;
    left: 25% !important;
    right: 25% !important;
    height: 2px !important;
    background-color: #0056b3 !important;
}

/* Branch children container */
.branch-children {
    display: flex !important;
    justify-content: center !important;
    position: relative !important;
    width: 100% !important;
    margin-top: 25px !important;
}

.branch-header {
    position: relative !important;
}
.branch-header::after {
    content: '' !important;
    position: absolute !important;
    top: 100% !important;
    left: 50% !important;
    width: 2px !important;
    height: 25px !important;
    background-color: #0056b3 !important;
}

.branch-children::before {
    content: '' !important;
    position: absolute !important;
    top: 0 !important;
    height: 2px !important;
    background-color: #0056b3 !important;
}

.tree-branch:first-child .branch-children::before {
    left: 16.66% !important;
    right: 16.66% !important;
}
.tree-branch:last-child .branch-children::before {
    left: 25% !important;
    right: 25% !important;
}

/* Leaf item */
.leaf-item {
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    position: relative !important;
    padding-top: 25px !important;
    box-sizing: border-box !important;
}
.tree-branch:first-child .leaf-item {
    width: 33.33% !important;
}
.tree-branch:last-child .leaf-item {
    width: 50% !important;
}

.leaf-item::before {
    content: '' !important;
    position: absolute !important;
    top: 0 !important;
    left: 50% !important;
    width: 2px !important;
    height: 25px !important;
    background-color: #0056b3 !important;
}

/* Split-badge Card Design matching image 100% */
.org-card {
    margin: 0 !important;
    background: #ffffff !important;
    border: 2px solid #0056b3 !important;
    border-radius: 6px !important;
    padding: 0 !important;
    width: 200px !important;
    height: 48px !important;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.05) !important;
    z-index: 10 !important;
    transition: all 0.3s ease !important;
    position: relative !important;
    box-sizing: border-box !important;
    overflow: hidden !important;
}
.org-card .card-icon-area {
    position: absolute !important;
    left: 0 !important;
    top: 0 !important;
    bottom: 0 !important;
    width: 44px !important;
    background-color: #0056b3 !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    flex-shrink: 0 !important;
}
.org-card .card-icon-area i {
    color: #ffffff !important;
    font-size: 1.1em !important;
}
.org-card .card-text-area {
    width: 100% !important;
    height: 100% !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    padding: 4px 8px 4px 52px !important; /* Offset by 44px icon area + 8px padding */
    text-align: center !important;
    background-color: #ffffff !important;
    box-sizing: border-box !important;
}
.org-card .card-text-area span {
    font-weight: 700 !important;
    color: #0b2545 !important;
    font-size: 0.8em !important;
    text-transform: uppercase !important;
    line-height: 1.3 !important;
    white-space: normal !important;
}

/* Hover effects */
.org-card:hover {
    transform: translateY(-3px) !important;
    box-shadow: 0 8px 20px rgba(0, 86, 179, 0.15) !important;
}
.org-card:hover .card-text-area {
    background-color: #f8fafc !important;
}

/* Primary color node: Đại hội đồng cổ đông */
.org-card.primary-node {
    border-color: #004085 !important;
    width: 240px !important;
}
.org-card.primary-node .card-icon-area {
    background-color: #004085 !important;
}
.org-card.primary-node .card-text-area {
    background-color: #004085 !important;
}
.org-card.primary-node .card-text-area span {
    color: #ffffff !important;
}
.org-card.primary-node:hover .card-text-area {
    background-color: #c74735 !important;
}

/* Section Title nodes: Văn phòng công ty / Bộ phận sản xuất */
.org-card.section-node {
    border-color: #004085 !important;
    width: 210px !important;
}
.org-card.section-node .card-icon-area {
    background-color: #ffffff !important;
}
.org-card.section-node .card-icon-area i {
    color: #0056b3 !important;
}
.org-card.section-node .card-text-area {
    background: linear-gradient(135deg, #0056b3 0%, #004085 100%) !important;
}
.org-card.section-node .card-text-area span {
    color: #ffffff !important;
}
.org-card.section-node:hover .card-text-area {
    background: linear-gradient(135deg, #c74735 0%, #a83222 100%) !important;
}

/* Leaf nodes */
.org-card.leaf-node {
    border: 1px solid #cbd5e1 !important;
    border-left: 2px solid #0056b3 !important;
    height: 60px !important;
    width: 175px !important;
}
.org-card.leaf-node .card-icon-area {
    background-color: #f8fafc !important;
    width: 36px !important;
}
.org-card.leaf-node .card-icon-area i {
    color: #0056b3 !important;
    font-size: 1em !important;
}
.org-card.leaf-node .card-text-area {
    padding: 4px 8px 4px 44px !important; /* Offset by 36px icon area + 8px padding */
}
.org-card.leaf-node .card-text-area span {
    font-weight: 600 !important;
    color: #334155 !important;
    text-transform: none !important;
    line-height: 1.3 !important;
    font-size: 0.8em !important;
}

/* Mobile responsive stacked design */
@media (max-width: 767px) {
    .org-tree-new {
        flex-direction: column !important;
        align-items: center !important;
        min-width: 0 !important;
    }
    .vertical-line {
        height: 20px !important;
    }
    .relative-row {
        display: flex !important;
        flex-direction: column !important;
        align-items: center !important;
        gap: 20px !important;
    }
    .side-node.left-side {
        position: relative !important;
        right: auto !important;
        top: auto !important;
        transform: none !important;
        order: 1 !important;
    }
    .side-node.left-side::before,
    .side-node.left-side::after {
        display: none !important;
    }
    .tree-branches-row {
        flex-direction: column !important;
        align-items: center !important;
    }
    .tree-branches-row::before {
        display: none !important;
    }
    .tree-branch {
        width: 100% !important;
        padding-top: 20px !important;
    }
    .tree-branch::before {
        height: 20px !important;
    }
    .branch-header::after {
        height: 20px !important;
    }
    .branch-children {
        flex-direction: column !important;
        align-items: center !important;
        margin-top: 0 !important;
    }
    .branch-children::before {
        display: none !important;
    }
    .leaf-item {
        width: 100% !important;
        padding-top: 20px !important;
    }
    .leaf-item::before {
        height: 20px !important;
    }
    .org-card {
        width: 240px !important;
    }
    .org-card.leaf-node {
        width: 240px !important;
    }
}