/* =====================================================================
   قالب حرفه‌ای رویداد/نمایشگاه برای صفحه‌های فرود (/p/{slug})
   همه‌ی کلاس‌ها با پیشوند ev- — رنگ‌ها از فیلدهای لندینگ به‌صورت CSS var تزریقی می‌شوند:
   --ev-color (رنگ اصلی)، --ev-color2 (رنگ دوم)
   ===================================================================== */

:root {
    --ev-color: #1a56b0;
    --ev-color2: #0f172a;
    --ev-ink: #0f172a;
    --ev-muted: #55627a;
    --ev-soft: #f4f6fb;
    --ev-line: #e3e8f2;
    --ev-radius: 18px;
    --ev-shadow: 0 18px 50px rgba(15, 23, 42, .10);
    --ev-shadow-sm: 0 8px 24px rgba(15, 23, 42, .08);
    --ev-nav-h: 66px;
}

html { scroll-behavior: smooth; }

body.ev {
    font-family: Vazirmatn, Tahoma, sans-serif;
    margin: 0;
    background: var(--ev-soft);
    color: var(--ev-ink);
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}

body.ev section[id] { scroll-margin-top: calc(var(--ev-nav-h) + 14px); }

/* ————— نوار بالا ————— */
.ev-nav {
    position: fixed; inset-inline: 0; top: 0; z-index: 60;
    height: var(--ev-nav-h);
    display: flex; align-items: center;
    transition: background .3s ease, box-shadow .3s ease, height .3s ease;
}
.ev-nav__in {
    width: min(1140px, 100% - 36px); margin-inline: auto;
    display: flex; align-items: center; gap: 18px;
}
.ev-nav__brand {
    display: flex; align-items: center; gap: 10px;
    color: #fff; font-weight: 800; font-size: 1.02rem;
    text-decoration: none; white-space: nowrap;
    filter: drop-shadow(0 1px 4px rgba(0,0,0,.25));
}
.ev-nav__brand img { max-height: 38px; max-width: 150px; border-radius: 8px; }
.ev-nav__links { display: flex; align-items: center; gap: 4px; margin-inline-start: auto; }
.ev-nav__links a {
    color: rgba(255,255,255,.92); text-decoration: none; font-size: .92rem;
    padding: 8px 14px; border-radius: 999px; transition: background .2s;
    text-shadow: 0 1px 3px rgba(0,0,0,.3);
}
.ev-nav__links a:hover { background: rgba(255,255,255,.14); color: #fff; }
.ev-nav__cta {
    margin-inline-start: auto;
    background: #fff; color: var(--ev-color2) !important;
    font-weight: 700; font-size: .9rem; text-decoration: none;
    padding: 10px 20px; border-radius: 999px;
    box-shadow: 0 6px 18px rgba(0,0,0,.18);
    transition: transform .2s, box-shadow .2s;
}
.ev-nav__cta:hover { transform: translateY(-1px); box-shadow: 0 10px 24px rgba(0,0,0,.24); }
.ev-nav__burger {
    display: none; margin-inline-start: auto;
    background: rgba(255,255,255,.16); border: none; color: #fff;
    width: 42px; height: 42px; border-radius: 12px; font-size: 20px; cursor: pointer;
}

/* حالت چسبیده: پس‌زمینه‌ی سفید و سایه */
.ev-nav--solid { background: rgba(255,255,255,.94); backdrop-filter: blur(12px); box-shadow: var(--ev-shadow-sm); }
.ev-nav--solid .ev-nav__brand { color: var(--ev-ink); filter: none; }
.ev-nav--solid .ev-nav__links a { color: var(--ev-muted); text-shadow: none; }
.ev-nav--solid .ev-nav__links a:hover { background: var(--ev-soft); color: var(--ev-color); }
.ev-nav--solid .ev-nav__cta { background: var(--ev-color); color: #fff !important; }
.ev-nav--solid .ev-nav__burger { background: var(--ev-soft); color: var(--ev-ink); }

/* ————— Hero ————— */
.ev-hero {
    position: relative; min-height: 100svh;
    display: flex; align-items: center; justify-content: center;
    text-align: center; overflow: hidden;
    padding: calc(var(--ev-nav-h) + 40px) 18px 84px;
    background: linear-gradient(135deg, var(--ev-color), var(--ev-color2));
}
.ev-hero__bg {
    position: absolute; inset: 0; z-index: 1;
    background-size: cover; background-position: center;
    transform: scale(1.04);
    animation: evHeroZoom 18s ease-out forwards;
}
@keyframes evHeroZoom { to { transform: scale(1); } }
.ev-hero__veil {
    position: absolute; inset: 0; z-index: 2;
    background: linear-gradient(180deg, rgba(8,12,28,var(--ev-overlay,.55)) 0%, rgba(8,12,28,calc(var(--ev-overlay,.55) * .78)) 46%, rgba(8,12,28,calc(var(--ev-overlay,.55) * 1.35)) 100%);
}
.ev-hero__in { position: relative; z-index: 3; max-width: 900px; color: #fff; }
.ev-badge {
    display: inline-flex; align-items: center; gap: 8px;
    background: rgba(255,255,255,.14); border: 1px solid rgba(255,255,255,.28);
    backdrop-filter: blur(6px);
    color: #fff; font-size: .85rem; font-weight: 600;
    padding: 8px 18px; border-radius: 999px; margin-bottom: 22px;
    animation: evRise .8s ease both;
}
.ev-badge::before {
    content: ""; width: 8px; height: 8px; border-radius: 50%;
    background: #4ade80; box-shadow: 0 0 0 4px rgba(74,222,128,.25);
    animation: evPulse 2s infinite;
}
@keyframes evPulse { 50% { box-shadow: 0 0 0 7px rgba(74,222,128,.08); } }
.ev-hero h1 {
    font-size: clamp(1.9rem, 5.2vw, 3.4rem);
    font-weight: 900; line-height: 1.4; margin: 0 0 14px;
    text-wrap: balance; text-shadow: 0 4px 24px rgba(0,0,0,.35);
    animation: evRise .8s .08s ease both;
}
.ev-hero__sub {
    font-size: clamp(1rem, 2.2vw, 1.2rem);
    line-height: 2; opacity: .95; margin: 0 auto 26px; max-width: 640px;
    animation: evRise .8s .16s ease both;
}
@keyframes evRise { from { opacity: 0; transform: translateY(22px); } to { opacity: 1; transform: none; } }

/* چیپ‌های تاریخ و مکان */
.ev-chips {
    display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; margin-bottom: 30px;
    animation: evRise .8s .24s ease both;
}
.ev-chip {
    display: inline-flex; align-items: center; gap: 8px;
    background: rgba(255,255,255,.13); border: 1px solid rgba(255,255,255,.24);
    backdrop-filter: blur(6px);
    padding: 9px 16px; border-radius: 14px; font-size: .9rem; font-weight: 600;
}
.ev-chip svg { width: 17px; height: 17px; opacity: .9; flex: none; }

/* شمارش معکوس */
.ev-count {
    display: flex; justify-content: center; gap: 12px; margin-bottom: 34px;
    animation: evRise .8s .32s ease both;
}
.ev-count__cell {
    min-width: 78px; padding: 14px 8px 11px; border-radius: 16px;
    background: rgba(255,255,255,.12); border: 1px solid rgba(255,255,255,.22);
    backdrop-filter: blur(8px);
}
.ev-count__num { display: block; font-size: clamp(1.5rem, 3.4vw, 2.1rem); font-weight: 900; line-height: 1.2; font-variant-numeric: tabular-nums; }
.ev-count__lbl { display: block; font-size: .74rem; opacity: .85; margin-top: 3px; }

/* دکمه‌های Hero */
.ev-actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 12px; animation: evRise .8s .4s ease both; }
.ev-btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 8px;
    padding: 15px 34px; border-radius: 999px; border: none; cursor: pointer;
    font-family: inherit; font-size: 1.02rem; font-weight: 800; text-decoration: none !important;
    transition: transform .2s, box-shadow .2s, background .2s;
}
.ev-btn--primary {
    background: linear-gradient(135deg, var(--ev-color), color-mix(in srgb, var(--ev-color) 62%, #fff 8%));
    color: #fff; box-shadow: 0 14px 34px color-mix(in srgb, var(--ev-color) 45%, transparent);
}
.ev-btn--primary:hover { transform: translateY(-2px); box-shadow: 0 20px 44px color-mix(in srgb, var(--ev-color) 55%, transparent); }
.ev-btn--ghost {
    background: rgba(255,255,255,.13); color: #fff;
    border: 1px solid rgba(255,255,255,.35); backdrop-filter: blur(6px);
}
.ev-btn--ghost:hover { background: rgba(255,255,255,.22); }

.ev-scroll {
    position: absolute; bottom: 22px; inset-inline-start: 50%; transform: translateX(50%);
    color: rgba(255,255,255,.75); font-size: 1.4rem;
    animation: evBounce 2s infinite; text-decoration: none;
}
@keyframes evBounce { 0%,100% { transform: translate(50%, 0); } 50% { transform: translate(50%, 8px); } }

/* ————— بخش‌های عمومی ————— */
.ev-section { padding-block: clamp(58px, 8vw, 104px); }
.ev-section--white { background: #fff; }
.ev-section__in { width: min(1140px, 100% - 36px); margin-inline: auto; }

.ev-sec-head { text-align: center; max-width: 660px; margin: 0 auto clamp(34px, 5vw, 54px); }
.ev-eyebrow {
    display: inline-block; color: var(--ev-color); font-size: .84rem; font-weight: 800;
    letter-spacing: .02em; background: color-mix(in srgb, var(--ev-color) 9%, transparent);
    padding: 6px 16px; border-radius: 999px; margin-bottom: 14px;
}
.ev-sec-head h2 {
    font-size: clamp(1.5rem, 3.4vw, 2.2rem); font-weight: 900; margin: 0 0 12px; line-height: 1.5;
}
.ev-sec-head p { color: var(--ev-muted); font-size: 1rem; line-height: 2; margin: 0; }

/* انیمیشن ظهور با اسکرول */
.ev-reveal { opacity: 0; transform: translateY(26px); transition: opacity .7s ease, transform .7s ease; }
.ev-reveal.ev-in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
    .ev-reveal { opacity: 1; transform: none; transition: none; }
    .ev-hero__bg { animation: none; }
    html { scroll-behavior: auto; }
}

/* ————— درباره ————— */
.ev-about { display: grid; grid-template-columns: 1.35fr 1fr; gap: 28px; align-items: start; }
.ev-about__text { font-size: .98rem; line-height: 2.15; color: #33415c; }
.ev-about__text .ev-lead { font-size: 1.06rem; font-weight: 600; color: var(--ev-ink); margin-bottom: 12px; }
.ev-body p { margin: 0 0 12px; }
.ev-body img { max-width: 100%; border-radius: 12px; }
.ev-body :is(h1,h2,h3,h4) { font-size: 1.1rem; font-weight: 800; margin: 18px 0 8px; color: var(--ev-ink); }
.ev-body ul, .ev-body ol { padding-inline-start: 1.3em; margin: 0 0 12px; }

.ev-benefits {
    background: #fff; border: 1px solid var(--ev-line); border-radius: var(--ev-radius);
    padding: 26px 24px; box-shadow: var(--ev-shadow-sm);
}
.ev-benefits h3 { font-size: 1.05rem; font-weight: 800; margin: 0 0 16px; }
.ev-benefits ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 12px; }
.ev-benefits li { display: flex; gap: 11px; align-items: flex-start; font-size: .93rem; line-height: 1.9; color: #33415c; }
.ev-benefits li::before {
    content: "✓"; flex: 0 0 24px; height: 24px; margin-top: 2px;
    display: grid; place-items: center; border-radius: 8px;
    background: color-mix(in srgb, var(--ev-color) 14%, #fff);
    color: var(--ev-color); font-weight: 800; font-size: 13px;
}
.ev-quote {
    margin-top: 18px; padding: 14px 16px; border-radius: 12px;
    background: var(--ev-soft); border-inline-start: 3px solid var(--ev-color);
    font-size: .88rem; line-height: 2; color: #46536e;
}
.ev-quote cite { display: block; margin-top: 6px; font-style: normal; font-size: .82rem; color: var(--ev-muted); }

/* ————— گالری ————— */
.ev-gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 14px; }
.ev-gallery a {
    position: relative; display: block; overflow: hidden; border-radius: 16px;
    aspect-ratio: 4 / 3; box-shadow: var(--ev-shadow-sm);
}
.ev-gallery a:nth-child(6n+1), .ev-gallery a:nth-child(6n+4) { grid-row: span 1; }
.ev-gallery img {
    width: 100%; height: 100%; object-fit: cover; transition: transform .5s ease;
    display: block;
}
.ev-gallery a:hover img { transform: scale(1.07); }
.ev-gallery figcaption, .ev-gallery .ev-cap {
    position: absolute; inset-inline: 0; bottom: 0;
    padding: 26px 14px 10px;
    background: linear-gradient(0deg, rgba(8,12,28,.72), transparent);
    color: #fff; font-size: .82rem;
    opacity: 0; transition: opacity .3s;
}
.ev-gallery a:hover .ev-cap, .ev-gallery a:focus .ev-cap { opacity: 1; }
.ev-gallery-more {
    text-align: center; margin-top: 10px; color: var(--ev-muted); font-size: .85rem;
}

/* ————— ویدئو ————— */
.ev-videos { display: grid; grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); gap: 18px; }
.ev-video {
    position: relative; border-radius: var(--ev-radius); overflow: hidden;
    aspect-ratio: 16 / 9; background: var(--ev-color2);
    box-shadow: var(--ev-shadow); cursor: pointer; border: none; padding: 0; width: 100%;
}
.ev-video img, .ev-video video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.ev-video__play {
    position: absolute; inset: 0; display: grid; place-items: center;
    background: linear-gradient(0deg, rgba(8,12,28,.45), rgba(8,12,28,.12));
    transition: background .3s;
}
.ev-video:hover .ev-video__play { background: linear-gradient(0deg, rgba(8,12,28,.35), rgba(8,12,28,.05)); }
.ev-video__play span {
    width: 74px; height: 74px; border-radius: 50%;
    display: grid; place-items: center;
    background: rgba(255,255,255,.94); color: var(--ev-color);
    box-shadow: 0 10px 30px rgba(0,0,0,.35);
    transition: transform .25s;
}
.ev-video:hover .ev-video__play span { transform: scale(1.1); }
.ev-video__play svg { width: 30px; height: 30px; margin-inline-start: -4px; }
.ev-video__title {
    position: absolute; inset-inline: 0; bottom: 0; padding: 30px 18px 14px;
    background: linear-gradient(0deg, rgba(8,12,28,.75), transparent);
    color: #fff; font-size: .92rem; font-weight: 700; text-align: start;
}
.ev-video iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }

/* ————— برنامه زمان‌بندی ————— */
.ev-schedule { max-width: 760px; margin-inline: auto; position: relative; padding-inline-start: 26px; }
.ev-schedule::before {
    content: ""; position: absolute; inset-inline-start: 7px; top: 12px; bottom: 12px;
    width: 2px; border-radius: 2px;
    background: linear-gradient(180deg, var(--ev-color), color-mix(in srgb, var(--ev-color) 20%, transparent));
}
.ev-sched__item { position: relative; padding: 0 0 26px; }
.ev-sched__item:last-child { padding-bottom: 0; }
.ev-sched__item::before {
    content: ""; position: absolute; inset-inline-start: -26px; top: 7px;
    width: 16px; height: 16px; border-radius: 50%;
    background: #fff; border: 3.5px solid var(--ev-color);
    box-shadow: 0 0 0 4px color-mix(in srgb, var(--ev-color) 14%, transparent);
}
.ev-sched__time {
    display: inline-block; background: color-mix(in srgb, var(--ev-color) 11%, #fff);
    color: var(--ev-color); font-weight: 800; font-size: .84rem;
    padding: 4px 12px; border-radius: 8px; margin-bottom: 8px; font-variant-numeric: tabular-nums;
}
.ev-sched__title { font-weight: 800; font-size: 1.02rem; margin-bottom: 4px; }
.ev-sched__desc { color: var(--ev-muted); font-size: .92rem; line-height: 2; margin: 0; }

/* ————— مکان ————— */
.ev-venue { display: grid; grid-template-columns: 1fr 1.25fr; gap: 22px; align-items: stretch; }
.ev-venue__card {
    background: #fff; border: 1px solid var(--ev-line); border-radius: var(--ev-radius);
    padding: 30px 26px; box-shadow: var(--ev-shadow-sm);
    display: flex; flex-direction: column; gap: 16px; justify-content: center;
}
.ev-venue__row { display: flex; gap: 13px; align-items: flex-start; }
.ev-venue__row svg { width: 21px; height: 21px; color: var(--ev-color); flex: none; margin-top: 3px; }
.ev-venue__row b { display: block; margin-bottom: 3px; font-size: .95rem; }
.ev-venue__row span { color: var(--ev-muted); font-size: .9rem; line-height: 2; }
.ev-venue__map {
    border-radius: var(--ev-radius); overflow: hidden; min-height: 320px;
    box-shadow: var(--ev-shadow); border: 1px solid var(--ev-line);
    background: var(--ev-soft);
}
.ev-venue__map iframe { width: 100%; height: 100%; min-height: 320px; border: 0; display: block; }

/* ————— ثبت‌نام ————— */
.ev-register {
    position: relative; overflow: hidden;
    background: linear-gradient(135deg, var(--ev-color), var(--ev-color2));
    border-radius: clamp(20px, 3vw, 30px);
    padding: clamp(28px, 5vw, 56px);
    box-shadow: var(--ev-shadow);
}
.ev-register::before {
    content: ""; position: absolute; width: 420px; height: 420px; border-radius: 50%;
    background: rgba(255,255,255,.07); top: -180px; inset-inline-start: -140px;
}
.ev-register__grid { position: relative; display: grid; grid-template-columns: 1fr 1.05fr; gap: clamp(22px, 4vw, 44px); align-items: center; }
.ev-register__side { color: #fff; }
.ev-register__side h2 { font-size: clamp(1.4rem, 3vw, 2rem); font-weight: 900; margin: 0 0 12px; line-height: 1.5; }
.ev-register__side p { opacity: .92; line-height: 2.1; margin: 0 0 18px; font-size: .96rem; }
.ev-register__side .ev-chip { margin-bottom: 0; }
.ev-register__side ul { list-style: none; padding: 0; margin: 0 0 20px; display: grid; gap: 10px; }
.ev-register__side ul li { display: flex; gap: 9px; font-size: .92rem; opacity: .95; }
.ev-register__side ul li::before { content: "✓"; font-weight: 800; color: #6ee7a0; }
.ev-form-card {
    background: #fff; border-radius: 20px; padding: clamp(22px, 3.4vw, 34px);
    box-shadow: 0 24px 70px rgba(0,0,0,.28);
}
.ev-form-card .form-label { font-size: .86rem; font-weight: 600; color: #33415c; }
.ev-form-card .form-control { border-radius: 12px; border-color: var(--ev-line); padding: 10px 14px; }
.ev-form-card .form-control:focus { border-color: var(--ev-color); box-shadow: 0 0 0 4px color-mix(in srgb, var(--ev-color) 14%, transparent); }
.ev-form-card .ev-btn { width: 100%; }

.ev-note { text-align: center; color: var(--ev-muted); font-size: .8rem; margin-top: 10px; }

/* وضعیت موفقیت */
.ev-success { text-align: center; padding: 16px 6px; }
.ev-success__icon {
    width: 84px; height: 84px; margin: 0 auto 18px; border-radius: 50%;
    display: grid; place-items: center; font-size: 42px;
    background: #e8f9ef; box-shadow: 0 0 0 10px rgba(74,222,128,.12);
    animation: evPop .5s ease both;
}
@keyframes evPop { from { transform: scale(.4); opacity: 0; } to { transform: none; opacity: 1; } }
.ev-success h3 { font-weight: 900; margin-bottom: 8px; }
.ev-success p { color: var(--ev-muted); line-height: 2; }

/* ————— FAQ ————— */
.ev-faq { max-width: 760px; margin-inline: auto; display: grid; gap: 12px; }
.ev-faq details {
    background: #fff; border: 1px solid var(--ev-line); border-radius: 14px;
    overflow: hidden; transition: box-shadow .2s;
}
.ev-faq details[open] { box-shadow: var(--ev-shadow-sm); }
.ev-faq summary {
    list-style: none; cursor: pointer; padding: 17px 20px;
    font-weight: 700; font-size: .96rem; display: flex; align-items: center; gap: 12px;
}
.ev-faq summary::-webkit-details-marker { display: none; }
.ev-faq summary::before {
    content: "?"; flex: none; width: 26px; height: 26px; border-radius: 8px;
    display: grid; place-items: center;
    background: color-mix(in srgb, var(--ev-color) 12%, #fff);
    color: var(--ev-color); font-weight: 800; font-size: .9rem;
}
.ev-faq summary::after {
    content: "+"; margin-inline-start: auto; color: var(--ev-muted);
    font-size: 1.3rem; font-weight: 400; transition: transform .25s;
}
.ev-faq details[open] summary::after { transform: rotate(45deg); }
.ev-faq details p { padding: 0 20px 18px 58px; margin: 0; color: var(--ev-muted); line-height: 2.05; font-size: .92rem; }

/* ————— فوتر ————— */
.ev-footer { background: var(--ev-color2); color: rgba(255,255,255,.78); padding: 40px 18px 96px; text-align: center; }
.ev-footer img { max-height: 44px; border-radius: 8px; margin-bottom: 14px; }
.ev-footer .ev-footer__title { color: #fff; font-weight: 800; font-size: 1.05rem; margin-bottom: 8px; }
.ev-footer small { font-size: .8rem; line-height: 2; display: block; }

/* نوار CTA موبایل */
.ev-ctabar {
    position: fixed; inset-inline: 0; bottom: 0; z-index: 55;
    padding: 10px 14px calc(10px + env(safe-area-inset-bottom));
    background: rgba(255,255,255,.96); backdrop-filter: blur(10px);
    border-top: 1px solid var(--ev-line);
    display: none;
    transform: translateY(110%); transition: transform .35s ease;
}
.ev-ctabar.ev-show { transform: none; }
.ev-ctabar .ev-btn { width: 100%; padding: 13px; font-size: .98rem; }

/* ————— ریسپانسیو ————— */
@media (max-width: 991px) {
    .ev-about, .ev-venue, .ev-register__grid { grid-template-columns: 1fr; }
    .ev-nav__links {
        position: fixed; top: var(--ev-nav-h); inset-inline: 10px;
        flex-direction: column; align-items: stretch; gap: 2px;
        background: rgba(255,255,255,.97); backdrop-filter: blur(14px);
        border-radius: 16px; padding: 8px; box-shadow: var(--ev-shadow);
        display: none;
    }
    .ev-nav__links.ev-open { display: flex; }
    .ev-nav__links a { color: var(--ev-ink) !important; text-shadow: none !important; padding: 12px 14px; }
    .ev-nav__links a:hover { background: var(--ev-soft); }
    .ev-nav__burger { display: grid; place-items: center; }
    .ev-nav__cta { margin-inline-start: 0; }
    .ev-ctabar { display: block; }
    .ev-footer { padding-bottom: 110px; }
}
@media (max-width: 575px) {
    .ev-count { gap: 8px; }
    .ev-count__cell { min-width: 68px; }
    .ev-gallery { grid-template-columns: repeat(2, 1fr); gap: 10px; }
    .ev-actions .ev-btn { width: 100%; }
    .ev-btn { padding: 14px 24px; }
}
