/* ==========================================================================
   Painting-ForKids.com — Main Stylesheet
   Pure Custom CSS | Responsive Grid & Flexbox | HostGator Static Ready
   ========================================================================== */

:root {
  --bg-page: #fffdf5;
  --bg-surface: #ffffff;
  --bg-soft: #fff5d6;
  --bg-sky: #eef7ff;
  --ink: #232946;
  --ink-muted: #4f5672;

  --brand-orange: #ff8c24;
  --brand-orange-dark: #e06d06;
  --brand-pink: #ff4d79;
  --brand-blue: #3a86ff;
  --brand-teal: #00b4a6;
  --brand-purple: #7c3aed;
  --brand-yellow: #ffd166;

  --border-color: #232946;
  --radius-sm: 12px;
  --radius-md: 18px;
  --radius-lg: 24px;
  --shadow-card: 0 5px 0 rgba(35, 41, 70, 0.14);
  --shadow-lift: 0 10px 24px rgba(35, 41, 70, 0.16);
  --font-display: "Fredoka", "Comic Sans MS", system-ui, sans-serif;
  --font-body: "Nunito", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --max-width: 1220px;
}

*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  -webkit-tap-highlight-color: transparent;
}

[hidden] {
  display: none !important;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-body);
  color: var(--ink);
  background-color: var(--bg-page);
  background-image:
    radial-gradient(circle at 12% 10%, rgba(255, 209, 102, 0.22) 0, transparent 28%),
    radial-gradient(circle at 88% 15%, rgba(58, 134, 255, 0.12) 0, transparent 26%),
    radial-gradient(circle at 80% 85%, rgba(255, 77, 121, 0.1) 0, transparent 28%);
  line-height: 1.65;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

img,
svg {
  max-width: 100%;
  display: block;
}

a {
  color: var(--brand-blue);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

h1,
h2,
h3,
h4 {
  font-family: var(--font-display);
  line-height: 1.25;
  color: var(--ink);
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}

.container {
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 18px;
}

/* ==========================================================================
   Header & Navigation (Clean Single-Row + Coloring Dropdown)
   ========================================================================== */

.site-header {
  position: sticky;
  top: 0;
  z-index: 60;
  background: rgba(255, 253, 245, 0.96);
  backdrop-filter: blur(12px);
  border-bottom: 2px solid rgba(35, 41, 70, 0.1);
  box-shadow: 0 4px 20px rgba(35, 41, 70, 0.06);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-height: 72px;
}

.brand-logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-display);
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--ink);
  text-decoration: none;
  flex-shrink: 0;
  white-space: nowrap;
}

.brand-logo:hover {
  text-decoration: none;
  transform: scale(1.02);
}

.brand-logo img {
  width: 42px;
  height: 42px;
  filter: drop-shadow(0 2px 4px rgba(35, 41, 70, 0.14));
}

.brand-logo span em {
  font-style: normal;
  color: var(--brand-orange-dark);
}

.nav-toggle {
  display: none;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: var(--radius-sm);
  border: 2px solid var(--border-color);
  background: var(--brand-yellow);
  color: var(--ink);
  font-size: 1.35rem;
  font-weight: 700;
  cursor: pointer;
  flex-shrink: 0;
}

.main-nav {
  display: flex;
  align-items: center;
  gap: 6px;
  flex: 1;
  justify-content: center;
}

.nav-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: var(--font-display);
  font-size: 0.96rem;
  font-weight: 600;
  color: var(--ink);
  background: transparent;
  border: 2px solid transparent;
  border-radius: 999px;
  padding: 8px 14px;
  cursor: pointer;
  white-space: nowrap;
  transition: background-color 0.15s ease, color 0.15s ease, transform 0.15s ease;
  text-decoration: none;
}

.nav-link:hover {
  text-decoration: none;
  background: rgba(255, 209, 102, 0.32);
  color: var(--ink);
}

.nav-link.active {
  background: var(--brand-yellow);
  border-color: var(--border-color);
  color: var(--ink);
}

/* Dropdown for 6 Coloring Categories */
.nav-dropdown {
  position: relative;
}

.nav-dropdown-btn {
  font-family: var(--font-display);
}

.nav-caret {
  font-size: 0.72rem;
  transition: transform 0.18s ease;
}

.nav-dropdown.is-open .nav-caret {
  transform: rotate(180deg);
}

.nav-dropdown-menu {
  position: absolute;
  top: calc(100% + 10px);
  left: 50%;
  transform: translateX(-50%) translateY(-6px);
  min-width: 340px;
  background: #ffffff;
  border: 2.5px solid var(--border-color);
  border-radius: var(--radius-md);
  box-shadow: 0 16px 36px rgba(35, 41, 70, 0.18);
  padding: 12px;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.18s ease, transform 0.18s ease, visibility 0.18s ease;
  z-index: 80;
}

.nav-dropdown.is-open .nav-dropdown-menu,
.nav-dropdown:hover .nav-dropdown-menu {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: translateX(-50%) translateY(0);
}

.dropdown-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 11px;
  border-radius: 12px;
  color: var(--ink);
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.94rem;
  text-decoration: none;
  transition: background-color 0.14s ease, transform 0.14s ease;
}

.dropdown-item:hover,
.dropdown-item.active {
  text-decoration: none;
  background: var(--bg-soft);
  transform: translateX(2px);
}

.dropdown-item-icon {
  font-size: 1.35rem;
  width: 32px;
  height: 32px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 10px;
  background: var(--bg-sky);
  flex-shrink: 0;
}

.dropdown-item small {
  display: block;
  font-family: var(--font-body);
  font-size: 0.74rem;
  color: var(--ink-muted);
  font-weight: 700;
}

/* Header Right Action (My Gallery) */
.header-cta {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: var(--font-display);
  font-size: 0.94rem;
  font-weight: 700;
  padding: 8px 16px;
  border-radius: 999px;
  border: 2.5px solid var(--border-color);
  background: var(--brand-yellow);
  color: var(--ink);
  box-shadow: 0 3px 0 var(--border-color);
  white-space: nowrap;
  flex-shrink: 0;
  text-decoration: none;
  transition: transform 0.14s ease, box-shadow 0.14s ease, background-color 0.14s ease;
}

.header-cta:hover,
.header-cta.active {
  text-decoration: none;
  background: var(--brand-orange);
  color: #fff;
  transform: translateY(-2px);
  box-shadow: 0 5px 0 var(--border-color);
}

.nav-mobile-gallery {
  display: none;
}

/* ==========================================================================
   Main Content & Balanced 2-Column Hero
   ========================================================================== */

.page-main {
  flex: 1;
  padding: 24px 0 52px;
}

.hero-banner {
  background: linear-gradient(135deg, #fff5cc 0%, #ffe6f0 52%, #e0f2fe 100%);
  border: 2.5px solid rgba(35, 41, 70, 0.18);
  border-radius: 28px;
  padding: 32px 34px;
  box-shadow: 0 12px 32px rgba(35, 41, 70, 0.08);
  margin-bottom: 24px;
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(0, 0.9fr);
  align-items: center;
  gap: 28px;
  overflow: hidden;
}

.hero-banner.hero-compact {
  grid-template-columns: 1fr;
  padding: 24px 28px;
}

.hero-text {
  max-width: 640px;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: var(--font-display);
  font-size: 0.85rem;
  font-weight: 600;
  background: var(--brand-teal);
  color: #fff;
  padding: 5px 14px;
  border-radius: 999px;
  border: 2px solid var(--border-color);
  margin-bottom: 12px;
}

.hero-banner h1 {
  font-size: clamp(1.8rem, 3.3vw, 2.65rem);
  line-height: 1.18;
  margin-bottom: 10px;
}

.hero-banner p {
  color: var(--ink-muted);
  font-size: 1.06rem;
  font-weight: 600;
}

.hero-cta-row {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 18px;
}

/* Playful Polaroid Collage in Hero Right Column */
.hero-visual {
  position: relative;
  min-height: 230px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.hero-polaroid {
  background: #ffffff;
  border: 2.5px solid var(--border-color);
  border-radius: 18px;
  padding: 10px 10px 12px;
  box-shadow: 0 12px 24px rgba(35, 41, 70, 0.14);
  width: 158px;
  text-align: center;
  text-decoration: none;
  color: var(--ink);
  transition: transform 0.22s ease, box-shadow 0.22s ease;
}

.hero-polaroid img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: contain;
  border-radius: 10px;
  margin-bottom: 6px;
}

.hero-polaroid span {
  display: block;
  font-family: var(--font-display);
  font-size: 0.86rem;
  font-weight: 700;
}

.hero-polaroid-left {
  transform: rotate(-7deg) translateX(14px) translateY(10px);
  z-index: 1;
}

.hero-polaroid-center {
  transform: rotate(1deg) scale(1.08);
  z-index: 3;
}

.hero-polaroid-right {
  transform: rotate(7deg) translateX(-14px) translateY(14px);
  z-index: 2;
}

.hero-polaroid:hover {
  text-decoration: none;
  transform: rotate(0deg) scale(1.12) translateY(-6px);
  box-shadow: 0 18px 32px rgba(35, 41, 70, 0.2);
  z-index: 5;
}

.hero-abc-thumb {
  width: 100%;
  aspect-ratio: 4 / 3;
  border-radius: 10px;
  background: linear-gradient(135deg, #fff5d6 0%, #dbeafe 100%);
  border: 2px dashed #64748b;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  margin-bottom: 6px;
}

.hero-abc-thumb strong {
  font-family: var(--font-display);
  font-size: 2.2rem;
  line-height: 1;
  color: var(--brand-orange-dark);
}

.hero-abc-thumb small {
  font-family: var(--font-display);
  font-size: 0.78rem;
  color: var(--ink-muted);
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-family: var(--font-display);
  font-size: 1rem;
  font-weight: 600;
  padding: 10px 18px;
  border-radius: 999px;
  border: 2.5px solid var(--border-color);
  background: var(--brand-orange);
  color: #fff;
  cursor: pointer;
  box-shadow: 0 3px 0 var(--border-color);
  transition: transform 0.12s ease, box-shadow 0.12s ease, background-color 0.15s ease;
  text-decoration: none;
}

.btn:hover {
  text-decoration: none;
  transform: translateY(-2px);
  box-shadow: 0 5px 0 var(--border-color);
}

.btn:active {
  transform: translateY(1px);
  box-shadow: 0 1px 0 var(--border-color);
}

.btn-secondary {
  background: var(--bg-surface);
  color: var(--ink);
}

.btn-teal {
  background: var(--brand-teal);
  color: #fff;
}

.btn-pink {
  background: var(--brand-pink);
  color: #fff;
}

/* Breadcrumbs */
.breadcrumbs {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  font-family: var(--font-display);
  font-size: 0.95rem;
  margin-bottom: 16px;
  color: var(--ink-muted);
}

.breadcrumbs a {
  color: var(--ink);
  font-weight: 600;
}

.breadcrumbs span[aria-hidden="true"] {
  opacity: 0.55;
}

/* ==========================================================================
   Category Hub & Drawing Grids
   ========================================================================== */

.section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin: 28px 0 14px;
  flex-wrap: wrap;
}

.section-header h2 {
  font-size: clamp(1.35rem, 2.4vw, 1.8rem);
  display: flex;
  align-items: center;
  gap: 10px;
}

.section-link {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--ink);
  background: var(--brand-yellow);
  border: 2px solid var(--border-color);
  border-radius: 999px;
  padding: 5px 14px;
  text-decoration: none;
}

.section-link:hover {
  text-decoration: none;
  background: var(--brand-orange);
  color: #fff;
}

/* 10-Category Visual Hub (Balanced 5 x 2 on Desktop) */
.category-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 24px;
}

.category-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  background: var(--bg-surface);
  border: 3px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 10px 8px 12px;
  box-shadow: var(--shadow-card);
  color: var(--ink);
  text-decoration: none;
  transition: transform 0.18s ease, box-shadow 0.18s ease, background-color 0.18s ease;
}

.category-card:hover {
  text-decoration: none;
  transform: translateY(-4px);
  box-shadow: var(--shadow-lift);
  background: var(--bg-soft);
}

.category-card img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: contain;
  border-radius: var(--radius-sm);
  margin-bottom: 6px;
}

.category-card h3 {
  font-size: 1.05rem;
  margin-bottom: 2px;
}

.category-card span {
  font-size: 0.82rem;
  color: var(--ink-muted);
  font-weight: 700;
}

/* Drawing Cards Grid */
.drawing-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 18px;
}

.drawing-card {
  display: flex;
  flex-direction: column;
  background: var(--bg-surface);
  border: 3px solid var(--border-color);
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-card);
  color: var(--ink);
  text-decoration: none;
  transition: transform 0.18s ease, box-shadow 0.18s ease;
}

.drawing-card:hover {
  text-decoration: none;
  transform: translateY(-4px) scale(1.01);
  box-shadow: var(--shadow-lift);
}

.drawing-thumb {
  position: relative;
  background: #ffffff;
  aspect-ratio: 4 / 3;
  padding: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-bottom: 2.5px solid var(--border-color);
}

.star-ribbon {
  position: absolute;
  top: 8px;
  right: 8px;
  background: var(--brand-yellow);
  color: var(--ink);
  border: 2px solid var(--border-color);
  border-radius: 999px;
  padding: 2px 9px;
  font-family: var(--font-display);
  font-size: 0.78rem;
  font-weight: 700;
  box-shadow: 0 2px 0 rgba(35, 41, 70, 0.25);
  z-index: 2;
}

.drawing-thumb img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  transition: transform 0.2s ease;
}

.drawing-card:hover .drawing-thumb img {
  transform: scale(1.05);
}

.drawing-card-body {
  padding: 12px 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  background: var(--bg-surface);
}

.drawing-card-body h3 {
  font-size: 1.08rem;
}

.play-tag {
  font-family: var(--font-display);
  font-size: 0.8rem;
  font-weight: 600;
  background: var(--brand-orange);
  color: #fff;
  padding: 3px 10px;
  border-radius: 999px;
  border: 2px solid var(--border-color);
  flex-shrink: 0;
}

/* ==========================================================================
   Interactive Coloring Studio (Level 3 Game Pages)
   ========================================================================== */

.studio-shell {
  background: var(--bg-surface);
  border: 3px solid var(--border-color);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-card);
  padding: 16px;
  margin-bottom: 28px;
}

.studio-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  padding-bottom: 12px;
  margin-bottom: 14px;
  border-bottom: 2px dashed rgba(35, 41, 70, 0.2);
}

.studio-title-wrap {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.studio-title-wrap h1 {
  font-size: clamp(1.3rem, 2.5vw, 1.85rem);
}

.active-color-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--bg-soft);
  border: 2px solid var(--border-color);
  border-radius: 999px;
  padding: 5px 12px;
  font-family: var(--font-display);
  font-size: 0.9rem;
  font-weight: 600;
}

.active-color-dot {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  border: 2px solid var(--border-color);
  background: #ff4d4d;
  flex-shrink: 0;
}

.studio-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.tool-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: var(--font-display);
  font-size: 0.9rem;
  font-weight: 600;
  padding: 7px 12px;
  border-radius: var(--radius-sm);
  border: 2px solid var(--border-color);
  background: #fff;
  color: var(--ink);
  cursor: pointer;
  box-shadow: 0 2px 0 var(--border-color);
  transition: transform 0.1s ease, background-color 0.15s ease;
}

.tool-btn:hover {
  background: var(--bg-soft);
  transform: translateY(-1px);
}

.tool-btn:active {
  transform: translateY(1px);
  box-shadow: none;
}

.tool-btn[aria-pressed="true"],
.tool-btn.is-active {
  background: var(--brand-yellow);
}

.tool-btn:disabled {
  opacity: 0.45;
  cursor: not-allowed;
  transform: none;
}

.tool-btn-primary {
  background: var(--brand-teal);
  color: #fff;
}

.tool-btn-primary:hover {
  background: #00998d;
  color: #fff;
}

.tool-btn-danger {
  background: #ffe3e8;
  color: #b41d3c;
}

.studio-workspace {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 260px;
  gap: 18px;
  align-items: start;
}

.canvas-stage {
  position: relative;
  background: #ffffff;
  border: 3px solid var(--border-color);
  border-radius: var(--radius-md);
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  touch-action: manipulation;
  user-select: none;
}

.canvas-stage.brush-mode {
  touch-action: none;
  cursor: crosshair;
}

.canvas-stage svg {
  width: 100%;
  height: auto;
  max-height: 620px;
  display: block;
}

.canvas-stage svg .paintable {
  cursor: pointer;
  transition: filter 0.12s ease;
}

.canvas-stage:not(.brush-mode) svg .paintable:hover {
  filter: brightness(0.95);
}

.canvas-stage svg .outlines {
  pointer-events: none;
}

.canvas-stage svg .brush-layer {
  pointer-events: none;
}

/* Color Palette Panel */
.palette-panel {
  background: var(--bg-sky);
  border: 2.5px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 14px;
}

.palette-panel h2 {
  font-size: 1.08rem;
  margin-bottom: 10px;
}

.palette-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 14px;
}

.color-swatch {
  width: 100%;
  aspect-ratio: 1 / 1;
  border-radius: 50%;
  border: 3px solid var(--border-color);
  cursor: pointer;
  position: relative;
  box-shadow: 0 3px 0 rgba(35, 41, 70, 0.25);
  transition: transform 0.14s ease, box-shadow 0.14s ease;
}

.color-swatch:hover {
  transform: scale(1.1);
}

.color-swatch.is-selected {
  transform: scale(1.14);
  box-shadow: 0 0 0 3px #fff, 0 0 0 6px var(--border-color);
}

.color-swatch.is-selected::after {
  content: "✓";
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 1.05rem;
  color: #fff;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.65);
}

.color-swatch.is-light.is-selected::after {
  color: var(--ink);
  text-shadow: none;
}

.brush-controls {
  padding-top: 12px;
  border-top: 2px dashed rgba(35, 41, 70, 0.2);
}

.mode-row,
.size-row {
  display: flex;
  gap: 8px;
  margin-bottom: 10px;
}

.mode-row .tool-btn,
.size-row .tool-btn {
  flex: 1;
  justify-content: center;
  padding: 7px 8px;
  font-size: 0.85rem;
}

.size-row[hidden] {
  display: none;
}

.studio-tip {
  margin-top: 8px;
  font-size: 0.85rem;
  color: var(--ink-muted);
  font-weight: 600;
}

/* Progress Bar, Sticker Tray, Paper Colors, Celebration & Fullscreen */
.studio-progress-bar {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 12px;
  padding: 8px 14px;
  background: var(--bg-soft);
  border: 2px solid var(--border-color);
  border-radius: var(--radius-sm);
  font-family: var(--font-display);
  font-size: 0.92rem;
  font-weight: 600;
}

.progress-track {
  flex: 1;
  height: 14px;
  background: #fff;
  border: 2px solid var(--border-color);
  border-radius: 999px;
  overflow: hidden;
}

.progress-fill {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, #ff4d79, #ff8c24, #ffd166, #00b4a6, #3a86ff);
  border-radius: 999px;
  transition: width 0.25s ease;
}

.progress-star {
  font-size: 1.25rem;
  transition: transform 0.25s ease;
}

.progress-star.is-earned {
  transform: scale(1.28) rotate(12deg);
}

.mode-row {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  margin-bottom: 10px;
}

.sticker-tray {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 6px;
  margin-bottom: 10px;
}

.sticker-tray[hidden] {
  display: none;
}

.sticker-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 6px;
  border-radius: 10px;
  border: 2px solid var(--border-color);
  background: #fff;
  font-size: 1.25rem;
  cursor: pointer;
  transition: transform 0.12s ease, background-color 0.12s ease;
}

.sticker-btn:hover {
  transform: scale(1.08);
  background: var(--bg-soft);
}

.sticker-btn.is-active {
  background: var(--brand-yellow);
  box-shadow: 0 0 0 2px var(--border-color);
}

.paper-bg-row {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 10px;
  padding-top: 10px;
  border-top: 2px dashed rgba(35, 41, 70, 0.2);
}

.paper-bg-label {
  font-family: var(--font-display);
  font-size: 0.85rem;
  font-weight: 600;
  width: 100%;
}

.paper-swatch {
  width: 28px;
  height: 28px;
  border-radius: 8px;
  border: 2px solid var(--border-color);
  cursor: pointer;
  transition: transform 0.12s ease;
}

.paper-swatch:hover,
.paper-swatch.is-active {
  transform: scale(1.14);
  box-shadow: 0 0 0 2px #fff, 0 0 0 4px var(--border-color);
}

.canvas-stage.sticker-mode {
  cursor: copy;
}

/* Fullscreen Studio Mode */
.studio-shell:fullscreen,
.studio-shell.is-fullscreen {
  position: fixed;
  inset: 0;
  z-index: 999;
  margin: 0;
  border-radius: 0;
  border: none;
  overflow-y: auto;
  background: var(--bg-page);
  padding: 16px 20px;
}

.studio-shell:fullscreen .canvas-stage svg,
.studio-shell.is-fullscreen .canvas-stage svg {
  max-height: 76vh;
}

.studio-shell:fullscreen .notebook-stage canvas,
.studio-shell.is-fullscreen .notebook-stage canvas {
  max-height: 68vh;
  width: auto;
  max-width: 100%;
  margin: 0 auto;
}

/* Celebration Banner & Confetti */
.confetti-canvas {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 2000;
}

.celebration-toast {
  position: fixed;
  left: 50%;
  bottom: 28px;
  transform: translateX(-50%) translateY(20px);
  z-index: 2001;
  background: linear-gradient(135deg, #ffd166 0%, #ff8c24 100%);
  color: var(--ink);
  border: 3px solid var(--border-color);
  border-radius: 999px;
  padding: 12px 24px;
  font-family: var(--font-display);
  font-size: 1.15rem;
  font-weight: 700;
  box-shadow: 0 10px 28px rgba(35, 41, 70, 0.28);
  opacity: 0;
  transition: opacity 0.25s ease, transform 0.25s ease;
  cursor: pointer;
  text-align: center;
}

.celebration-toast.is-visible {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

/* My Art Gallery Page */
.gallery-stats {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
  background: var(--bg-surface);
  border: 3px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 16px 20px;
  box-shadow: var(--shadow-card);
  margin-bottom: 24px;
}

.gallery-stats .progress-track {
  min-width: 180px;
}

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
}

.gallery-card {
  background: var(--bg-surface);
  border: 3px solid var(--border-color);
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-card);
  display: flex;
  flex-direction: column;
}

.gallery-card img {
  width: 100%;
  aspect-ratio: 6 / 5;
  object-fit: contain;
  background: #fff;
  border-bottom: 2.5px solid var(--border-color);
}

.gallery-card-meta {
  padding: 12px 14px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.gallery-card-meta h3 {
  font-size: 1.05rem;
}

.gallery-card-date {
  font-size: 0.82rem;
  color: var(--ink-muted);
  font-weight: 600;
}

.gallery-card-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.gallery-empty {
  text-align: center;
  background: var(--bg-surface);
  border: 3px dashed var(--border-color);
  border-radius: var(--radius-lg);
  padding: 40px 24px;
}

.gallery-empty h2 {
  margin-bottom: 8px;
}

.gallery-empty p {
  color: var(--ink-muted);
  margin-bottom: 18px;
}

/* Quick Fun Feature Strip on Homepage (4 Crisp Compact Feature Tiles!) */
.fun-strip {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
  margin-bottom: 28px;
}

.fun-banner {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 10px;
  padding: 16px 18px;
  border: 2px solid rgba(35, 41, 70, 0.16);
  border-radius: 20px;
  box-shadow: 0 6px 18px rgba(35, 41, 70, 0.06);
  color: var(--ink);
  text-decoration: none;
  transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
}

.fun-banner:hover {
  text-decoration: none;
  transform: translateY(-4px);
  border-color: var(--border-color);
  box-shadow: 0 12px 24px rgba(35, 41, 70, 0.12);
}

.fun-banner-draw {
  background: linear-gradient(145deg, #fff1f5 0%, #fff8dc 100%);
}

.fun-banner-gallery {
  background: linear-gradient(145deg, #ecfdf5 0%, #eff6ff 100%);
}

.fun-banner-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.fun-banner-icon {
  font-size: 1.75rem;
  width: 44px;
  height: 44px;
  border-radius: 14px;
  background: #ffffff;
  border: 2px solid rgba(35, 41, 70, 0.15);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.fun-banner-pill {
  font-family: var(--font-display);
  font-size: 0.72rem;
  font-weight: 700;
  padding: 3px 9px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.85);
  border: 1.5px solid rgba(35, 41, 70, 0.18);
  color: var(--ink);
}

.fun-banner h3 {
  font-size: 1.06rem;
  margin-bottom: 3px;
}

.fun-banner p {
  font-size: 0.86rem;
  color: var(--ink-muted);
  font-weight: 600;
  line-height: 1.45;
}

@media (max-width: 1024px) {
  .fun-strip {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 768px) {
  .gallery-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 520px) {
  .fun-strip {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 520px) {
  .gallery-grid {
    grid-template-columns: 1fr;
  }
}

/* ==========================================================================
   Custom Name Generator, Printable Bundles, Affiliate Art Kits & Pinterest Bar
   ========================================================================== */

.name-controls-bar {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  background: var(--bg-soft);
  border: 2.5px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 14px 16px;
  margin-bottom: 14px;
}

.name-input-group {
  display: flex;
  align-items: center;
  gap: 10px;
  flex: 1;
  min-width: 230px;
}

.name-input-group label {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1rem;
  white-space: nowrap;
}

.name-input {
  flex: 1;
  font-family: var(--font-display);
  font-size: 1.2rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  padding: 9px 14px;
  border-radius: var(--radius-sm);
  border: 2.5px solid var(--border-color);
  background: #fff;
  color: var(--ink);
  min-width: 140px;
}

.name-input:focus {
  outline: 3px solid var(--brand-orange);
  outline-offset: 1px;
}

.theme-pills {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.theme-pill-btn {
  font-family: var(--font-display);
  font-size: 0.9rem;
  font-weight: 600;
  padding: 7px 13px;
  border-radius: 999px;
  border: 2px solid var(--border-color);
  background: #fff;
  color: var(--ink);
  cursor: pointer;
  transition: transform 0.12s ease, background-color 0.12s ease;
}

.theme-pill-btn:hover {
  transform: translateY(-1px);
  background: var(--bg-sky);
}

.theme-pill-btn.is-active {
  background: var(--brand-yellow);
  box-shadow: 0 2px 0 var(--border-color);
}

/* Parent Share / Pin & Printable Utility Bar (Strictly below studio!) */
.parent-utility-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
  background: linear-gradient(135deg, #eef7ff 0%, #fff5d6 100%);
  border: 2.5px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 14px 18px;
  margin-top: 18px;
  margin-bottom: 24px;
}

.parent-utility-text {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--ink);
}

.parent-utility-text span {
  display: inline-block;
  font-family: var(--font-display);
  font-size: 0.78rem;
  background: var(--ink);
  color: #fff;
  padding: 2px 8px;
  border-radius: 999px;
  margin-right: 8px;
  vertical-align: middle;
}

.parent-utility-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.btn-pinterest {
  background: #e60023;
  color: #fff;
}

.btn-pinterest:hover {
  background: #c4001e;
  color: #fff;
}

/* Printable PDF Storefront Cards */
.bundle-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 20px;
  margin-bottom: 28px;
}

.bundle-card {
  background: var(--bg-surface);
  border: 3px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 22px 24px;
  box-shadow: var(--shadow-card);
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.bundle-card.is-featured {
  background: linear-gradient(135deg, #fffdf0 0%, #fff0f6 100%);
}

.bundle-badge {
  align-self: flex-start;
  font-family: var(--font-display);
  font-size: 0.82rem;
  font-weight: 700;
  background: var(--brand-pink);
  color: #fff;
  padding: 4px 12px;
  border-radius: 999px;
  border: 2px solid var(--border-color);
}

.bundle-price-row {
  display: flex;
  align-items: baseline;
  gap: 12px;
  font-family: var(--font-display);
}

.bundle-price-main {
  font-size: 1.75rem;
  font-weight: 700;
  color: var(--ink);
}

.bundle-price-alt {
  font-size: 1rem;
  font-weight: 600;
  color: var(--ink-muted);
}

.bundle-features {
  list-style: none;
  display: grid;
  gap: 6px;
  color: var(--ink-muted);
  font-weight: 600;
  font-size: 0.95rem;
}

.bundle-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: auto;
  padding-top: 8px;
}

/* Parents' Recommended Kids Art Kits (Amazon Affiliate Ready) */
.parent-kits-section {
  background: var(--bg-surface);
  border: 3px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 24px;
  box-shadow: var(--shadow-card);
  margin-top: 30px;
}

.parent-kits-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 14px;
}

.parent-badge {
  font-family: var(--font-display);
  font-size: 0.8rem;
  font-weight: 700;
  background: var(--bg-sky);
  color: var(--ink);
  border: 2px solid var(--border-color);
  border-radius: 999px;
  padding: 3px 11px;
}

.art-kit-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
  margin-bottom: 12px;
}

.art-kit-card {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 16px;
  background: var(--bg-page);
  border: 2.5px solid var(--border-color);
  border-radius: var(--radius-md);
  color: var(--ink);
  text-decoration: none;
  transition: transform 0.16s ease, box-shadow 0.16s ease;
}

.art-kit-card:hover {
  text-decoration: none;
  transform: translateY(-3px);
  box-shadow: var(--shadow-card);
  background: var(--bg-soft);
}

.art-kit-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.art-kit-icon {
  font-size: 1.9rem;
}

.art-kit-tag {
  font-family: var(--font-display);
  font-size: 0.72rem;
  font-weight: 700;
  background: var(--brand-yellow);
  border: 1.5px solid var(--border-color);
  border-radius: 999px;
  padding: 2px 8px;
}

.art-kit-card h3 {
  font-size: 1rem;
}

.art-kit-card p {
  font-size: 0.85rem;
  color: var(--ink-muted);
  font-weight: 600;
}

.art-kit-cta {
  margin-top: auto;
  font-family: var(--font-display);
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--brand-orange-dark);
}

.affiliate-disclosure {
  font-size: 0.8rem;
  color: var(--ink-muted);
  margin: 0;
}

/* COPPA-Safe Ad Slot (Collapsed cleanly until PFKConfig.ads.enabled = true) */
.coppa-ad-slot {
  display: none;
  margin: 24px auto;
  min-height: 90px;
  max-width: 728px;
  text-align: center;
  border: 2px dashed rgba(35, 41, 70, 0.2);
  border-radius: var(--radius-sm);
  padding: 8px;
}

.coppa-ad-slot.is-active {
  display: block;
}

/* Razorpay Parent Checkout Modal */
.checkout-modal {
  position: fixed;
  inset: 0;
  z-index: 1500;
  background: rgba(35, 41, 70, 0.58);
  backdrop-filter: blur(4px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 18px;
}

.checkout-modal[hidden] {
  display: none;
}

.checkout-modal-card {
  position: relative;
  width: 100%;
  max-width: 440px;
  background: #ffffff;
  border: 3px solid var(--border-color);
  border-radius: 24px;
  padding: 26px 24px;
  box-shadow: 0 20px 44px rgba(35, 41, 70, 0.28);
}

.modal-close-btn {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: 2px solid var(--border-color);
  background: var(--bg-soft);
  font-size: 1rem;
  font-weight: 700;
  cursor: pointer;
}

.checkout-form {
  display: grid;
  gap: 12px;
}

.checkout-form label {
  display: grid;
  gap: 5px;
  font-family: var(--font-display);
  font-size: 0.92rem;
  font-weight: 600;
  color: var(--ink);
}

.checkout-form input {
  font-family: var(--font-body);
  font-size: 1rem;
  padding: 10px 12px;
  border-radius: 12px;
  border: 2px solid var(--border-color);
  color: var(--ink);
}

.checkout-form input:focus {
  outline: 3px solid var(--brand-orange);
  outline-offset: 1px;
}

.checkout-status {
  font-size: 0.85rem;
  color: var(--ink-muted);
  font-weight: 700;
  min-height: 1.2em;
}

.unlocked-bar[hidden] {
  display: none;
}

/* ==========================================================================
   PWA Install & Notification Dock Bar + Broadcast Alert Toast
   ========================================================================== */

.pwa-dock-bar {
  position: fixed;
  left: 50%;
  bottom: 16px;
  transform: translateX(-50%);
  z-index: 950;
  width: min(94vw, 680px);
  background: #ffffff;
  border: 2.5px solid var(--border-color);
  border-radius: 20px;
  padding: 12px 16px;
  box-shadow: 0 14px 34px rgba(35, 41, 70, 0.22);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.pwa-dock-info {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 220px;
  flex: 1;
}

.pwa-dock-info img {
  border-radius: 12px;
  border: 2px solid var(--border-color);
  flex-shrink: 0;
}

.pwa-dock-info strong {
  display: block;
  font-family: var(--font-display);
  font-size: 0.98rem;
  color: var(--ink);
}

.pwa-dock-info small {
  display: block;
  font-size: 0.82rem;
  color: var(--ink-muted);
  font-weight: 600;
}

.pwa-dock-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.pwa-dock-close {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: 2px solid var(--border-color);
  background: var(--bg-soft);
  font-weight: 700;
  cursor: pointer;
}

.pwa-alert-toast {
  position: fixed;
  top: 84px;
  right: 18px;
  z-index: 1200;
  max-width: 380px;
  background: #fff;
  border: 3px solid var(--border-color);
  border-radius: 18px;
  padding: 14px 16px;
  box-shadow: 0 16px 36px rgba(35, 41, 70, 0.24);
  display: flex;
  align-items: center;
  gap: 12px;
}

.pwa-alert-icon {
  font-size: 1.8rem;
  flex-shrink: 0;
}

.pwa-alert-body strong {
  display: block;
  font-family: var(--font-display);
  font-size: 0.98rem;
}

.pwa-alert-body p {
  font-size: 0.85rem;
  color: var(--ink-muted);
  font-weight: 600;
}

.pwa-alert-actions {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
}

.pwa-alert-actions .btn {
  padding: 6px 12px;
  font-size: 0.82rem;
}

@media print {
  .pwa-dock-bar,
  .pwa-alert-toast {
    display: none !important;
  }
}

@media (max-width: 900px) {
  .art-kit-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .bundle-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 520px) {
  .art-kit-grid {
    grid-template-columns: 1fr;
  }
}

@media print {
  .name-controls-bar,
  .parent-utility-bar,
  .parent-kits-section,
  .coppa-ad-slot {
    display: none !important;
  }
}

/* ==========================================================================
   ABC (A-Z) & 123 (1-100) Dotted Handwriting Tracing Studio (/tracing/)
   ========================================================================== */

.tracing-tabs {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 14px;
}

.tracing-mode-tabs {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.tab-pill {
  font-family: var(--font-display);
  font-size: 1rem;
  font-weight: 700;
  padding: 9px 18px;
  border-radius: 999px;
  border: 2.5px solid var(--border-color);
  background: #fff;
  color: var(--ink);
  cursor: pointer;
  box-shadow: 0 3px 0 var(--border-color);
  transition: transform 0.12s ease, background-color 0.15s ease;
}

.tab-pill:hover {
  transform: translateY(-2px);
  background: var(--bg-soft);
}

.tab-pill.is-active {
  background: var(--brand-orange);
  color: #fff;
}

.case-toggle-group {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}

.case-toggle-group[hidden] {
  display: none;
}

.range-pills {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  margin-bottom: 10px;
}

.range-pills[hidden] {
  display: none;
}

.range-btn {
  font-family: var(--font-display);
  font-size: 0.84rem;
  font-weight: 600;
  padding: 5px 11px;
  border-radius: 999px;
  border: 2px solid var(--border-color);
  background: #fff;
  color: var(--ink);
  cursor: pointer;
}

.range-btn.is-active {
  background: var(--brand-teal);
  color: #fff;
}

.char-picker-grid {
  display: grid;
  grid-template-columns: repeat(13, minmax(0, 1fr));
  gap: 7px;
  margin-bottom: 16px;
}

.char-picker-grid.is-numbers {
  grid-template-columns: repeat(10, minmax(0, 1fr));
}

.char-tile {
  position: relative;
  font-family: var(--font-display);
  font-size: 1.08rem;
  font-weight: 700;
  padding: 8px 4px;
  border-radius: 12px;
  border: 2px solid var(--border-color);
  background: #fff;
  color: var(--ink);
  cursor: pointer;
  text-align: center;
  box-shadow: 0 2px 0 rgba(35, 41, 70, 0.2);
  transition: transform 0.12s ease, background-color 0.12s ease;
}

.char-tile:hover {
  transform: translateY(-2px);
  background: var(--bg-soft);
}

.char-tile.is-selected {
  background: var(--brand-yellow);
  box-shadow: 0 0 0 2px var(--border-color);
  transform: scale(1.06);
}

.char-tile.is-mastered::after {
  content: "⭐";
  position: absolute;
  top: -7px;
  right: -5px;
  font-size: 0.72rem;
}

.tracing-workspace {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 300px;
  gap: 18px;
  align-items: start;
}

.notebook-stage {
  position: relative;
  background: #fffef9;
  border: 3px solid var(--border-color);
  border-radius: var(--radius-md);
  overflow: hidden;
  touch-action: none;
  user-select: none;
  box-shadow: inset 0 0 0 4px rgba(58, 134, 255, 0.08);
}

.notebook-stage canvas {
  width: 100%;
  height: auto;
  display: block;
  cursor: crosshair;
}

.phonics-panel {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.phonics-card {
  background: linear-gradient(135deg, #fff5d6 0%, #ffe8f3 100%);
  border: 2.5px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 16px;
  text-align: center;
}

.phonics-headline {
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--ink);
  margin-bottom: 6px;
}

.phonics-sub {
  font-size: 0.92rem;
  color: var(--ink-muted);
  font-weight: 700;
  margin-bottom: 12px;
}

.phonics-examples {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 12px;
}

.example-word-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  padding: 10px 8px;
  border-radius: 14px;
  border: 2px solid var(--border-color);
  background: #fff;
  cursor: pointer;
  font-family: var(--font-display);
  color: var(--ink);
  box-shadow: 0 2px 0 rgba(35, 41, 70, 0.2);
  transition: transform 0.12s ease, background-color 0.12s ease;
}

.example-word-btn:hover {
  transform: translateY(-2px);
  background: var(--brand-yellow);
}

.example-emoji {
  font-size: 2rem;
  line-height: 1.1;
}

.example-word-label {
  font-size: 0.92rem;
  font-weight: 700;
}

.counting-visual {
  background: #fff;
  border: 2px solid var(--border-color);
  border-radius: 14px;
  padding: 12px;
  margin-bottom: 12px;
}

.counting-dots {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 6px;
  font-size: 1.3rem;
}

.tens-ones-wrap {
  display: flex;
  flex-direction: column;
  gap: 8px;
  align-items: center;
}

.tens-bars {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 6px;
}

.ten-rod {
  background: var(--brand-teal);
  color: #fff;
  border: 2px solid var(--border-color);
  border-radius: 8px;
  padding: 2px 8px;
  font-family: var(--font-display);
  font-size: 0.8rem;
  font-weight: 700;
}

.one-cube {
  background: var(--brand-yellow);
  color: var(--ink);
  border: 2px solid var(--border-color);
  border-radius: 6px;
  padding: 2px 7px;
  font-family: var(--font-display);
  font-size: 0.8rem;
  font-weight: 700;
}

.tracing-colors-card {
  background: var(--bg-sky);
  border: 2.5px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 14px;
}

.tracing-colors-card h3 {
  font-size: 1rem;
  margin-bottom: 10px;
}

.trace-swatch-row {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 12px;
}

.trace-swatch {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  border: 2.5px solid var(--border-color);
  cursor: pointer;
  transition: transform 0.12s ease;
}

.trace-swatch:hover,
.trace-swatch.is-active {
  transform: scale(1.16);
  box-shadow: 0 0 0 2px #fff, 0 0 0 4px var(--border-color);
}

.trace-nav-row {
  display: flex;
  gap: 8px;
}

.trace-nav-row .btn {
  flex: 1;
  padding: 9px 12px;
  font-size: 0.92rem;
}

/* Printable Dotted Practice Worksheet (only visible when printing /tracing/) */
.print-worksheet {
  display: none;
}

@media (max-width: 1024px) {
  .tracing-workspace {
    grid-template-columns: 1fr;
  }
  .char-picker-grid {
    grid-template-columns: repeat(9, minmax(0, 1fr));
  }
}

@media (max-width: 640px) {
  .char-picker-grid {
    grid-template-columns: repeat(7, minmax(0, 1fr));
  }
  .char-picker-grid.is-numbers {
    grid-template-columns: repeat(5, minmax(0, 1fr));
  }
}

@media print {
  body.is-tracing-page .studio-shell,
  body.is-tracing-page .site-header,
  body.is-tracing-page .site-footer,
  body.is-tracing-page .breadcrumbs,
  body.is-tracing-page .seo-card,
  body.is-tracing-page .parent-utility-bar,
  body.is-tracing-page .parent-kits-section {
    display: none !important;
  }

  body.is-tracing-page .print-worksheet {
    display: block !important;
    padding: 12px;
    font-family: var(--font-display);
    color: #232946;
  }

  .ws-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 3px solid #232946;
    padding-bottom: 10px;
    margin-bottom: 18px;
  }

  .ws-row {
    position: relative;
    display: flex;
    justify-content: space-around;
    align-items: center;
    height: 140px;
    margin-bottom: 22px;
    border-top: 2px solid #93c5fd;
    border-bottom: 2px solid #fca5a5;
  }

  .ws-row::before {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    top: 50%;
    border-top: 2px dashed #cbd5e1;
  }

  .ws-char-dotted {
    position: relative;
    z-index: 1;
    font-size: 92px;
    font-weight: 700;
    color: transparent;
    -webkit-text-stroke: 2.5px #94a3b8;
    letter-spacing: 0.04em;
  }
}

/* ==========================================================================
   SEO Content & FAQ Blocks (Below the fold)
   ========================================================================== */

.seo-card {
  background: var(--bg-surface);
  border: 3px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 26px 28px;
  box-shadow: var(--shadow-card);
  margin-top: 30px;
}

.seo-card h2 {
  font-size: 1.5rem;
  margin: 20px 0 10px;
}

.seo-card h2:first-child {
  margin-top: 0;
}

.seo-card h3 {
  font-size: 1.15rem;
  margin: 16px 0 6px;
  color: var(--brand-purple);
}

.seo-card p {
  margin-bottom: 12px;
  color: var(--ink-muted);
}

.seo-card ul {
  margin: 10px 0 16px 22px;
  color: var(--ink-muted);
}

.seo-card li {
  margin-bottom: 6px;
}

.faq-list {
  display: grid;
  gap: 12px;
  margin-top: 12px;
}

.faq-item {
  border: 2px solid var(--border-color);
  border-radius: var(--radius-sm);
  background: var(--bg-page);
  overflow: hidden;
}

.faq-item summary {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.05rem;
  padding: 12px 16px;
  cursor: pointer;
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.faq-item summary::-webkit-details-marker {
  display: none;
}

.faq-item summary::after {
  content: "+";
  font-size: 1.3rem;
  line-height: 1;
  color: var(--brand-orange-dark);
}

.faq-item[open] summary::after {
  content: "−";
}

.faq-item p {
  padding: 0 16px 14px;
  margin: 0;
}

/* ==========================================================================
   Footer (Clean Multi-Column Kids Studio Footer)
   ========================================================================== */

.site-footer {
  background: var(--ink);
  color: #d8ddf0;
  border-top: 4px solid var(--brand-orange);
  padding: 38px 0 26px;
  margin-top: auto;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr 1fr;
  gap: 24px;
  padding-bottom: 24px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.14);
  margin-bottom: 18px;
}

.footer-brand p {
  font-size: 0.92rem;
  color: #c2c8e0;
  margin-top: 8px;
  max-width: 300px;
}

.footer-col h3 {
  font-size: 1rem;
  color: var(--brand-yellow);
  margin-bottom: 10px;
}

.footer-col ul {
  list-style: none;
  display: grid;
  gap: 7px;
}

.footer-col a {
  color: #e6e8f2;
  font-size: 0.92rem;
  font-weight: 600;
  text-decoration: none;
}

.footer-col a:hover {
  color: var(--brand-yellow);
  text-decoration: underline;
}

.footer-partners {
  display: flex;
  align-items: center;
  gap: 10px 14px;
  flex-wrap: wrap;
  padding-bottom: 14px;
  margin-bottom: 14px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  font-size: 0.88rem;
  color: #c2c8e0;
}

.footer-partners-label {
  font-family: var(--font-display);
  font-weight: 600;
  color: var(--brand-yellow);
}

.footer-partners a {
  color: #ffffff;
  font-weight: 700;
  text-decoration: none;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.16);
  padding: 4px 12px;
  border-radius: 999px;
  transition: background 0.16s ease, border-color 0.16s ease, color 0.16s ease;
}

.footer-partners a:hover {
  background: rgba(255, 209, 102, 0.18);
  border-color: var(--brand-yellow);
  color: var(--brand-yellow);
}

.footer-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  font-size: 0.88rem;
  color: #b4bcd8;
}

.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}

.footer-links {
  display: flex;
  gap: 18px;
  flex-wrap: wrap;
  font-family: var(--font-display);
}

.footer-links a {
  color: var(--brand-yellow);
}

/* ==========================================================================
   Responsive Breakpoints
   ========================================================================== */

@media (max-width: 1024px) {
  .category-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .drawing-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .studio-workspace {
    grid-template-columns: 1fr;
  }

  .palette-grid {
    grid-template-columns: repeat(10, minmax(0, 1fr));
  }
}

@media (max-width: 960px) {
  .nav-toggle {
    display: inline-flex;
  }

  .header-cta {
    display: none;
  }

  .main-nav {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--bg-page);
    border-bottom: 3px solid var(--border-color);
    box-shadow: 0 14px 30px rgba(35, 41, 70, 0.16);
    padding: 14px 18px 20px;
    flex-direction: column;
    align-items: stretch;
    gap: 8px;
  }

  .main-nav.is-open {
    display: flex;
  }

  .nav-link {
    justify-content: space-between;
    background: #fff;
    border: 2px solid rgba(35, 41, 70, 0.16);
    padding: 11px 16px;
  }

  .nav-dropdown-menu {
    position: static;
    transform: none !important;
    min-width: 0;
    margin-top: 6px;
    box-shadow: none;
    display: none;
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
  }

  .nav-dropdown.is-open .nav-dropdown-menu {
    display: grid;
  }

  .nav-dropdown:hover .nav-dropdown-menu {
    display: none;
  }

  .nav-dropdown.is-open:hover .nav-dropdown-menu {
    display: grid;
  }

  .nav-mobile-gallery {
    display: inline-flex !important;
    background: var(--brand-yellow) !important;
    border-color: var(--border-color) !important;
  }

  .hero-banner {
    grid-template-columns: 1fr;
    padding: 24px 20px;
  }

  .hero-visual {
    min-height: 170px;
  }

  .hero-polaroid {
    width: 126px;
  }

  .footer-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 768px) {
  .drawing-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
  }

  .palette-grid {
    grid-template-columns: repeat(5, minmax(0, 1fr));
  }

  .seo-card {
    padding: 18px;
  }
}

@media (max-width: 520px) {
  .footer-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 480px) {
  .category-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
  }

  .studio-shell {
    padding: 12px;
  }

  .tool-btn {
    font-size: 0.84rem;
    padding: 6px 10px;
  }
}

/* ==========================================================================
   Connect the Dots Studio (Sprint 1 — Reusable Dot-to-Dot Engine)
   ========================================================================== */

.dots-shell {
  position: relative;
  overflow: hidden;
}

.dots-confetti-host {
  position: absolute;
  inset: 0;
  pointer-events: none;
  overflow: hidden;
  z-index: 6;
}

.dots-confetti-piece {
  position: absolute;
  top: -16px;
  width: 11px;
  height: 16px;
  border-radius: 3px;
  animation: dotsConfettiFall 2.1s ease-in forwards;
}

@keyframes dotsConfettiFall {
  0% { transform: translateY(0) rotate(0deg); opacity: 1; }
  100% { transform: translateY(620px) rotate(520deg); opacity: 0; }
}

.dots-level-pill {
  display: inline-flex;
  align-items: center;
  background: #fef3c7;
  color: #92400e;
  border: 2px solid var(--border-color);
  border-radius: 999px;
  padding: 4px 12px;
  font-family: var(--font-display);
  font-size: 0.84rem;
  font-weight: 600;
}

.dots-progress-row {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 14px;
  flex-wrap: wrap;
}

.dots-progress-track {
  flex: 1;
  min-width: 180px;
  height: 16px;
  background: #f1f5f9;
  border: 2px solid var(--border-color);
  border-radius: 999px;
  overflow: hidden;
}

.dots-progress-fill {
  height: 100%;
  background: linear-gradient(90deg, #ff8c24, #22c55e);
  border-radius: 999px;
  transition: width 0.2s ease;
}

.dots-progress-label {
  font-family: var(--font-display);
  font-size: 0.94rem;
  font-weight: 600;
  color: var(--ink);
}

.dots-stage {
  background: #ffffff;
  border: 3px solid var(--border-color);
  border-radius: 22px;
  overflow: hidden;
  box-shadow: inset 0 2px 10px rgba(35, 41, 70, 0.05);
  max-width: 820px;
  margin: 0 auto;
}

.dots-stage:focus-visible {
  outline: 4px solid var(--brand-orange);
  outline-offset: 3px;
}

.dots-stage svg {
  width: 100%;
  height: auto;
  display: block;
  user-select: none;
  -webkit-user-select: none;
}

.dots-pulse-ring {
  transform-box: fill-box;
  transform-origin: center;
  animation: dotsPulse 1.2s ease-in-out infinite;
}

@keyframes dotsPulse {
  0%, 100% { transform: scale(0.88); opacity: 0.95; }
  50% { transform: scale(1.22); opacity: 0.45; }
}

.dots-tip {
  text-align: center;
  margin: 12px 0 4px;
  font-family: var(--font-display);
  font-size: 1rem;
  font-weight: 600;
  color: var(--ink-muted);
}

.dots-celebrate-bar {
  margin-top: 14px;
  padding: 16px 18px;
  background: #ecfdf5;
  border: 2.5px solid #10b981;
  border-radius: 18px;
}

.dots-celebrate-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 12px;
}

.dots-celebrate-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.dots-quick-palette {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  align-items: center;
}

.dots-swatch {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: 3px solid var(--border-color);
  cursor: pointer;
  transition: transform 0.14s ease, box-shadow 0.14s ease;
}

.dots-swatch:hover {
  transform: scale(1.1);
}

.dots-swatch.is-active {
  transform: scale(1.14);
  box-shadow: 0 0 0 3px #fff, 0 0 0 6px var(--brand-orange);
}

.dots-worksheet-bar {
  margin-top: 16px;
  padding: 14px 18px;
  background: #fff7ed;
  border: 2.5px dashed #fb923c;
  border-radius: 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
}

.dots-worksheet-bar small {
  display: block;
  color: var(--ink-muted);
  font-weight: 600;
  margin-top: 2px;
}

.dots-worksheet-controls {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.dots-paper-label {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.9rem;
}

.dots-paper-label select {
  padding: 9px 12px;
  min-height: 44px;
  border: 2px solid var(--border-color);
  border-radius: 12px;
  font-family: var(--font-body);
  font-weight: 700;
  background: #fff;
  color: var(--ink);
}

.dots-library {
  margin-top: 28px;
}

.dots-filter-row {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 16px;
}

.dots-filter-btn {
  min-height: 44px;
  padding: 8px 16px;
  border-radius: 999px;
  border: 2.5px solid var(--border-color);
  background: #fff;
  color: var(--ink);
  font-family: var(--font-display);
  font-size: 0.92rem;
  font-weight: 600;
  cursor: pointer;
  transition: transform 0.14s ease, background 0.14s ease;
}

.dots-filter-btn:hover {
  transform: translateY(-2px);
}

.dots-filter-btn.is-active {
  background: var(--brand-orange);
  color: #fff;
}

.dots-picker-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(230px, 1fr));
  gap: 12px;
}

.dots-pick-card {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 64px;
  padding: 12px 14px;
  text-align: left;
  background: #fff;
  border: 2.5px solid var(--border-color);
  border-radius: 16px;
  cursor: pointer;
  box-shadow: var(--shadow-card);
  transition: transform 0.14s ease, background 0.14s ease;
}

.dots-pick-card:hover {
  transform: translateY(-2px);
  background: #fffbeb;
}

.dots-pick-card.is-active {
  background: #fef3c7;
  border-color: var(--brand-orange-dark);
  box-shadow: 0 0 0 3px rgba(255, 140, 36, 0.28);
}

.dots-pick-emoji {
  font-size: 1.9rem;
  line-height: 1;
}

.dots-pick-info {
  display: grid;
  gap: 2px;
}

.dots-pick-info strong {
  font-family: var(--font-display);
  font-size: 1rem;
  color: var(--ink);
}

.dots-pick-info small {
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--ink-muted);
}

@media (prefers-reduced-motion: reduce) {
  .dots-pulse-ring,
  .dots-confetti-piece {
    animation: none !important;
  }
}

/* ==========================================================================
   India Map & Geography Studio (Sprint 2 — 5 Interactive Modes)
   ========================================================================== */

.country-switcher-bar {
  background: linear-gradient(135deg, #fff7ed 0%, #eff6ff 100%);
  border: 2.5px solid var(--border-color);
  border-radius: 18px;
  padding: 14px 16px;
  margin-bottom: 14px;
  display: grid;
  gap: 10px;
}

.country-switcher-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.country-select-label {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  font-family: var(--font-display);
  font-size: 1rem;
  font-weight: 700;
  color: var(--ink);
}

.country-select-label select {
  min-height: 44px;
  padding: 8px 14px;
  border-radius: 12px;
  border: 2.5px solid var(--border-color);
  background: #ffffff;
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 0.96rem;
  font-weight: 700;
  cursor: pointer;
}

.country-detected-pill {
  display: inline-flex;
  align-items: center;
  background: #ecfdf5;
  color: #065f46;
  border: 2px solid #10b981;
  border-radius: 999px;
  padding: 5px 12px;
  font-family: var(--font-display);
  font-size: 0.84rem;
  font-weight: 600;
}

.country-quickbar {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.country-quick-pill {
  min-height: 38px;
  padding: 6px 13px;
  border-radius: 999px;
  border: 2px solid var(--border-color);
  background: #ffffff;
  color: var(--ink);
  font-family: var(--font-display);
  font-size: 0.88rem;
  font-weight: 600;
  cursor: pointer;
  transition: transform 0.12s ease, background 0.12s ease;
}

.country-quick-pill:hover {
  transform: translateY(-1px);
  background: #fef3c7;
}

.country-quick-pill.is-active {
  background: var(--brand-orange);
  color: #ffffff;
}

.india-tabs {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.india-tab {
  min-height: 44px;
  padding: 9px 16px;
  border-radius: 999px;
  border: 2.5px solid var(--border-color);
  background: #ffffff;
  color: var(--ink);
  font-family: var(--font-display);
  font-size: 0.94rem;
  font-weight: 600;
  cursor: pointer;
  transition: transform 0.14s ease, background 0.14s ease;
}

.india-tab:hover {
  transform: translateY(-2px);
}

.india-tab.is-active {
  background: var(--brand-teal);
  color: #ffffff;
}

.india-quiz-banner {
  margin: 12px 0 14px;
  padding: 14px 18px;
  background: #fefce8;
  border: 2.5px solid #f59e0b;
  border-radius: 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
}

/* Full-Width Edge-to-Edge Map Studio + True Fullscreen Mode */
.studio-shell.india-shell {
  width: min(98vw, 1760px);
  max-width: none;
  margin-left: 50%;
  transform: translateX(-50%);
  padding: 16px 20px;
}

.india-workspace {
  display: grid;
  grid-template-columns: minmax(0, 1.8fr) minmax(270px, 340px);
  gap: 18px;
  align-items: start;
}

.india-map-stage {
  background: #e0f2fe;
  border: 3px solid var(--border-color);
  border-radius: 22px;
  overflow: hidden;
  padding: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.india-map-stage svg {
  width: 100%;
  height: auto;
  max-height: 76vh;
  display: block;
}

.studio-shell.india-shell:fullscreen,
.studio-shell.india-shell.is-fullscreen {
  position: fixed;
  inset: 0;
  width: 100vw !important;
  height: 100vh !important;
  margin: 0 !important;
  transform: none !important;
  border-radius: 0;
  border: none;
  z-index: 1200;
  overflow-y: auto;
  background: var(--bg-page);
  padding: 14px 20px;
}

.studio-shell.india-shell:fullscreen .india-map-stage svg,
.studio-shell.india-shell.is-fullscreen .india-map-stage svg {
  max-height: calc(100vh - 190px);
}

@media (max-width: 960px) {
  .studio-shell.india-shell {
    width: 100%;
    margin-left: 0;
    transform: none;
    padding: 12px;
  }
  .india-map-stage svg {
    max-height: 62vh;
  }
}

.india-region-path {
  cursor: pointer;
  transition: opacity 0.12s ease, filter 0.12s ease;
}

.india-region-path:hover {
  filter: brightness(0.93);
  stroke-width: 2.2;
}

.india-sidebar {
  display: grid;
  gap: 14px;
}

.india-fact-card {
  background: #fffbeb;
  border: 2.5px solid var(--border-color);
  border-radius: 18px;
  padding: 14px 16px;
}

.india-fact-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 6px;
}

.india-fact-head strong {
  font-family: var(--font-display);
  font-size: 1.15rem;
}

.india-type-badge {
  display: inline-block;
  font-family: var(--font-display);
  font-size: 0.76rem;
  font-weight: 600;
  background: #e0f2fe;
  color: #0369a1;
  border: 1.5px solid #7dd3fc;
  border-radius: 999px;
  padding: 2px 10px;
}

.india-fact-cap {
  font-size: 0.94rem;
  margin-bottom: 6px;
  color: var(--ink);
}

.india-fact-card p {
  margin: 0;
  font-size: 0.9rem;
  color: var(--ink-muted);
  font-weight: 600;
}

.india-side-box {
  background: #ffffff;
  border: 2.5px solid var(--border-color);
  border-radius: 18px;
  padding: 14px;
}

.india-side-box h3 {
  font-size: 1rem;
  margin: 0 0 10px;
}

.india-palette-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 8px;
}

.india-swatch {
  width: 100%;
  aspect-ratio: 1;
  min-width: 40px;
  min-height: 40px;
  border-radius: 50%;
  border: 2.5px solid var(--border-color);
  cursor: pointer;
  transition: transform 0.14s ease;
}

.india-swatch:hover {
  transform: scale(1.08);
}

.india-swatch.is-active {
  transform: scale(1.12);
  box-shadow: 0 0 0 2.5px #fff, 0 0 0 5.5px var(--brand-orange);
}

.india-chips-wrap {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.india-chip {
  min-height: 36px;
  padding: 4px 10px;
  border-radius: 999px;
  border: 2px solid var(--border-color);
  background: #fff;
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 0.8rem;
  font-weight: 700;
  cursor: pointer;
}

.india-chip:hover {
  transform: translateY(-1px);
}

.india-panel {
  margin-top: 10px;
}

.india-subhead {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
  margin-bottom: 14px;
}

.india-subhead h3 {
  margin: 0;
  font-size: 1.25rem;
}

.india-match-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

.india-match-col {
  display: grid;
  gap: 10px;
}

.india-match-card {
  min-height: 54px;
  padding: 12px 16px;
  border-radius: 16px;
  border: 2.5px solid var(--border-color);
  background: #fff;
  color: var(--ink);
  font-family: var(--font-display);
  font-size: 1rem;
  font-weight: 600;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  cursor: pointer;
  text-align: left;
  transition: transform 0.14s ease, background 0.14s ease;
}

.india-match-card small {
  font-family: var(--font-body);
  font-size: 0.78rem;
  color: var(--ink-muted);
}

.india-match-card.is-capital {
  background: #f0f9ff;
}

.india-match-card.is-selected {
  background: #fef3c7;
  border-color: var(--brand-orange-dark);
  transform: scale(1.02);
}

.india-match-card.is-solved {
  background: #dcfce7;
  border-color: #16a34a;
  color: #166534;
  cursor: default;
}

.india-puzzle-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(240px, 0.85fr);
  gap: 18px;
  align-items: start;
}

.india-puzzle-map {
  background: #e0f2fe;
  border: 3px solid var(--border-color);
  border-radius: 22px;
  overflow: hidden;
  padding: 6px;
}

.india-puzzle-map svg {
  width: 100%;
  height: auto;
  display: block;
}

.india-puzzle-tray {
  background: #fff;
  border: 2.5px solid var(--border-color);
  border-radius: 18px;
  padding: 14px;
  display: grid;
  gap: 10px;
}

.india-pieces-list {
  display: grid;
  gap: 8px;
  max-height: 440px;
  overflow-y: auto;
}

.india-piece-btn {
  min-height: 50px;
  padding: 10px 14px;
  border-radius: 14px;
  border: 2px solid var(--border-color);
  background: #fffbeb;
  text-align: left;
  cursor: pointer;
  display: grid;
  gap: 2px;
}

.india-piece-btn strong {
  font-family: var(--font-display);
  font-size: 0.98rem;
  color: var(--ink);
}

.india-piece-btn small {
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--ink-muted);
}

.india-piece-btn.is-selected {
  background: #ffedd5;
  border-color: var(--brand-orange-dark);
  box-shadow: 0 0 0 3px rgba(255, 140, 36, 0.25);
}

.india-win-box {
  background: #dcfce7;
  border: 2px solid #16a34a;
  border-radius: 14px;
  padding: 16px;
  text-align: center;
  font-family: var(--font-display);
  font-size: 1.1rem;
  color: #166534;
}

.india-symbols-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 16px;
}

.india-symbol-card {
  background: #fff;
  border: 2.5px solid var(--border-color);
  border-radius: 20px;
  padding: 16px;
  display: grid;
  gap: 8px;
  text-align: center;
  box-shadow: var(--shadow-card);
}

.india-symbol-art {
  background: #f8fafc;
  border: 2px solid #e2e8f0;
  border-radius: 14px;
  padding: 8px;
}

.india-symbol-art svg {
  width: 100%;
  max-width: 220px;
  height: auto;
  margin: 0 auto;
  display: block;
}

.india-symbol-card h4 {
  margin: 0;
  font-size: 1.1rem;
}

.india-symbol-card p {
  margin: 0;
  font-size: 0.88rem;
  color: var(--ink-muted);
  font-weight: 600;
}

.spotlight-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  margin: 10px 0 22px;
}

.spotlight-card {
  border: 3px solid var(--border-color);
  border-radius: 24px;
  padding: 22px;
  box-shadow: var(--shadow-card);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 14px;
}

.spotlight-card h2 {
  font-size: 1.38rem;
  margin: 6px 0;
}

.spotlight-card p {
  margin: 0;
  font-size: 0.94rem;
  color: var(--ink-muted);
  font-weight: 600;
}

@media (max-width: 900px) {
  .india-workspace,
  .india-puzzle-grid,
  .spotlight-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 600px) {
  .india-match-grid {
    grid-template-columns: 1fr;
  }
}

/* ==========================================================================
   Sprint 3 & 4 — Learning Center, Infinite Mazes, Memory Match & Parents Hub
   ========================================================================== */

.learn-card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  gap: 12px;
  margin: 14px 0;
}

.learn-shape-card {
  display: grid;
  justify-items: center;
  gap: 4px;
  padding: 14px 10px;
  background: #fff;
  border: 2.5px solid var(--border-color);
  border-radius: 18px;
  cursor: pointer;
  box-shadow: var(--shadow-card);
  transition: transform 0.14s ease, background 0.14s ease;
}

.learn-shape-card:hover {
  transform: translateY(-3px);
  background: #fffbeb;
}

.learn-shape-card.is-active {
  background: #fef3c7;
  border-color: var(--brand-orange-dark);
}

.learn-shape-card strong {
  font-family: var(--font-display);
  font-size: 1.05rem;
  color: var(--ink);
}

.learn-shape-card small {
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--ink-muted);
  text-align: center;
}

.learn-info-banner {
  background: #ecfdf5;
  border: 2.5px solid #10b981;
  border-radius: 16px;
  padding: 14px 18px;
  text-align: center;
  font-family: var(--font-display);
  font-size: 1.08rem;
  color: #065f46;
}

.learn-quiz-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  margin: 8px 0 14px;
}

.learn-quiz-head h3 {
  margin: 0;
  font-size: 1.3rem;
}

.learn-options-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
  margin-bottom: 12px;
}

.learn-option-card {
  min-height: 148px;
  padding: 16px 10px;
  display: grid;
  place-items: center;
  gap: 8px;
  background: #fff;
  border: 3px solid var(--border-color);
  border-radius: 20px;
  cursor: pointer;
  box-shadow: var(--shadow-card);
  transition: transform 0.14s ease, background 0.14s ease;
}

.learn-option-card:hover {
  transform: translateY(-3px);
  background: #fffbeb;
}

.learn-option-card.is-correct {
  background: #dcfce7;
  border-color: #16a34a;
}

.learn-option-card.is-wrong {
  background: #ffe4e6;
  border-color: #e11d48;
}

.learn-option-card strong {
  font-family: var(--font-display);
  font-size: 1.05rem;
  color: var(--ink);
}

.count-objects-board {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
  padding: 22px 16px;
  background: #fffbeb;
  border: 3px solid var(--border-color);
  border-radius: 22px;
  margin-bottom: 16px;
}

.count-item-btn {
  position: relative;
  width: 68px;
  height: 68px;
  border-radius: 18px;
  border: 2.5px solid var(--border-color);
  background: #fff;
  font-size: 2.2rem;
  display: grid;
  place-items: center;
  cursor: pointer;
  transition: transform 0.14s ease, background 0.14s ease;
}

.count-item-btn:hover {
  transform: scale(1.08);
}

.count-item-btn.is-counted {
  background: #dcfce7;
  border-color: #16a34a;
}

.count-tag {
  position: absolute;
  top: -8px;
  right: -8px;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: var(--brand-orange);
  color: #fff;
  font-style: normal;
  font-family: var(--font-display);
  font-size: 0.84rem;
  font-weight: 700;
  display: grid;
  place-items: center;
  border: 2px solid var(--border-color);
}

.count-choices-row {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
  max-width: 560px;
  margin: 0 auto 10px;
}

.count-num-btn {
  min-height: 64px;
  border-radius: 18px;
  border: 3px solid var(--border-color);
  background: #fff;
  font-family: var(--font-display);
  font-size: 1.8rem;
  font-weight: 700;
  color: var(--ink);
  cursor: pointer;
  box-shadow: var(--shadow-card);
  transition: transform 0.14s ease, background 0.14s ease;
}

.count-num-btn:hover {
  transform: translateY(-2px);
  background: #fef3c7;
}

.count-num-btn.is-correct {
  background: #dcfce7;
  border-color: #16a34a;
  color: #166534;
}

.count-num-btn.is-wrong {
  background: #ffe4e6;
  border-color: #e11d48;
}

.shadow-match-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
  margin-bottom: 10px;
}

.shadow-col {
  display: grid;
  gap: 12px;
}

.shadow-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 16px;
  background: #fff;
  border: 3px solid var(--border-color);
  border-radius: 18px;
  cursor: pointer;
  box-shadow: var(--shadow-card);
  transition: transform 0.14s ease;
}

.shadow-card img {
  width: 96px;
  height: 72px;
  object-fit: contain;
}

.shadow-card strong {
  font-family: var(--font-display);
  font-size: 1.05rem;
  color: var(--ink);
}

.shadow-card.is-silhouette img {
  filter: brightness(0) contrast(1.2);
}

.shadow-card.is-selected {
  background: #fef3c7;
  border-color: var(--brand-orange-dark);
  transform: scale(1.02);
}

.shadow-card.is-solved {
  background: #dcfce7;
  border-color: #16a34a;
}

.shadow-card.is-silhouette.is-solved img {
  filter: none;
}

.maze-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 210px;
  gap: 18px;
  align-items: center;
  margin-bottom: 8px;
}

.maze-stage {
  max-width: 600px;
  width: 100%;
  margin: 0 auto;
  border: 3px solid var(--border-color);
  border-radius: 22px;
  overflow: hidden;
  background: #fffbeb;
}

.maze-stage svg {
  width: 100%;
  height: auto;
  display: block;
}

.maze-dpad {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  padding: 16px;
  background: #f8fafc;
  border: 2.5px solid var(--border-color);
  border-radius: 20px;
}

.dpad-mid {
  display: flex;
  gap: 8px;
}

.dpad-btn {
  width: 54px;
  height: 54px;
  border-radius: 14px;
  border: 2.5px solid var(--border-color);
  background: #fff;
  font-size: 1.45rem;
  cursor: pointer;
  box-shadow: 0 3px 0 var(--border-color);
}

.dpad-btn:active {
  transform: translateY(2px);
  box-shadow: 0 1px 0 var(--border-color);
}

.memory-board {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  max-width: 660px;
  margin: 0 auto 14px;
}

.memory-card {
  position: relative;
  aspect-ratio: 1;
  min-height: 92px;
  border-radius: 18px;
  border: 3px solid var(--border-color);
  background: linear-gradient(135deg, #ff8c24, #ffd166);
  cursor: pointer;
  display: grid;
  place-items: center;
  box-shadow: var(--shadow-card);
  transition: transform 0.16s ease, background 0.16s ease;
}

.memory-card:hover {
  transform: translateY(-2px);
}

.memory-front {
  font-size: 2.2rem;
}

.memory-back {
  display: none;
  flex-direction: column;
  align-items: center;
  gap: 2px;
}

.memory-back em {
  font-style: normal;
  font-size: 2.6rem;
  line-height: 1;
}

.memory-back small {
  font-family: var(--font-display);
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--ink);
}

.memory-card.is-flipped,
.memory-card.is-matched {
  background: #ffffff;
}

.memory-card.is-flipped .memory-front,
.memory-card.is-matched .memory-front {
  display: none;
}

.memory-card.is-flipped .memory-back,
.memory-card.is-matched .memory-back {
  display: flex;
}

.memory-card.is-matched {
  background: #dcfce7;
  border-color: #16a34a;
  cursor: default;
}

.pt-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
  margin-bottom: 24px;
}

.pt-card {
  background: #fff;
  border: 2.5px solid var(--border-color);
  border-radius: 22px;
  padding: 20px;
  box-shadow: var(--shadow-card);
}

.pt-card h3 {
  font-size: 1.2rem;
  margin: 4px 0 12px;
}

.pt-card ul {
  list-style: none;
  display: grid;
  gap: 10px;
  padding: 0;
  margin: 0;
  font-size: 0.92rem;
  color: var(--ink-muted);
  font-weight: 600;
}

.pt-card a {
  color: var(--ink);
  font-weight: 700;
  text-decoration: none;
}

.pt-card a:hover {
  color: var(--brand-orange-dark);
  text-decoration: underline;
}

.learning-hub-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
  margin-bottom: 24px;
}

.learning-hub-card {
  background: #fff;
  border: 2.5px solid var(--border-color);
  border-radius: 18px;
  padding: 16px;
  text-decoration: none;
  color: var(--ink);
  display: flex;
  align-items: flex-start;
  gap: 12px;
  box-shadow: var(--shadow-card);
  transition: transform 0.14s ease, background 0.14s ease;
}

.learning-hub-card:hover {
  transform: translateY(-2px);
  background: #fffbeb;
}

.learning-hub-icon {
  font-size: 2rem;
  line-height: 1;
}

.learning-hub-card h3 {
  font-size: 1.05rem;
  margin: 0 0 3px;
}

.learning-hub-card p {
  margin: 0;
  font-size: 0.86rem;
  color: var(--ink-muted);
  font-weight: 600;
}

@media (max-width: 900px) {
  .maze-layout,
  .pt-grid,
  .learning-hub-grid {
    grid-template-columns: 1fr;
  }
  .learn-options-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 600px) {
  .shadow-match-grid {
    grid-template-columns: 1fr;
  }
  .memory-board {
    gap: 8px;
  }
}

.body-workspace {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(260px, 0.85fr);
  gap: 18px;
  align-items: start;
}

.body-diagram-box {
  background: #f8fafc;
  border: 3px solid var(--border-color);
  border-radius: 22px;
  overflow: hidden;
  padding: 6px;
}

.body-diagram-box svg {
  width: 100%;
  height: auto;
  display: block;
}

.body-side {
  display: grid;
  gap: 14px;
}

.india-chip.is-active-chip {
  background: var(--brand-orange) !important;
  color: #ffffff;
}

@media (max-width: 900px) {
  .body-workspace {
    grid-template-columns: 1fr;
  }
}

.space-canvas-wrap {
  background: #0f172a;
  border: 3px solid var(--border-color);
  border-radius: 22px;
  overflow: hidden;
  padding: 6px;
}

.space-canvas-wrap svg {
  width: 100%;
  height: auto;
  display: block;
}

.space-fact-grid {
  display: grid;
  grid-template-columns: 1.25fr 0.75fr;
  gap: 16px;
  align-items: start;
}

.space-order-slots {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
  gap: 10px;
}

.space-slot {
  min-height: 54px;
  padding: 8px 10px;
  border-radius: 14px;
  border: 2.5px dashed #94a3b8;
  background: #f8fafc;
  font-family: var(--font-display);
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--ink-muted);
  display: grid;
  place-items: center;
  text-align: center;
}

.space-slot.is-sun {
  background: #fef08a;
  border-style: solid;
  border-color: #f59e0b;
  color: #92400e;
}

.space-slot.is-next {
  border-color: var(--brand-orange);
  background: #fff7ed;
  color: var(--brand-orange-dark);
}

.space-slot.is-filled {
  border-style: solid;
  border-color: #16a34a;
  background: #dcfce7;
  color: #166534;
}

@media (max-width: 900px) {
  .space-fact-grid {
    grid-template-columns: 1fr;
  }
}

/* ==========================================================================
   Interactive Homepage Hub (Compact Hero, Filter Pills, Age Picker & Dock)
   ========================================================================== */

.hero-banner.hero-home {
  padding: 20px 26px;
  margin-bottom: 18px;
  gap: 20px;
}

.hero-banner.hero-home h1 {
  font-size: clamp(1.55rem, 2.8vw, 2.25rem);
  margin-bottom: 8px;
}

.hero-banner.hero-home p {
  font-size: 0.98rem;
  margin-bottom: 0;
}

.hero-banner.hero-home .hero-cta-row {
  margin-top: 14px;
  gap: 10px;
}

.hero-banner.hero-home .hero-visual {
  min-height: 182px;
}

.hero-banner.hero-home .hero-polaroid {
  width: 138px;
  padding: 8px 8px 10px;
}

.home-filter-bar {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  margin: 0 0 16px;
}

.home-filter-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: var(--font-display);
  font-size: 0.9rem;
  font-weight: 700;
  padding: 7px 14px;
  border-radius: 999px;
  border: 2.5px solid var(--border-color);
  background: #ffffff;
  color: var(--ink);
  cursor: pointer;
  box-shadow: 0 2px 0 rgba(35, 41, 70, 0.16);
  transition: transform 0.14s ease, background-color 0.14s ease, color 0.14s ease;
}

.home-filter-pill:hover {
  transform: translateY(-2px);
  background: var(--bg-soft);
}

.home-filter-pill.is-active {
  background: var(--brand-orange);
  color: #ffffff;
  box-shadow: 0 3px 0 var(--border-color);
}

.age-filter-pill {
  font-family: var(--font-display);
  font-size: 0.85rem;
  font-weight: 700;
  padding: 5px 12px;
  border-radius: 999px;
  border: 2px solid var(--border-color);
  background: #ffffff;
  color: var(--ink);
  cursor: pointer;
  transition: background-color 0.14s ease, color 0.14s ease, transform 0.14s ease;
}

.age-filter-pill:hover {
  background: #fef9c3;
  transform: translateY(-1px);
}

.age-filter-pill.is-active {
  background: var(--brand-teal);
  color: #ffffff;
}

.home-browser-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.btn-surprise {
  background: linear-gradient(135deg, #8b5cf6 0%, #ec4899 100%);
  color: #ffffff;
}

.fun-banner-links {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  margin-top: 8px;
}

.fun-mini-link {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-family: var(--font-display);
  font-size: 0.78rem;
  font-weight: 700;
  padding: 3px 9px;
  border-radius: 999px;
  background: #ffffff;
  border: 1.5px solid var(--border-color);
  color: var(--ink);
  text-decoration: none;
}

.fun-mini-link:hover {
  background: var(--brand-yellow);
  text-decoration: none;
}

.learning-hub-card.is-age-dim {
  opacity: 0.35;
  transform: scale(0.98);
}

.learning-hub-card.is-age-match {
  border-color: var(--brand-teal);
  box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.2), var(--shadow-card);
}

.home-parents-dock {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
  background: linear-gradient(135deg, #fefce8 0%, #ecfdf5 55%, #eff6ff 100%);
  border: 2.5px solid var(--border-color);
  border-radius: 20px;
  padding: 16px 20px;
  margin-bottom: 24px;
  box-shadow: var(--shadow-card);
}

.home-parents-dock h3 {
  font-size: 1.08rem;
  margin: 0 0 2px;
}

.home-parents-dock p {
  margin: 0;
  font-size: 0.88rem;
  color: var(--ink-muted);
  font-weight: 600;
}

.home-parents-dock-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

@media (max-width: 1040px) {
  .learning-hub-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 680px) {
  .hero-banner.hero-home {
    padding: 16px 16px;
  }
  .hero-banner.hero-home .hero-visual {
    display: none;
  }
  .home-filter-bar {
    flex-wrap: nowrap;
    overflow-x: auto;
    padding-bottom: 6px;
    -webkit-overflow-scrolling: touch;
  }
  .home-filter-pill {
    flex-shrink: 0;
  }
  .learning-hub-grid {
    grid-template-columns: 1fr;
  }
}

/* Visual Paint Splash Ripple + Musical Note Burst on Tap */
.paint-splash-ring {
  position: absolute;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  border: 4px solid var(--brand-orange);
  pointer-events: none;
  transform: translate(-50%, -50%) scale(0.4);
  opacity: 0.95;
  z-index: 12;
  animation: pfkSplashRing 0.52s cubic-bezier(0.22, 1, 0.36, 1) forwards;
}

.paint-splash-note {
  position: absolute;
  font-size: 1.45rem;
  line-height: 1;
  pointer-events: none;
  transform: translate(-50%, -50%) scale(0.7);
  opacity: 1;
  z-index: 13;
  filter: drop-shadow(0 2px 3px rgba(35, 41, 70, 0.25));
  animation: pfkSplashNote 0.58s ease-out forwards;
}

@keyframes pfkSplashRing {
  0% {
    transform: translate(-50%, -50%) scale(0.35);
    opacity: 0.95;
  }
  100% {
    transform: translate(-50%, -50%) scale(3.1);
    opacity: 0;
  }
}

@keyframes pfkSplashNote {
  0% {
    transform: translate(-50%, -40%) scale(0.65);
    opacity: 0;
  }
  25% {
    transform: translate(-50%, -90%) scale(1.18);
    opacity: 1;
  }
  100% {
    transform: translate(-50%, -180%) scale(0.95);
    opacity: 0;
  }
}

@media print {
  .paint-splash-ring,
  .paint-splash-note {
    display: none !important;
  }
}

/* ==========================================================================
   Print Stylesheet — Prints ONLY the Coloring Artwork Cleanly
   ========================================================================== */

@media print {
  body {
    background: #fff !important;
  }

  .site-header,
  .site-footer,
  .breadcrumbs,
  .studio-topbar,
  .palette-panel,
  .seo-card,
  .related-section {
    display: none !important;
  }

  .page-main,
  .container,
  .studio-shell,
  .studio-workspace,
  .canvas-stage {
    margin: 0 !important;
    padding: 0 !important;
    border: none !important;
    box-shadow: none !important;
    display: block !important;
    width: 100% !important;
  }

  .canvas-stage svg {
    width: 100% !important;
    max-height: 92vh !important;
    margin: 0 auto !important;
  }
}
