@import url('https://cdn.jsdelivr.net/gh/rastikerdar/vazirmatn@v33.003/Vazirmatn-font-face.css');

:root {
    color-scheme: dark;
    --project-bg: #070b16;
    --project-panel: rgba(15, 23, 42, .78);
    --project-line: rgba(255, 255, 255, .09);
    --project-muted: #a7b0c2;
    --project-gold: #fbbf24;
}

html { scroll-behavior: smooth; background: var(--project-bg); }
body { margin: 0; background: radial-gradient(ellipse at 50% -18rem, rgba(217, 119, 6, .13), transparent 58%), var(--project-bg); color: #f8fafc; font-family: Vazirmatn, sans-serif; }
body.project-lightbox-open { overflow: hidden; }
button, a { -webkit-tap-highlight-color: transparent; }
.project-page-loading #projectLoading { animation: project-page-reveal .3s cubic-bezier(.16, 1, .3, 1) both; }
@keyframes project-page-reveal { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: translateY(0); } }
.project-header { position: relative; z-index: 3; padding: 1rem clamp(1rem, 4vw, 3.5rem) 0; }
.project-nav { display: flex; width: min(100%, 1280px); min-height: 72px; align-items: center; justify-content: space-between; gap: 1rem; margin-inline: auto; padding: .7rem 1rem; border: 1px solid var(--project-line); border-radius: 1.4rem; background: rgba(15, 23, 42, .78); box-shadow: 0 18px 70px rgba(0, 0, 0, .18); backdrop-filter: blur(20px); }
.project-brand { display: inline-flex; min-width: max-content; align-items: center; gap: .75rem; color: #fff; text-decoration: none; }
.project-brand-icon { display: grid; width: 2.8rem; height: 2.8rem; place-items: center; border: 1px solid rgba(251, 191, 36, .34); border-radius: 1rem; background: rgba(245, 158, 11, .13); color: var(--project-gold); font-size: 1.2rem; }
.project-brand strong, .project-brand small { display: block; }
.project-brand strong { font-size: .96rem; font-weight: 900; }
.project-brand small { margin-top: .16rem; color: var(--project-gold); font-size: .6rem; }
.project-nav-links { display: flex; align-items: center; gap: clamp(.8rem, 3vw, 2rem); }
.project-nav-links a { color: #cbd5e1; font-size: .75rem; font-weight: 700; text-decoration: none; transition: color .2s ease; }
.project-nav-links a:hover { color: var(--project-gold); }
.project-detail-main { width: min(100% - 2rem, 1200px); min-height: 70vh; margin-inline: auto; }
.project-loading, .project-error { display: grid; min-height: 62vh; align-content: center; justify-items: center; gap: 1rem; color: var(--project-muted); text-align: center; }
.project-loading-mark, .project-error-icon { display: grid; width: 4rem; height: 4rem; place-items: center; border: 1px solid rgba(251, 191, 36, .25); border-radius: 1.4rem; background: rgba(245, 158, 11, .1); color: var(--project-gold); font-size: 1.6rem; }
.project-error.hidden { display: none; }
.project-error h1 { margin: 0; color: #fff; font-size: clamp(1.5rem, 5vw, 2rem); }
.project-error p { margin: 0 0 .4rem; font-size: .9rem; }
.project-hero { position: relative; display: grid; grid-template-columns: minmax(0, .92fr) minmax(0, 1.08fr); align-items: center; gap: clamp(2rem, 5vw, 4.5rem); overflow-x: clip; padding: clamp(3rem, 8vw, 7rem) 0 2.25rem; }
.project-hero-glow { position: absolute; z-index: -1; top: 10%; right: -15%; width: 38rem; height: 30rem; border-radius: 50%; background: radial-gradient(circle, rgba(245, 158, 11, .105), transparent 68%); pointer-events: none; }
.project-hero-copy { position: relative; z-index: 1; }
.project-eyebrow, .project-section-kicker { display: block; color: var(--project-gold); font-size: .72rem; font-weight: 900; letter-spacing: .02em; }
.project-eyebrow { margin-top: 1.1rem; }
.project-hero h1 { max-width: 38rem; margin: .8rem 0 0; color: #fff; font-size: clamp(2rem, 5vw, 4.15rem); font-weight: 950; line-height: 1.35; }
.project-meta { margin: .8rem 0 0; color: #eabf64; font-size: .85rem; font-weight: 700; }
.project-intro { max-width: 42rem; margin: 1.35rem 0 0; color: #bdc5d3; font-size: clamp(.9rem, 1.35vw, 1rem); line-height: 2.15; }
.project-hero-actions { display: flex; flex-wrap: wrap; gap: .7rem; margin-top: 1.7rem; }
.project-primary-link, .project-secondary-link { display: inline-flex; min-height: 2.9rem; align-items: center; justify-content: center; gap: .55rem; border: 1px solid transparent; border-radius: .9rem; padding: .7rem 1rem; font-size: .76rem; font-weight: 900; text-decoration: none; transition: transform .22s ease, background .22s ease, border-color .22s ease; }
.project-primary-link { background: var(--project-gold); color: #111827; }
.project-secondary-link { border-color: var(--project-line); background: rgba(255, 255, 255, .035); color: #f8fafc; }
.project-primary-link:hover, .project-secondary-link:hover { transform: translateY(-2px); }
.project-primary-link:hover { background: #fcd34d; }
.project-secondary-link:hover { border-color: rgba(251, 191, 36, .35); }
.project-hero-image-button { position: relative; display: block; width: 100%; padding: .55rem; overflow: hidden; border: 1px solid rgba(255, 255, 255, .13); border-radius: 1.8rem; background: linear-gradient(145deg, rgba(255, 255, 255, .08), rgba(255, 255, 255, .015)); box-shadow: 0 30px 90px rgba(0, 0, 0, .4); cursor: zoom-in; }
.project-hero-image-button img { display: block; width: 100%; aspect-ratio: 1.18 / 1; border-radius: 1.35rem; background: #111827; object-fit: cover; transition: transform .75s cubic-bezier(.16, 1, .3, 1); }
.project-hero-image-button:hover img { transform: scale(1.035); }
.project-image-hint { position: absolute; right: 1.2rem; bottom: 1.1rem; display: inline-flex; align-items: center; gap: .45rem; border: 1px solid rgba(255, 255, 255, .16); border-radius: 999px; background: rgba(3, 7, 18, .72); padding: .5rem .75rem; color: #fff; font-size: .65rem; backdrop-filter: blur(10px); }
.project-highlights { display: flex; grid-column: 1 / -1; flex-wrap: wrap; align-items: center; justify-content: center; gap: .6rem; margin-top: .4rem; }
.project-highlight { display: inline-flex; min-height: 3rem; flex: 0 1 auto; align-items: center; gap: .55rem; border: 1px solid var(--project-line); border-radius: 999px; background: rgba(15, 23, 42, .5); padding: .55rem .85rem; }
.project-highlight i { color: var(--project-gold); }
.project-highlight span { color: #d3d9e3; font-size: .72rem; font-weight: 800; line-height: 1.5; }
.project-story-section, .project-process-section, .project-gallery-section { padding-top: clamp(4rem, 8vw, 7rem); }
.project-hero + .project-gallery-section { padding-top: clamp(2rem, 4vw, 3rem); }
.project-section-heading { max-width: 47rem; }
.project-section-heading h2, .project-gallery-heading h2 { margin: .6rem 0 0; color: #fff; font-size: clamp(1.55rem, 3.5vw, 2.4rem); font-weight: 950; }
.project-section-heading > p { margin: .8rem 0 0; color: var(--project-muted); font-size: .9rem; line-height: 2; }
.project-story-grid { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, .9fr); gap: 1rem; margin-top: 1.6rem; }
.project-story-card { min-height: 14rem; border: 1px solid var(--project-line); border-radius: 1.4rem; background: linear-gradient(145deg, rgba(15, 23, 42, .82), rgba(15, 23, 42, .45)); padding: clamp(1.2rem, 3vw, 2rem); }
.project-story-card-featured { border-color: rgba(251, 191, 36, .2); background: radial-gradient(ellipse at 100% 0, rgba(245, 158, 11, .11), transparent 58%), rgba(15, 23, 42, .75); }
.project-story-icon { display: grid; width: 2.65rem; height: 2.65rem; place-items: center; border: 1px solid rgba(251, 191, 36, .22); border-radius: .9rem; background: rgba(245, 158, 11, .1); color: var(--project-gold); }
.project-story-card h3 { margin: 1rem 0 0; color: #fff; font-size: 1rem; font-weight: 900; }
.project-story-card p, .project-story-card li { color: #bac3d1; font-size: .82rem; line-height: 2; }
.project-story-card p { margin: .6rem 0 0; }
.project-story-card ul { display: grid; gap: .55rem; margin: .8rem 0 0; padding: 0; list-style: none; }
.project-story-card li { position: relative; padding-right: 1.2rem; }
.project-story-card li::before { position: absolute; top: .78rem; right: 0; width: .38rem; height: .38rem; border-radius: 50%; background: var(--project-gold); content: ""; }
.project-process-section { border-top: 1px solid rgba(255, 255, 255, .06); margin-top: clamp(3rem, 7vw, 5.5rem); padding-top: clamp(3.5rem, 7vw, 6rem); }
.project-process-list { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: .8rem; margin: 1.8rem 0 0; padding: 0; list-style: none; counter-reset: project-process; }
.project-process-step { position: relative; min-height: 12.5rem; border: 1px solid var(--project-line); border-radius: 1.2rem; background: rgba(15, 23, 42, .55); padding: 1.2rem; counter-increment: project-process; }
.project-process-step::before { display: block; color: rgba(251, 191, 36, .72); font-size: .75rem; font-weight: 900; content: "۰" counter(project-process, persian); }
.project-process-step h3 { margin: 1rem 0 0; color: #fff; font-size: .9rem; font-weight: 900; }
.project-process-step p { margin: .5rem 0 0; color: var(--project-muted); font-size: .74rem; line-height: 1.9; }
.project-gallery-section { border-top: 1px solid rgba(255, 255, 255, .06); margin-top: clamp(3rem, 7vw, 5.5rem); padding-top: clamp(3.5rem, 7vw, 6rem); }
.project-gallery-heading { display: flex; align-items: end; justify-content: space-between; gap: 1rem; }
.project-gallery-count { display: inline-flex; min-width: max-content; align-items: center; gap: .45rem; border: 1px solid var(--project-line); border-radius: 999px; padding: .55rem .8rem; color: #d2d8e2; font-size: .72rem; }
.project-gallery-count i { color: var(--project-gold); }
.project-gallery-stages { display: grid; gap: 1.15rem; margin-top: 1.6rem; }
.project-gallery-stage { --stage-accent: #fbbf24; overflow: hidden; border: 1px solid color-mix(in srgb, var(--stage-accent) 24%, transparent); border-radius: 1.5rem; background: radial-gradient(ellipse at 100% 0, color-mix(in srgb, var(--stage-accent) 9%, transparent), transparent 55%), rgba(15, 23, 42, .48); padding: clamp(.85rem, 2vw, 1.25rem); }
.project-gallery-stage--before { --stage-accent: #fb923c; }
.project-gallery-stage--during { --stage-accent: #60a5fa; }
.project-gallery-stage--after { --stage-accent: #4ade80; }
.project-gallery-stage--comparison { --stage-accent: #fbbf24; }
.project-gallery-stage--design { --stage-accent: #c084fc; }
.project-gallery-stage--gallery { --stage-accent: #94a3b8; }
.project-gallery-stage-heading { display: flex; align-items: center; justify-content: space-between; gap: 1rem; margin-bottom: 1rem; }
.project-gallery-stage-heading h3 { margin: 0; color: #fff; font-size: clamp(1.05rem, 2vw, 1.35rem); font-weight: 950; }
.project-gallery-stage-heading p { margin: .35rem 0 0; color: var(--project-muted); font-size: .76rem; line-height: 1.8; }
.project-gallery-stage-count { display: inline-flex; min-width: max-content; align-items: center; border: 1px solid color-mix(in srgb, var(--stage-accent) 30%, transparent); border-radius: 999px; background: color-mix(in srgb, var(--stage-accent) 8%, transparent); padding: .4rem .7rem; color: var(--stage-accent); font-size: .7rem; font-weight: 800; }
.project-gallery-grid { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); grid-auto-rows: clamp(7rem, 13vw, 10.5rem); gap: .7rem; }
.project-gallery-item { position: relative; display: block; box-sizing: border-box; width: 100%; height: 100%; min-width: 0; padding: .4rem; overflow: hidden; border: 1px solid var(--project-line); border-radius: 1.15rem; background: rgba(15, 23, 42, .7); cursor: zoom-in; text-align: right; }
.project-gallery-item img { display: block; width: 100%; height: 100%; min-height: 0; border-radius: .85rem; background: #111827; object-fit: cover; transition: transform .55s cubic-bezier(.16, 1, .3, 1), filter .4s ease; }
.project-gallery-item:hover img, .project-gallery-item:focus-visible img { transform: scale(1.035); filter: brightness(1.08); }
.project-gallery-grid--before > :first-child, .project-gallery-grid--during > :first-child, .project-gallery-grid--after > :first-child, .project-gallery-grid--comparison > :first-child { grid-column: span 3; grid-row: span 2; }
.project-gallery-grid--during > :nth-child(2) { grid-column: span 3; grid-row: span 2; }
.project-gallery-grid--after > :first-child { grid-column: span 4; }
.project-gallery-grid--design > :first-child, .project-gallery-grid--gallery > :first-child { grid-column: span 4; grid-row: span 2; }
.project-gallery-grid.is-single { grid-template-columns: minmax(0, 1fr); grid-auto-rows: auto; }
.project-gallery-grid.is-single .project-gallery-item { width: 100%; max-width: 54rem; aspect-ratio: 16 / 9; justify-self: center; }
.project-gallery-grid.is-single .project-gallery-item img { aspect-ratio: auto; }
.project-gallery-number { position: absolute; top: .75rem; left: .75rem; display: grid; width: 1.8rem; height: 1.8rem; place-items: center; border: 1px solid rgba(255, 255, 255, .18); border-radius: 999px; background: rgba(3, 7, 18, .72); color: #fff; font-size: .68rem; backdrop-filter: blur(8px); }
.project-gallery-stage-label { position: absolute; right: .8rem; bottom: .8rem; max-width: calc(100% - 1.6rem); border: 1px solid color-mix(in srgb, var(--stage-accent) 38%, transparent); border-radius: 999px; background: rgba(3, 7, 18, .78); padding: .32rem .62rem; color: #fff; font-size: .65rem; font-weight: 800; backdrop-filter: blur(10px); }
.project-contact-section { display: flex; align-items: center; justify-content: space-between; gap: 1.5rem; margin: clamp(4rem, 8vw, 7rem) 0; border: 1px solid rgba(251, 191, 36, .18); border-radius: 1.5rem; background: radial-gradient(ellipse at 100% 0, rgba(245, 158, 11, .12), transparent 55%), rgba(15, 23, 42, .7); padding: clamp(1.4rem, 4vw, 2.6rem); }
.project-contact-section h2 { margin: .55rem 0 0; color: #fff; font-size: clamp(1.15rem, 3vw, 1.7rem); font-weight: 950; }
.project-contact-section p { max-width: 42rem; margin: .45rem 0 0; color: var(--project-muted); font-size: .82rem; line-height: 1.9; }
.project-related-service-link { color: #fcd34d; font-weight: 800; text-decoration: underline; text-decoration-color: rgba(252, 211, 77, .48); text-underline-offset: .25em; }
.project-related-service-link:hover { color: #fff; text-decoration-color: currentColor; }
.project-contact-section .project-primary-link { min-width: max-content; }
.project-footer { display: flex; width: min(100% - 2rem, 1200px); min-height: 5.5rem; align-items: center; justify-content: space-between; gap: 1rem; margin-inline: auto; border-top: 1px solid var(--project-line); }
.project-footer > p, .project-footer > a:last-child { color: #8993a5; font-size: .7rem; }
.project-footer > a:last-child { text-decoration: none; }
.project-footer > a:last-child:hover { color: var(--project-gold); }
.project-lightbox { position: fixed; z-index: 100; inset: 0; display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; justify-items: center; gap: clamp(.4rem, 2vw, 1.5rem); background: rgba(2, 6, 18, .94); padding: clamp(1rem, 4vw, 3.5rem); opacity: 0; pointer-events: none; transition: opacity .32s ease; backdrop-filter: blur(16px); }
.project-lightbox[aria-hidden="false"] { opacity: 1; pointer-events: auto; }
.lightbox-figure { display: grid; max-width: min(100%, 1100px); max-height: 100%; justify-items: center; gap: .8rem; margin: 0; transform: scale(.965); transition: transform .38s cubic-bezier(.16, 1, .3, 1); }
.project-lightbox[aria-hidden="false"] .lightbox-figure { transform: scale(1); }
.lightbox-figure img { display: block; max-width: 100%; max-height: calc(100vh - 8rem); border-radius: 1rem; object-fit: contain; box-shadow: 0 30px 100px rgba(0, 0, 0, .48); }
.lightbox-figure figcaption { color: #e2e8f0; font-size: .75rem; text-align: center; }
.lightbox-close, .lightbox-arrow { display: grid; width: 2.9rem; height: 2.9rem; place-items: center; border: 1px solid rgba(255, 255, 255, .16); border-radius: 1rem; background: rgba(15, 23, 42, .82); color: #fff; cursor: pointer; transition: border-color .2s ease, color .2s ease, transform .2s ease; }
.lightbox-close:hover, .lightbox-arrow:hover { transform: scale(1.04); border-color: rgba(251, 191, 36, .55); color: var(--project-gold); }
.lightbox-close { position: absolute; top: 1.25rem; left: 1.25rem; }
.lightbox-arrow { position: relative; z-index: 1; }
.project-detail-main > .project-error:not(.hidden) { min-height: 65vh; }
.project-page-ready .project-loading, .project-page-error .project-loading { display: none; }
.project-page-error #projectError:not(.hidden) { display: grid; }

@media (max-width: 760px) {
    .project-nav { min-height: 62px; padding: .55rem .7rem; }
    .project-brand-icon { width: 2.45rem; height: 2.45rem; }
    .project-nav-links { display: none; }
    .project-detail-main { width: min(100% - 1.25rem, 620px); }
    .project-hero { grid-template-columns: 1fr; gap: 1.1rem; padding-top: 1.5rem; }
    .project-hero-copy { max-width: 42rem; }
    .project-eyebrow { margin-top: .7rem; }
    .project-hero h1 { max-width: 24ch; margin-top: .55rem; font-size: clamp(1.65rem, 7vw, 2.25rem); line-height: 1.5; }
    .project-meta { display: inline-flex; width: fit-content; max-width: 100%; margin-top: .65rem; border: 1px solid rgba(251, 191, 36, .2); border-radius: 999px; background: rgba(245, 158, 11, .07); padding: .32rem .7rem; font-size: .72rem; line-height: 1.7; }
    .project-intro { max-width: 38rem; margin-top: .8rem; font-size: .86rem; line-height: 1.9; }
    .project-hero-actions { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .55rem; margin-top: 1rem; }
    .project-primary-link, .project-secondary-link { min-height: 3.1rem; padding: .6rem .65rem; font-size: .68rem; line-height: 1.65; }
    .project-hero-image-button { grid-row: 2; }
    .project-hero-image-button img { aspect-ratio: 1.2 / .88; }
    .project-highlights { gap: .4rem; margin-top: 0; }
    .project-highlight { min-height: 2.7rem; gap: .4rem; padding: .45rem .65rem; }
    .project-highlight span { font-size: .65rem; line-height: 1.5; }
    .project-story-grid { grid-template-columns: 1fr; }
    .project-story-card { min-height: auto; }
    .project-process-list { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .project-process-step { min-height: 11rem; padding: 1rem; }
    .project-gallery-stage-heading { align-items: start; }
    .project-gallery-stage-heading p { font-size: .7rem; }
    .project-gallery-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); grid-auto-rows: clamp(6rem, 28vw, 9rem); gap: .5rem; }
    .project-gallery-grid--before > :first-child, .project-gallery-grid--during > :first-child, .project-gallery-grid--after > :first-child, .project-gallery-grid--comparison > :first-child, .project-gallery-grid--design > :first-child, .project-gallery-grid--gallery > :first-child { grid-column: span 2; grid-row: span 2; }
    .project-gallery-grid--during > :nth-child(2) { grid-column: span 2; grid-row: span 2; }
    .project-gallery-grid.is-single { grid-template-columns: minmax(0, 1fr); grid-auto-rows: auto; }
    .project-gallery-grid.is-single .project-gallery-item { aspect-ratio: 1.35 / 1; }
    .project-gallery-number { top: .65rem; left: .65rem; width: 1.6rem; height: 1.6rem; }
    .project-gallery-stage-label { right: .65rem; bottom: .65rem; padding: .28rem .52rem; font-size: .6rem; }
    .project-gallery-heading { align-items: start; }
    .project-contact-section { align-items: start; flex-direction: column; }
    .project-footer { flex-wrap: wrap; padding-block: 1rem; }
    .project-footer > p { order: 1; width: 100%; margin: 0; text-align: center; }
    .project-lightbox { grid-template-columns: 2.5rem minmax(0, 1fr) 2.5rem; padding: 1rem .5rem; }
    .lightbox-arrow { width: 2.4rem; height: 2.4rem; }
    .lightbox-figure img { max-height: calc(100vh - 7rem); }
}

@media (max-width: 380px) {
    .project-hero-actions { grid-template-columns: 1fr; }
}

@media (hover: none) and (pointer: coarse) {
    .project-nav,
    .project-image-hint,
    .project-gallery-number,
    .project-gallery-stage-label {
        -webkit-backdrop-filter: none;
        backdrop-filter: none;
    }

    .project-gallery-item img,
    .project-hero-image-button img {
        transition: none;
    }

    .project-gallery-item:hover img,
    .project-gallery-item:focus-visible img,
    .project-hero-image-button:hover img {
        transform: none;
        filter: none;
    }
}

@media (max-width: 390px) {
    .project-gallery-count { padding: .45rem .55rem; font-size: .64rem; }
    .project-process-step { min-height: 12rem; }
}

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { scroll-behavior: auto !important; animation-duration: .01ms !important; transition-duration: .01ms !important; }
}
