/* DFS Group - About Page Styles */

/* ===== GLOBAL RESPONSIVE BASE ===== */
body {
    overflow-x: hidden;
}

/* ===== NAVBAR FALLBACK ===== */
.mobile-menu {
    display: none;
}
.hamburger {
    display: none;
}

@media (max-width: 1024px) {
    .top-bar-inner { flex-direction: column; gap: 8px; align-items: flex-start; padding: 8px 20px; }
    .nav-links { gap: 16px; flex-wrap: wrap; }
    .main-nav-inner { padding: 0 20px; flex-wrap: wrap; gap: 12px; }
    .main-nav-inner .product-links { flex-wrap: wrap; gap: 8px; }
}

@media (max-width: 767px) {
    .top-bar-links { display: none; }
    .hamburger { display: flex; cursor: pointer; padding: 6px; }
    .mobile-menu.open {
        display: flex;
        flex-direction: column;
        background: linear-gradient(90deg, #009086, #09577e);
        padding: 16px 20px;
        gap: 12px;
    }
    .mobile-menu a, .mobile-menu div { color: #fff; font-size: 15px; }
}

/* ===== HERO ===== */
@media (max-width: 768px) {
    .hero-section { height: 260px !important; }
    .hero-text { font-size: 28px !important; width: 90% !important; margin-left: 20px !important; }
}

/* ===== GIỚI THIỆU ===== */
@media (max-width: 1024px) {
    .intro-flex { flex-direction: column !important; }
    .intro-img { height: 300px !important; width: 100% !important; margin: 0 !important; }
}

/* ===== MỤC TIÊU / SỨ MỆNH ===== */
.mission-inner {
    max-width: 800px;
    padding: 0 clamp(16px, 5vw, 340px);
}
@media (max-width: 768px) {
    .mission-inner { max-width: 100%; }
}

/* ===== GIÁ TRỊ CỐT LÕI TABS ===== */
.core-values-tabs {
    display: flex;
    gap: 24px;
    border-radius: 20px;
    overflow: hidden;
    width: 100%;
    cursor: pointer;
}
.core-tab {
    position: relative;
    overflow: hidden;
    flex: 0 0 157px;
    transition: flex 0.55s cubic-bezier(.4, 0, .2, 1);
    border-radius: 20px;
    background: #fff;
}
.core-tab.active { flex: 1 1 0%; }
.core-tab img.tab-bg {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.core-tab .tab-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(28, 173, 195, 0.00) 0%, #018E86 100%);
}
.core-tab .tab-label-collapsed {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    display: flex;
    color: #FFFBFB;
    text-align: center;
    font-size: 20px;
    font-weight: 500;
    line-height: normal;
    align-items: center;
    height: 100%;
    justify-content: center;
    padding-bottom: 20px;
    opacity: 1;
    transition: opacity 0.3s;
    letter-spacing: 2px;
}
.core-tab.active .tab-label-collapsed { opacity: 0; pointer-events: none; }
.core-tab .tab-content-expanded {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 36px 48px;
    opacity: 0;
    transition: opacity 0.4s 0.1s;
    pointer-events: none;
}
.core-tab.active .tab-content-expanded { opacity: 1; pointer-events: auto; }
.core-tab .tab-title { color: #FFFBFB; text-align: center; font-size: 48px; font-weight: 500; text-transform: uppercase; }
.core-tab .tab-desc { color: #FFF; text-align: center; font-size: 18px; font-weight: 500; line-height: 150%; }

@media (max-width: 768px) {
    .core-values-tabs { flex-direction: column; height: auto !important; }
    .core-tab { flex: 0 0 60px; height: 60px; border-radius: 12px; }
    .core-tab.active { flex: 0 0 360px; height: 360px; }
    .core-tab .tab-label-collapsed { font-size: 18px; }
    .core-tab .tab-title { font-size: 36px; }
    .core-tab .tab-desc { font-size: 15px; }
}

/* ===== HISTORY SECTION BACKGROUNDS ===== */
.roadmap-section__bg {
    position: absolute;
    inset: 0;
    background-position: center;
    background-size: cover;
    background-image: url('https://c.animaapp.com/mnr7un3zyH8Y3r/img/rectangle-21866.png');
}
.roadmap-section__overlay {
    position: absolute;
    inset: 0;
    pointer-events: none;
    background:
        linear-gradient(90deg, rgb(1, 142, 134) 0%, rgba(9, 88, 126, 0) 70%),
        linear-gradient(270deg, rgba(0, 0, 0, 0.16) 0%, rgba(0, 0, 0, 0.5) 100%);
}

.aboutHistory {
    background-position: center center;
    background-repeat: no-repeat;
    background-size: cover;
    overflow-x: hidden;
    overflow-y: visible;
    padding-bottom: clamp(24px, 4vw, 48px);
}

.aboutHistory__copy {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
}

.aboutHistory__title {
    color: #FFF;
    font-size: 40px;
    font-weight: 700;
    line-height: normal;
    text-align: left;
    margin: 0;
}

.aboutHistory__text {
    color: #FFF;
    text-align: left;
    font-size: 18px;
    font-weight: 500;
    line-height: 1.55;
    max-width: 926px;
    margin-top: 0;
}

.aboutHistory__wrap {
    overflow-x: auto;
    overflow-y: visible;
    max-width: 100%;
    scrollbar-width: none;
    user-select: none;
    cursor: grab;
    -webkit-overflow-scrolling: touch;
    touch-action: pan-x;
    /* Chừa chỗ để năm (scale) + popup không bị cắt mép trên/dưới */
    padding-top: clamp(20px, 3vw, 40px);
    padding-bottom: clamp(16px, 2.5vw, 32px);
    /* Thêm lề trái trong vùng scroll, tránh sát mép viewport / overflow section */
    padding-inline-start: clamp(4px, 1.5vw, 12px);
}

.aboutHistory__wrap.is-dragging,
.aboutHistory__wrap.is-dragging * {
    cursor: grabbing !important;
}

.aboutHistory__wrap::-webkit-scrollbar {
    width: 0;
    height: 0;
}

.aboutHistory__box {
    display: flex;
    flex-wrap: nowrap;
    align-items: flex-start;
    width: max-content;
    min-width: min-content;
    column-gap: 20px;
    padding-bottom: 200px;
    padding-top: 100px;
    padding-inline-start: clamp(28px, 5vw, 35px);
    padding-inline-end: clamp(32px, 6vw, 120px);
    box-sizing: content-box;
}

.aboutHistory__box .item {
    display: flex;
    flex-shrink: 0;
    flex-grow: 0;
    width: 260px;
    min-width: 260px;
    position: relative;
    gap: 20px;
    z-index: 1;
}

.aboutHistory__box .item:hover {
    z-index: 20;
}

.aboutHistory__box .item::after {
    content: "";
    flex-grow: 1;
    display: block;
    height: 32px;
    background-image: url('../images/line_svg.svg');
    background-position: center center;
    background-repeat: no-repeat;
    background-size: 100%;
}

.aboutHistory__box .item__time {
    position: absolute;
    display: block;
    width: fit-content;
    left: 50%;
    bottom: calc(100% + 12px);
    transform: translateX(-50%);
    transform-origin: center bottom;
    transition: .15s ease-in-out;
    color: #FFF;
    font-size: 24px;
    font-weight: 700;
    line-height: 1.5;
}

.aboutHistory__box .item__inner {
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    position: relative;
    padding: 0px 0px 232px;
    width: 4px;
}

.aboutHistory__box .item__inner::before,
.aboutHistory__box .item__inner::after {
    content: "";
    position: absolute;
    display: block;
    left: 50%;
    transform: translateX(-50%);
    transition: .15s ease-in-out;
}

.aboutHistory__box .item__inner::before {
    width: 4px;
    height: 64px;
    border-radius: 9rem;
    background: #fff;
    top: 0;
    box-shadow: 0px 4px 4px 0px rgba(0, 0, 0, 0.25);
}

.aboutHistory__box .item__inner::after {
    width: 29px;
    height: 38px;
    background-image: url('../images/Vector.png');
    background-position: center center;
    background-repeat: no-repeat;
    background-size: 100%;
    top: 88px;
}

.aboutHistory__box .item__content {
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    width: max-content;
    max-width: 430px;
    transition: .15s ease-in-out;
    opacity: 0;
    pointer-events: none;
    z-index: 2;
    padding-top: 8px;
}

.aboutHistory__box .item:first-child .item__content {
    left: 0;
    transform: none;
    max-width: min(430px, calc(100vw - 32px));
}

.aboutHistory__box .item:first-child .item__title,
.aboutHistory__box .item:first-child .item__text {
    text-align: left;
}

.aboutHistory__box .item__title {
    color: #FFF;
    text-align: center;
    font-size: 32px;
    font-weight: 600;
    line-height: 1.3;
}

.aboutHistory__box .item__text {
    color: #FFF;
    text-align: center;
    font-size: 20px;
    font-weight: 400;
    line-height: 1.2;
    letter-spacing: 0.5px;
}

/* Hover: scale năm nhưng vẫn căn giữa cột */
.aboutHistory__box .item:hover .item__time {
    transform: translateX(-50%) scale(1.35);
    color: #B8F0EC;
    text-shadow: 0 1px 12px rgba(28, 173, 195, 0.55);
}

.aboutHistory__box .item:hover .item__inner::before {
    height: 160px;
    background: linear-gradient(180deg, #1CADC3 0%, #018E86 100%);
    box-shadow: 0 4px 16px rgba(28, 173, 195, 0.45);
}

.aboutHistory__box .item:hover .item__inner::after {
    top: 184px;
    transform: translateX(-50%);
}

.aboutHistory__box .item:hover .item__content {
    opacity: 1;
    pointer-events: auto;
}

/* RESPONSIVE FALLBACKS */
@media (max-width: 575px) {
    .aboutHistory__title { font-size: 22px; }
    .aboutHistory__text { font-size: 16px; }
    .aboutHistory__box .item__title { font-size: 20px; }
    .aboutHistory__box .item__content { font-size: 16px; max-width: calc(100vw - 24px); }
}

/* FOOTER RESPONSIVE */
@media (max-width: 1024px) {
    .footer-grid { grid-template-columns: repeat(2, 1fr) !important; gap: 32px !important; }
}
@media (max-width: 640px) {
    .footer-grid { grid-template-columns: 1fr !important; }
}

/* STATS RESPONSIVE */
@media (max-width: 1024px) {
    .stats-grid { grid-template-columns: repeat(2, 1fr) !important; }
}
@media (max-width: 600px) {
    .stats-grid { grid-template-columns: 1fr !important; }
}
