/* ============================================
   ATR INSTITUTIONAL WEBSITE - EXTENDED STYLES
   Builds on top of simple.css design system
   ============================================ */

/* ===== SMOOTH SCROLL & PAGE TRANSITIONS ===== */
html {
    scroll-behavior: smooth;
}

body {
    opacity: 1;
    transition: opacity 0.4s ease;
}

body.page-loading {
    opacity: 0;
}

/* ===== ENHANCED TYPOGRAPHY ===== */
.text-gold {
    color: var(--gold);
}

.text-white {
    color: var(--white);
}

.text-muted {
    color: var(--gray-dark);
}

/* ===== NAVIGATION - INSTITUTIONAL ===== */
.nav-inst {
    display: flex;
    align-items: center;
    gap: 32px;
    flex: 1;
    justify-content: flex-end;
    margin-left: 48px;
}

.nav-inst-links {
    display: flex;
    gap: 28px;
    list-style: none;
}

.nav-inst-links a {
    color: var(--gray);
    font-size: 0.9rem;
    font-weight: 500;
    transition: color 0.2s ease;
    position: relative;
}

.nav-inst-links a::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--gold);
    transition: width 0.3s ease;
}

.nav-inst-links a:hover {
    color: var(--white);
}

.nav-inst-links a:hover::after {
    width: 100%;
}

.nav-inst-links a.active {
    color: var(--gold);
}

.nav-inst-links a.active::after {
    width: 100%;
}

/* ===== PAGE HERO - VARIATIONS ===== */
.page-hero {
    min-height: 80vh;
    display: flex;
    align-items: center;
    padding-top: 120px;
    padding-bottom: 80px;
    position: relative;
    z-index: 1;
    background: var(--black);
    overflow: hidden;
}

.page-hero--short {
    min-height: 50vh;
    padding-bottom: 60px;
}

.page-hero--full {
    min-height: 100vh;
}

/* Hero with background image */
.page-hero--img {
    position: relative;
}

.page-hero__bg {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center;
    opacity: 0.15;
    z-index: 0;
}

.page-hero__bg::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg,
            rgba(9, 9, 11, 0.4) 0%,
            rgba(9, 9, 11, 0.8) 60%,
            rgba(9, 9, 11, 1) 100%);
}

.page-hero .container {
    position: relative;
    z-index: 2;
}

.page-hero__content {
    max-width: 800px;
}

.page-hero--center .page-hero__content {
    max-width: 900px;
    margin: 0 auto;
    text-align: center;
}

.page-hero h1 {
    font-size: clamp(2.5rem, 5.5vw, 4rem);
    margin-bottom: 24px;
    line-height: 1.1;
}

.page-hero h1 .highlight {
    color: var(--gold);
}

.page-hero__subtitle {
    font-size: clamp(1.1rem, 2vw, 1.3rem);
    color: var(--gray-light);
    line-height: 1.8;
    margin-bottom: 36px;
    max-width: 700px;
}

.page-hero--center .page-hero__subtitle {
    margin-left: auto;
    margin-right: auto;
}

/* ===== SECTION VARIATIONS ===== */
.section--dark {
    background: var(--black-surface);
}

.section--gradient {
    background: linear-gradient(180deg, var(--black) 0%, var(--black-surface) 50%, var(--black) 100%);
}

.section--gold-accent {
    position: relative;
}

.section--gold-accent::before {
    content: '';
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 120px;
    height: 2px;
    background: linear-gradient(90deg, transparent, var(--gold), transparent);
}

/* ===== SPLIT LAYOUT (Text + Image 50/50) ===== */
.split {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 80px;
    align-items: center;
}

.split--reverse {
    direction: rtl;
}

.split--reverse>* {
    direction: ltr;
}

.split__text {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.split__text h2 {
    margin-bottom: 8px;
}

.split__text p {
    line-height: 1.8;
    color: var(--gray-light);
}

.split__text ul {
    margin-top: 8px;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.split__text li {
    padding-left: 8px;
    border-left: 2px solid var(--gold);
    color: var(--gray-light);
    line-height: 1.6;
}

.split__text li strong {
    color: var(--white);
    display: block;
    margin-bottom: 4px;
}

.split__image {
    position: relative;
    border-radius: 20px;
    overflow: hidden;
}

.split__image img {
    width: 100%;
    height: auto;
    display: block;
    border-radius: 20px;
    border: 1px solid rgba(212, 175, 55, 0.2);
}

.split__image--glow {
    box-shadow: 0 20px 60px rgba(212, 175, 55, 0.08);
}

/* ===== STATS BAR ===== */
.stats-bar {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 0;
    padding: 48px 0;
    border-top: 1px solid var(--border);
    border-bottom: 1px solid var(--border);
}

.stats-bar__item {
    text-align: center;
    padding: 16px 24px;
    position: relative;
}

.stats-bar__item:not(:last-child)::after {
    content: '';
    position: absolute;
    right: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 1px;
    height: 48px;
    background: rgba(212, 175, 55, 0.3);
}

.stats-bar__value {
    display: block;
    font-size: clamp(2.5rem, 4vw, 3.5rem);
    font-weight: 700;
    color: var(--gold);
    font-family: var(--font-heading);
    line-height: 1;
    margin-bottom: 8px;
}

.stats-bar__label {
    font-size: 0.85rem;
    color: var(--gray);
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

/* ===== QUOTE / MANIFESTO BLOCK ===== */
.quote-block {
    max-width: 900px;
    margin: 0 auto;
    text-align: center;
    padding: 80px 40px;
    position: relative;
}

.quote-block::before {
    content: '"';
    position: absolute;
    top: 20px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 6rem;
    color: var(--gold);
    opacity: 0.15;
    font-family: var(--font-heading);
    line-height: 1;
}

.quote-block__text {
    font-size: clamp(1.3rem, 2.5vw, 1.8rem);
    font-family: var(--font-heading);
    font-weight: 600;
    color: var(--white);
    line-height: 1.5;
    margin-bottom: 24px;
}

.quote-block__author {
    font-size: 0.9rem;
    color: var(--gold);
    font-weight: 600;
    letter-spacing: 0.05em;
    text-transform: uppercase;
}

.quote-block__tagline {
    font-size: 1rem;
    color: var(--gray);
    margin-top: 16px;
    font-style: italic;
}

/* ===== PHILOSOPHY CARDS ===== */
.philosophy-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 32px;
}

.philosophy-card {
    background: var(--black-card);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 40px 32px;
    text-align: center;
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.philosophy-card:hover {
    border-color: var(--gold);
    transform: translateY(-6px);
    box-shadow: 0 16px 40px rgba(0, 0, 0, 0.3);
}

.philosophy-card__icon {
    width: 64px;
    height: 64px;
    margin: 0 auto 20px;
    background: var(--gold-subtle);
    border: 1px solid rgba(212, 175, 55, 0.3);
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.8rem;
}

.philosophy-card h3 {
    font-size: 1.2rem;
    margin-bottom: 12px;
}

.philosophy-card p {
    font-size: 0.95rem;
    line-height: 1.7;
}

/* ===== ATR CYCLE (A - T - R) ===== */
.atr-cycle {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0;
    position: relative;
    margin: 60px 0;
}

.atr-cycle::before {
    content: '';
    position: absolute;
    top: 40px;
    left: 10%;
    right: 10%;
    height: 2px;
    background: linear-gradient(90deg, var(--gold), rgba(212, 175, 55, 0.3), var(--gold));
    z-index: 0;
}

.atr-cycle__step {
    text-align: center;
    position: relative;
    z-index: 1;
    padding: 0 24px;
}

.atr-cycle__letter {
    width: 80px;
    height: 80px;
    margin: 0 auto 20px;
    background: var(--black);
    border: 2px solid var(--gold);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    font-weight: 700;
    color: var(--gold);
    font-family: var(--font-heading);
    transition: all 0.3s ease;
}

.atr-cycle__step:hover .atr-cycle__letter {
    background: var(--gold);
    color: var(--black);
    box-shadow: 0 0 30px rgba(212, 175, 55, 0.3);
}

.atr-cycle__step h3 {
    font-size: 1.2rem;
    margin-bottom: 8px;
    margin-top: 16px;
}

.atr-cycle__step p {
    font-size: 0.95rem;
    line-height: 1.6;
    color: var(--gray-light);
}

/* ===== PILLARS SECTION (5 alternating) ===== */
.pillar-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
    padding: 60px 0;
    border-bottom: 1px solid var(--border);
}

.pillar-row:last-child {
    border-bottom: none;
}

.pillar-row--reverse {
    direction: rtl;
}

.pillar-row--reverse>* {
    direction: ltr;
}

.pillar-row__number {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    background: var(--gold-subtle);
    border: 1px solid rgba(212, 175, 55, 0.3);
    border-radius: 8px;
    font-family: var(--font-heading);
    font-weight: 700;
    font-size: 0.9rem;
    color: var(--gold);
    margin-bottom: 16px;
}

.pillar-row__text h3 {
    font-size: 1.5rem;
    margin-bottom: 16px;
}

.pillar-row__text p {
    line-height: 1.8;
    color: var(--gray-light);
}

.pillar-row__image {
    border-radius: 16px;
    overflow: hidden;
    border: 1px solid rgba(212, 175, 55, 0.15);
}

.pillar-row__image img {
    width: 100%;
    height: 280px;
    object-fit: cover;
    display: block;
    transition: transform 0.5s ease;
}

.pillar-row:hover .pillar-row__image img {
    transform: scale(1.03);
}

/* ===== TIMELINE ===== */
.timeline-inst {
    max-width: 700px;
    margin: 0 auto;
    position: relative;
    padding-left: 40px;
}

.timeline-inst::before {
    content: '';
    position: absolute;
    left: 15px;
    top: 0;
    bottom: 0;
    width: 2px;
    background: linear-gradient(180deg, var(--gold), rgba(212, 175, 55, 0.2));
}

.timeline-inst__item {
    position: relative;
    padding-bottom: 48px;
    padding-left: 32px;
}

.timeline-inst__item:last-child {
    padding-bottom: 0;
}

.timeline-inst__dot {
    position: absolute;
    left: -32px;
    top: 4px;
    width: 14px;
    height: 14px;
    background: var(--gold);
    border-radius: 50%;
    border: 3px solid var(--black);
    box-shadow: 0 0 0 3px var(--gold);
}

.timeline-inst__badge {
    display: inline-block;
    padding: 4px 12px;
    background: var(--gold-subtle);
    border-radius: 100px;
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--gold);
    text-transform: uppercase;
    letter-spacing: 0.08em;
    margin-bottom: 8px;
}

.timeline-inst__item h4 {
    font-size: 1.15rem;
    margin-bottom: 8px;
}

.timeline-inst__item p {
    font-size: 0.95rem;
    line-height: 1.7;
    color: var(--gray-light);
}

/* ===== FIT TABLE (For who / Not for who) ===== */
.fit-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 32px;
}

.fit-col {
    background: var(--black-card);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 40px 32px;
}

.fit-col--yes {
    border-color: rgba(212, 175, 55, 0.3);
}

.fit-col--no {
    border-color: rgba(255, 80, 80, 0.2);
}

.fit-col h3 {
    font-size: 1.2rem;
    margin-bottom: 24px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.fit-col--yes h3 {
    color: var(--gold);
}

.fit-col--no h3 {
    color: #ff6b6b;
}

.fit-col ul {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.fit-col li {
    padding-left: 8px;
    font-size: 0.95rem;
    line-height: 1.5;
}

.fit-col--yes li::before {
    content: '✓ ';
    color: var(--gold);
    font-weight: 700;
}

.fit-col--no li::before {
    content: '✗ ';
    color: #ff6b6b;
    font-weight: 700;
}

/* ===== CONTACT FORM ===== */
.contact-grid {
    display: grid;
    grid-template-columns: 1.2fr 0.8fr;
    gap: 60px;
    align-items: start;
}

.contact-form {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.form-group label {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--gray);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.form-group input,
.form-group textarea {
    padding: 14px 18px;
    background: var(--black-card);
    border: 1px solid var(--border);
    border-radius: 10px;
    color: var(--white);
    font-family: var(--font-body);
    font-size: 1rem;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--gold);
    box-shadow: 0 0 0 3px rgba(212, 175, 55, 0.1);
}

.form-group textarea {
    resize: vertical;
    min-height: 120px;
}

.form-group input::placeholder,
.form-group textarea::placeholder {
    color: var(--gray-dark);
}

/* Contact Channels */
.contact-channels {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.channel-card {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 20px 24px;
    background: var(--black-card);
    border: 1px solid var(--border);
    border-radius: 12px;
    transition: all 0.25s ease;
    text-decoration: none;
}

.channel-card:hover {
    border-color: var(--gold);
    transform: translateX(4px);
}

.channel-card__icon {
    width: 48px;
    height: 48px;
    background: var(--gold-subtle);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.4rem;
    flex-shrink: 0;
}

.channel-card__info h4 {
    font-size: 1rem;
    margin-bottom: 2px;
    color: var(--white);
}

.channel-card__info p {
    font-size: 0.85rem;
    color: var(--gray);
}

/* ===== SOCIAL LINKS ===== */
.social-row {
    display: flex;
    gap: 16px;
    margin-top: 16px;
}

.social-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 24px;
    background: var(--black-card);
    border: 1px solid var(--border);
    border-radius: 100px;
    color: var(--gray-light);
    font-size: 0.9rem;
    font-weight: 500;
    transition: all 0.25s ease;
}

.social-link:hover {
    border-color: var(--gold);
    color: var(--gold);
}

.social-link svg {
    width: 18px;
    height: 18px;
}

/* ===== SCROLL REVEAL ANIMATIONS ===== */
.reveal {
    opacity: 0;
    transform: translateY(30px);
    /* Transition is now handled completely by GSAP for buttery smooth physics */
}

.reveal.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Delays are now handled by GSAP stagger */

.reveal--delay-3 {
    transition-delay: 0.3s;
}

.reveal--delay-4 {
    transition-delay: 0.4s;
}

/* ===== IMAGE PLACEHOLDER ===== */
.img-placeholder {
    background: linear-gradient(135deg, var(--black-card) 0%, var(--black-elevated) 100%);
    border: 1px dashed rgba(212, 175, 55, 0.3);
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--gray-dark);
    font-size: 0.85rem;
    font-style: italic;
    min-height: 300px;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 1024px) {

    .split,
    .pillar-row {
        grid-template-columns: 1fr;
        gap: 40px;
    }

    .split--reverse,
    .pillar-row--reverse {
        direction: ltr;
    }

    .stats-bar {
        grid-template-columns: repeat(2, 1fr);
        gap: 24px;
    }

    .stats-bar__item:nth-child(2)::after {
        display: none;
    }

    .contact-grid {
        grid-template-columns: 1fr;
    }

    .fit-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .page-hero {
        padding-top: 160px;
        padding-bottom: 60px;
        min-height: auto;
    }

    .page-hero h1 {
        font-size: clamp(2rem, 7vw, 2.8rem);
    }

    .nav-inst-links {
        display: none;
    }

    .nav-inst .btn {
        display: none;
    }

    .menu-toggle {
        display: flex;
    }

    .philosophy-grid {
        grid-template-columns: 1fr;
    }

    .atr-cycle {
        grid-template-columns: 1fr;
        gap: 40px;
    }

    .atr-cycle::before {
        display: none;
    }

    .stats-bar {
        grid-template-columns: 1fr 1fr;
    }

    .stats-bar__item::after {
        display: none;
    }

    .hero-ctas {
        flex-direction: column;
    }

    .hero-ctas .btn {
        width: 100%;
        justify-content: center;
    }

    .social-row {
        flex-direction: column;
    }

    .quote-block {
        padding: 60px 20px;
    }
}

/* ===== SWUP PAGE TRANSITIONS ===== */
.transition-fade {
    transition: opacity 0.4s ease-out;
    opacity: 1;
}

html.is-animating .transition-fade {
    opacity: 0;
}

/* ===== MAGNETIC BUTTONS & TILT CARDS ===== */
.magnetic-btn {
    /* JS will transform this */
    will-change: transform;
}

.tilt-card {
    will-change: transform;
    transform-style: preserve-3d;
}

/* Fix cursor for Swup loading */
html.is-animating {
    cursor: wait;
}