/* about-responsive.css - Premium Responsive Layer */

/* ── Global Touch Fixes ── */
@media (hover: none) and (pointer: coarse) {

    #cursor-dot,
    #cursor-ring {
        display: none !important;
    }

    body {
        cursor: auto !important;
    }
}

/* ── Tablet & Small Laptops (Up to 1024px) ── */
@media (max-width: 1024px) {
    .unified-timeline {
        max-width: 90%;
    }

    .cv-grid {
        grid-template-columns: 1fr;
        gap: 4rem;
    }

    /* 991px adjustments from about.php */
    .unified-timeline::before {
        left: 40px;
        transform: none;
    }

    .year-bubble {
        left: 40px;
        transform: translateX(-50%);
        width: 60px;
        height: 60px;
        font-size: 0.75rem;
    }

    .timeline-row {
        justify-content: flex-start !important;
        padding-left: 80px !important;
    }

    .timeline-content-wrap {
        width: 100% !important;
    }

    .timeline-row::after {
        left: 40px !important;
        right: auto !important;
        width: 15px !important;
        display: block !important;
    }
}

/* ── Mobile & Tablet Small (Up to 768px) ── */
@media (max-width: 768px) {

    /* ── nav-inner: logo left, toggle far right ── */
    header .nav-inner {
        display: flex !important;
        align-items: center;
        justify-content: space-between;
        width: 100%;
    }

    header .nav-inner>nav {
        display: flex;
        align-items: center;
        justify-content: flex-end;
        flex: 1;
    }

    /* ── Hamburger far right ── */
    .menu-toggle {
        display: flex !important;
        flex-direction: column;
        align-items: flex-end;
        gap: 5px;
        z-index: 9001 !important;
        cursor: pointer;
        padding: 8px;
        border: 1px solid transparent;
        border-radius: 8px;
        position: absolute;
        right: 4vw;
        top: 50%;
        transform: translateY(-50%);
        transition: border-color 0.3s, background 0.3s;
    }

    .menu-toggle:hover {
        border-color: rgba(212, 175, 55, 0.25);
        background: rgba(212, 175, 55, 0.05);
    }

    .menu-toggle span {
        display: block;
        border-radius: 2px;
        background: var(--gold);
        transition: all 0.45s cubic-bezier(0.23, 1, 0.32, 1);
    }

    .menu-toggle span:nth-child(1) {
        width: 26px;
        height: 1.5px;
    }

    .menu-toggle span:nth-child(2) {
        width: 18px;
        height: 1.5px;
        opacity: 0.55;
    }

    .menu-toggle span:nth-child(3) {
        width: 22px;
        height: 1.5px;
    }

    .menu-toggle.active span:nth-child(1) {
        width: 22px;
        transform: translateY(6.5px) rotate(45deg);
        opacity: 1;
    }

    .menu-toggle.active span:nth-child(2) {
        opacity: 0;
        transform: scaleX(0);
    }

    .menu-toggle.active span:nth-child(3) {
        width: 22px;
        transform: translateY(-6.5px) rotate(-45deg);
        opacity: 1;
    }

    /* ── Scroll lock ── */
    body.menu-open {
        overflow: hidden !important;
    }

    /* ── Full-Screen Overlay (transform-based) ── */
    .nav-links {
        display: flex !important;
        position: fixed;
        top: 0;
        left: 0;
        width: 100vw;
        height: 100vh;
        flex-direction: column;
        justify-content: center;
        align-items: center;
        gap: 0;
        background: rgba(2, 5, 12, 0.97);
        backdrop-filter: blur(60px);
        -webkit-backdrop-filter: blur(60px);
        transform: translateX(100%);
        transition: transform 0.9s cubic-bezier(0.76, 0, 0.24, 1);
        z-index: 8500;
        visibility: visible !important;
        padding: 0 !important;
        overflow: hidden;
        list-style: none;
        counter-reset: zenith-counter;
    }

    .nav-links.active {
        transform: translateX(0);
    }

    /* Grid layer */
    .nav-links::before {
        content: '';
        position: absolute;
        inset: 0;
        background-image:
            linear-gradient(rgba(212, 175, 55, 0.03) 1px, transparent 1px),
            linear-gradient(90deg, rgba(212, 175, 55, 0.03) 1px, transparent 1px);
        background-size: 60px 60px;
        z-index: 0;
        pointer-events: none;
    }

    /* Blob layer */
    .nav-links::after {
        content: '';
        position: absolute;
        inset: 0;
        background:
            radial-gradient(ellipse at 20% 25%, rgba(212, 175, 55, 0.12) 0%, transparent 50%),
            radial-gradient(ellipse at 80% 70%, rgba(0, 180, 255, 0.07) 0%, transparent 50%),
            radial-gradient(ellipse at 55% 5%, rgba(130, 0, 220, 0.05) 0%, transparent 45%);
        animation: zenithAtmos 25s ease-in-out infinite alternate;
        z-index: 0;
        pointer-events: none;
    }

    @keyframes zenithAtmos {
        0% {
            transform: scale(1) rotate(0deg);
        }

        50% {
            transform: scale(1.1) rotate(6deg);
        }

        100% {
            transform: scale(1.05) rotate(-4deg);
        }
    }

    /* Nav items */
    .nav-links>li {
        position: relative;
        z-index: 1;
        width: 100%;
        text-align: center;
        opacity: 0;
        transform: translateY(30px);
        filter: blur(6px);
        transition: opacity 0.8s cubic-bezier(0.23, 1, 0.32, 1),
            transform 0.8s cubic-bezier(0.23, 1, 0.32, 1),
            filter 0.8s cubic-bezier(0.23, 1, 0.32, 1);
        padding: 0.8rem 0;
        list-style: none;
    }

    .nav-links>li:not(:last-child) {
        counter-increment: zenith-counter;
    }

    .nav-links.active>li {
        opacity: 1;
        transform: translateY(0);
        filter: blur(0);
    }

    .nav-links.active>li:nth-child(1) {
        transition-delay: 0.15s;
    }

    .nav-links.active>li:nth-child(2) {
        transition-delay: 0.25s;
    }

    .nav-links.active>li:nth-child(3) {
        transition-delay: 0.35s;
    }

    .nav-links.active>li:nth-child(4) {
        transition-delay: 0.45s;
    }

    .nav-links.active>li:last-child {
        transition-delay: 0.6s;
    }

    /* Link with inline number */
    .nav-links>li:not(:last-child)>a {
        font-family: 'Playfair Display', Georgia, serif !important;
        font-size: 1rem;
        font-weight: 500;
        line-height: 1.2;
        letter-spacing: 0.1em;
        text-transform: uppercase;
        color: rgba(240, 235, 220, 0.9) !important;
        text-decoration: none !important;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        gap: 0.6em;
        position: relative;
        transition: color 0.3s ease, letter-spacing 0.3s ease, transform 0.3s ease;
    }

    .nav-links>li:not(:last-child)>a::before {
        content: counter(zenith-counter, decimal-leading-zero);
        font-family: 'Space Mono', monospace;
        font-size: 0.5em;
        font-weight: 400;
        font-style: normal;
        letter-spacing: 4px;
        color: var(--gold);
        opacity: 0.6;
        flex-shrink: 0;
    }

    .nav-links>li:not(:last-child)>a::after {
        content: '';
        position: absolute;
        bottom: -2px;
        left: 50%;
        width: 0;
        height: 1px;
        background: linear-gradient(90deg, transparent, var(--gold), transparent);
        transform: translateX(-50%);
        transition: width 0.4s ease;
    }

    .nav-links>li:not(:last-child)>a:hover {
        color: var(--gold) !important;
        letter-spacing: 0.12em;
        transform: scale(1.03);
    }

    .nav-links>li:not(:last-child)>a:hover::after {
        width: 50%;
    }

    /* Lang switcher */
    .nav-links>li:last-child {
        margin-top: 2rem;
        padding: 1.5rem 1rem 0;
        border-top: 1px solid rgba(212, 175, 55, 0.1);
        width: 60%;
        text-align: center;
        list-style: none;
    }

    .nav-links>li:last-child .lang-switcher {
        display: flex !important;
        justify-content: center;
        align-items: center;
        gap: 1.5rem;
        margin: 0 !important;
    }

    .nav-links>li:last-child .lang-btn {
        display: flex;
        align-items: center;
        gap: 0.4rem;
        font-family: 'Space Mono', monospace;
        font-size: 0.68rem;
        letter-spacing: 3px;
        color: rgba(255, 255, 255, 0.4) !important;
        text-decoration: none;
        text-transform: uppercase;
        transition: color 0.3s;
    }

    .nav-links>li:last-child .lang-btn.active,
    .nav-links>li:last-child .lang-btn:hover {
        color: var(--gold) !important;
    }

    /* Page Hero */
    .page-hero {
        padding-top: 8rem;
        min-height: auto;
    }

    .page-hero h1 {
        font-size: 2.8rem;
    }

    .hero-stats-row {
        display: grid !important;
        grid-template-columns: 1fr 1fr;
        gap: 1rem;
    }

    .stat-item {
        padding: 1.2rem;
    }

    /* Bio Section */
    .bio-grid {
        grid-template-columns: 1fr;
        gap: 2.5rem;
    }

    .bio-avatar {
        position: static;
    }

    .bio-avatar-card {
        padding: 2rem;
    }

    .bio-text-card {
        padding: 1.5rem;
    }

    /* Unified Timeline - Mobile Layout */
    .unified-timeline::before {
        left: 20px;
        transform: none;
    }

    .year-bubble {
        left: 20px;
        transform: none;
        width: 44px;
        height: 44px;
        font-size: 0.65rem;
    }

    .timeline-row {
        justify-content: flex-start !important;
        padding-left: 45px !important;
        text-align: left !important;
    }

    .timeline-content {
        width: 100% !important;
        max-width: 100% !important;
        border-radius: 15px !important;
        margin: 0 !important;
    }

    .timeline-icon-box {
        left: -38px !important;
        right: auto !important;
        top: 15px !important;
    }

    .timeline-items-container {
        padding-left: 0;
    }

    /* Awards */
    .award-banner {
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
        border-radius: 15px;
    }

    .award-banner>i {
        font-size: 1.5rem;
    }

    /* Courses */
    .courses-grid {
        grid-template-columns: 1fr;
    }

    /* Expertise Tags */
    .exp-tags {
        display: grid !important;
        grid-template-columns: 1fr 1fr;
        gap: 0.8rem;
        margin-top: 2rem;
    }

    .exp-tag {
        font-size: 0.65rem !important;
        padding: 0.5rem 0.2rem !important;
        text-align: center;
        justify-content: center;
        display: flex;
        align-items: center;
        width: 100%;
        line-height: 1.2;
        overflow-wrap: anywhere;
        word-break: break-all;
    }
}

/* ── Mobile Small (Up to 480px) ── */
@media (max-width: 480px) {
    .page-hero h1 {
        font-size: 2.2rem;
    }

    .philo-quote p {
        font-size: 1.2rem;
    }

    .bio-avatar-card,
    .bio-text-card {
        padding: 1.5rem;
    }

    .avatar-circle {
        width: 110px;
        height: 110px;
    }

    .timeline-content {
        padding: 1.2rem !important;
    }
}

.menu-toggle {
    display: none;
}