/*
  Дистанційна школа Акцент — ui.css
  Shared "new design" language (2026 handoff): the reusable section/component classes that
  the redesigned pages had been re-implementing inline or in per-page <style> blocks
  (index's inline styles, osvitni's .op-*, zmi's .zmi-*). Extracted here once so every
  migrated page uses ONE source instead of copy-pasting.

  Load order on a migrated page:  base.css → components.css → ui.css
  (ui.css REPLACES pages.css / home.css; it depends on base.css variables + components.css chrome).

  Truly page-unique bits (e.g. osvitni's levels table, vartist's pricing grid) still live in a
  small page-scoped <style> block, exactly like vartist/video do today.
*/

/* ===== SECTION HEADERS ===== */
.eyebrow {
  text-align: center;
  font-size: 13px;
  font-weight: 800;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--orange);
  margin: 0 0 6px;
}
.sec-title {
  text-align: center;
  font-size: 30px;
  font-weight: 800;
  color: var(--ink);
  letter-spacing: -.01em;
  margin: 0 0 8px;
}
.sec-title.tight { margin-bottom: 34px; }      /* when there is no subtitle below */
.sec-sub {
  text-align: center;
  font-size: 15px;
  color: var(--gray);
  margin: 0 auto 36px;
  max-width: 560px;
}
.eyebrow.left { text-align: left; margin-bottom: 10px; }   /* left-aligned section intro (split layouts) */
.eyebrow.on-navy { color: #ffd9a8; }                       /* on a navy/dark background */

/* ===== BREADCRUMB ===== */
.u-crumb { font-size: 13px; color: #6f6a59; font-weight: 600; margin-bottom: 18px; }
.u-crumb a { color: #6f6a59; }
.u-crumb b { color: var(--text); font-weight: 700; }
/* Shared byline (article sign-off), used on blog pages */
.u-byline { font-weight: 600; color: var(--navy); margin-top: 1.5rem; }

/* ===== LEAD HERO (2-column) ===== */
.u-hero { display: grid; grid-template-columns: 1.06fr .94fr; gap: 52px; align-items: center; }
.u-hero-badge {
  display: inline-flex; align-items: center; gap: 9px; white-space: nowrap;
  background: rgba(247,148,29,.14); color: #c9760a;
  padding: 8px 15px; border-radius: 999px;
  font-size: 13px; font-weight: 700;
}
.u-hero-h1 {
  font-size: 44px; line-height: 1.09; font-weight: 800;
  color: var(--ink); letter-spacing: -.025em; margin: 18px 0 0;
}
.u-hero-h1 span { color: var(--orange); }
/* Article/blog hero title: smaller, denser, wider measure (replaces per-page inline style) */
.u-hero-h1--article { font-size: 32px; line-height: 1.22; max-width: 820px; }
.u-hero-lead { font-size: 18px; line-height: 1.62; color: #54596a; margin: 18px 0 0; max-width: 540px; }
.u-hero-actions { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 26px; }
.u-hero-media { position: relative; }
.u-hero-media img {
  width: 100%; height: 380px; object-fit: cover;
  border-radius: 20px; box-shadow: 0 28px 56px -22px rgba(17,22,74,.5); display: block;
}
.u-float-card {     /* small floating badge over a hero/media image */
  position: absolute; bottom: 18px; left: -16px;
  background: #fff; border-radius: 16px; padding: 13px 18px;
  box-shadow: 0 18px 36px -14px rgba(17,22,74,.4);
  display: flex; align-items: center; gap: 12px;
}

/* ===== BUTTONS (large new-design variants; .btn/.btn-dark stay in components.css) ===== */
.btn-lg {
  display: inline-flex; align-items: center; gap: 10px;
  background: var(--orange); color: #fff !important;
  font-size: 16px; font-weight: 700; padding: 16px 30px; border-radius: 13px;
  box-shadow: 0 14px 26px -10px rgba(247,148,29,.7);
  transition: background .2s, transform .15s;
}
.btn-lg:hover { background: var(--orange-dk); transform: translateY(-1px); }
.btn-outline {
  display: inline-flex; align-items: center; gap: 10px;
  background: #fff; color: var(--navy) !important;
  font-size: 16px; font-weight: 700; padding: 14px 26px; border-radius: 13px;
  border: 2px solid var(--navy); transition: background .2s;
}
.btn-outline:hover { background: #f6f1e1; }
.btn-ghost {        /* on a dark/navy background */
  display: inline-flex; align-items: center; gap: 10px;
  background: rgba(255,255,255,.12); color: #fff !important;
  font-size: 16px; font-weight: 700; padding: 16px 30px; border-radius: 13px;
  border: 1px solid rgba(255,255,255,.3); transition: background .2s;
}
.btn-ghost:hover { background: rgba(255,255,255,.2); }

/* ===== CARD + GRIDS ===== */
.card { background: #fff; border: 1px solid var(--card-border); border-radius: var(--radius-card); box-shadow: var(--shadow-soft); }
.card-lift { transition: transform .2s, box-shadow .2s; }
.card-lift:hover { transform: translateY(-3px); box-shadow: var(--shadow-hover); }
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.split { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; align-items: center; }   /* 2-col editorial (image + text) */
.split img { width: 100%; border-radius: 20px; display: block; }

/* Related-links cards ("Читайте також") — reusable; use with .card .card-lift inside .grid-2/.grid-3 */
.rel-card { display: flex; flex-direction: column; padding: 22px; text-decoration: none; }
.rel-card .rel-eyebrow { font-size: 12px; font-weight: 800; letter-spacing: .06em; color: var(--orange); }
.rel-card .rel-title { font-size: 17px; font-weight: 700; color: var(--ink); margin: 8px 0 0; line-height: 1.35; }
.rel-card .rel-go { margin-top: 14px; font-size: 13px; font-weight: 700; color: var(--navy); }

/* ===== PILL / ICON / FEATURE LIST ===== */
.pill { display: inline-block; font-size: 13px; font-weight: 700; padding: 7px 14px; border-radius: 999px; }
.pill-navy { color: var(--navy); background: rgba(26,35,126,.07); }
.u-icon {           /* rounded tinted square holding an emoji/icon */
  width: 52px; height: 52px; border-radius: 14px;
  display: flex; align-items: center; justify-content: center; font-size: 26px; flex-shrink: 0;
}
.u-icon-orange { background: rgba(247,148,29,.15); }
.u-icon-navy { background: rgba(26,35,126,.10); }
.u-flist { list-style: none; padding: 0; margin: 18px 0 0; display: flex; flex-direction: column; gap: 11px; }
.u-flist li { display: flex; gap: 10px; font-size: 14.5px; color: var(--text); line-height: 1.45; margin: 0; }
.u-flist li::before { content: "✓"; color: var(--orange); font-weight: 800; }

/* ===== SUBJECT-LIST PAGES (предмети за класами: 1–4 / 5–9 / 10–11) ===== */
.subj-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 22px; }
.subj-card { overflow: hidden; }
.subj-card .hd { background: var(--navy); color: #fff; font-size: 16px; font-weight: 800; padding: 14px 20px; }
.subj-card ul { list-style: none; padding: 10px 20px 16px; margin: 0; }
.subj-card li { font-size: 14px; color: var(--text); line-height: 1.4; padding: 7px 0 7px 22px; position: relative; border-bottom: 1px solid #f3edda; }
.subj-card li:last-child { border-bottom: none; }
.subj-card li::before { content: "•"; position: absolute; left: 4px; top: 7px; color: var(--orange); font-weight: 800; }

/* ===== PRICING / TARIFF CARDS (vartist, paketi-navchannya) ===== */
.tariff-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 22px; }
.tariff-grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.tariff { display: flex; flex-direction: column; position: relative; overflow: hidden; }   /* use with .card */
.tariff.featured { border: 2px solid var(--orange); background: #fffaf0; box-shadow: 0 20px 44px -20px rgba(247,148,29,.5); }
.tariff-img { width: 100%; height: 160px; object-fit: cover; display: block; }
.tariff-body { padding: 24px 22px; display: flex; flex-direction: column; flex: 1; }
.tariff-name { font-size: 18px; font-weight: 800; color: var(--ink); margin: 0; }
.tariff-note { font-size: 12.5px; color: var(--gray); margin-top: 3px; }
.tariff-old { font-size: 13px; color: #b3aa92; text-decoration: line-through; margin-top: 12px; }
.tariff-price { font-size: 23px; font-weight: 800; color: var(--orange); margin: 6px 0 0; }
.tariff-price span { font-size: 13px; font-weight: 600; color: #9a9486; }
.tariff-old + .tariff-price { margin-top: 2px; }
.tariff-desc { font-size: 13.5px; color: var(--gray); line-height: 1.55; margin: 12px 0 0; }
.tariff-list { list-style: none; padding: 0; margin: 14px 0 0; display: flex; flex-direction: column; gap: 8px; flex: 1; }
.tariff-list li { font-size: 13.5px; color: var(--text); line-height: 1.45; }
.tariff-list.check li { padding-left: 22px; position: relative; }
.tariff-list.check li::before { content: "✓"; position: absolute; left: 0; color: var(--orange); font-weight: 800; }
.tariff-badge { align-self: flex-start; background: var(--orange); color: #fff; font-size: 11px; font-weight: 800; letter-spacing: .03em; padding: 4px 11px; border-radius: 999px; margin-bottom: 10px; }
.tariff-recommend { background: rgba(247,148,29,.1); border-left: 3px solid var(--orange); padding: 10px 14px; border-radius: 8px; margin-top: 14px; font-size: 13px; line-height: 1.5; color: var(--text); }
.badge-new { display: inline-block; background: var(--orange); color: #fff; font-size: .7rem; font-weight: 700; padding: 1px 7px; border-radius: 10px; margin-left: 4px; vertical-align: middle; }
@media (max-width: 860px) { .tariff-grid-3 { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .tariff-grid-3 { grid-template-columns: 1fr; } }

/* ===== NAVY CTA BAND ===== */
.cta-band {
  background: linear-gradient(135deg, #1a237e, #0f1448);
  border-radius: 22px; padding: 46px 48px;
  display: flex; flex-wrap: wrap; gap: 24px; align-items: center; justify-content: space-between;
  box-shadow: 0 26px 54px -26px rgba(17,22,74,.6);
}
.cta-band h2 { font-size: 28px; font-weight: 800; color: #fff; margin: 0; letter-spacing: -.02em; }
.cta-band p { font-size: 16px; color: rgba(255,255,255,.82); margin: 10px 0 0; max-width: 580px; line-height: 1.55; }
.cta-actions { display: flex; flex-wrap: wrap; gap: 14px; }

/* ===== NAVY CONTENT PANEL (gradient block with content) ===== */
.panel-navy {
  background: linear-gradient(135deg, #1a237e 0%, #141a5e 55%, #0f1448 100%);
  border-radius: 22px; padding: 48px; position: relative; overflow: hidden;
  box-shadow: 0 26px 54px -26px rgba(17,22,74,.6);
}

/* ===== FAQ ACCORDION (native <details>, WebView-safe, no JS) ===== */
.faq-list { display: flex; flex-direction: column; gap: 12px; }
.faq-item { background: #fff; border: 1px solid var(--card-border); border-radius: 14px; overflow: hidden; box-shadow: 0 10px 26px -22px rgba(17,22,74,.5); }
.faq-item summary {
  list-style: none; cursor: pointer; padding: 20px 24px;
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  font-size: 16.5px; font-weight: 700; color: var(--ink); line-height: 1.4;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-sign { font-size: 24px; font-weight: 700; color: var(--orange); flex-shrink: 0; line-height: 1; }
.faq-sign::before { content: "+"; }
.faq-item[open] .faq-sign::before { content: "\2212"; }   /* − */
.faq-answer { padding: 0 24px 22px; font-size: 15px; line-height: 1.62; color: #54596a; }
.faq-answer a { color: var(--navy); font-weight: 700; }

/* ===== RESPONSIVE ===== */
@media (max-width: 860px) {
  .u-hero { grid-template-columns: 1fr; gap: 30px; }
  .u-hero-h1 { font-size: 32px; }
  .u-hero-media img { height: 300px; }
  .panel-navy { padding: 36px 28px; }
  .grid-3 { grid-template-columns: repeat(2, 1fr); }
  .split { grid-template-columns: 1fr; gap: 30px; }
}
@media (max-width: 760px) {
  .grid-2 { grid-template-columns: 1fr; }
}
@media (max-width: 560px) {
  .cta-band { padding: 34px 26px; }
  .cta-band h2 { font-size: 23px; }
  .sec-title { font-size: 24px; }
  .grid-3 { grid-template-columns: 1fr; }
}

/* ===== PAGE HERO (shared inner-page banner: gradient + soft decorative glows) ===== */
/* Replaces the repeated inline style="background:radial-gradient(...)" on inner-page heroes. */
.u-pagehero { position: relative; overflow: hidden; background: radial-gradient(120% 120% at 100% 0%, #fff6e6 0%, #f6f1e1 55%, #f2ecd9 100%); }
.u-pagehero::before { content: ""; position: absolute; top: -160px; right: -120px; width: 420px; height: 420px; border-radius: 50%; background: radial-gradient(circle, rgba(247,148,29,.20), transparent 70%); pointer-events: none; }
.u-pagehero::after { content: ""; position: absolute; bottom: -190px; left: -150px; width: 480px; height: 480px; border-radius: 50%; background: radial-gradient(circle, rgba(26,35,126,.10), transparent 70%); pointer-events: none; }
.u-pagehero > .container { position: relative; z-index: 1; }
.u-pagehero.center > .container { text-align: center; }
.u-pagehero.center .u-hero-h1 { max-width: 780px; margin-left: auto; margin-right: auto; }
.u-pagehero.center .u-hero-lead { margin-left: auto; margin-right: auto; max-width: 660px; }

/* ===== SCROLL REVEAL — content is VISIBLE by default; js/main.js adds .is-visible
   only to PLAY an entrance animation. If JS never runs, nothing is ever hidden. ===== */
@media (prefers-reduced-motion: no-preference) {
  .reveal.is-visible { animation: reveal-in .6s cubic-bezier(.22,.61,.36,1) both; }
}
@keyframes reveal-in { from { opacity: 0; transform: translateY(22px); } to { opacity: 1; transform: none; } }
