/* Kivolo Kids — landing custom overrides on top of Tailwind v2.
   Keeps brand palette + Fredoka/Nunito typography + crisp card style.  */

@font-face {
  font-family: 'Fredoka'; font-style: normal; font-weight: 500; font-display: swap;
  src: url('/assets/fonts/Fredoka-500-latin.woff2') format('woff2');
}
@font-face {
  font-family: 'Fredoka'; font-style: normal; font-weight: 600; font-display: swap;
  src: url('/assets/fonts/Fredoka-600-latin.woff2') format('woff2');
}
@font-face {
  font-family: 'Fredoka'; font-style: normal; font-weight: 700; font-display: swap;
  src: url('/assets/fonts/Fredoka-700-latin.woff2') format('woff2');
}
@font-face {
  font-family: 'Nunito'; font-style: normal; font-weight: 400; font-display: swap;
  src: url('/assets/fonts/Nunito-400-latin.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Nunito'; font-style: normal; font-weight: 400; font-display: swap;
  src: url('/assets/fonts/Nunito-400-cyrillic.woff2') format('woff2');
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
  font-family: 'Nunito'; font-style: normal; font-weight: 600; font-display: swap;
  src: url('/assets/fonts/Nunito-600-latin.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Nunito'; font-style: normal; font-weight: 600; font-display: swap;
  src: url('/assets/fonts/Nunito-600-cyrillic.woff2') format('woff2');
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
  font-family: 'Nunito'; font-style: normal; font-weight: 700; font-display: swap;
  src: url('/assets/fonts/Nunito-700-latin.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Nunito'; font-style: normal; font-weight: 700; font-display: swap;
  src: url('/assets/fonts/Nunito-700-cyrillic.woff2') format('woff2');
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}

:root {
  --kv-coral:   #FF5B7F;
  --kv-orange:  #FF9F1C;
  --kv-yellow:  #FFD93D;
  --kv-green:   #6BCB77;
  --kv-teal:    #4D96FF;
  --kv-purple:  #9B5DE5;
  --kv-ink:     #0B1E3F;
  --kv-cream:   #FFF8EC;
  --kv-tint-1:  #FEE8EE;
  --kv-tint-2:  #FFF7D9;
  --kv-tint-3:  #E9F8EC;
  --kv-tint-4:  #F1E9FC;
  --kv-tint-5:  #E3F5F8;
  --radius-card:   24px;
  --radius-pill:   999px;
  --shadow-soft:   0 12px 30px rgba(11, 30, 63, 0.10);
  --shadow-hover:  0 22px 46px rgba(11, 30, 63, 0.18);
  --shadow-coral:  0 14px 34px rgba(255, 91, 127, 0.32);
  --font-display:  'Fredoka', 'Nunito', system-ui, sans-serif;
  --font-body:     'Nunito', system-ui, -apple-system, sans-serif;
}

/* Reset Tailwind preflight conflicts that hurt our look */
* { box-sizing: border-box; }
html { font-size: 17px; -webkit-tap-highlight-color: transparent; scroll-behavior: smooth; }
body {
  font-family: var(--font-body);
  color: var(--kv-ink);
  background: var(--kv-cream);
  margin: 0;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
h1, h2, h3 {
  font-family: var(--font-display);
  font-weight: 700;
  letter-spacing: -0.015em;
  margin: 0;
  color: var(--kv-ink);
}
h1 { font-size: clamp(2rem, 4.5vw, 3.4rem); line-height: 1.05; }
h2 { font-size: clamp(1.6rem, 3vw, 2.4rem); line-height: 1.1; }
h3 { font-size: 1.15rem; line-height: 1.3; }
p  { margin: 0; }
a  { color: var(--kv-teal); text-decoration: none; }
a:hover { text-decoration: underline; }
img { max-width: 100%; display: block; }
button { font-family: inherit; cursor: pointer; }

.kv-skip {
  position: absolute; left: -9999px; top: 0;
  background: var(--kv-ink); color: #fff; padding: 8px 16px; z-index: 100;
}
.kv-skip:focus { left: 16px; top: 16px; }

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

.kv-container {
  max-width: 1180px; margin: 0 auto; padding: 0 24px;
}
.kv-container-narrow { max-width: 720px; }

/* ── Header ──────────────────────────────────────────────────── */
.kv-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255, 248, 236, 0.85);
  backdrop-filter: saturate(180%) blur(10px);
  -webkit-backdrop-filter: saturate(180%) blur(10px);
  border-bottom: 1px solid rgba(11,30,63,0.06);
}
.kv-header-inner {
  max-width: 1180px; margin: 0 auto; padding: 14px 24px;
  display: flex; align-items: center; justify-content: space-between;
}
.kv-brand img { height: 56px; width: auto; }

.kv-lang-switcher {
  display: inline-flex; gap: 4px;
  padding: 4px;
  background: rgba(11,30,63,0.06);
  border-radius: var(--radius-pill);
}
.kv-lang-btn {
  border: 0; background: transparent;
  padding: 6px 14px; border-radius: var(--radius-pill);
  font-weight: 700; color: var(--kv-ink); font-size: 14px;
  transition: all .18s ease;
}
.kv-lang-btn.is-active { background: #fff; box-shadow: var(--shadow-soft); color: var(--kv-coral); }
.kv-lang-btn:hover:not(.is-active) { background: rgba(255,255,255,0.5); }

/* ── Hero ────────────────────────────────────────────────────── */
.kv-hero {
  padding: clamp(40px, 7vw, 88px) 0 clamp(40px, 6vw, 80px);
  background:
    radial-gradient(circle at 10% 0%, rgba(255,217,61,0.35), transparent 55%),
    radial-gradient(circle at 90% 30%, rgba(155,93,229,0.18), transparent 55%),
    var(--kv-cream);
  overflow: hidden;
}
.kv-hero-inner {
  max-width: 1180px; margin: 0 auto; padding: 0 24px;
  display: grid; grid-template-columns: 1.1fr 0.9fr;
  gap: 40px; align-items: center;
}
.kv-hero-copy h1 { color: var(--kv-ink); }
.kv-hero-sub {
  margin-top: 18px; font-size: clamp(1rem, 1.4vw, 1.18rem);
  color: rgba(11,30,63,0.78); max-width: 560px;
}
.kv-hero-cta {
  margin-top: 28px; display: flex; flex-wrap: wrap; gap: 12px;
}

.kv-btn {
  display: inline-flex; align-items: center; justify-content: center;
  padding: 14px 26px; border-radius: var(--radius-pill);
  font-family: var(--font-display); font-weight: 600;
  font-size: 1rem; letter-spacing: 0.005em;
  text-decoration: none; border: 0; cursor: pointer;
  transition: transform .18s ease, box-shadow .18s ease, background .18s ease;
}
.kv-btn-primary {
  background: var(--kv-coral); color: #fff;
  box-shadow: var(--shadow-coral);
}
.kv-btn-primary:hover {
  transform: translateY(-1px); text-decoration: none;
  background: #ff406b;
}
.kv-btn-ghost {
  background: rgba(11,30,63,0.06); color: var(--kv-ink);
}
.kv-btn-ghost:hover {
  background: rgba(11,30,63,0.10); text-decoration: none;
}

.kv-hero-art {
  position: relative; aspect-ratio: 1/1; max-width: 460px; justify-self: end; width: 100%;
}
.kv-hero-blob {
  position: absolute; inset: 8% 4% 12% 8%;
  background:
    radial-gradient(circle at 30% 30%, rgba(255, 91, 127, 0.55), rgba(255, 91, 127, 0) 60%),
    radial-gradient(circle at 70% 75%, rgba(77, 150, 255, 0.50), rgba(77, 150, 255, 0) 65%),
    radial-gradient(circle at 50% 50%, rgba(255, 217, 61, 0.50), rgba(255, 217, 61, 0) 60%);
  filter: blur(8px);
  border-radius: 50%;
  animation: kv-blob 8s ease-in-out infinite alternate;
}
@keyframes kv-blob {
  0%   { transform: scale(0.96) rotate(-2deg); }
  100% { transform: scale(1.04) rotate(2deg); }
}
.kv-kivvi-main {
  position: relative; z-index: 2;
  width: 78%; height: auto; margin: 0 auto;
  filter: drop-shadow(0 18px 30px rgba(11,30,63,0.16));
  animation: kv-float 6s ease-in-out infinite alternate;
}
.kv-kivvi-float {
  position: absolute; z-index: 3;
  filter: drop-shadow(0 10px 18px rgba(11,30,63,0.16));
}
.kv-kivvi-float-1 { top: 6%; right: 4%; width: 22%; animation: kv-float 5s ease-in-out infinite alternate; }
.kv-kivvi-float-2 { bottom: 8%; left: 2%; width: 18%; animation: kv-float 7s ease-in-out infinite alternate-reverse; }
@keyframes kv-float {
  0%   { transform: translateY(-6px); }
  100% { transform: translateY(8px); }
}

/* ── Sections ─────────────────────────────────────────────────── */
.kv-section { padding: clamp(48px, 7vw, 88px) 0; }
.kv-section h2 { text-align: center; }
.kv-section-sub {
  text-align: center; max-width: 640px; margin: 12px auto 0;
  font-size: 1.05rem; color: rgba(11,30,63,0.72);
}

/* ── Safety grid ──────────────────────────────────────────────── */
.kv-section-safety { background: #fff; }
.kv-safety-grid {
  margin-top: 44px;
  display: grid; gap: 18px;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
}
.kv-safety-card {
  padding: 28px 24px;
  border-radius: var(--radius-card);
  background: var(--kv-tint-2);
  box-shadow: var(--shadow-soft);
  transition: transform .2s ease, box-shadow .2s ease;
}
.kv-safety-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-hover); }
.kv-bg-tint-1 { background: var(--kv-tint-1); }
.kv-bg-tint-2 { background: var(--kv-tint-2); }
.kv-bg-tint-3 { background: var(--kv-tint-3); }
.kv-bg-tint-4 { background: var(--kv-tint-4); }
.kv-safety-icon {
  font-size: 2.2rem; margin-bottom: 12px;
  width: 56px; height: 56px; display: inline-flex; align-items: center; justify-content: center;
  background: #fff; border-radius: 18px;
  box-shadow: 0 4px 10px rgba(11,30,63,0.08);
}
.kv-safety-card h3 { margin-bottom: 8px; }
.kv-safety-card p { color: rgba(11,30,63,0.74); font-size: 0.97rem; }

/* ── Partners ─────────────────────────────────────────────────── */
.kv-section-partners { background: var(--kv-cream); }
.kv-partners-count {
  display: inline-block; margin-left: 8px;
  background: var(--kv-coral); color: #fff;
  padding: 2px 10px; border-radius: var(--radius-pill);
  font-size: 0.85rem; font-weight: 700;
  font-family: var(--font-display);
}
.kv-partners-filter {
  margin-top: 28px; display: flex; flex-wrap: wrap; gap: 8px;
  justify-content: center;
}
.kv-filter-pill {
  border: 0; background: rgba(11,30,63,0.06);
  color: var(--kv-ink); padding: 10px 20px;
  border-radius: var(--radius-pill);
  font-family: var(--font-display); font-weight: 600;
  font-size: 0.95rem;
  transition: all .18s ease;
}
.kv-filter-pill:hover:not(.is-active) { background: rgba(11,30,63,0.10); }
.kv-filter-pill.is-active {
  background: var(--kv-ink); color: #fff;
  box-shadow: 0 8px 18px rgba(11,30,63,0.20);
}
.kv-partners-grid {
  margin-top: 36px;
  display: grid; gap: 18px;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
}
.kv-partners-loading { text-align: center; color: rgba(11,30,63,0.6); padding: 40px; grid-column: 1/-1; }

.kv-partner-card {
  background: #fff;
  border-radius: var(--radius-card);
  padding: 18px;
  box-shadow: var(--shadow-soft);
  display: flex; flex-direction: column; gap: 10px;
  transition: transform .2s ease, box-shadow .2s ease;
  border: 1px solid rgba(11,30,63,0.04);
}
.kv-partner-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-hover); }
.kv-partner-icon {
  width: 84px; height: 84px;
  border-radius: 22px;
  object-fit: cover;
  box-shadow: 0 4px 12px rgba(11,30,63,0.10);
  background: #fafafa;
}
.kv-partner-title {
  font-family: var(--font-display); font-weight: 600; font-size: 1.0rem;
  color: var(--kv-ink); line-height: 1.25;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
  min-height: 2.5em;
}
.kv-partner-meta {
  display: flex; align-items: center; gap: 8px; flex-wrap: wrap;
  font-size: 0.78rem; color: rgba(11,30,63,0.6);
}
.kv-partner-badge {
  display: inline-block;
  padding: 2px 9px; border-radius: var(--radius-pill);
  background: var(--kv-tint-4); color: var(--kv-purple);
  font-size: 0.72rem; font-weight: 700; font-family: var(--font-display);
  text-transform: uppercase; letter-spacing: 0.04em;
}
.kv-partner-badge[data-company="devgame"]  { background: #FFE2E8; color: var(--kv-coral); }
.kv-partner-badge[data-company="lcpgame"]  { background: #E5F2FF; color: var(--kv-teal); }
.kv-partner-badge[data-company="tatomamo"] { background: #E9F8EC; color: #2f8e3d; }
.kv-partner-rating { display: inline-flex; align-items: center; gap: 4px; }
.kv-partner-rating::before { content: "★"; color: var(--kv-orange); }
.kv-partner-links {
  display: flex; gap: 8px; margin-top: auto;
}
.kv-store-link {
  flex: 1; display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  padding: 8px 10px; border-radius: 12px;
  background: rgba(11,30,63,0.06); color: var(--kv-ink);
  font-size: 0.78rem; font-weight: 700; font-family: var(--font-display);
  text-decoration: none;
  transition: background .18s ease;
}
.kv-store-link:hover { background: rgba(11,30,63,0.12); text-decoration: none; }
.kv-store-link[disabled], .kv-store-link.is-disabled {
  opacity: 0.35; pointer-events: none;
}

/* ── Subscribe form ──────────────────────────────────────────── */
.kv-section-subscribe {
  background: linear-gradient(180deg, var(--kv-cream), #fff);
}
.kv-subscribe-card {
  background: #fff;
  border-radius: 32px;
  padding: 48px 32px;
  text-align: center;
  box-shadow: 0 32px 80px rgba(11,30,63,0.10);
  position: relative;
}
.kv-subscribe-kivvi {
  width: 100px; height: auto; margin: -86px auto 16px;
  filter: drop-shadow(0 12px 22px rgba(11,30,63,0.14));
}
.kv-subscribe-form {
  margin-top: 28px;
  display: flex; gap: 10px; flex-wrap: wrap;
  max-width: 480px; margin-left: auto; margin-right: auto;
}
.kv-subscribe-form input[type="email"] {
  flex: 1 1 220px;
  padding: 14px 18px;
  border-radius: var(--radius-pill);
  border: 2px solid rgba(11,30,63,0.10);
  font-size: 1rem; font-family: var(--font-body);
  background: #fff; color: var(--kv-ink);
  transition: border-color .18s ease;
}
.kv-subscribe-form input[type="email"]:focus {
  outline: 0; border-color: var(--kv-coral);
}
.kv-subscribe-status {
  margin-top: 16px; font-weight: 600; min-height: 1.2em;
}
.kv-subscribe-status.is-success { color: #2f8e3d; }
.kv-subscribe-status.is-error   { color: var(--kv-coral); }
.kv-subscribe-fineprint {
  margin-top: 18px; font-size: 0.82rem; color: rgba(11,30,63,0.56);
}

/* ── Footer ──────────────────────────────────────────────────── */
.kv-footer {
  padding: 32px 0;
  border-top: 1px solid rgba(11,30,63,0.06);
  background: #fff;
}
.kv-footer-inner {
  display: flex; flex-wrap: wrap; gap: 16px;
  align-items: center; justify-content: space-between;
}
.kv-footer-brand { display: inline-flex; align-items: center; gap: 12px; }
.kv-footer-copyright { color: rgba(11,30,63,0.5); font-size: 0.85rem; }
.kv-footer-links { display: inline-flex; flex-wrap: wrap; gap: 18px; }
.kv-footer-links a { color: rgba(11,30,63,0.7); font-size: 0.9rem; }
.kv-footer-links a:hover { color: var(--kv-coral); }
.kv-footer-meta {
  width: 100%; padding-top: 16px; border-top: 1px dashed rgba(11,30,63,0.08);
  font-size: 0.80rem; color: rgba(11,30,63,0.5); text-align: center;
}

/* ── Mobile ──────────────────────────────────────────────────── */
@media (max-width: 760px) {
  .kv-hero-inner { grid-template-columns: 1fr; gap: 24px; }
  .kv-hero-art { max-width: 320px; margin: 0 auto; justify-self: center; }
  .kv-hero-cta { justify-content: center; }
  .kv-hero-copy { text-align: center; }
  .kv-hero-sub { margin-left: auto; margin-right: auto; }
  .kv-partners-grid { grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 12px; }
  .kv-partner-icon { width: 64px; height: 64px; border-radius: 16px; }
  .kv-partner-card { padding: 14px; }
  .kv-partner-title { font-size: 0.92rem; }
  .kv-subscribe-card { padding: 36px 20px; }
  .kv-subscribe-kivvi { margin-top: -70px; }
}

@media (prefers-reduced-motion: reduce) {
  .kv-kivvi-main, .kv-kivvi-float, .kv-hero-blob { animation: none; }
  html { scroll-behavior: auto; }
}
