/* ==========================================================================
   12 Petpals Overseas Website — style.css
   Warm / premium / playful / trustworthy / international / product-first
   Mobile-first. Cards only for repeated items, demo entries, policy cards,
   or feature modules. No cards inside cards.
   ========================================================================== */

:root {
  --cream: #FFF8EC;
  --white: #FFFFFF;
  --orange: #F46A35;
  --orange-deep: #E4571F;
  --gold: #F6B940;
  --navy: #243047;
  --blue: #3A8DFF;
  --muted: #647084;
  --line: #EFE4D0;
  --green: #2E9E5B; /* status only */
  --radius: 18px;
  --radius-sm: 12px;
  --shadow: 0 10px 30px rgba(36, 48, 71, 0.08);
  --shadow-lg: 0 20px 50px rgba(36, 48, 71, 0.12);
  --font: "Inter", "Nunito Sans", -apple-system, BlinkMacSystemFont, "Segoe UI",
          "Noto Sans SC", "PingFang SC", "Microsoft YaHei", system-ui, sans-serif;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

body {
  font-family: var(--font);
  color: var(--navy);
  background: var(--white);
  line-height: 1.6;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; height: auto; display: block; }
a { color: var(--orange); text-decoration: none; }
a:hover { color: var(--orange-deep); }

.container { width: 100%; max-width: 1120px; margin: 0 auto; padding: 0 20px; }

/* ---- Typography ---- */
h1, h2, h3, h4 { line-height: 1.2; font-weight: 800; color: var(--navy); }
h1 { font-size: 2rem; }
h2 { font-size: 1.6rem; }
h3 { font-size: 1.2rem; }

.section { padding: 56px 0; }
.section--cream { background: var(--cream); }
.section--white { background: var(--white); }

.section-head { max-width: 720px; margin-bottom: 32px; }
.section-head h2 { margin-bottom: 12px; }
.section-head .sub { color: var(--muted); font-size: 1.05rem; }

.eyebrow {
  display: inline-block; font-size: 0.8rem; font-weight: 700;
  letter-spacing: 0.08em; text-transform: uppercase;
  color: var(--orange); margin-bottom: 10px;
}

/* ---- Buttons ---- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  font-family: var(--font); font-weight: 700; font-size: 1rem;
  padding: 13px 22px; border-radius: 999px; border: 2px solid transparent;
  cursor: pointer; text-align: center; transition: transform .12s ease, box-shadow .12s ease, background .12s ease;
  white-space: nowrap;
}
.btn:hover { transform: translateY(-1px); }
.btn:active { transform: translateY(0); }
.btn--primary { background: var(--orange); color: #fff; box-shadow: 0 8px 20px rgba(244, 106, 53, 0.28); }
.btn--primary:hover { background: var(--orange-deep); color: #fff; box-shadow: 0 10px 24px rgba(244, 106, 53, 0.36); }
.btn--secondary { background: transparent; color: var(--navy); border-color: var(--navy); }
.btn--secondary:hover { background: var(--navy); color: #fff; }
.btn--ghost { background: transparent; color: var(--orange); border-color: transparent; padding-left: 4px; padding-right: 4px; }
.btn--block { width: 100%; }

/* ---- Header ---- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255, 255, 255, 0.92); backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.header-inner { display: flex; align-items: center; gap: 12px; min-height: 64px; }
.brand { display: flex; align-items: center; gap: 10px; color: var(--navy); }
.brand:hover { color: var(--navy); }
.brand-logo { width: 40px; height: 40px; object-fit: contain; }
.brand-name { font-weight: 800; font-size: 1.15rem; letter-spacing: -0.01em; }

.nav-toggle {
  margin-left: auto; background: none; border: none; font-size: 1.6rem;
  color: var(--navy); cursor: pointer; line-height: 1; padding: 6px 10px;
}
.site-nav { display: none; }
.site-nav.open { display: flex; }
.site-nav { flex-direction: column; }
.site-nav a {
  color: var(--navy); font-weight: 600; font-size: 0.98rem;
  padding: 10px 0; border-bottom: 1px solid var(--line);
}
.site-nav a:hover, .site-nav a.active { color: var(--orange); }

.lang-toggle {
  margin-left: auto; background: var(--cream); border: 1px solid var(--line);
  color: var(--navy); font-weight: 700; font-size: 0.9rem;
  padding: 8px 14px; border-radius: 999px; cursor: pointer; white-space: nowrap;
}
.lang-toggle:hover { border-color: var(--orange); color: var(--orange); }

/* ---- Hero ---- */
.hero { background: var(--cream); padding: 40px 0 56px; overflow: hidden; }
.hero-inner { display: grid; gap: 32px; align-items: center; }
.hero h1 { font-size: 2.1rem; margin-bottom: 12px; }
.hero .tagline { font-size: 1.15rem; font-weight: 700; color: var(--orange); margin-bottom: 10px; }
.hero .lead { color: var(--muted); font-size: 1.02rem; margin-bottom: 22px; max-width: 30em; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; margin-bottom: 10px; }
.hero-mini { font-size: 0.9rem; color: var(--muted); }
.hero-media { position: relative; }

/* Video placeholder */
.video-frame {
  position: relative; aspect-ratio: 1280 / 592; border-radius: var(--radius);
  overflow: hidden; background: var(--navy); box-shadow: var(--shadow-lg);
}
.video-frame img, .video-frame video { width: 100%; height: 100%; object-fit: cover; display: block; }
.video-frame::after {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(180deg, rgba(36,48,71,0) 40%, rgba(36,48,71,0.35) 100%);
}
.video-badge {
  position: absolute; left: 14px; top: 14px; z-index: 2;
  background: rgba(255,255,255,0.92); color: var(--navy);
  font-size: 0.82rem; font-weight: 700; padding: 6px 12px; border-radius: 999px;
}
.play-btn {
  position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); z-index: 2;
  width: 64px; height: 64px; border-radius: 50%; border: none; cursor: pointer;
  background: rgba(255,255,255,0.95); color: var(--orange);
  display: flex; align-items: center; justify-content: center; box-shadow: var(--shadow);
}
.play-btn::before { content: ""; width: 0; height: 0; border-left: 20px solid var(--orange); border-top: 12px solid transparent; border-bottom: 12px solid transparent; margin-left: 4px; }
.video-title { font-weight: 800; font-size: 1.05rem; margin-top: 16px; }
.video-caption { color: var(--muted); font-size: 0.92rem; margin-top: 4px; }

/* ---- Feature grid / cards ---- */
.grid { display: grid; gap: 20px; }
.grid--2 { grid-template-columns: 1fr; }
.grid--3 { grid-template-columns: 1fr; }
.grid--4 { grid-template-columns: 1fr; }

.card {
  background: var(--white); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 24px; box-shadow: var(--shadow);
}
.card h3 { margin-bottom: 8px; }
.card p { color: var(--muted); font-size: 0.96rem; }
.card ul { list-style: none; color: var(--muted); margin-top: 8px; }
.card ul li { padding: 4px 0; }
.card ul li::before { content: "•"; color: var(--gold); font-weight: 800; margin-right: 8px; }
.card .card-img { border-radius: var(--radius-sm); margin-bottom: 14px; aspect-ratio: 16/9; object-fit: cover; width: 100%; }

.card--accent { border-top: 4px solid var(--gold); }

/* Feature split (image + text alternating) */
.feature { display: grid; gap: 24px; align-items: center; padding: 28px 0; }
.feature .feature-img { border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); }
.feature .feature-img img { aspect-ratio: 16/9; object-fit: cover; width: 100%; }
.feature h3 { font-size: 1.4rem; margin-bottom: 10px; }
.feature p { color: var(--muted); margin-bottom: 6px; }
.feature-sub { color: var(--orange) !important; font-weight: 700; margin-bottom: 8px !important; }

/* Word card grid (core first words) */
.word-card-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.word-card {
  background: var(--white); border: 1px solid var(--line);
  border-radius: var(--radius-sm); overflow: hidden; box-shadow: var(--shadow);
}
.word-card img { width: 100%; height: auto; display: block; }

/* Scene grid (story learning 2x2) */
.scene-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.scene-cell { border-radius: var(--radius-sm); overflow: hidden; box-shadow: var(--shadow); }
.scene-cell img { width: 100%; height: 100%; display: block; aspect-ratio: 16/9; object-fit: cover; }

/* Battle grid (2x2: monsters top, landmark scenes bottom) */
.battle-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.battle-cell { border-radius: var(--radius-sm); overflow: hidden; box-shadow: var(--shadow); background: var(--white); }
.battle-cell img { width: 100%; height: 100%; display: block; }
.battle-cell--monster { background: transparent; box-shadow: none; border-radius: 0; }
.battle-cell--monster img { aspect-ratio: 4/5; object-fit: contain; padding: 12px; }
.battle-cell--scene img { aspect-ratio: 16/9; object-fit: cover; }

/* Shop media (shop shot + 2 rows of item cards) */
.shop-media { display: flex; flex-direction: column; gap: 12px; }
.shop-cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.shop-card { border-radius: var(--radius-sm); overflow: hidden; box-shadow: var(--shadow); }
.shop-card img { width: 100%; height: auto; display: block; }

/* Timer cards (25min + 30min reminders, stacked, transparent) */
.timer-grid { display: grid; grid-template-columns: 1fr; gap: 12px; }
.timer-cell { background: transparent; box-shadow: none; border-radius: 0; }
.timer-cell img { width: 50%; height: auto; display: block; margin: 0 auto; }

/* Category chips + FAQ */
.chip-list { display: flex; flex-wrap: wrap; gap: 10px; }
.chip {
  display: inline-block; background: var(--cream); border: 1px solid var(--line);
  color: var(--navy); font-weight: 600; font-size: 0.9rem;
  padding: 8px 14px; border-radius: 999px;
}
.faq-item { border-bottom: 1px solid var(--line); padding: 20px 0; }
.faq-item:first-of-type { border-top: 1px solid var(--line); }
.faq-item h3 { font-size: 1.1rem; margin-bottom: 8px; }
.faq-item p { color: var(--muted); }

/* ---- Two starter versions ---- */
.starter-grid { display: grid; gap: 20px; }
.starter-card {
  background: var(--white); border: 2px solid var(--line); border-radius: var(--radius);
  padding: 26px; display: flex; flex-direction: column; gap: 10px; box-shadow: var(--shadow);
}
.starter-card .tag {
  align-self: flex-start; font-size: 0.75rem; font-weight: 700; letter-spacing: 0.04em;
  text-transform: uppercase; background: var(--cream); color: var(--orange);
  padding: 4px 10px; border-radius: 999px;
}
.starter-card h3 { font-size: 1.3rem; }
.starter-card ul { list-style: none; color: var(--muted); margin: 4px 0 14px; }
.starter-card ul li { padding: 4px 0; }
.starter-card ul li::before { content: "•"; color: var(--gold); font-weight: 800; margin-right: 8px; }

/* ---- Purchase placeholder ---- */
.purchase-box {
  background: var(--navy); color: #fff; border-radius: var(--radius);
  padding: 32px 26px; box-shadow: var(--shadow-lg);
}
.purchase-box h2 { color: #fff; margin-bottom: 10px; }
.purchase-box p { color: rgba(255,255,255,0.78); }
.purchase-box ul { list-style: none; margin: 18px 0 22px; display: grid; gap: 10px; }
.purchase-box ul li { display: flex; gap: 10px; align-items: flex-start; color: rgba(255,255,255,0.9); }
.purchase-box ul li::before { content: "✓"; color: var(--gold); font-weight: 800; }
.purchase-box .btn { background: var(--gold); color: var(--navy); box-shadow: none; }
.purchase-box .btn:hover { background: #fff; }
.purchase-box .note { font-size: 0.85rem; color: rgba(255,255,255,0.6); margin-top: 14px; }
.purchase-box .note a { color: var(--gold); }

/* ---- Safety cards ---- */
.safety-grid { display: grid; gap: 14px; }
.safety-item {
  display: flex; gap: 12px; align-items: flex-start;
  background: var(--white); border: 1px solid var(--line);
  border-radius: var(--radius-sm); padding: 16px;
}
.safety-item .icon {
  flex: 0 0 auto; width: 26px; height: 26px; border-radius: 50%;
  background: var(--cream); color: var(--green); font-weight: 800;
  display: flex; align-items: center; justify-content: center; font-size: 0.9rem;
}
.safety-item p { color: var(--muted); font-size: 0.95rem; }

/* ---- Demo page ---- */
.demo-hero { background: var(--cream); padding: 48px 0; }
.demo-hero h1 { margin-bottom: 12px; }
.demo-hero .lead { color: var(--muted); max-width: 30em; }
.demo-hero .lead + p { color: var(--muted); max-width: 46em; margin-top: 10px; }

/* ---- Forms ---- */
.form { display: grid; gap: 16px; max-width: 560px; }
.form label { font-weight: 700; font-size: 0.92rem; }
.form input, .form textarea, .form select {
  width: 100%; font-family: var(--font); font-size: 1rem; color: var(--navy);
  padding: 12px 14px; border: 1.5px solid var(--line); border-radius: var(--radius-sm);
  background: var(--white);
}
.form input:focus, .form textarea:focus, .form select:focus {
  outline: none; border-color: var(--orange); box-shadow: 0 0 0 3px rgba(244,106,53,0.12);
}
.form textarea { min-height: 120px; resize: vertical; }

/* ---- Policy pages ---- */
.prose { max-width: 760px; }
.prose h2 { font-size: 1.3rem; margin: 28px 0 10px; }
.prose p { color: var(--muted); margin-bottom: 14px; }
.prose ul { color: var(--muted); margin: 0 0 14px 20px; }
.prose a { font-weight: 600; }

/* ---- Footer ---- */
.site-footer { background: var(--navy); color: rgba(255,255,255,0.72); padding: 48px 0 32px; }
.footer-inner { display: grid; gap: 28px; }
.footer-brand { display: flex; align-items: center; gap: 10px; color: #fff; }
.footer-brand .brand-logo { width: 36px; height: 36px; }
.footer-brand span { font-weight: 800; font-size: 1.05rem; }
.footer-links { display: grid; grid-template-columns: 1fr 1fr; gap: 10px 20px; }
.footer-links a { color: rgba(255,255,255,0.72); font-size: 0.9rem; }
.footer-links a:hover { color: var(--gold); }
.footer-contact { font-size: 0.9rem; }
.footer-contact a { color: var(--gold); }
.footer-bottom {
  margin-top: 28px; padding-top: 20px; border-top: 1px solid rgba(255,255,255,0.12);
  font-size: 0.82rem; color: rgba(255,255,255,0.5);
}

/* ---- Language switch active state ---- */
[hidden] { display: none !important; }

/* ==========================================================================
   Desktop (>= 768px)
   ========================================================================== */
@media (min-width: 768px) {
  h1 { font-size: 2.6rem; }
  h2 { font-size: 2rem; }
  .section { padding: 76px 0; }
  .container { padding: 0 32px; }

  .nav-toggle { display: none; }
  .site-nav { display: flex !important; flex-direction: row; align-items: center; gap: 4px; margin-left: 24px; }
  .site-nav a { border-bottom: none; padding: 8px 12px; border-radius: 999px; }
  .site-nav a:hover, .site-nav a.active { background: var(--cream); }
  .lang-toggle { margin-left: auto; }

  .hero { padding: 64px 0 80px; }
  .hero-inner { grid-template-columns: 1.05fr 1fr; gap: 48px; }

  .grid--2 { grid-template-columns: 1fr 1fr; }
  .grid--3 { grid-template-columns: repeat(3, 1fr); }
  .grid--4 { grid-template-columns: repeat(4, 1fr); }

  .feature { grid-template-columns: 1fr 1fr; gap: 40px; padding: 36px 0; }
  .feature--reverse .feature-img { order: 2; }

  .starter-grid { grid-template-columns: 1fr 1fr; }

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

  .footer-inner { grid-template-columns: 1.2fr 1fr 1fr; align-items: start; }
}

@media (min-width: 1024px) {
  .grid--3 { gap: 24px; }
  .grid--4 { gap: 22px; }
  .safety-grid { grid-template-columns: repeat(3, 1fr); }
}
