/* =========================================================
   IMAN — BARISTA PORTFOLIO
   Mobile-first. Dark, warm, glass, slow. RTL Persian.
   Created by MasoodRajabi codebymasood@gmail.com and AmirFakhar 
   ========================================================= */

:root {
    /* --- color tokens --- */
    --bg: #0f0f0f;
    --bg-soft: #161210;
    --surface: #1c1714;
    --surface-2: #221b16;
    --coffee: #6f4e37;
    --coffee-deep: #46301f;
    --gold: #c58a46;
    --cream: #f6f2eb;
    --accent: #d9a441;
    --line: rgba(246, 242, 235, 0.09);
    --shadow-1: 0 20px 60px rgba(0, 0, 0, 0.55);
    --shadow-2: 0 8px 24px rgba(0, 0, 0, 0.4);
    /* --- type --- */
    --font-display: "Vazirmatn", Tahoma, sans-serif;
    --font-body: "Estedad", Tahoma, sans-serif;
    /* --- motion --- */
    --ease: cubic-bezier(0.16, 0.84, 0.34, 1);
    --ease-soft: cubic-bezier(0.4, 0, 0.2, 1);
    --container: 1140px;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    background: var(--bg);
    color: var(--cream);
    font-family: var(--font-body);
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
    line-height: 1.85;
}

    body.no-scroll {
        overflow: hidden;
        height: 100vh;
    }

h1,
h2,
h3 {
    font-family: var(--font-display);
    margin: 0;
    color: var(--cream);
}

p {
    margin: 0;
}

a {
    color: inherit;
    text-decoration: none;
}

img,
svg {
    display: block;
    max-width: 100%;
}

button {
    font-family: inherit;
    cursor: pointer;
    background: none;
    border: none;
    color: inherit;
}

input,
textarea {
    font-family: inherit;
}

::selection {
    background: var(--coffee);
    color: var(--cream);
}

:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 3px;
    border-radius: 4px;
}

@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.001ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.001ms !important;
        scroll-behavior: auto !important;
    }
}

.container {
    width: 100%;
    max-width: var(--container);
    margin-inline: auto;
    padding-inline: 24px;
}

.section {
    position: relative;
    padding: 96px 0;
}

.eyebrow {
    font-size: 0.8rem;
    letter-spacing: 0.04em;
    color: var(--gold);
    margin-bottom: 10px;
    font-weight: 500;
}

    .eyebrow.centered {
        text-align: center;
    }

.section-title {
    font-size: clamp(1.7rem, 5vw, 2.6rem);
    font-weight: 800;
    line-height: 1.35;
    margin-bottom: 40px;
}

    .section-title.centered {
        text-align: center;
        max-width: 560px;
        margin-inline: auto;
        margin-bottom: 56px;
    }

.glass-card {
    background: linear-gradient( 155deg, rgba(255, 255, 255, 0.05), rgba(255, 255, 255, 0.015) );
    border: 1px solid var(--line);
    border-radius: 22px;
    backdrop-filter: blur(18px) saturate(140%);
    -webkit-backdrop-filter: blur(18px) saturate(140%);
    box-shadow: var(--shadow-1), inset 0 1px 0 rgba(255, 255, 255, 0.05);
    padding: 28px;
    overflow: auto;
}

/* ===================== BUTTON ===================== */
.btn-primary {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 16px 30px;
    border-radius: 100px;
    background: linear-gradient(135deg, var(--gold), var(--coffee));
    color: #1a120b;
    font-weight: 700;
    font-size: 0.98rem;
    box-shadow: 0 12px 30px rgba(197, 138, 70, 0.25), inset 0 1px 0 rgba(255, 255, 255, 0.3);
    transition: transform 0.45s var(--ease), box-shadow 0.45s var(--ease);
    position: relative;
    overflow: hidden;
}

    .btn-primary:hover {
        transform: translateY(-3px) scale(1.02);
        box-shadow: 0 18px 40px rgba(197, 138, 70, 0.4), inset 0 1px 0 rgba(255, 255, 255, 0.35);
    }

    .btn-primary:active {
        transform: translateY(0) scale(0.98);
    }

.cta-arrow {
    width: 16px;
    height: 16px;
    transition: transform 0.4s var(--ease);
}

.btn-primary:hover .cta-arrow {
    transform: translateY(3px);
}

/* =========================================================
   LOADING SCREEN
   ========================================================= */
.loader {
    position: fixed;
    inset: 0;
    z-index: 999;
    background: radial-gradient(circle at 50% 40%, #181210 0%, #0a0807 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: opacity 0.9s var(--ease-soft), visibility 0.9s;
}

    .loader.is-done {
        opacity: 0;
        visibility: hidden;
        pointer-events: none;
    }

.loader-inner {
    text-align: center;
}

.loader-cup {
    width: 120px;
    height: 130px;
    margin-inline: auto;
    overflow: visible;
}

.cup-outline {
    fill: none;
    stroke: var(--gold);
    stroke-width: 2.4;
    stroke-linecap: round;
    opacity: 0.85;
}

#loaderLiquid {
    transition: y 0.25s linear, height 0.25s linear;
}

.steam-path {
    fill: none;
    stroke: var(--cream);
    stroke-width: 2;
    stroke-linecap: round;
    opacity: 0;
}

.steam-group .s1 {
    animation: steamRise 2.6s ease-in-out infinite;
    animation-delay: 0.1s;
}

.steam-group .s2 {
    animation: steamRise 2.6s ease-in-out infinite;
    animation-delay: 0.6s;
}

.steam-group .s3 {
    animation: steamRise 2.6s ease-in-out infinite;
    animation-delay: 1.1s;
}

@keyframes steamRise {
    0% {
        opacity: 0;
        transform: translateY(6px) scaleY(0.8);
    }

    35% {
        opacity: 0.55;
    }

    100% {
        opacity: 0;
        transform: translateY(-14px) scaleY(1.15);
    }
}

.loader-text {
    margin-top: 22px;
    font-size: 0.98rem;
    color: var(--cream);
    letter-spacing: 0.01em;
    opacity: 0.85;
}

.loader-percent {
    margin-top: 8px;
    font-family: var(--font-display);
    font-weight: 800;
    font-size: 1.6rem;
    color: var(--accent);
    direction: ltr;
}

.percent-sign {
    font-size: 1rem;
    margin-inline-start: 2px;
    opacity: 0.7;
}

/* =========================================================
   EXTRACTION TUBE — signature scroll progress element
   A thin pour of coffee that fills as the story unfolds.
   ========================================================= */
.extraction-tube {
    position: fixed;
    inset-inline-end: 14px;
    top: 0;
    height: 100vh;
    width: 14px;
    z-index: 60;
    display: none; /* enabled from tablet breakpoint up, see below */
    flex-direction: column;
    align-items: center;
    pointer-events: none;
}

.tube-glass {
    position: relative;
    width: 5px;
    flex: 1;
    margin-top: 28px;
    margin-bottom: 6px;
    background: rgba(246, 242, 235, 0.06);
    border-radius: 6px;
    overflow: hidden;
    box-shadow: inset 0 0 0 1px rgba(246, 242, 235, 0.08);
}

.tube-fill {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 0%;
    background: linear-gradient(180deg, var(--gold), var(--coffee-deep));
    border-radius: 6px 6px 0 0;
    transition: height 0.12s linear;
}

.crema {
    position: absolute;
    top: -2px;
    left: -2px;
    right: -2px;
    height: 4px;
    background: radial-gradient( circle, rgba(246, 242, 235, 0.55) 0%, transparent 70% );
    filter: blur(0.5px);
    animation: cremaDrift 3s ease-in-out infinite;
}

@keyframes cremaDrift {
    0%, 100% {
        transform: translateX(-1px);
    }

    50% {
        transform: translateX(1px);
    }
}

.tube-cup {
    width: 18px;
    height: 16px;
    fill: none;
    stroke: var(--gold);
    stroke-width: 2;
    opacity: 0.8;
}

@media (min-width: 768px) {
    .extraction-tube {
        display: flex;
    }
}

/* =========================================================
   FLOATING BRAND MARK
   ========================================================= */
.brand-mark {
    position: fixed;
    top: 22px;
    inset-inline-start: 24px;
    z-index: 50;
    font-family: var(--font-display);
    font-weight: 800;
    font-size: 1.05rem;
    color: var(--cream);
    opacity: 0;
    transform: translateY(-8px);
    transition: opacity 0.5s var(--ease), transform 0.5s var(--ease);
    letter-spacing: 0.01em;
}

    .brand-mark::after {
        content: "";
        display: inline-block;
        width: 6px;
        height: 6px;
        border-radius: 50%;
        background: var(--accent);
        margin-inline-start: 8px;
        vertical-align: middle;
        box-shadow: 0 0 10px var(--accent);
    }

    .brand-mark.is-visible {
        opacity: 1;
        transform: translateY(0);
    }

/* =========================================================
   HERO
   ========================================================= */
.hero {
    position: relative;
    min-height: 100vh;
    min-height: 100dvh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 0 24px;
    overflow: hidden;
}

.hero-bg {
    position: absolute;
    inset: 0;
    z-index: 0;
}

.bg-glow {
    position: absolute;
    border-radius: 50%;
    filter: blur(80px);
    opacity: 0.35;
    animation: glowDrift 18s ease-in-out infinite;
}

.glow-1 {
    width: 60vw;
    height: 60vw;
    max-width: 520px;
    max-height: 520px;
    background: var(--coffee);
    top: -10%;
    inset-inline-start: -15%;
}

.glow-2 {
    width: 50vw;
    height: 50vw;
    max-width: 440px;
    max-height: 440px;
    background: var(--gold);
    bottom: -15%;
    inset-inline-end: -10%;
    animation-delay: -9s;
}

@keyframes glowDrift {
    0%, 100% {
        transform: translate(0, 0) scale(1);
    }

    50% {
        transform: translate(30px, -20px) scale(1.12);
    }
}

.particles-canvas {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    opacity: 0.6;
}

.hero-content {
    position: relative;
    z-index: 2;
    max-width: 680px;
}

.hero-eyebrow {
    font-size: 0.85rem;
    color: var(--gold);
    letter-spacing: 0.06em;
    margin-bottom: 18px;
    font-weight: 500;
}

.hero-name {
    font-size: clamp(3.4rem, 17vw, 7.5rem);
    font-weight: 900;
    line-height: 1;
    color: var(--cream);
    margin-bottom: 18px;
    background: linear-gradient(135deg, var(--cream) 40%, var(--gold) 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

    .hero-name .word {
        display: inline-block;
    }

.hero-roles {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    font-size: clamp(1.1rem, 3vw, 1.5rem);
    font-weight: 700;
    color: var(--cream);
    margin-bottom: 14px;
    flex-wrap: wrap;
}

.hero-divider {
    color: var(--gold);
    opacity: 0.6;
}

.hero-tagline {
    font-size: 1.02rem;
    color: rgba(246, 242, 235, 0.7);
    margin-bottom: 38px;
}

/* word-reveal entrance: blur + rise, staggered by --d index */
.reveal-word {
    opacity: 0;
    transform: translateY(18px);
    filter: blur(6px);
    animation: wordReveal 0.9s var(--ease) forwards;
    animation-delay: calc(var(--d, 0) * 0.18s + 0.15s);
}

@keyframes wordReveal {
    to {
        opacity: 1;
        transform: translateY(0);
        filter: blur(0);
    }
}

.hero-name .word {
    opacity: 0;
    transform: translateY(24px) scale(0.96);
    filter: blur(10px);
    animation: nameReveal 1.1s var(--ease) forwards;
    animation-delay: 0.05s;
}

@keyframes nameReveal {
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
        filter: blur(0);
    }
}

.hero-cta {
    animation-delay: 0.85s;
}

.scroll-hint {
    position: absolute;
    bottom: 34px;
    inset-inline-start: 50%;
    transform: translateX(50%);
    z-index: 2;
}

.scroll-line {
    display: block;
    width: 1px;
    height: 46px;
    background: linear-gradient(180deg, var(--gold), transparent);
    position: relative;
    overflow: hidden;
}

    .scroll-line::after {
        content: "";
        position: absolute;
        top: -46px;
        left: 0;
        width: 1px;
        height: 46px;
        background: var(--cream);
        animation: scrollDrip 2.4s ease-in-out infinite;
    }

@keyframes scrollDrip {
    0% {
        top: -46px;
    }

    100% {
        top: 46px;
    }
}

/* =========================================================
   SCROLL-REVEAL base (applied via JS IntersectionObserver)
   Each section overrides the actual transform/filter so the
   motion language differs per section, per design brief.
   ========================================================= */
[data-reveal] {
    opacity: 0;
    transition: opacity 0.9s var(--ease), transform 0.9s var(--ease), filter 0.9s var(--ease);
    will-change: transform, opacity, filter;
}

    [data-reveal].is-visible {
        opacity: 1;
    }

/* ===================== ABOUT ===================== */
.about-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 48px;
    align-items: center;
}

.about-portrait {
    display: flex;
    justify-content: center;
}

.portrait-frame {
    position: relative;
    max-width: 300px;
    width: 100%;
}

.portrait-placeholder {
    position: relative;
    border-radius: 20px;
    overflow: hidden;
    box-shadow: var(--shadow-1);
    border: 1px solid var(--line);
}

    .portrait-placeholder svg {
        width: 100%;
        height: auto;
    }

.portrait-label {
    position: absolute;
    bottom: 14px;
    inset-inline-start: 14px;
    font-size: 0.75rem;
    color: rgba(246, 242, 235, 0.55);
    background: rgba(0, 0, 0, 0.35);
    padding: 4px 10px;
    border-radius: 100px;
    backdrop-filter: blur(6px);
}

.portrait-steam {
    position: absolute;
    top: -30px;
    inset-inline-end: 30%;
    width: 60px;
    height: 80px;
    background: radial-gradient( ellipse at center, rgba(246, 242, 235, 0.12), transparent 70% );
    filter: blur(8px);
    animation: portraitSteam 5s ease-in-out infinite;
    pointer-events: none;
}

@keyframes portraitSteam {
    0%, 100% {
        opacity: 0.4;
        transform: translateY(0);
    }

    50% {
        opacity: 0.9;
        transform: translateY(-14px);
    }
}

[data-reveal="about-portrait"] {
    transform: translateX(-26px) scale(0.94);
    filter: blur(8px);
}

    [data-reveal="about-portrait"].is-visible {
        transform: translateX(0) scale(1);
        filter: blur(0);
    }

[data-reveal="about-card"] {
    transform: translateX(26px);
    filter: blur(10px);
    clip-path: inset(0 0 0 0);
}

    [data-reveal="about-card"].is-visible {
        transform: translateX(0);
        filter: blur(0);
    }

.about-card p {
    margin-bottom: 16px;
    color: rgba(246, 242, 235, 0.85);
}

    .about-card p:last-child {
        margin-bottom: 0;
    }

/* ===================== SKILLS ===================== */
.skills-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 18px;
}

@media (min-width: 560px) {
    .skills-grid {
        grid-template-columns: 1fr 1fr;
    }
}

@media (min-width: 900px) {
    .skills-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

.skill-card {
    position: relative;
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: 18px;
    padding: 26px 20px;
    text-align: center;
    overflow: hidden;
    transition: transform 0.5s var(--ease), box-shadow 0.5s var(--ease), border-color 0.5s var(--ease);
}

    .skill-card:hover,
    .skill-card:focus-within {
        transform: translateY(-8px) rotate(-0.6deg);
        box-shadow: 0 22px 50px rgba(197, 138, 70, 0.18);
        border-color: rgba(197, 138, 70, 0.4);
    }

.skill-icon {
    width: 38px;
    height: 38px;
    color: var(--gold);
    margin-inline: auto;
    margin-bottom: 14px;
    transition: transform 0.5s var(--ease), color 0.5s var(--ease);
}

.skill-card:hover .skill-icon {
    transform: scale(1.12) rotate(4deg);
    color: var(--accent);
}

.skill-card h3 {
    font-size: 1.02rem;
    font-weight: 700;
    margin-bottom: 8px;
}

.skill-card p {
    font-size: 0.85rem;
    color: rgba(246, 242, 235, 0.6);
    line-height: 1.7;
}

.skill-steam {
    position: absolute;
    top: -10px;
    inset-inline-start: 50%;
    width: 2px;
    height: 30px;
    background: linear-gradient(180deg, rgba(246, 242, 235, 0.5), transparent);
    opacity: 0;
    transition: opacity 0.4s;
    filter: blur(1px);
}

.skill-card:hover .skill-steam {
    opacity: 1;
    animation: skillSteam 1.6s ease-in-out infinite;
}

@keyframes skillSteam {
    0% {
        transform: translateY(8px) scaleY(0.7);
        opacity: 0;
    }

    50% {
        opacity: 0.7;
    }

    100% {
        transform: translateY(-16px) scaleY(1.2);
        opacity: 0;
    }
}

[data-reveal^="skill-"] {
    transform: translateY(36px) rotate(2deg);
}

    [data-reveal^="skill-"].is-visible {
        transform: translateY(0) rotate(0);
    }

/* ===================== TIMELINE ===================== */
.timeline {
    position: relative;
    max-width: 680px;
    margin-inline: auto;
    padding-inline-start: 0;
}

.timeline-line {
    position: absolute;
    top: 6px;
    bottom: 6px;
    inset-inline-start: 7px;
    width: 2px;
    background: rgba(246, 242, 235, 0.08);
    border-radius: 2px;
    overflow: hidden;
}

.timeline-line-fill {
    display: block;
    width: 100%;
    height: 0%;
    background: linear-gradient(180deg, var(--gold), var(--coffee));
    transition: height 0.25s linear;
}

.timeline-item {
    position: relative;
    padding-inline-start: 38px;
    margin-bottom: 38px;
}

    .timeline-item:last-child {
        margin-bottom: 0;
    }

.timeline-dot {
    position: absolute;
    inset-inline-start: 0;
    top: 6px;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: var(--bg);
    border: 2px solid var(--gold);
    box-shadow: 0 0 0 4px var(--bg);
    transition: background 0.4s, box-shadow 0.4s;
}

.timeline-item.is-visible .timeline-dot {
    background: var(--accent);
    box-shadow: 0 0 0 4px var(--bg), 0 0 16px rgba(217, 164, 65, 0.6);
}

.timeline-card {
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: 16px;
    padding: 20px 22px;
}

.timeline-year {
    font-size: 0.74rem;
    color: var(--gold);
    letter-spacing: 0.03em;
}

.timeline-card h3 {
    font-size: 1.08rem;
    font-weight: 700;
    margin: 6px 0 8px;
}

.timeline-card p {
    font-size: 0.9rem;
    color: rgba(246, 242, 235, 0.65);
}

[data-reveal^="tl-"] {
    transform: translateX(28px);
    filter: blur(4px);
}

    [data-reveal^="tl-"].is-visible {
        transform: translateX(0);
        filter: blur(0);
    }

@media (min-width: 768px) {
    [data-reveal="tl-1"],
    [data-reveal="tl-3"] {
        transform: translateX(28px);
    }

    [data-reveal="tl-2"],
    [data-reveal="tl-4"] {
        transform: translateX(-28px);
    }
}

/* ===================== GALLERY ===================== */
.masonry {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
}

@media (min-width: 700px) {
    .masonry {
        grid-template-columns: repeat(3, 1fr);
        gap: 16px;
    }
}

.masonry-item {
    position: relative;
    margin: 0;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: var(--shadow-2);
}

.masonry-ph {
    overflow: hidden;
}

    .masonry-ph svg {
        width: 100%;
        height: auto;
        display: block;
        transition: transform 0.7s var(--ease);
    }

.masonry-item:hover .masonry-ph svg {
    transform: scale(1.12);
}

.masonry-item::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient( 180deg, transparent 40%, rgba(70, 48, 31, 0.85) 100% );
    opacity: 0.7;
    transition: opacity 0.5s;
}

.masonry-item:hover::after {
    opacity: 0.92;
}

.masonry-item figcaption {
    position: absolute;
    bottom: 0;
    inset-inline-start: 0;
    inset-inline-end: 0;
    padding: 14px;
    font-size: 0.82rem;
    font-weight: 500;
    transform: translateY(8px);
    opacity: 0.85;
    transition: transform 0.5s var(--ease);
}

.masonry-item:hover figcaption {
    transform: translateY(0);
    opacity: 1;
}

.mi-2,
.mi-4 {
    align-self: start;
}

@media (min-width: 700px) {
    .mi-1 {
        grid-row: span 1;
    }

    .mi-4 {
        grid-row: span 2;
    }
}

[data-reveal^="gal-"] {
    transform: scale(0.86);
    filter: blur(6px);
}

    [data-reveal^="gal-"].is-visible {
        transform: scale(1);
        filter: blur(0);
    }

/* ===================== INTERESTS ===================== */
.interests-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
}

@media (min-width: 600px) {
    .interests-grid {
        grid-template-columns: repeat(5, 1fr);
    }
}

.interest-card {
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: 18px;
    padding: 26px 12px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    font-weight: 600;
    font-size: 0.92rem;
    transition: transform 0.55s var(--ease), background 0.55s var(--ease), border-color 0.55s;
    transform-style: preserve-3d;
    perspective: 600px;
}

.interest-icon {
    width: 32px;
    height: 32px;
    color: var(--cream);
    transition: transform 0.55s var(--ease), color 0.55s;
}

.interest-card:hover {
    transform: translateY(-6px) rotateX(6deg);
    background: linear-gradient( 155deg, rgba(197, 138, 70, 0.16), rgba(197, 138, 70, 0.04) );
    border-color: rgba(197, 138, 70, 0.35);
}

    .interest-card:hover .interest-icon {
        transform: rotateY(180deg);
        color: var(--gold);
    }

[data-reveal^="int-"] {
    transform: translateY(30px) rotateX(-12deg);
}

    [data-reveal^="int-"].is-visible {
        transform: translateY(0) rotateX(0);
    }

/* ===================== QUOTE ===================== */
.quote-section {
    position: relative;
    padding: 120px 24px;
    text-align: center;
    max-width: 760px;
    margin-inline: auto;
}

.quote-mark {
    font-family: var(--font-display);
    font-size: 4rem;
    color: var(--coffee);
    line-height: 1;
    opacity: 0;
    transform: scale(0.5);
    transition: opacity 1s var(--ease), transform 1s var(--ease);
}

.quote-section.is-visible .quote-mark {
    opacity: 0.55;
    transform: scale(1);
}

.quote-mark-open {
    transform-origin: bottom;
    margin-bottom: -10px;
}

.quote-mark-close {
    transform: scale(0.5) rotate(180deg);
    margin-top: -10px;
}

.quote-section.is-visible .quote-mark-close {
    transform: scale(1) rotate(180deg);
}

.quote-text {
    display: block;
    font-family: var(--font-display);
    font-weight: 800;
    font-size: clamp(1.4rem, 4.4vw, 2.3rem);
    line-height: 1.7;
    color: var(--cream);
    filter: blur(8px);
    opacity: 0;
    transition: filter 1.1s var(--ease), opacity 1.1s var(--ease);
}

.quote-section.is-visible .quote-text {
    filter: blur(0);
    opacity: 1;
}

/* ===================== STATS ===================== */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 32px 16px;
    text-align: center;
}

@media (min-width: 700px) {
    .stats-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

.stat-item {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.stat-number {
    font-family: var(--font-display);
    font-weight: 900;
    font-size: clamp(2.1rem, 6vw, 3rem);
    color: var(--gold);
    direction: ltr;
}

.stat-plus {
    font-size: 1rem;
    color: var(--accent);
    font-weight: 700;
    margin-top: -4px;
}

.stat-label {
    margin-top: 8px;
    font-size: 0.88rem;
    color: rgba(246, 242, 235, 0.65);
}

/* ===================== CONTACT ===================== */
.contact-card {
    max-width: 780px;
    margin-inline: auto;
    padding: 34px 24px;
}

[data-reveal="contact-card"] {
    transform: translateY(30px);
    filter: blur(6px);
}

    [data-reveal="contact-card"].is-visible {
        transform: translateY(0);
        filter: blur(0);
    }

.contact-links {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
    margin-bottom: 34px;
}

@media (min-width: 560px) {
    .contact-links {
        grid-template-columns: repeat(3, 1fr);
    }
}

.contact-link {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 13px 14px;
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--line);
    font-size: 0.85rem;
    transition: transform 0.4s var(--ease), background 0.4s, border-color 0.4s;
}

    .contact-link svg {
        width: 19px;
        height: 19px;
        color: var(--gold);
        flex-shrink: 0;
        transition: transform 0.4s var(--ease);
    }

    .contact-link:hover {
        transform: translateY(-3px);
        background: rgba(197, 138, 70, 0.1);
        border-color: rgba(197, 138, 70, 0.3);
    }

        .contact-link:hover svg {
            transform: scale(1.15);
            color: var(--accent);
        }

.contact-form {
    display: flex;
    flex-direction: column;
    gap: 22px;
}

.field {
    position: relative;
}

    .field input,
    .field textarea {
        width: 100%;
        background: transparent;
        border: none;
        border-bottom: 1px solid rgba(246, 242, 235, 0.2);
        color: var(--cream);
        font-size: 1rem;
        padding: 10px 2px;
        resize: vertical;
    }

    .field textarea {
        min-height: 90px;
    }

    .field label {
        position: absolute;
        top: 10px;
        inset-inline-start: 2px;
        color: rgba(246, 242, 235, 0.5);
        font-size: 0.95rem;
        transition: top 0.35s var(--ease), font-size 0.35s var(--ease), color 0.35s var(--ease);
        pointer-events: none;
    }

    .field input:focus + label,
    .field input:not(:placeholder-shown) + label,
    .field textarea:focus + label,
    .field textarea:not(:placeholder-shown) + label {
        top: -26px;
        font-size: 0.78rem;
        color: var(--gold);
    }

.field-underline {
    position: absolute;
    bottom: 0;
    inset-inline-start: 0;
    height: 2px;
    width: 0;
    background: linear-gradient(90deg, var(--accent), var(--gold));
    transition: width 0.45s var(--ease);
}

.field input:focus ~ .field-underline,
.field textarea:focus ~ .field-underline {
    width: 100%;
}

.send-btn {
    align-self: flex-start;
    margin-top: 6px;
}

.send-icon {
    width: 16px;
    height: 16px;
    transition: transform 0.5s var(--ease);
}

.send-btn:hover .send-icon {
    transform: translateX(-3px) translateY(3px);
}

[dir="rtl"] .send-btn:hover .send-icon {
    transform: translateX(3px) translateY(-3px) scaleX(-1);
}

.form-success {
    font-size: 0.86rem;
    color: var(--accent);
    opacity:1;
    max-height: 0;
   /* overflow: hidden;*/
    transition: opacity 0.5s var(--ease), max-height 0.5s var(--ease);
}

    .form-success.is-shown {
        opacity: 1;
        max-height: 60px;
    }

/* ===================== FOOTER ===================== */
.footer {
    text-align: center;
    padding: 40px 24px 10px;
    color: rgba(246, 242, 235, 0.45);
    font-size: 0.88rem;
    border-top: 1px solid var(--line);
}

/* =========================================================
   RESPONSIVE: tablet & desktop refinements
   ========================================================= */
@media (min-width: 900px) {
    .about-grid {
        grid-template-columns: 0.85fr 1fr;
        gap: 64px;
    }

    .about-portrait {
        justify-content: flex-end;
    }

    .timeline-item {
        padding-inline-start: 0;
        width: 46%;
    }

    .timeline {
        display: flex;
        flex-direction: column;
    }

    .timeline-item:nth-child(even) {
        align-self: flex-start;
        margin-inline-start: 54px;
    }

    .timeline-item:nth-child(odd) {
        align-self: flex-end;
        margin-inline-end: 54px;
    }

    .timeline-line {
        inset-inline-start: 50%;
        transform: translateX(-1px);
    }

    .timeline-dot {
        inset-inline-start: auto;
    }

    .timeline-item:nth-child(even) .timeline-dot {
        inset-inline-end: -62px;
    }

    .timeline-item:nth-child(odd) .timeline-dot {
        inset-inline-start: -62px;
    }
}

@media (min-width: 1100px) {
    .section {
        padding: 130px 0;
    }
}

.login-page {
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
    overflow: hidden;
}

.login-wrapper {
    width: 100%;
    max-width: 430px;
    padding: 25px;
    position: relative;
    z-index: 5;
}

.login-card {
    padding: 40px;
}

    .login-card h2 {
        text-align: center;
        margin-bottom: 10px;
        font-size: 2rem;
    }

.login-subtitle {
    text-align: center;
    color: rgba(246,242,235,.65);
    margin-bottom: 35px;
}

.login-btn {
    width: 100%;
    justify-content: center;
    margin-top: 25px;
}

.login-error {
    margin-top: 15px;
    padding: 12px;
    border-radius: 12px;
    background: rgba(180,30,30,.15);
    border: 1px solid rgba(255,0,0,.25);
    color: #ffb0b0;
    text-align: center;
}

.form-success {
    font-size: 0.86rem;
    color: var(--accent);
    opacity: 3.4;
    max-height: 30px;
    overflow: hidden;
    transition: opacity 0.5s var(--ease), max-height 0.5s var(--ease);
}
.media-wrap {
    position: relative;
    width: 100%;
    height: 100%;
    overflow: hidden;
}

    .media-wrap video,
    .masonry-item img {
        width: 100%;
        height: 100%;
        object-fit: cover;
        display: block;
    }


.play-btn {
    position: absolute;
    inset: 50% auto auto 50%;
    transform: translate(-50%, -50%);
    width: 60px;
    height: 60px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255,255,255,.15);
    backdrop-filter: blur(8px);
    color: white;
    font-size: 22px;
    border: 1px solid rgba(255,255,255,.3);
}


.video-modal {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,.85);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 9999;
}


    .video-modal.active {
        display: flex;
    }


    .video-modal video {
        max-width: 90%;
        max-height: 85%;
        border-radius: 18px;
    }


.close-video {
    position: absolute;
    top: 30px;
    right: 40px;
    width: 45px;
    height: 45px;
    border-radius: 50%;
    border: none;
    background: white;
    color: #111;
    font-size: 30px;
    cursor: pointer;
}