:root {
  --lapis: #16225a;
  --lapis-2: #24379a;
  --night: #0d1438;
  --ink: #121a45;
  --text: #3b3f5c;
  --muted: #5d6079;
  --turq: #0e6f7a;
  --turq-2: #1fb0b8;
  --gold: #c9a24a;
  --gold-2: #e6c879;
  --gold-ink: #94721f;
  --ivory: #f8f3e8;
  --ivory-2: #f0e7d4;
  --card: #fffdf8;
  --line: #e2d6ba;
  --serif: "Cormorant Garamond", Georgia, serif;
  --sans: "Manrope", system-ui, sans-serif;
  --ease: cubic-bezier(.2, .7, .2, 1);
}
* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; scroll-padding-top: 90px; -webkit-text-size-adjust: 100%; }
body { background: var(--ivory); color: var(--text); font-family: var(--sans); font-size: 17px; line-height: 1.65; overflow-x: hidden; -webkit-font-smoothing: antialiased; }
img { display: block; max-width: 100%; height: auto; }
a { color: var(--lapis-2); text-underline-offset: 3px; }
:focus-visible { outline: 2px solid var(--turq); outline-offset: 3px; border-radius: 6px; }
::selection { background: var(--gold-2); color: var(--ink); }
.wrap { width: min(1200px, 100% - 48px); margin-inline: auto; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: 12px; top: -60px; z-index: 200; padding: 10px 14px; border-radius: 8px; background: var(--ink); color: #fff; }
.skip:focus { top: 12px; }
h1, h2, h3, dd, b, .lede, .motto { font-variant-numeric: lining-nums; }
h1, h2, h3 { font-family: var(--serif); color: var(--ink); font-weight: 600; line-height: 1.08; letter-spacing: -.005em; }
h2 { font-size: clamp(36px, 4.4vw, 58px); }
h2 em, h1 em { font-style: italic; font-weight: 500; color: var(--gold-ink); }
.pattern { position: absolute; inset: 0; width: 100%; height: 100%; color: var(--gold); opacity: .09; pointer-events: none; }

/* progress */
.ink-bar { position: fixed; inset: 0 0 auto; height: 3px; z-index: 80; }
.ink-bar span { display: block; height: 100%; background: linear-gradient(90deg, var(--turq-2), var(--gold)); transform-origin: 0 50%; transform: scaleX(0); }

/* header */
.site-head { position: sticky; top: 0; z-index: 60; background: rgba(248, 243, 232, .9); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); border-bottom: 1px solid var(--line); }
.head-row { display: flex; align-items: center; gap: 24px; min-height: 70px; }
.brand { display: flex; align-items: center; gap: 12px; text-decoration: none; color: var(--ink); flex: none; }
.brand img { width: 46px; height: 46px; border-radius: 50%; box-shadow: 0 0 0 2px var(--ivory), 0 0 0 3px var(--gold); }
.brand span { display: flex; flex-direction: column; line-height: 1.1; }
.brand b { font-family: var(--serif); font-size: 22px; font-weight: 700; }
.brand i { font-style: normal; font-size: 11.5px; letter-spacing: .14em; text-transform: uppercase; color: var(--turq); margin-top: 3px; font-weight: 600; }
.index-nav { position: relative; display: flex; gap: 26px; margin-left: auto; overflow-x: auto; scrollbar-width: none; }
.index-nav::-webkit-scrollbar { display: none; }
.index-nav a { flex: none; position: relative; padding: 10px 0; font-size: 15px; font-weight: 600; color: var(--ink); text-decoration: none; }
.index-nav a::after { content: ""; position: absolute; left: 50%; bottom: 4px; width: 6px; height: 6px; background: var(--gold); transform: translateX(-50%) rotate(45deg) scale(0); transition: transform .3s var(--ease); }
.index-nav a:hover::after, .index-nav a.on::after { transform: translateX(-50%) rotate(45deg) scale(1); }
.index-nav a.on { color: var(--turq); }

/* buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 10px; min-height: 48px; padding: 0 24px; border-radius: 999px; font-weight: 700; font-size: 15.5px; text-decoration: none; border: 0; cursor: pointer; transition: transform .25s var(--ease), box-shadow .25s, background .25s, color .25s, border-color .25s; }
.btn:hover { transform: translateY(-2px); }
.btn-sm { min-height: 42px; padding: 0 18px; font-size: 14.5px; }
.btn-big { min-height: 58px; padding: 0 30px; font-size: 16.5px; }
.btn-gold { background: linear-gradient(180deg, var(--gold-2), var(--gold)); color: var(--night); box-shadow: 0 12px 26px -14px rgba(201, 162, 74, .9), inset 0 1px 0 rgba(255, 255, 255, .5); }
.btn-gold:hover { color: var(--night); box-shadow: 0 18px 32px -14px rgba(201, 162, 74, 1), inset 0 1px 0 rgba(255, 255, 255, .5); }
.btn-line { border: 1.5px solid var(--lapis-2); color: var(--lapis-2); background: transparent; }
.btn-line:hover { background: var(--lapis-2); color: #fff; }
.btn-ghost-light { border: 1.5px solid rgba(255, 255, 255, .45); color: #fff; }
.btn-ghost-light:hover { border-color: #fff; color: #fff; background: rgba(255, 255, 255, .08); }

/* hero */
.hero { position: relative; overflow: hidden; color: #e9ecf8; background: radial-gradient(900px 600px at 78% 35%, #2b3fa3 0%, var(--lapis) 55%, var(--night) 100%); padding: 64px 0 0; }
.glow { position: absolute; width: 520px; height: 520px; left: 72%; top: 46%; transform: translate(-50%, -50%); border-radius: 50%; background: radial-gradient(circle, rgba(230, 200, 121, .28), transparent 65%); pointer-events: none; }
.hero-grid { position: relative; display: grid; grid-template-columns: 1.15fr .85fr; gap: 56px; align-items: center; }
.hero-copy { display: flex; flex-direction: column; gap: 22px; }
.chip { align-self: flex-start; display: inline-flex; align-items: center; gap: 10px; padding: 8px 16px; border-radius: 999px; background: rgba(255, 255, 255, .08); border: 1px solid rgba(230, 200, 121, .35); color: var(--gold-2); font-size: 14px; font-weight: 600; }
.dot { width: 8px; height: 8px; border-radius: 50%; background: var(--turq-2); box-shadow: 0 0 0 0 rgba(31, 176, 184, .7); animation: ping 2.2s infinite; }
@keyframes ping { 70% { box-shadow: 0 0 0 9px rgba(31, 176, 184, 0); } 100% { box-shadow: 0 0 0 0 rgba(31, 176, 184, 0); } }
.hero h1 { color: #fff; font-size: clamp(46px, 6.2vw, 86px); line-height: 1; font-weight: 600; }
.hero h1 em { color: var(--gold-2); }
.hero-lead { font-size: clamp(18px, 1.6vw, 21px); color: #c9cfec; max-width: 34rem; }
.cta-note { font-size: 14.5px; color: #aab2da; margin-top: 12px; max-width: 30rem; }
.secondary { list-style: none; display: grid; grid-template-columns: repeat(2, max-content); gap: 4px 28px; }
.secondary a { display: inline-flex; align-items: center; gap: 8px; min-height: 40px; color: #fff; font-weight: 600; font-size: 15px; text-decoration: none; border-bottom: 1px solid rgba(230, 200, 121, .35); transition: border-color .25s, color .25s; }
.secondary a::after { content: "→"; color: var(--gold-2); transition: transform .25s var(--ease); }
.secondary a:hover { border-color: var(--gold-2); }
.secondary a:hover::after { transform: translateX(4px); }

.hero-art { position: relative; justify-self: center; width: min(400px, 100%); margin: 0; }
/* pishtaq: arched portal framing the full, uncropped photo */
.pishtaq { position: relative; padding: 96px 16px 16px; background: linear-gradient(180deg, #fbf6ea, #efe4cc); border-radius: 50% 50% 22px 22px / 170px 170px 22px 22px; box-shadow: 0 0 0 1px var(--gold), 0 40px 80px -30px rgba(0, 0, 0, .6); }
.pishtaq::before { content: ""; position: absolute; inset: 8px; border: 1px solid var(--gold); border-radius: 50% 50% 16px 16px / 162px 162px 16px 16px; pointer-events: none; }
.crest { position: absolute; left: 50%; top: 18px; width: 64px; height: 64px; border-radius: 50%; transform: translateX(-50%); box-shadow: 0 0 0 3px #fbf6ea, 0 0 0 4px var(--gold); }
.photo { display: block; border-radius: 12px; overflow: hidden; aspect-ratio: 360 / 476; }
.photo img { width: 100%; height: 100%; object-fit: contain; transition: transform 1.2s var(--ease); }
.photo:hover img { transform: scale(1.03); }
.spin-star { position: absolute; z-index: 2; width: 74px; height: 74px; right: -22px; top: 70px; fill: var(--gold-2); filter: drop-shadow(0 6px 14px rgba(0, 0, 0, .35)); animation: spin 26s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.badge { position: absolute; z-index: 2; left: -30px; bottom: 54px; display: flex; flex-direction: column; padding: 12px 18px; border-radius: 14px; background: #fff; color: var(--ink); text-decoration: none; box-shadow: 0 20px 40px -18px rgba(0, 0, 0, .55); border-left: 4px solid var(--turq); animation: floaty 5.5s ease-in-out infinite; }
.badge span { font-size: 12px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--turq); }
.badge b { font-size: 17px; }
@keyframes floaty { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-8px); } }
.hero-facts { position: relative; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); margin-top: 64px; border-top: 1px solid rgba(230, 200, 121, .3); }
.hero-facts div { padding: 22px 20px 26px 0; }
.hero-facts div + div { padding-left: 22px; border-left: 1px solid rgba(230, 200, 121, .18); }
.hero-facts dt { font-size: 12px; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--turq-2); }
.hero-facts dd { font-family: var(--serif); font-size: clamp(26px, 2.6vw, 36px); font-weight: 600; color: #fff; line-height: 1.2; }

/* tile border, like a glazed frieze */
.tile-band { height: 26px; background-color: var(--turq); background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='52' height='26'%3E%3Cpath d='M26 3l3 7 7-3-3 6 7 3-7 3 3 6-7-3-3 7-3-7-7 3 3-6-7-3 7-3-3-6 7 3z' fill='%23e6c879'/%3E%3Cpath d='M0 13l6-6 6 6-6 6zM40 13l6-6 6 6-6 6z' fill='%2316225a'/%3E%3C/svg%3E"); border-top: 3px solid var(--gold); border-bottom: 3px solid var(--gold); }

/* load-in */
.rise { animation: rise .9s var(--ease) both; }
.d1 { animation-delay: .08s; } .d2 { animation-delay: .18s; } .d3 { animation-delay: .28s; } .d4 { animation-delay: .38s; }
@keyframes rise { from { opacity: 0; transform: translateY(22px); } to { opacity: 1; transform: none; } }

/* sections */
.sec { padding: 100px 0; }
.sec-tint { background: var(--ivory-2); }
.sec-head { margin-bottom: 44px; }
.sec-head-row { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 20px; }
.eyebrow { display: inline-flex; align-items: center; gap: 10px; margin-bottom: 12px; font-size: 13px; font-weight: 700; letter-spacing: .16em; text-transform: uppercase; color: var(--turq); }
.eyebrow svg { width: 16px; height: 16px; fill: var(--gold); }
.eyebrow.light { color: var(--turq-2); }
.prose p { margin-bottom: 16px; max-width: 60ch; }
.lede { font-family: var(--serif); font-size: clamp(23px, 2.2vw, 29px); line-height: 1.32; color: var(--ink); }
.two-col { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr); gap: 56px; align-items: start; }
.index-list { background: var(--card); border: 1px solid var(--line); border-radius: 22px; padding: 8px 26px; }
.index-list div { display: grid; grid-template-columns: 160px 1fr; gap: 16px; padding: 14px 0; }
.index-list div + div { border-top: 1px dashed var(--line); }
.index-list dt { font-size: 12px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); padding-top: 3px; }
.index-list dd { color: var(--ink); font-weight: 600; }
.aside-note { margin-top: 36px; padding: 16px 20px; border-radius: 14px; background: rgba(19, 138, 150, .08); border-left: 3px solid var(--turq); font-size: 15.5px; max-width: 80ch; }

/* arched cards */
.arches { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 24px; }
.arch-card { position: relative; text-align: center; background: var(--card); border: 1px solid var(--line); border-radius: 160px 160px 20px 20px; padding: 58px 30px 34px; transition: transform .4s var(--ease), box-shadow .4s, border-color .4s; }
.arch-card::before { content: ""; position: absolute; inset: 8px; border: 1px solid rgba(201, 162, 74, .35); border-radius: 152px 152px 14px 14px; pointer-events: none; transition: border-color .4s; }
.arch-card:hover { transform: translateY(-6px); box-shadow: 0 30px 50px -32px rgba(22, 34, 90, .55); border-color: var(--gold); }
.arch-card:hover::before { border-color: var(--gold); }
.arch-ic { display: grid; place-items: center; width: 64px; height: 64px; margin: 0 auto 18px; border-radius: 50%; background: var(--turq); color: #fff; box-shadow: 0 0 0 6px rgba(19, 138, 150, .12); transition: transform .5s var(--ease); }
.arch-card:hover .arch-ic { transform: rotate(-10deg) scale(1.06); }
.arch-ic svg { width: 28px; height: 28px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.arch-card h3 { font-size: 32px; margin-bottom: 10px; }
.arch-card p { font-size: 15.5px; color: var(--muted); }

/* feature (teachers) */
.feature { display: grid; grid-template-columns: 320px minmax(0, 1fr); gap: 64px; align-items: center; }
.frame { margin: 0; padding: 12px; background: var(--card); border: 1px solid var(--gold); border-radius: 22px; box-shadow: 0 30px 60px -36px rgba(22, 34, 90, .6); transform: rotate(-2deg); transition: transform .5s var(--ease); }
.frame:hover { transform: rotate(0); }
.frame img { border-radius: 12px; }
.feature h2 { margin-bottom: 18px; }
.feature .btn { margin-top: 8px; }

/* values */
.values-band { position: relative; overflow: hidden; background: var(--lapis); padding: 90px 0; text-align: center; }
.values { display: grid; grid-template-columns: 1fr auto 1fr auto 1fr; align-items: center; gap: 24px; margin-top: 18px; }
.values h3 { font-size: clamp(54px, 7vw, 96px); color: var(--gold-2); font-weight: 600; font-style: italic; }
.values p { color: #c9cfec; font-size: 16px; max-width: 24ch; margin: 6px auto 0; }
.v-star { width: 26px; height: 26px; fill: var(--turq-2); animation: spin 18s linear infinite; }

/* news */
.news { display: grid; gap: 44px; }
.story-lead { display: grid; grid-template-columns: 300px minmax(0, 1fr); gap: 48px; align-items: center; padding: 22px; background: var(--card); border: 1px solid var(--line); border-radius: 26px; }
.story-lead h3 { font-size: clamp(32px, 3.4vw, 46px); margin: 6px 0 14px; }
.story-lead p { max-width: 54ch; }
.story-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 26px; }
.story h3 { font-size: 24px; margin: 4px 0 4px; }
.story-grid .story p:not(.tag) { font-size: 14.5px; color: var(--muted); }
.story-grid .poster { margin-bottom: 16px; }
.tag { font-size: 12px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--turq); }
.source { font-size: 13px; color: var(--muted); margin-top: 12px; }
.poster { position: relative; display: block; aspect-ratio: 9 / 16; overflow: hidden; border-radius: 16px; background: var(--ivory-2); box-shadow: 0 0 0 1px rgba(201, 162, 74, .45), 0 24px 40px -28px rgba(22, 34, 90, .6); transition: transform .45s var(--ease), box-shadow .45s var(--ease); }
.poster img { width: 100%; height: 100%; object-fit: contain; }
.poster:hover { transform: translateY(-6px); box-shadow: 0 0 0 2px var(--gold), 0 34px 50px -28px rgba(22, 34, 90, .7); }
.play { position: absolute; right: 14px; bottom: 14px; width: 48px; height: 48px; border-radius: 50%; background: rgba(255, 255, 255, .95); box-shadow: 0 8px 20px -6px rgba(0, 0, 0, .4); transition: transform .3s var(--ease), background .3s; }
.play::after { content: ""; position: absolute; left: 19px; top: 15px; border-left: 14px solid var(--turq); border-top: 9px solid transparent; border-bottom: 9px solid transparent; }
.poster:hover .play { transform: scale(1.1); }

/* admissions */
.admit { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 48px; align-items: start; }
.coupon { position: relative; overflow: hidden; padding: 34px 32px 32px; border-radius: 26px; background: var(--lapis); color: #e9ecf8; box-shadow: 0 40px 70px -40px rgba(13, 20, 56, .8); }
.coupon > * { position: relative; }
.coupon .pattern { position: absolute; }
.coupon h3 { color: #fff; font-size: clamp(28px, 2.8vw, 36px); margin-bottom: 18px; }
.coupon .kicker { color: var(--gold-2); font-size: 12.5px; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; margin-bottom: 10px; }
.coupon .cta-note { color: #aab2da; margin: 0 0 20px; }
.spec { width: 100%; border-collapse: collapse; margin-bottom: 24px; font-size: 16px; }
.spec caption { text-align: left; padding-bottom: 8px; font-size: 12.5px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }
.spec th, .spec td { text-align: left; vertical-align: top; padding: 12px 0; border-bottom: 1px solid var(--line); }
.spec th { width: 34%; font-size: 12px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); padding-top: 15px; }
.spec td { color: var(--ink); font-weight: 600; }
.coupon .spec th { color: var(--gold-2); border-color: rgba(230, 200, 121, .22); }
.coupon .spec td { color: #fff; border-color: rgba(230, 200, 121, .22); }
.actions { display: flex; flex-wrap: wrap; align-items: center; gap: 14px; }
.process { list-style: none; display: grid; gap: 12px; }
.process li { display: grid; grid-template-columns: 54px 1fr; gap: 18px; align-items: start; padding: 18px 20px; background: var(--card); border: 1px solid var(--line); border-radius: 18px; transition: border-color .3s, transform .3s var(--ease); }
.process li:hover { border-color: var(--gold); transform: translateX(4px); }
.process b { display: grid; place-items: center; width: 50px; height: 50px; background: var(--turq); color: #fff; font-family: var(--serif); font-size: 26px; clip-path: polygon(30% 0, 70% 0, 100% 30%, 100% 70%, 70% 100%, 30% 100%, 0 70%, 0 30%); }
.process h3, .process h4 { font-family: var(--serif); font-size: 24px; line-height: 1.2; color: var(--ink); margin-bottom: 2px; }
.process p { font-size: 15.5px; color: var(--muted); }

/* contacts */
.contacts { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 14px; }
.ad { display: block; padding: 24px 22px; background: var(--card); border: 1px solid var(--line); border-top: 3px solid var(--gold); border-radius: 18px; color: var(--ink); text-decoration: none; transition: transform .3s var(--ease), background .3s, color .3s; }
.ad span { display: block; font-size: 12px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--turq); margin-bottom: 8px; }
.ad b { font-family: var(--serif); font-size: 25px; font-weight: 600; word-break: break-word; line-height: 1.2; }
.contacts .ad b { font-size: 19px; }
.ad small { display: block; font-size: 14px; color: var(--muted); margin-top: 6px; }
.ad:hover { transform: translateY(-4px); background: var(--lapis); color: #fff; }
.ad:hover span { color: var(--gold-2); }
.ad:hover small { color: #c9cfec; }

/* footer */
.site-foot { position: relative; overflow: hidden; background: var(--night); color: #c9cfec; padding: 56px 0 26px; border-top: 3px solid var(--gold); }
.foot-row { position: relative; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 24px; }
.brand-light { color: #fff; }
.brand-light b { color: #fff; }
.brand-light i { color: var(--turq-2); }
.foot-links { display: flex; flex-wrap: wrap; gap: 6px 26px; }
.foot-links a { color: #fff; text-decoration: none; padding: 8px 0; font-weight: 600; }
.foot-links a:hover { color: var(--gold-2); }
.foot-bottom { position: relative; display: flex; flex-wrap: wrap; justify-content: space-between; gap: 10px; margin-top: 34px; padding-top: 20px; border-top: 1px solid rgba(230, 200, 121, .2); font-size: 14px; }
.motto { font-family: var(--serif); font-style: italic; font-size: 18px; color: var(--gold-2); }

/* sub page (qabul) */
.page-hero { position: relative; overflow: hidden; background: radial-gradient(900px 500px at 80% 20%, #2b3fa3 0%, var(--lapis) 55%, var(--night) 100%); color: #e9ecf8; padding: 46px 0 64px; }
.crumbs { position: relative; display: flex; gap: 8px; font-size: 14px; color: #aab2da; margin-bottom: 24px; }
.crumbs a { color: #fff; }
.page-hero h1 { position: relative; color: #fff; font-size: clamp(42px, 5.4vw, 74px); max-width: 16ch; margin: 14px 0 18px; }
.page-hero .hero-lead { position: relative; margin-bottom: 26px; }
.page-hero .actions { position: relative; }
.faq { display: grid; gap: 12px; }
.faq details { background: var(--card); border: 1px solid var(--line); border-radius: 16px; padding: 0 22px; transition: border-color .3s; }
.faq details[open] { border-color: var(--gold); }
.faq summary { cursor: pointer; list-style: none; padding: 18px 34px 18px 0; position: relative; font-family: var(--serif); font-weight: 600; font-size: 23px; color: var(--ink); }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; position: absolute; right: 0; top: 14px; font-family: var(--sans); font-size: 24px; color: var(--turq); transition: transform .3s var(--ease); }
.faq details[open] summary::after { transform: rotate(45deg); }
.faq details p { padding: 0 0 20px; max-width: 70ch; color: var(--muted); }

/* mobile action bar */
.action-bar { display: none; }

/* scroll reveal */
.js .reveal { opacity: 0; transform: translateY(24px); transition: opacity .9s var(--ease), transform .9s var(--ease); transition-delay: var(--delay, 0s); }
.js .reveal.in { opacity: 1; transform: none; }

/* responsive */
@media (max-width: 1060px) {
  .head-row { flex-wrap: wrap; gap: 0 16px; min-height: 0; padding-top: 10px; }
  .head-cta { margin-left: auto; }
  .index-nav { order: 3; width: 100%; margin: 4px 0 0; gap: 22px; border-top: 1px solid var(--line); }
  html { scroll-padding-top: 120px; }
  .hero-grid { grid-template-columns: 1fr; gap: 48px; }
  .hero-art { width: min(360px, 88%); }
  .hero-facts { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .hero-facts div:nth-child(3) { padding-left: 0; border-left: 0; }
  .hero-facts div:nth-child(n+3) { border-top: 1px solid rgba(230, 200, 121, .18); }
  .story-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .contacts { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .arches { grid-template-columns: 1fr; max-width: 520px; margin-inline: auto; }
}
@media (max-width: 760px) {
  body { font-size: 16.5px; padding-bottom: 66px; }
  .wrap { width: calc(100% - 32px); }
  .brand b { font-size: 19px; }
  .brand i { display: none; }
  .brand img { width: 40px; height: 40px; }
  .head-cta { display: none; }
  .sec { padding: 72px 0; }
  .hero { padding-top: 40px; }
  .chip { font-size: 12.5px; padding: 7px 14px; }
  .btn-big { width: 100%; font-size: 15px; padding: 0 18px; }
  .secondary { grid-template-columns: 1fr 1fr; gap: 4px 16px; }
  .secondary a { font-size: 14px; }
  .badge { left: -8px; bottom: 30px; }
  .spin-star { right: -6px; width: 56px; height: 56px; }
  .two-col, .admit, .feature { grid-template-columns: 1fr; gap: 34px; }
  .feature .frame { max-width: 270px; margin: 0 auto; }
  .index-list div { grid-template-columns: 1fr; gap: 2px; }
  .values { grid-template-columns: 1fr; gap: 14px; }
  .story-lead { grid-template-columns: 1fr; gap: 22px; padding: 16px; }
  .story-lead .poster { max-width: 280px; margin: 0 auto; width: 100%; }
  .story-grid { gap: 18px; }
  .story h3 { font-size: 21px; }
  .coupon { padding: 26px 20px 24px; }
  .contacts { grid-template-columns: 1fr; }
  .process li { grid-template-columns: 46px 1fr; padding: 16px; }
  .process b { width: 44px; height: 44px; font-size: 22px; }
  .action-bar { display: grid; grid-template-columns: 1fr auto; position: fixed; left: 0; right: 0; bottom: 0; z-index: 70; gap: 8px; padding: 8px 12px calc(8px + env(safe-area-inset-bottom)); background: rgba(248, 243, 232, .96); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); border-top: 1px solid var(--line); transform: translateY(110%); transition: transform .35s var(--ease); }
  .action-bar.show { transform: none; }
  .action-bar a { display: grid; place-items: center; min-height: 48px; padding: 0 20px; border-radius: 999px; font-weight: 700; font-size: 15px; text-decoration: none; }
  .ab-main { background: linear-gradient(180deg, var(--gold-2), var(--gold)); color: var(--night); }
  .ab-call { border: 1.5px solid var(--lapis-2); color: var(--lapis-2); }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  html { scroll-behavior: auto; }
  .js .reveal { opacity: 1; transform: none; }
}

/* ===== horizontal journey (homepage) =====
   Base = stacked chapters (phones, short screens, reduced motion).
   .is-h (set by app.js) = pinned stage that slides sideways while scrolling. */
.journey-page { background: var(--night); }
.panel { position: relative; overflow: hidden; overflow: clip; padding: 84px 20px; }
.p-intro, .p-events, .p-contact, .p-english { background: radial-gradient(900px 600px at 75% 35%, #2b3fa3 0%, var(--lapis) 55%, var(--night) 100%); color: #e9ecf8; }
.p-about, .p-teachers, .p-admit { background: var(--ivory); }
.p-monitor { background: var(--ivory-2); }
.p-values { background: var(--night); color: #e9ecf8; text-align: center; }
.p-intro h1 { color: #fff; font-size: clamp(44px, 5.4vw, 82px); line-height: 1; }
.p-intro h1 em, .p-events h2 em, .p-contact h2 em { color: var(--gold-2); }
.p-events h2, .p-contact h2 { color: #fff; }
.p-copy { display: flex; flex-direction: column; align-items: flex-start; gap: 18px; }
.p-copy .btn-big { margin-top: 4px; }
.p-intro .cta-note { margin-top: -6px; }
.p-grid { position: relative; z-index: 1; display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, .9fr); gap: 6vw; align-items: center; width: 100%; max-width: 1240px; margin: 0 auto; }
.p-head { position: relative; z-index: 1; text-align: center; margin-bottom: 28px; }
.p-head h2 { font-size: clamp(36px, 4vw, 56px); }
.small { font-size: 14.5px; color: var(--muted); }
.numeral { position: absolute; right: 3vw; bottom: 2vh; z-index: 0; width: clamp(160px, 42vh, 420px); height: auto; aspect-ratio: 1; fill: none; stroke: rgba(201, 162, 74, .38); stroke-width: 1.5px; pointer-events: none; translate: calc(var(--p, 0) * 160px) 0; }
.drift { translate: calc(var(--p, 0) * -90px) 0; }

/* intro */
.p-media { position: relative; justify-self: center; margin: 0; width: clamp(240px, calc((100vh - 340px) * .74), 390px); }
.scroll-cue { position: absolute; left: 7vw; bottom: 92px; z-index: 2; display: none; align-items: center; gap: 14px; font-size: 13px; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--gold-2); }
.scroll-cue i { font-style: normal; font-size: 22px; animation: nudge 1.6s ease-in-out infinite; }
@keyframes nudge { 50% { transform: translateX(10px); } }

/* about: rotating seal */
.seal { position: relative; justify-self: center; width: min(340px, 70vw); aspect-ratio: 1; margin: 0; display: grid; place-items: center; }
.seal-ring { position: absolute; inset: 0; width: 100%; height: 100%; animation: spin 40s linear infinite; }
.seal-ring text { font-family: var(--sans); font-size: 17px; font-weight: 700; letter-spacing: 5px; fill: var(--gold-ink); }
.seal img { width: 62%; border-radius: 50%; box-shadow: 0 0 0 8px var(--ivory), 0 0 0 9px var(--gold), 0 30px 60px -20px rgba(22, 34, 90, .5); }
.p-about .index-list { width: 100%; }

/* english: big poster + overlapping note */
.p-stage { position: relative; z-index: 1; display: flex; justify-content: center; align-items: center; }
.poster.big { height: min(66vh, 620px); width: auto; flex: none; }
.note-card { color: var(--text); position: relative; z-index: 2; max-width: 440px; margin-left: 48px; margin-top: 14vh; padding: 30px 30px 26px; background: var(--card); border-radius: 22px; box-shadow: 0 40px 70px -30px rgba(0, 0, 0, .55); border-top: 4px solid var(--gold); }
.note-card h2 { font-size: clamp(36px, 3.6vw, 52px); margin-bottom: 12px; }
.note-card p { margin-bottom: 10px; }

/* monitoring */
.poster.tilt { justify-self: center; height: min(64vh, 600px); width: auto; rotate: 4deg; }

/* events: fanned posters */
.fan3 { position: relative; z-index: 1; display: flex; justify-content: center; align-items: center; }
.fan3 figure { margin: 0; text-align: center; }
.fan3 .poster { width: auto; }
.f-c { z-index: 2; }
.f-c .poster { height: min(50vh, 470px); }
.f-l .poster, .f-r .poster { height: min(41vh, 390px); }
.f-l { rotate: -7deg; margin-right: 22px; }
.f-r { rotate: 7deg; margin-left: 22px; }
.fan3 figcaption { margin-top: 14px; font-size: 13.5px; font-weight: 600; color: #e9ecf8; }
.p-more { position: absolute; right: 7vw; bottom: 92px; z-index: 2; }

/* teachers */
.p-stage-c { position: relative; display: grid; place-items: center; }
.p-teachers .frame img { height: min(58vh, 540px); width: auto; }
.stage-star { position: absolute; fill: var(--gold); animation: spin 22s linear infinite; }
.stage-star.s1 { width: 54px; height: 54px; left: 6%; top: 8%; }
.stage-star.s2 { width: 30px; height: 30px; right: 8%; bottom: 12%; fill: var(--turq); animation-direction: reverse; }

/* values */
.p-values .eyebrow { justify-content: center; }
.words { position: relative; z-index: 1; display: grid; grid-template-columns: 1fr auto 1fr auto 1fr; align-items: center; gap: 3vw; max-width: 1240px; margin: 24px auto 0; }
.words h3 { font-size: clamp(64px, 9vw, 150px); color: var(--gold-2); font-style: italic; font-weight: 600; line-height: 1; }
.words p { color: #c9cfec; max-width: 24ch; margin: 12px auto 0; }

/* admissions */
.p-admit .admit { position: relative; z-index: 1; max-width: 1120px; margin: 0 auto; width: 100%; gap: 32px; }
.p-admit .process { gap: 10px; }
.p-admit .process li { padding: 14px 18px; }
.p-foot { position: relative; z-index: 1; text-align: center; margin-top: 18px; }

/* contacts */
.crest-big { width: 96px; height: 96px; border-radius: 50%; margin: 0 auto 18px; box-shadow: 0 0 0 4px var(--night), 0 0 0 5px var(--gold); }
.p-contact .contacts { position: relative; z-index: 1; max-width: 1280px; margin: 0 auto; }
.p-copyright { position: relative; z-index: 1; text-align: center; margin-top: 34px; font-size: 14px; color: #aab2da; }

/* chapter rail */
.j-rail { display: none; }

/* in-chapter entrance */
.js .panel .p-copy > *, .js .panel .p-head > *, .js .note-card, .js .words .w, .js .contacts .ad, .js .process li { transition: opacity .8s var(--ease), translate .8s var(--ease); }
.js .panel:not(.active) .p-copy > *, .js .panel:not(.active) .p-head > *, .js .panel:not(.active) .note-card, .js .panel:not(.active) .words .w, .js .panel:not(.active) .contacts .ad, .js .panel:not(.active) .process li { opacity: 0; translate: 0 26px; }
.js .panel.active .p-copy > :nth-child(2), .js .panel.active .p-head > :nth-child(2), .js .panel.active .words .w:nth-of-type(2), .js .panel.active .contacts .ad:nth-child(2), .js .panel.active .process li:nth-child(2) { transition-delay: .08s; }
.js .panel.active .p-copy > :nth-child(3), .js .panel.active .p-head > :nth-child(3), .js .panel.active .words .w:nth-of-type(3), .js .panel.active .contacts .ad:nth-child(3), .js .panel.active .process li:nth-child(3) { transition-delay: .16s; }
.js .panel.active .p-copy > :nth-child(n+4), .js .panel.active .contacts .ad:nth-child(4), .js .panel.active .process li:nth-child(4) { transition-delay: .24s; }

/* pinned horizontal mode */
.journey.is-h .j-sticky { position: sticky; top: var(--head, 70px); height: calc(100vh - var(--head, 70px)); overflow: hidden; overflow: clip; }
.journey.is-h .j-track { display: flex; height: 100%; will-change: transform; }
.journey.is-h .panel { flex: 0 0 var(--vw, 100vw); height: 100%; padding: 40px 7vw 104px; display: flex; flex-direction: column; justify-content: center; }
.journey.is-h .scroll-cue { display: inline-flex; }
.journey.is-h .j-rail { position: absolute; left: 0; right: 0; bottom: 0; z-index: 5; display: flex; justify-content: center; gap: 4px; padding: 10px 16px 14px; background: linear-gradient(transparent, rgba(13, 20, 56, .92) 40%); }
.j-rail button { display: inline-flex; align-items: baseline; gap: 8px; padding: 10px 12px; border: 0; background: none; cursor: pointer; font-family: var(--sans); font-size: 13px; font-weight: 600; color: #aab2da; transition: color .25s; }
.j-rail button i { display: inline-flex; color: var(--gold); }
.j-rail button i svg { width: 14px; height: 14px; fill: currentColor; }
.j-rail button:hover, .j-rail button.on { color: #fff; }
.j-rail button.on i { color: var(--gold-2); }
.j-line { position: absolute; left: 7vw; right: 7vw; bottom: 8px; height: 2px; background: rgba(230, 200, 121, .2); }
.j-line span { display: block; height: 100%; background: linear-gradient(90deg, var(--turq-2), var(--gold-2)); transform-origin: 0 50%; transform: scaleX(0); }

/* stacked mode on smaller screens */
@media (max-width: 999px) {
  .p-grid { grid-template-columns: 1fr; gap: 44px; }
  .p-intro .p-copy { align-items: center; text-align: center; }
  .p-intro .p-copy .secondary { justify-items: center; }
  .p-stage { flex-direction: column; }
  .note-card { margin: -60px 0 0; max-width: 520px; }
  .poster.big { height: auto; width: min(300px, 78vw); }
  .poster.tilt { height: auto; width: min(280px, 70vw); }
  .f-c .poster { height: auto; width: min(170px, 33vw); }
  .f-l .poster, .f-r .poster { height: auto; width: min(140px, 25vw); }
  .p-more { position: static; display: flex; width: max-content; margin: 34px auto 0; }
  .p-teachers .frame { justify-self: center; }
  .p-teachers .frame img { height: auto; width: min(260px, 66vw); }
  .words { grid-template-columns: 1fr; gap: 18px; }
  .numeral { width: 180px; }
}
@media (max-width: 760px) {
  .panel { padding: 72px 16px; }
  .p-intro { padding-top: 48px; }
  .p-media { width: min(300px, 82vw); }
  .fan3 figcaption { font-size: 12px; }
  .f-l { margin-right: 4px; }
  .f-r { margin-left: 4px; }
}

/* pinned mode on short laptop screens */
@media (max-height: 820px) {
  .journey.is-h .panel { padding-top: 22px; padding-bottom: 88px; }
  .journey.is-h .p-copy { gap: 12px; }
  .journey.is-h h2 { font-size: clamp(30px, 6.2vh, 50px); }
  .journey.is-h .lede { font-size: clamp(18px, 2.8vh, 25px); }
  .journey.is-h .index-list div { padding: 7px 0; }
  .journey.is-h .seal { width: min(300px, 46vh); }
  .journey.is-h .p-head { margin-bottom: 18px; }
}

/* sprite holder for the shared star and girih pattern */
.svg-defs { position: absolute; width: 0; height: 0; overflow: hidden; }

/* privacy page */
.policy { max-width: 760px; }
.policy h1 { font-size: clamp(40px, 5vw, 64px); margin-bottom: 8px; }
.policy h2 { font-size: clamp(26px, 2.6vw, 34px); margin: 34px 0 10px; }
.policy ul { padding-left: 20px; display: grid; gap: 10px; max-width: 60ch; }
.p-copyright a, .foot-bottom a { color: #fff; }
.head-row > .head-cta:last-child { margin-left: auto; }

/* name styling: "Qorako‘l Renessans school"; Qorako‘l stands out in gold */
.qk { color: var(--gold-ink); font-weight: 700; }
.p-intro .qk, .page-hero .qk, .coupon .qk { color: var(--gold-2); }
.brand b { letter-spacing: .04em; }

/* trackpad: sideways swipes move the journey, never the browser history */
html, body { overscroll-behavior-x: none; }
.qk-name { color: var(--gold-2); font-style: italic; }

/* big screens: let the content fill the stage */
@media (min-width: 1500px) {
  .wrap { width: min(1560px, 100% - 96px); }
  .journey.is-h .panel { padding-inline: 6vw; }
  .p-grid, .words { max-width: 1680px; }
  .p-admit .admit, .p-contact .contacts { max-width: 1480px; }
  .p-intro h1 { font-size: clamp(64px, 4.6vw, 112px); }
  .p-head h2 { font-size: clamp(48px, 3.6vw, 80px); }
  .note-card { max-width: 560px; padding: 40px 40px 34px; }
  .note-card h2 { font-size: clamp(44px, 3.2vw, 68px); }
  .hero-lead { font-size: 22px; }
  body { font-size: 19px; }
  .poster.big { height: min(70vh, 820px); }
  .poster.tilt { height: min(68vh, 780px); }
  .p-teachers .frame img { height: min(62vh, 720px); }
  .p-media { width: clamp(240px, calc((100vh - 340px) * .74), 520px); }
  .seal { width: min(460px, 70vw); }
}

/* application form */
.page-hero.compact { padding-bottom: 56px; }
.apply { max-width: 820px; }
.apply-form { display: grid; gap: 20px; padding: 36px; background: var(--card); border: 1px solid var(--line); border-top: 4px solid var(--gold); border-radius: 26px; box-shadow: 0 30px 60px -36px rgba(22, 34, 90, .35); }
.field-row { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; }
.field { display: grid; gap: 8px; }
.field span { font-size: 13px; font-weight: 700; letter-spacing: .06em; color: var(--ink); }
.field input, .field select, .field textarea { width: 100%; padding: 14px 16px; border: 1.5px solid var(--line); border-radius: 14px; background: #fff; color: var(--ink); font: inherit; font-size: 16px; }
.field textarea { resize: vertical; }
.field input:focus, .field select:focus, .field textarea:focus { outline: 0; border-color: var(--lapis-2); box-shadow: 0 0 0 3px rgba(36, 55, 154, .15); }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.form-status { min-height: 1.4em; font-weight: 600; color: var(--turq); }
.form-status.bad { color: #b42318; }
.apply-form .btn[disabled] { opacity: .6; cursor: wait; }
.apply-done { text-align: center; padding: 56px 24px; background: var(--card); border: 1px solid var(--line); border-top: 4px solid var(--gold); border-radius: 26px; }
.apply-done[hidden], .apply-form[hidden] { display: none; }
.apply-done .actions { justify-content: center; margin-top: 22px; }
@media (max-width: 760px) {
  .apply-form { padding: 22px 18px; }
  .field-row { grid-template-columns: 1fr; }
}

/* bigger school seal on the "Maktab" chapter */
.seal { width: min(480px, 80vw); }
@media (min-width: 1500px) { .seal { width: min(640px, 70vw); } }

/* intro: blue on the left, school photo on the right, melting into each other */
.hero-photo { display: none; }
@media (min-width: 1000px) and (min-height: 640px) {
  .p-intro .hero-photo { display: block; position: absolute; z-index: 0; top: 0; right: 0; bottom: 0; aspect-ratio: 360 / 476; max-width: 55%; pointer-events: none;
    -webkit-mask-image: linear-gradient(to right, transparent 0, rgba(0, 0, 0, .6) 14%, #000 30%);
    mask-image: linear-gradient(to right, transparent 0, rgba(0, 0, 0, .6) 14%, #000 30%); }
  .p-intro .hero-photo img { width: 100%; height: 100%; object-fit: contain; object-position: 100% 50%; }
  .p-intro .hero-photo::after { content: ""; position: absolute; inset: 0; background: linear-gradient(to top, rgba(13, 20, 56, .45), transparent 22%); }
  .p-intro .p-media { display: none; }
  .p-intro .p-grid { grid-template-columns: minmax(0, 1fr); }
  .p-intro .p-copy { max-width: 50%; }
}

/* header tools: language switch + theme toggle */
.tools { display: flex; align-items: center; gap: 10px; flex: none; }
.lang { display: inline-flex; padding: 3px; border: 1px solid var(--line); border-radius: 999px; background: var(--card); }
.lang button { min-width: 38px; height: 32px; padding: 0 10px; border: 0; border-radius: 999px; background: transparent; color: var(--ink); font: 700 12.5px/1 var(--sans); letter-spacing: .06em; cursor: pointer; transition: background .2s, color .2s; }
.lang button:hover { background: rgba(201, 162, 74, .2); }
.lang button.on { background: var(--lapis); color: #fff; }
.theme-toggle { display: grid; place-items: center; width: 38px; height: 38px; border: 1px solid var(--line); border-radius: 50%; background: var(--card); color: var(--ink); cursor: pointer; transition: background .2s, border-color .2s; }
.theme-toggle:hover { border-color: var(--gold); }
.theme-toggle svg { width: 19px; height: 19px; fill: currentColor; stroke: currentColor; }
.theme-toggle .ic-sun { display: none; fill: none; }
.theme-toggle .ic-moon { stroke: none; }
:root[data-theme="dark"] .theme-toggle .ic-moon { display: none; }
:root[data-theme="dark"] .theme-toggle .ic-sun { display: block; }
.lang button:focus-visible, .theme-toggle:focus-visible { outline: 2px solid var(--turq); outline-offset: 2px; }
@media (max-width: 1060px) { .tools { margin-left: auto; } .head-cta { margin-left: 0; } }
@media (max-width: 420px) { .lang button { min-width: 32px; padding: 0 7px; } .brand i { display: none; } }

/* dark theme */
:root[data-theme="dark"] {
  color-scheme: dark;
  --ink: #eef0fb;
  --text: #c6ccea;
  --muted: #a4acd3;
  --ivory: #0e1536;
  --ivory-2: #121b43;
  --card: #18224f;
  --line: #2b3668;
  --lapis-2: #9db0ff;
  --turq: #27b6c0;
  --gold-ink: #e6c879;
}
:root[data-theme="dark"] body { background: var(--ivory); }
:root[data-theme="dark"] .site-head { background: rgba(13, 20, 56, .9); }
:root[data-theme="dark"] .action-bar { background: rgba(13, 20, 56, .96); }
:root[data-theme="dark"] .btn-line:hover { color: var(--night); }
:root[data-theme="dark"] .lang button.on { background: var(--gold-2); color: var(--night); }
:root[data-theme="dark"] .field input, :root[data-theme="dark"] .field select, :root[data-theme="dark"] .field textarea { background: #0e1536; color: var(--ink); }
:root[data-theme="dark"] .field input::placeholder, :root[data-theme="dark"] .field textarea::placeholder { color: #7f88b4; }
:root[data-theme="dark"] .form-status.bad { color: #ff9c92; }
:root[data-theme="dark"] .seal-ring text { fill: var(--gold-2); }
:root[data-theme="dark"] .seal img { box-shadow: 0 0 0 8px var(--ivory), 0 0 0 9px var(--gold), 0 30px 60px -20px rgba(0, 0, 0, .6); }
:root[data-theme="dark"] .brand img { box-shadow: 0 0 0 2px var(--night), 0 0 0 3px var(--gold); }
:root[data-theme="dark"] .numeral { stroke: rgba(230, 200, 121, .28); }
:root[data-theme="dark"] .ad:hover, :root[data-theme="dark"] .ad:hover b { background: var(--gold-2); color: var(--night); }
:root[data-theme="dark"] .ad:hover span, :root[data-theme="dark"] .ad:hover small { color: var(--lapis); }
:root[data-theme="dark"] .note-card { color: var(--text); }
:root[data-theme="dark"] .note-card h2 { color: var(--ink); }
:root[data-theme="dark"] .poster { background: var(--ivory-2); }
:root[data-theme="dark"] .frame { background: var(--card); box-shadow: 0 30px 60px -36px rgba(0, 0, 0, .8); }
:root[data-theme="dark"] .apply-form, :root[data-theme="dark"] .apply-done { box-shadow: 0 30px 60px -36px rgba(0, 0, 0, .7); }
@media (min-width: 1061px) and (max-width: 1520px) {
  .head-row { gap: 16px; }
  .index-nav { gap: 17px; min-width: 0; }
  .index-nav a { font-size: 14px; }
}
