/**
 * EDVICE Atlas product showcases — device frames + UI mocks.
 * Drop real screenshots into assets/atlas-screenshots/ and set img.atlas-screenshot src.
 */

/* ——— Feature row layouts ——— */

.edv-feature-row {
    padding: var(--edv-space-xl) 0;
    overflow: hidden;
}

.edv-feature-row--alt {
    background: rgba(90, 0, 255, 0.04);
}

.edv-section--dark.edv-feature-row--alt {
    background: rgba(242, 247, 242, 0.04);
}

.edv-feature-row__copy h3 {
    font-family: var(--edv-font);
    font-size: var(--edv-text-2xl);
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: var(--edv-space-sm);
}

.edv-feature-row__copy p {
    font-size: var(--edv-text-base);
    line-height: 1.65;
    color: var(--edv-muted);
    margin-bottom: var(--edv-space-md);
}

.edv-section--dark .edv-feature-row__copy p {
    color: var(--edv-muted-on-dark);
}

.edv-feature-row__tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: var(--edv-space-md);
}

.edv-tag {
    font-family: var(--edv-font);
    font-size: 0.7rem;
    font-weight: 600;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    padding: 0.35rem 0.75rem;
    border-radius: 999px;
    background: rgba(0, 211, 80, 0.15);
    color: var(--edv-dark);
}

.edv-section--dark .edv-tag {
    background: rgba(0, 211, 80, 0.2);
    color: var(--edv-cream);
}

@media (min-width: 992px) {
    .edv-feature-row--reverse .edv-feature-row__visual {
        order: 2;
    }

    .edv-feature-row--reverse .edv-feature-row__copy {
        order: 1;
    }
}

/* ——— Device frames ——— */

.atlas-device {
    position: relative;
    margin: 0 auto;
    max-width: 100%;
}

.atlas-device--portal {
    border-radius: 16px;
    overflow: hidden;
    background: #f4f6f4;
    border: 1px solid rgba(14, 9, 35, 0.08);
    box-shadow:
        0 0 0 1px rgba(0, 211, 80, 0.06),
        0 20px 50px rgba(14, 9, 35, 0.1);
}

.atlas-device--portal .atlas-device__screen {
    border-radius: 16px;
    aspect-ratio: 16 / 10;
}

.atlas-device--browser {
    border-radius: var(--edv-radius-lg);
    box-shadow: var(--edv-shadow-glow), var(--edv-shadow-md);
    background: var(--edv-dark);
    padding: 0.65rem 0.65rem 0;
}

.atlas-device--browser .atlas-device__bar {
    display: flex;
    gap: 0.35rem;
    padding-bottom: 0.55rem;
}

.atlas-device--browser .atlas-device__dot {
    width: 9px;
    height: 9px;
    border-radius: 50%;
    background: rgba(242, 247, 242, 0.22);
}

.atlas-device--browser .atlas-device__dot--active {
    background: var(--edv-green);
}

.atlas-device__screen {
    position: relative;
    border-radius: var(--edv-radius-md) var(--edv-radius-md) 0 0;
    overflow: hidden;
    background: #f4f6f4;
    aspect-ratio: 16 / 10;
    min-height: 220px;
}

.atlas-screenshot {
    position: absolute;
    inset: 0;
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: top left;
}

.atlas-device__screen:has(.atlas-screenshot) .atlas-mock-ui {
    display: none !important;
}

@media (max-width: 991px) {
    .atlas-device__screen {
        aspect-ratio: 16 / 11;
        min-height: 200px;
    }
}

@media (max-width: 575px) {
    .atlas-device__screen {
        aspect-ratio: 4 / 3;
        min-height: 180px;
    }
}

.atlas-device--laptop {
    padding: 1.25rem 1.25rem 0.75rem;
    background: linear-gradient(145deg, #1a1535, #0e0923);
    border-radius: 14px 14px 0 0;
    max-width: 520px;
}

.atlas-device--laptop::after {
    content: "";
    display: block;
    height: 12px;
    margin: 0.75rem -1.25rem -0.75rem;
    background: linear-gradient(180deg, #2a2548, #0e0923);
    border-radius: 0 0 8px 8px;
}

.atlas-device--mobile {
    max-width: 240px;
    padding: 0.5rem;
    background: var(--edv-dark);
    border-radius: 28px;
    box-shadow: var(--edv-shadow-md);
}

.atlas-device--mobile .atlas-device__screen {
    border-radius: 22px;
    aspect-ratio: 9 / 16;
    min-height: 320px;
}

.atlas-device--float {
    transform: perspective(900px) rotateY(-6deg) rotateX(2deg);
}

/* ——— CSS UI mocks (fallback when no screenshot) ——— */

.atlas-mock-ui {
    position: absolute;
    inset: 0;
    padding: 1rem;
    font-family: var(--edv-font);
    font-size: 0.65rem;
    color: var(--edv-dark);
    background: #f8faf8;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.atlas-mock-ui__top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid var(--edv-border);
}

.atlas-mock-ui__brand {
    font-weight: 700;
    color: var(--edv-indigo);
    font-size: 0.7rem;
}

.atlas-mock-ui__nav {
    display: flex;
    gap: 0.35rem;
}

.atlas-mock-ui__pill {
    padding: 0.2rem 0.45rem;
    border-radius: 99px;
    background: rgba(90, 0, 255, 0.08);
    color: var(--edv-indigo);
}

.atlas-mock-ui__pill--active {
    background: var(--edv-indigo);
    color: #fff;
}

.atlas-mock-ui__grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0.4rem;
    flex: 1;
}

.atlas-mock-ui__stat {
    background: #fff;
    border: 1px solid var(--edv-border);
    border-radius: 8px;
    padding: 0.5rem;
}

.atlas-mock-ui__stat strong {
    display: block;
    font-size: 1rem;
    color: var(--edv-indigo);
}

.atlas-mock-ui__list {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
    flex: 1;
}

.atlas-mock-ui__row {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    background: #fff;
    border: 1px solid var(--edv-border);
    border-radius: 8px;
    padding: 0.45rem 0.55rem;
}

.atlas-mock-ui__avatar {
    width: 1.5rem;
    height: 1.5rem;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--edv-green), var(--edv-indigo));
    flex-shrink: 0;
}

.atlas-mock-ui__bar {
    flex: 1;
    height: 5px;
    border-radius: 99px;
    background: rgba(0, 211, 80, 0.2);
    overflow: hidden;
}

.atlas-mock-ui__bar span {
    display: block;
    height: 100%;
    background: var(--edv-green);
    border-radius: 99px;
}

.atlas-mock-ui__search {
    display: flex;
    gap: 0.35rem;
    margin-bottom: 0.35rem;
}

.atlas-mock-ui__input {
    flex: 1;
    height: 1.75rem;
    border-radius: 8px;
    border: 1px solid var(--edv-border);
    background: #fff;
    padding: 0 0.5rem;
    display: flex;
    align-items: center;
    color: rgba(14, 9, 35, 0.4);
}

.atlas-mock-ui__btn {
    height: 1.75rem;
    padding: 0 0.6rem;
    border-radius: 8px;
    background: var(--edv-green);
    display: flex;
    align-items: center;
    font-weight: 600;
}

/* ——— Metrics strip ——— */

.edv-metrics {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: var(--edv-space-md);
}

@media (min-width: 768px) {
    .edv-metrics {
        grid-template-columns: repeat(4, 1fr);
    }
}

.edv-metric {
    text-align: center;
    padding: var(--edv-space-lg) var(--edv-space-sm);
    border-radius: var(--edv-radius-md);
    background: var(--edv-surface-card);
    border: 1px solid var(--edv-border);
}

.edv-section--dark .edv-metric {
    background: var(--edv-surface-card-dark);
    border-color: var(--edv-border-dark);
}

.edv-metric__value {
    font-family: var(--edv-font);
    font-size: clamp(1.75rem, 4vw, 2.5rem);
    font-weight: 700;
    color: var(--edv-indigo);
    line-height: 1;
    margin-bottom: 0.35rem;
}

.edv-section--dark .edv-metric__value {
    color: var(--edv-green);
}

.edv-metric__label {
    font-size: var(--edv-text-sm);
    color: var(--edv-muted);
    line-height: 1.4;
}

.edv-section--dark .edv-metric__label {
    color: var(--edv-muted-on-dark);
}

/* ——— Timeline ——— */

.edv-timeline {
    position: relative;
    padding-left: 1.5rem;
    border-left: 2px solid rgba(90, 0, 255, 0.2);
}

.edv-section--dark .edv-timeline {
    border-left-color: rgba(0, 211, 80, 0.35);
}

.edv-timeline__item {
    position: relative;
    padding-bottom: var(--edv-space-lg);
}

.edv-timeline__item::before {
    content: "";
    position: absolute;
    left: -1.65rem;
    top: 0.35rem;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: var(--edv-green);
    box-shadow: 0 0 0 3px rgba(0, 211, 80, 0.25);
}

.edv-timeline__step {
    font-size: var(--edv-text-xs);
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--edv-indigo);
    margin-bottom: 0.25rem;
}

.edv-section--dark .edv-timeline__step {
    color: var(--edv-green);
}

.edv-timeline__title {
    font-family: var(--edv-font);
    font-size: var(--edv-text-lg);
    font-weight: 700;
    margin-bottom: 0.35rem;
}

/* ——— FAQ ——— */

.edv-faq {
    max-width: 720px;
    margin: 0 auto;
}

.edv-faq__item {
    border-bottom: 1px solid var(--edv-border);
}

.edv-section--dark .edv-faq__item {
    border-bottom-color: var(--edv-border-dark);
}

.edv-faq__question {
    width: 100%;
    text-align: left;
    background: none;
    border: none;
    font-family: var(--edv-font);
    font-size: var(--edv-text-base);
    font-weight: 600;
    padding: var(--edv-space-md) 2rem var(--edv-space-md) 0;
    position: relative;
    cursor: pointer;
    color: inherit;
}

.edv-faq__question::after {
    content: "+";
    position: absolute;
    right: 0;
    top: 50%;
    transform: translateY(-50%);
    font-size: 1.25rem;
    color: var(--edv-indigo);
    transition: transform var(--edv-transition);
}

.edv-section--dark .edv-faq__question::after {
    color: var(--edv-green);
}

.edv-faq__item.is-open .edv-faq__question::after {
    transform: translateY(-50%) rotate(45deg);
}

.edv-faq__answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.35s ease, padding 0.35s ease;
    font-size: var(--edv-text-sm);
    line-height: 1.6;
    color: var(--edv-muted);
}

.edv-section--dark .edv-faq__answer {
    color: var(--edv-muted-on-dark);
}

.edv-faq__item.is-open .edv-faq__answer {
    max-height: 12rem;
    padding-bottom: var(--edv-space-md);
}

/* ——— Final CTA band ——— */

.edv-cta-band {
    text-align: center;
    padding: var(--edv-section-pad-y, 4rem) var(--edv-space-md);
    background: linear-gradient(135deg, var(--edv-indigo) 0%, #3d00aa 100%);
    color: var(--edv-cream);
}

.edv-cta-band__title {
    font-family: var(--edv-font);
    font-size: var(--edv-text-3xl);
    font-weight: 700;
    margin-bottom: var(--edv-space-sm);
}

.edv-cta-band__lead {
    font-size: var(--edv-text-lg);
    opacity: 0.9;
    max-width: 36rem;
    margin: 0 auto var(--edv-space-lg);
}

/* ——— Counsellor cards ——— */

.edv-counsellor-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--edv-space-md);
}

@media (min-width: 768px) {
    .edv-counsellor-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

.edv-counsellor-card {
    background: var(--edv-surface-card);
    border: 1px solid var(--edv-border);
    border-radius: var(--edv-radius-md);
    padding: var(--edv-space-lg);
    text-align: center;
}

.edv-section--dark .edv-counsellor-card {
    background: var(--edv-surface-card-dark);
    border-color: var(--edv-border-dark);
}

.edv-counsellor-card__icon {
    font-size: 1.75rem;
    margin-bottom: var(--edv-space-sm);
}

/* ——— Adaptive header logo ——— */

#logo-figure {
    position: relative;
    transition: opacity 0.35s ease;
}

#logo-figure .edvice-logo-variant {
    transition: opacity 0.4s ease, transform 0.4s ease;
}

#logo-figure .edvice-logo-variant--light {
    opacity: 1;
}

#logo-figure .edvice-logo-variant--green {
    position: absolute;
    top: 0;
    left: 0;
    opacity: 0;
    pointer-events: none;
}

#logo-figure .edvice-logo-variant--dark,
#logo-figure .edvice-logo-variant--color {
    position: absolute;
    top: 0;
    left: 0;
    opacity: 0;
    pointer-events: none;
}

body[data-logo-tone="green"] header {
    color: var(--edv-green);
}

body[data-logo-tone="light"] header {
    color: var(--edv-cream);
}

body[data-logo-tone="green"] #logo-type,
body[data-logo-tone="green"] .edv-header-title {
    color: var(--edv-green);
}

body[data-logo-tone="light"] #logo-type,
body[data-logo-tone="light"] .edv-header-title {
    color: var(--edv-cream);
}

body[data-logo-tone="green"] header .hamburger-inner,
body[data-logo-tone="green"] header .hamburger-inner::before,
body[data-logo-tone="green"] header .hamburger-inner::after {
    background-color: var(--edv-green);
}

body[data-logo-tone="light"] header .hamburger-inner,
body[data-logo-tone="light"] header .hamburger-inner::before,
body[data-logo-tone="light"] header .hamburger-inner::after {
    background-color: var(--edv-cream);
}

body[data-logo-tone="green"] #logo-figure .edvice-logo-variant--light {
    opacity: 0;
}

body[data-logo-tone="green"] #logo-figure .edvice-logo-variant--green {
    opacity: 1;
    pointer-events: auto;
}

body[data-logo-tone="green"] #logo-figure .edvice-logo-variant--dark,
body[data-logo-tone="green"] #logo-figure .edvice-logo-variant--color {
    opacity: 0;
    pointer-events: none;
}

body[data-logo-tone="light"]:not(.nav-is-active) #logo-figure .edvice-logo-variant--dark,
body[data-logo-tone="light"]:not(.nav-is-active) #logo-figure .edvice-logo-variant--green,
body[data-logo-tone="light"]:not(.nav-is-active) #logo-figure .edvice-logo-variant--color {
    opacity: 0;
    pointer-events: none;
}

body[data-logo-tone="light"]:not(.nav-is-active) #logo-figure .edvice-logo-variant--light {
    opacity: 1;
    pointer-events: auto;
}

body[data-logo-tone="dark"]:not(.nav-is-active) #logo-figure .edvice-logo-variant--light,
body[data-logo-tone="dark"]:not(.nav-is-active) #logo-figure .edvice-logo-variant--green,
body[data-logo-tone="dark"]:not(.nav-is-active) #logo-figure .edvice-logo-variant--color {
    opacity: 0;
    pointer-events: none;
}

body[data-logo-tone="dark"]:not(.nav-is-active) #logo-figure .edvice-logo-variant--dark {
    opacity: 1;
    pointer-events: auto;
}

/* Nav open — full brand logo (dark wordmark + green/purple mark) */
body.nav-is-active #logo-figure .edvice-logo-variant--light,
body.nav-is-active #logo-figure .edvice-logo-variant--green,
body.nav-is-active #logo-figure .edvice-logo-variant--dark {
    opacity: 0 !important;
    pointer-events: none;
}

body.nav-is-active #logo-figure .edvice-logo-variant--color {
    opacity: 1 !important;
    pointer-events: auto;
}

body.nav-is-active header {
    color: var(--edv-dark);
}

body.nav-is-active #logo-type,
body.nav-is-active .edv-header-title {
    color: var(--edv-dark);
}

body.nav-is-active header .hamburger-inner,
body.nav-is-active header .hamburger-inner::before,
body.nav-is-active header .hamburger-inner::after {
    background-color: var(--edv-green);
}

/* Hero study-abroad badge */
.edv-hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-family: var(--edv-font);
    font-size: var(--edv-text-xs);
    font-weight: 600;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--edv-cream);
    background: rgba(14, 9, 35, 0.45);
    border: 1px solid rgba(242, 247, 242, 0.25);
    border-radius: 999px;
    padding: 0.45rem 1rem;
    margin-bottom: var(--edv-space-sm);
}

.edv-hero-badge__dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--edv-green);
    animation: edv-pulse 2s ease infinite;
}

@keyframes edv-pulse {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.6; transform: scale(0.85); }
}
