/* Italy Admissions: cinematic layer (loads after style.css).
   Motion is added by assets/js/cinema.js; without JavaScript, or with reduced motion, every element shows in its final state. */
:root {
  --night: #0a261d;
  --night-2: #0f3428;
  --night-line: rgba(250, 246, 239, .12);
  --cream-dim: rgba(250, 246, 239, .72);
  --terra-glow: #f3b8a3;
  --ease-out: cubic-bezier(.16, 1, .3, 1);
}

.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* Scroll progress bar */
.scroll-progress {
  position: fixed; inset: 0 0 auto 0; height: 3px; z-index: 80; transform-origin: 0 50%; transform: scaleX(0);
  background: linear-gradient(90deg, var(--terra), var(--terra-glow));
}

/* Header over the dark hero (home page only) */
.site-header { transition: background .35s ease, border-color .35s ease; }
.site-header:not(.is-light) { background: rgba(10, 38, 29, .94); border-bottom-color: var(--night-line); }
.site-header:not(.is-light) .brand-name span { color: var(--terra-glow); }
.site-header:not(.is-light) .brand,
.site-header:not(.is-light) .nav-links a:not(.btn) { color: #faf6ef; }
.site-header:not(.is-light) .nav-links a:not(.btn):hover,
.site-header:not(.is-light) .nav-links a[aria-current="page"] { background: rgba(250, 246, 239, .1); color: #fff; }
.site-header:not(.is-light) .nav-toggle { color: #faf6ef; border-color: var(--night-line); }
@media (max-width: 900px) {
  .site-header:not(.is-light) .nav-menu { background: var(--night); border-bottom-color: var(--night-line); }
}

/* ---------- Hero ---------- */
.cine-hero {
  position: relative; overflow: hidden; color: #faf6ef; background: var(--night);
  min-height: calc(100svh - 72px); display: flex; align-items: center; padding: 56px 0 88px;
}
.cine-hero-bg {
  position: absolute; inset: 0; pointer-events: none;
  background:
    radial-gradient(60% 55% at 78% 40%, rgba(198, 93, 59, .28), transparent 70%),
    radial-gradient(45% 50% at 10% 90%, rgba(20, 106, 80, .55), transparent 70%),
    linear-gradient(180deg, var(--night) 0%, var(--night-2) 100%);
}
.cine-hero-bg::after { /* film grain */
  content: ""; position: absolute; inset: -50%; opacity: .07; mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  animation: grain 1s steps(4) infinite;
}
@keyframes grain { 0% { transform: translate(0, 0); } 25% { transform: translate(-3%, 2%); } 50% { transform: translate(2%, -3%); } 75% { transform: translate(-2%, -2%); } 100% { transform: translate(0, 0); } }

.cine-hero-grid { position: relative; display: grid; grid-template-columns: 1.05fr .95fr; gap: 40px; align-items: center; }
.eyebrow-light { color: var(--terra-glow); }
.split-title { color: #fff; font-size: clamp(2.6rem, 7vw, 5.6rem); line-height: .98; letter-spacing: -.035em; margin-bottom: .35em; }
.split-title .line { display: block; overflow: hidden; padding-bottom: .08em; }
.split-title .word { display: inline-block; }
.split-title em { font-style: italic; color: var(--terra-glow); }
.cine-hero .urdu { font-size: 1.35rem; color: var(--terra-glow); margin: 0 0 12px; }
.cine-hero .lead { color: var(--cream-dim); max-width: 560px; }
.cine-hero .hero-actions { margin-top: 28px; }
.btn-outline-light { background: transparent; color: #faf6ef; border-color: rgba(250, 246, 239, .35); }
.btn-outline-light:hover { color: #fff; border-color: #fff; background: rgba(250, 246, 239, .08); }
.btn-xl { padding: 18px 34px; font-size: 1.08rem; }
.magnetic { transition: transform .35s var(--ease-out), background .15s ease, color .15s ease; }

.cine-map-wrap { position: relative; justify-self: center; width: 100%; max-width: 480px; }
.italy-map { display: block; width: 100%; aspect-ratio: 0.86; }
.map-caption {
  position: absolute; left: 50%; bottom: -8px; transform: translateX(-50%); white-space: nowrap;
  font-size: .82rem; color: var(--cream-dim); display: flex; align-items: center; gap: 8px;
  background: rgba(10, 38, 29, .6); border: 1px solid var(--night-line); padding: 6px 14px; border-radius: 999px; backdrop-filter: blur(6px);
}
.pulse-dot { width: 8px; height: 8px; border-radius: 50%; background: #3ddc84; box-shadow: 0 0 0 0 rgba(61, 220, 132, .6); animation: pulse 1.8s ease-out infinite; }
@keyframes pulse { to { box-shadow: 0 0 0 10px rgba(61, 220, 132, 0); } }

.scroll-cue { position: absolute; left: 50%; bottom: 22px; transform: translateX(-50%); width: 26px; height: 42px; border: 2px solid rgba(250, 246, 239, .4); border-radius: 14px; }
.scroll-cue span { position: absolute; left: 50%; top: 8px; width: 4px; height: 8px; margin-left: -2px; border-radius: 2px; background: #faf6ef; animation: cue 1.6s var(--ease-out) infinite; }
@keyframes cue { 0% { opacity: 0; transform: translateY(0); } 30% { opacity: 1; } 100% { opacity: 0; transform: translateY(14px); } }

@media (max-width: 900px) {
  .cine-hero { min-height: auto; padding: 40px 0 84px; }
  .cine-hero-grid { grid-template-columns: 1fr; gap: 28px; }
  .cine-map-wrap { order: -1; max-width: 300px; }
}

/* ---------- Marquee ---------- */
.marquee { overflow: hidden; background: var(--terra); color: #fff; padding: 18px 0; border-block: 1px solid rgba(0, 0, 0, .08); }
.marquee-track { display: flex; width: max-content; gap: 28px; align-items: center; animation: marquee 38s linear infinite; }
.marquee:hover .marquee-track { animation-play-state: paused; }
.marquee span { font-family: var(--font-head); font-size: clamp(1.3rem, 2.6vw, 2rem); font-weight: 500; white-space: nowrap; letter-spacing: -.01em; }
.marquee i { font-style: normal; opacity: .6; }
@keyframes marquee { to { transform: translateX(-50%); } }

/* ---------- Live deadline cards ---------- */
.deadline-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 18px; }
.dl-card {
  position: relative; display: flex; flex-direction: column; gap: 10px; min-height: 230px; padding: 22px; border-radius: 18px;
  background: var(--paper); border: 1px solid var(--line); color: var(--ink); text-decoration: none; overflow: hidden;
  transition: transform .35s var(--ease-out), box-shadow .35s var(--ease-out), border-color .2s;
}
.dl-card:hover { color: var(--ink); transform: translateY(-4px); box-shadow: 0 18px 40px rgba(14, 77, 58, .14); border-color: var(--green-2); }
.dl-card:focus-visible { outline: 3px solid var(--terra); outline-offset: 3px; }
.dl-card.is-open { background: linear-gradient(160deg, var(--night) 0%, var(--green) 100%); color: #faf6ef; border-color: transparent; }
.dl-card.is-open:hover { color: #fff; }
.dl-top { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.dl-status { font-size: .68rem; font-weight: 800; letter-spacing: .1em; padding: 4px 9px; border-radius: 6px; background: var(--terra-soft); color: var(--terra); }
.dl-card.is-open .dl-status { background: #1f9d55; color: #fff; display: inline-flex; align-items: center; gap: 6px; animation: open-blink 1.2s ease-in-out infinite; }
.dl-card.is-open .dl-status::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: #fff; }
.dl-card.is-closed { opacity: .55; }
.dl-card .lv { font-size: .66rem; font-weight: 700; padding: 2px 8px; border-radius: 999px; background: var(--green-soft); color: var(--green); }
.dl-card.is-open .lv { background: rgba(250, 246, 239, .14); color: #faf6ef; }
.dl-card h3 { font-size: 1.15rem; margin: 2px 0 0; color: inherit; }
.dl-card p { margin: 0; font-size: .88rem; color: var(--muted); }
.dl-card.is-open p { color: var(--cream-dim); }
.dl-card .dl-close { font-weight: 700; color: var(--terra-glow); }
.dl-count { margin-top: auto; display: flex; align-items: baseline; gap: 8px; }
.dl-count b { font-family: var(--font-head); font-size: 3rem; line-height: 1; font-weight: 600; color: var(--green); font-variant-numeric: tabular-nums; }
.dl-card.is-open .dl-count b { color: var(--terra-glow); }
.dl-count span { font-size: .85rem; font-weight: 600; }
.dl-bar { height: 4px; border-radius: 4px; background: var(--line); overflow: hidden; }
.dl-card.is-open .dl-bar { background: rgba(250, 246, 239, .15); }
.dl-bar i { display: block; height: 100%; width: var(--p, 0%); background: linear-gradient(90deg, var(--terra), var(--terra-glow)); border-radius: inherit; }
.small-note { color: var(--muted); font-size: .85rem; margin-top: 18px; }

/* ---------- Why Italy ---------- */
.stat.big { font-size: clamp(2.4rem, 4vw, 3.2rem); background: linear-gradient(120deg, var(--green) 20%, var(--terra) 90%); -webkit-background-clip: text; background-clip: text; color: transparent; font-variant-numeric: tabular-nums; }
.glow-card { position: relative; overflow: hidden; transition: transform .35s var(--ease-out), box-shadow .35s var(--ease-out); }
.glow-card:hover { transform: translateY(-4px); box-shadow: 0 18px 40px rgba(27, 36, 48, .1); }

/* Cursor spotlight on cards (position set by cinema.js) */
.tilt-card, .glow-card { --mx: 50%; --my: 50%; }
.tilt-card::after, .glow-card::after {
  content: ""; position: absolute; inset: 0; border-radius: inherit; pointer-events: none; opacity: 0; transition: opacity .3s;
  background: radial-gradient(320px circle at var(--mx) var(--my), rgba(198, 93, 59, .13), transparent 60%);
}
.tilt-card:hover::after, .glow-card:hover::after { opacity: 1; }
.tilt-card { position: relative; transform-style: preserve-3d; transition: transform .25s ease-out, box-shadow .3s; will-change: transform; }
.tilt-card:hover { box-shadow: 0 22px 48px rgba(27, 36, 48, .12); }
.level-num { position: absolute; right: 18px; top: 6px; font-family: var(--font-head); font-size: 4.6rem; font-weight: 600; color: var(--green-soft); line-height: 1; pointer-events: none; }
.section.alt .level-num { color: #ece3d4; }
.level-card > *:not(.level-num) { position: relative; }

/* ---------- Journey (How it works) ---------- */
.journey { background: var(--night); color: #faf6ef; padding: 96px 0; position: relative; }
.journey h2 { color: #fff; }
.journey-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 56px; align-items: start; }
.journey-sticky { position: sticky; top: 96px; }
.journey-svg { width: 100%; height: auto; margin-top: 12px; overflow: visible; }
.jp-city circle { fill: var(--terra); }
.jp-it circle { fill: #3ddc84; }
.jp-city text { fill: var(--cream-dim); font: 600 15px var(--font-body); }
.journey-count { font-family: var(--font-head); font-size: 4rem; line-height: 1; color: var(--terra-glow); font-variant-numeric: tabular-nums; }
.journey-count small { font-size: 1.2rem; color: var(--cream-dim); margin-left: 6px; }
.journey-steps { list-style: none; margin: 0; padding: 0; }
.journey-step { min-height: 62vh; display: flex; flex-direction: column; justify-content: center; border-left: 1px solid var(--night-line); padding-left: 32px; opacity: .35; transition: opacity .5s ease; }
.journey-step.is-active { opacity: 1; }
.journey-step .js-num { font-family: var(--font-head); color: var(--terra-glow); font-size: 1.1rem; margin-bottom: 8px; }
.journey-step h3 { color: #fff; font-size: clamp(1.6rem, 3vw, 2.3rem); }
.journey-step p { color: var(--cream-dim); font-size: 1.05rem; max-width: 460px; }
@media (max-width: 900px) {
  .journey { padding: 72px 0; }
  .journey-grid { grid-template-columns: 1fr; gap: 8px; }
  .journey-sticky { position: relative; top: 0; }
  .journey-step { min-height: auto; padding: 22px 0 22px 22px; opacity: 1; }
  .journey-count { display: none; }
}

/* ---------- Promise (scroll-lit text) ---------- */
.promise-cine { background: var(--cream); }
.scrub-text { font-family: var(--font-head); font-size: clamp(1.7rem, 4.2vw, 3.2rem); line-height: 1.18; letter-spacing: -.02em; color: var(--ink); max-width: 1000px; margin: 8px 0 48px; }
.scrub-text .w { opacity: .14; transition: opacity .2s linear; }
.promise-grid { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(2, 1fr); gap: 18px; }
.promise-grid li { display: grid; grid-template-columns: 28px 1fr; gap: 12px; background: var(--paper); border: 1px solid var(--line); border-radius: 16px; padding: 22px; color: var(--muted); }
.promise-grid svg { width: 24px; height: 24px; color: var(--terra); margin-top: 2px; }
.promise-grid strong { display: block; color: var(--ink); }
@media (max-width: 700px) { .promise-grid { grid-template-columns: 1fr; } }

/* ---------- Final CTA ---------- */
.ciao { position: relative; overflow: hidden; text-align: center; padding: 110px 0 120px; background: linear-gradient(180deg, var(--terra) 0%, #a9472a 100%); color: #fff; }
.ciao-word { font-family: var(--font-head); font-size: clamp(3.4rem, 13vw, 11rem); line-height: .9; letter-spacing: -.05em; margin: 0 0 24px; color: rgba(255, 255, 255, .95); }
.ciao-word em { font-style: italic; color: #ffe2d6; }
.ciao h2 { color: #fff; }
.ciao p { color: #fde9e1; max-width: 560px; margin-left: auto; margin-right: auto; }
.ciao .urdu { color: #fff; font-size: 1.2rem; }
.ciao .btn { margin-top: 14px; }
.page-home .site-footer { margin-top: 0; }

/* ---------- Inner pages: dark cinematic hero ---------- */
.page-hero {
  position: relative; overflow: hidden; isolation: isolate; color: #faf6ef; padding: 96px 0 84px;
  background:
    radial-gradient(55% 80% at 85% 20%, rgba(198, 93, 59, .3), transparent 70%),
    radial-gradient(45% 70% at 5% 100%, rgba(20, 106, 80, .6), transparent 70%),
    linear-gradient(180deg, var(--night) 0%, var(--night-2) 100%);
}
.page-hero::before { /* slow drifting glow */
  content: ""; position: absolute; width: 520px; height: 520px; right: -140px; top: -200px; border-radius: 50%; pointer-events: none; z-index: -1;
  background: radial-gradient(circle, rgba(243, 184, 163, .22), transparent 65%); animation: drift 14s ease-in-out infinite alternate;
}
.page-hero::after { /* giant outlined Italian word */
  content: attr(data-bgword); position: absolute; right: 2%; bottom: -.22em; z-index: -1; pointer-events: none; white-space: nowrap;
  font-family: var(--font-head); font-style: italic; font-weight: 600; font-size: clamp(5rem, 17vw, 15rem); line-height: 1; letter-spacing: -.04em;
  color: transparent; -webkit-text-stroke: 1.5px rgba(250, 246, 239, .13);
}
@keyframes drift { to { transform: translate(-80px, 60px) scale(1.15); } }
.page-hero > .container { position: relative; }
.page-hero h1 { color: #fff; font-size: clamp(2.3rem, 5.6vw, 4.4rem); line-height: 1.02; letter-spacing: -.03em; max-width: 900px; }
.page-hero .article h1 { font-size: clamp(2rem, 4.4vw, 3.2rem); }
.page-hero .lead, .page-hero .muted { color: var(--cream-dim); }
.page-hero .eyebrow { color: var(--terra-glow); }
.page-hero .urdu { color: var(--terra-glow); font-size: 1.25rem; }
.page-hero .breadcrumb, .page-hero .breadcrumb a { color: rgba(250, 246, 239, .6); }
.page-hero .breadcrumb a:hover { color: #fff; }
.page-hero + .section { padding-top: 64px !important; }
.split-inline .wm { display: inline-block; overflow: hidden; vertical-align: top; padding-bottom: .1em; margin-bottom: -.1em; }
@media (max-width: 640px) { .page-hero { padding: 64px 0 60px; } }

/* 404 */
.page-plain .page-hero .center { padding: 40px 0; }
.lost-plane { width: min(600px, 100%); height: auto; margin: 36px auto 0; overflow: visible; }

/* Dark feature cards (services "Most requested", contact details) */
.card-dark { background: linear-gradient(160deg, var(--night) 0%, var(--green) 100%) !important; color: #faf6ef; border-color: transparent; }
.card-dark h3 { color: #fff; }
.card-dark .muted, .card-dark .meta, .card-dark li { color: var(--cream-dim); }
.card-dark .check-list li::before { border-color: var(--terra-glow); }
.card-dark a { color: var(--terra-glow); }
.card-dark a:hover { color: #fff; }
.card-dark .contact-line { border-top-color: var(--night-line); }
.card-dark .contact-line svg { color: var(--terra-glow); }
.card-dark strong { color: #fff; }
.card-dark .pulse-dot { display: inline-block; vertical-align: 1px; margin-right: 4px; }
.card-dark::after { background: radial-gradient(320px circle at var(--mx) var(--my), rgba(243, 184, 163, .16), transparent 60%) !important; }

/* Services: big faded number on every package */
.section > .grid-2 { counter-reset: svc; }
.service { counter-increment: svc; position: relative; }
.service::before {
  content: counter(svc, decimal-leading-zero); position: absolute; right: 18px; bottom: 6px; z-index: 0; pointer-events: none;
  font-family: var(--font-head); font-size: 4.2rem; font-weight: 600; line-height: 1; color: var(--green-soft);
}
.service.card-dark::before { color: rgba(250, 246, 239, .08); }
.service > * { position: relative; z-index: 1; }

/* FAQ */
.faq details { transition: border-color .25s, box-shadow .25s; }
.faq details:hover { border-color: var(--green-2); }
.faq details[open] { border-color: var(--terra); box-shadow: 0 12px 30px rgba(198, 93, 59, .1); }
.faq summary:hover { color: var(--terra); }

/* CTA band + promise box: cinematic versions */
.cta-band { position: relative; overflow: hidden; isolation: isolate; background: linear-gradient(135deg, var(--terra) 0%, #a9472a 100%); }
.cta-band::after {
  content: "Ciao"; position: absolute; right: -10px; bottom: -.3em; z-index: -1; pointer-events: none;
  font-family: var(--font-head); font-style: italic; font-size: 9rem; line-height: 1; color: transparent; -webkit-text-stroke: 1.5px rgba(255, 255, 255, .22);
}
.promise { position: relative; overflow: hidden; background: linear-gradient(160deg, var(--night) 0%, var(--green) 100%); }

/* About: rotating gradient ring around team initials */
@property --ang { syntax: "<angle>"; initial-value: 0deg; inherits: false; }
.person .avatar {
  overflow: visible; color: #faf6ef; border: 3px solid transparent;
  background: linear-gradient(var(--night), var(--night)) padding-box, conic-gradient(from var(--ang), var(--terra), var(--terra-glow), var(--green-2), var(--terra)) border-box;
  animation: ring 6s linear infinite;
}
@keyframes ring { to { --ang: 360deg; } }

/* Guides: accent bar grows on hover, arrow slides */
.post-card { position: relative; overflow: hidden; }
.post-card::before { content: ""; position: absolute; inset: 0 0 auto 0; height: 4px; background: linear-gradient(90deg, var(--terra), var(--terra-glow)); transform: scaleX(.15); transform-origin: 0 50%; transition: transform .5s var(--ease-out); }
.post-card:hover::before { transform: scaleX(1); }
.post-card .more span { display: inline-block; transition: transform .3s var(--ease-out); }
.post-card:hover .more span { transform: translateX(6px); }

/* Articles */
.article h2::before { content: ""; display: block; width: 46px; height: 3px; border-radius: 3px; margin-bottom: 14px; background: linear-gradient(90deg, var(--terra), var(--terra-glow)); }
.article .note { background: linear-gradient(90deg, var(--terra-soft), #fbf1ec); }
tbody tr { transition: background .2s; }
tbody tr:hover td { background: var(--cream); }

/* Contact form */
input, select, textarea { transition: border-color .2s, box-shadow .2s; }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--green-2); box-shadow: 0 0 0 4px rgba(20, 106, 80, .15); }
#enquiry-form { border-top: 4px solid var(--terra); }

/* ---------- Reveal states (only when JS runs and motion is allowed) ---------- */
.js.motion-ok [data-reveal], .js.motion-ok [data-rise] { opacity: 0; transform: translateY(28px); }
.js.motion-ok .split-title .word { transform: translateY(110%); }

/* ---------- Reduced motion: everything static and readable ---------- */
@media (prefers-reduced-motion: reduce) {
  .cine-hero-bg::after, .marquee-track, .pulse-dot, .scroll-cue span, .page-hero::before, .person .avatar, .dl-card.is-open .dl-status { animation: none !important; }
  .marquee-track { flex-wrap: wrap; width: auto; justify-content: center; }
  .scrub-text .w { opacity: 1 !important; }
  .tilt-card, .glow-card, .dl-card { transition: none; }
}
