:root {
  --mint: #78d8b2;
  --leaf: #32a876;
  --lime: #d9f99d;
  --sun: #ffd166;
  --coral: #ff7c7c;
  --sky: #8bd3ff;
  --ink: #234047;
  --soft: #fff8e7;
  --white: #ffffff;
  --line: rgba(35, 64, 71, 0.12);
  --shadow: 0 22px 60px rgba(35, 64, 71, 0.16);
}

* {
  box-sizing: border-box;
}

body {
  min-height: 100vh;
  margin: 0;
  color: var(--ink);
  font-family: "Nunito", system-ui, sans-serif;
  background:
    radial-gradient(circle at 12% 15%, rgba(255, 209, 102, 0.55) 0 120px, transparent 121px),
    radial-gradient(circle at 88% 22%, rgba(139, 211, 255, 0.55) 0 140px, transparent 141px),
    linear-gradient(135deg, #fff8e7 0%, #e7fbf3 50%, #fff1f1 100%);
}

a {
  color: inherit;
  text-decoration: none;
}

button,
input {
  font: inherit;
}

button {
  cursor: pointer;
}

.app-shell {
  display: grid;
  min-height: 100vh;
  place-items: center;
  padding: 24px;
}

.welcome-card,
.chat-stage {
  width: min(100%, 980px);
  border: 3px solid var(--line);
  border-radius: 28px;
  background: rgba(255, 255, 255, 0.82);
  box-shadow: var(--shadow);
  backdrop-filter: blur(18px);
}

.welcome-card {
  position: relative;
  max-width: 480px;
  padding: clamp(28px, 5vw, 44px);
}

.page-link {
  position: absolute;
  top: 18px;
  right: 18px;
  border-radius: 999px;
  padding: 8px 12px;
  color: var(--leaf);
  font-size: 14px;
  font-weight: 800;
  background: #eefaf5;
}

.brand-mark {
  display: grid;
  width: 68px;
  height: 68px;
  margin-bottom: 14px;
  place-items: center;
  border-radius: 22px;
  color: #fff;
  font-family: "Baloo 2", cursive;
  font-size: 30px;
  font-weight: 700;
  background: linear-gradient(135deg, var(--leaf), var(--sky));
  transform: rotate(-4deg);
}

h1,
p {
  margin: 0;
}

.welcome-card h1,
.top-bar h1 {
  font-family: "Baloo 2", "Nunito", sans-serif;
  line-height: 1;
}

.welcome-card h1 {
  font-size: clamp(48px, 12vw, 72px);
}

.welcome-card p {
  margin-top: 10px;
  color: rgba(35, 64, 71, 0.72);
  font-size: 18px;
}

.kid-form {
  display: grid;
  gap: 12px;
  margin-top: 30px;
}

label {
  font-weight: 700;
}

input {
  width: 100%;
  min-height: 54px;
  border: 2px solid transparent;
  border-radius: 16px;
  outline: none;
  padding: 0 16px;
  color: var(--ink);
  background: #f5fff9;
}

input:focus {
  border-color: var(--leaf);
  background: var(--white);
}

.primary-button,
.quiet-button {
  border: 0;
  border-radius: 16px;
  font-weight: 700;
}

.primary-button {
  min-height: 58px;
  margin-top: 12px;
  color: #fff;
  background: var(--coral);
  box-shadow: 0 12px 24px rgba(255, 124, 124, 0.28);
}

.chat-stage {
  display: grid;
  min-height: min(760px, calc(100vh - 48px));
  grid-template-rows: auto minmax(0, 1fr) 166px;
  overflow: hidden;
}

.hidden {
  display: none;
}

.top-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 24px clamp(22px, 5vw, 44px) 12px;
}

.eyebrow {
  color: var(--leaf);
  font-family: "Baloo 2", cursive;
  font-size: 18px;
  font-weight: 700;
}

.top-bar h1 {
  margin-top: 4px;
  font-size: clamp(30px, 6vw, 50px);
}

.quiet-button {
  min-height: 42px;
  padding: 0 16px;
  color: var(--ink);
  background: #eefaf5;
}

.top-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 10px;
}

.link-button {
  display: inline-grid;
  min-height: 42px;
  place-items: center;
}

.product-shell {
  width: min(100%, 980px);
  margin: 0 auto;
  padding: 24px;
}

.product-nav {
  display: flex;
  justify-content: flex-end;
  margin-bottom: 18px;
}

.product-hero,
.telegram-card {
  border: 3px solid var(--line);
  border-radius: 28px;
  background: rgba(255, 255, 255, 0.84);
  box-shadow: var(--shadow);
  backdrop-filter: blur(18px);
}

.product-hero {
  padding: clamp(30px, 6vw, 58px);
}

.product-hero h1 {
  max-width: 760px;
  margin: 8px 0 16px;
  font-family: "Baloo 2", "Nunito", sans-serif;
  font-size: clamp(42px, 8vw, 72px);
  line-height: 0.95;
}

.product-hero p,
.telegram-card p,
.product-points p {
  color: rgba(35, 64, 71, 0.74);
  font-size: 18px;
  font-weight: 700;
  line-height: 1.45;
}

.product-hero p {
  max-width: 680px;
  margin-bottom: 24px;
}

.telegram-button {
  display: inline-grid;
  min-height: 58px;
  place-items: center;
  border-radius: 18px;
  padding: 0 24px;
  color: #fff;
  font-size: 18px;
  font-weight: 900;
  background: linear-gradient(135deg, var(--leaf), #20c997);
  box-shadow: 0 14px 26px rgba(50, 168, 118, 0.26);
}

.telegram-button.secondary {
  background: linear-gradient(135deg, var(--coral), #ff9f66);
  box-shadow: 0 14px 26px rgba(255, 124, 124, 0.26);
}

.product-points {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
  margin: 18px 0;
}

.product-points article {
  border: 3px solid rgba(35, 64, 71, 0.08);
  border-radius: 22px;
  padding: 22px;
  background: rgba(255, 255, 255, 0.76);
}

.product-points h2,
.telegram-card h2,
.seo-section h2,
.faq-section h2 {
  margin: 0 0 8px;
  font-family: "Baloo 2", "Nunito", sans-serif;
  font-size: 28px;
  line-height: 1;
}

.seo-section,
.faq-section {
  margin: 18px 0;
  padding: clamp(24px, 5vw, 38px);
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.62);
}

.seo-section {
  display: grid;
  grid-template-columns: minmax(0, 0.92fr) minmax(0, 1.08fr);
  gap: 22px;
  align-items: start;
}

.seo-section h2 {
  max-width: 360px;
  font-size: clamp(30px, 5vw, 44px);
  line-height: 0.98;
}

.seo-copy {
  display: grid;
  gap: 14px;
}

.seo-copy p,
.faq-section p {
  color: rgba(35, 64, 71, 0.74);
  font-size: 17px;
  font-weight: 700;
  line-height: 1.48;
}

.faq-section {
  display: grid;
  gap: 14px;
}

.faq-section article {
  border: 2px solid rgba(35, 64, 71, 0.08);
  border-radius: 18px;
  padding: 18px;
  background: rgba(255, 255, 255, 0.66);
}

.faq-section h3 {
  margin: 0 0 8px;
  color: var(--ink);
  font-size: 20px;
  line-height: 1.2;
}

.telegram-card {
  padding: clamp(24px, 5vw, 38px);
}

.telegram-card p {
  max-width: 760px;
  margin-bottom: 18px;
}

.conversation {
  position: relative;
  display: grid;
  grid-template-rows: 104px 360px 44px;
  align-content: center;
  justify-items: center;
  padding: 0 clamp(18px, 5vw, 44px);
}

.speech-bubble {
  width: min(100%, 520px);
  height: 88px;
  border: 3px solid rgba(50, 168, 118, 0.18);
  border-radius: 24px;
  padding: 14px 22px;
  overflow: hidden;
  text-align: center;
  font-size: clamp(18px, 3vw, 24px);
  font-weight: 700;
  line-height: 1.25;
  background: var(--white);
  box-shadow: 0 14px 35px rgba(35, 64, 71, 0.1);
}

.dino-wrap {
  position: relative;
  display: grid;
  width: min(76vw, 360px);
  height: 340px;
  place-items: center;
}

.dino {
  width: 100%;
  filter: drop-shadow(0 18px 22px rgba(35, 64, 71, 0.16));
  transform-origin: 50% 70%;
}

.body,
.head,
.neck,
.tail,
.foot {
  fill: var(--mint);
}

.belly,
.muzzle {
  fill: var(--lime);
}

.cheek {
  fill: #ffaaa5;
  opacity: 0.9;
}

.eye-white {
  fill: var(--white);
}

.eye,
.nostril {
  fill: var(--ink);
}

.eye-shine {
  fill: var(--white);
}

.mouth,
.arm,
.brow {
  fill: none;
  stroke: var(--ink);
  stroke-width: 8;
  stroke-linecap: round;
}

.dino.speaking .mouth {
  animation: mouthTalk 0.24s ease-in-out infinite alternate;
  transform-box: fill-box;
  transform-origin: center;
}

.brow {
  stroke-width: 5;
}

.spike {
  fill: var(--sun);
  stroke: #f4bc4d;
  stroke-linejoin: round;
  stroke-width: 3;
}

.spot {
  fill: rgba(255, 255, 255, 0.36);
}

.shadow {
  position: absolute;
  bottom: 6px;
  z-index: -1;
  width: 62%;
  height: 24px;
  border-radius: 999px;
  background: rgba(35, 64, 71, 0.12);
}

.status-pill {
  align-self: center;
  min-height: 34px;
  border-radius: 999px;
  padding: 7px 16px;
  color: rgba(35, 64, 71, 0.72);
  font-weight: 700;
  background: rgba(255, 255, 255, 0.75);
}

.controls {
  display: grid;
  justify-items: center;
  align-items: start;
  padding: 8px clamp(22px, 5vw, 44px) 20px;
  user-select: none;
  -webkit-user-select: none;
}

.talk-button {
  position: relative;
  display: grid;
  align-items: center;
  justify-content: center;
  width: 96px;
  height: 96px;
  margin: 0 auto;
  border: 7px solid rgba(255, 255, 255, 0.92);
  border-radius: 999px;
  color: #fff;
  outline: 0;
  background: linear-gradient(135deg, var(--coral), #ff9f66);
  box-shadow:
    0 18px 34px rgba(255, 124, 124, 0.34),
    inset 0 -9px 0 rgba(137, 54, 54, 0.16);
  touch-action: none;
  -webkit-tap-highlight-color: transparent;
  transition:
    background 0.18s ease,
    box-shadow 0.18s ease,
    transform 0.18s ease,
    opacity 0.18s ease;
}

.talk-button::before {
  position: absolute;
  inset: -12px;
  z-index: -1;
  border-radius: inherit;
  background: rgba(255, 124, 124, 0.14);
  content: "";
}

.talk-button:hover:not(:disabled) {
  transform: translateY(-2px);
}

.talk-button:active:not(:disabled),
.talk-button.is-listening {
  transform: translateY(4px) scale(0.98);
  box-shadow:
    0 9px 18px rgba(50, 168, 118, 0.26),
    inset 0 7px 0 rgba(25, 98, 71, 0.18);
}

.talk-button.is-listening {
  background: linear-gradient(135deg, var(--leaf), #20c997);
}

.talk-button:disabled,
.talk-button.is-processing {
  cursor: not-allowed;
  opacity: 0.58;
  background: #b9c3c0;
  box-shadow:
    0 10px 20px rgba(35, 64, 71, 0.1),
    inset 0 -7px 0 rgba(35, 64, 71, 0.1);
  transform: none;
}

.mic-icon {
  position: relative;
  width: 30px;
  height: 42px;
  border: 5px solid currentColor;
  border-radius: 20px;
  background: var(--white);
  box-shadow: 0 0 0 9px rgba(255, 255, 255, 0.22);
}

.mic-icon::before {
  position: absolute;
  left: 50%;
  bottom: -20px;
  width: 5px;
  height: 16px;
  border-radius: 999px;
  background: currentColor;
  content: "";
  transform: translateX(-50%);
}

.mic-icon::after {
  position: absolute;
  left: 50%;
  bottom: -26px;
  width: 30px;
  height: 5px;
  border-radius: 999px;
  background: currentColor;
  content: "";
  transform: translateX(-50%);
}

.is-listening .mic-icon {
  animation: pulse 0.9s ease-in-out infinite;
}

.talk-label {
  min-height: 30px;
  margin-top: 10px;
  color: var(--ink);
  font-family: "Baloo 2", "Nunito", sans-serif;
  font-size: clamp(22px, 4vw, 30px);
  font-weight: 700;
  line-height: 1;
  text-align: center;
}

@keyframes pulse {
  0%,
  100% {
    box-shadow: 0 0 0 8px rgba(255, 255, 255, 0.24);
  }
  50% {
    box-shadow: 0 0 0 16px rgba(255, 255, 255, 0);
  }
}

@keyframes mouthTalk {
  from {
    transform: scaleY(0.72);
    stroke-width: 7;
  }
  to {
    transform: scaleY(1.55);
    stroke-width: 10;
  }
}

@media (max-width: 640px) {
  .app-shell {
    padding: 12px;
  }

  .welcome-card,
  .chat-stage {
    border-radius: 22px;
  }

  .chat-stage {
    min-height: calc(100vh - 24px);
    grid-template-rows: auto minmax(0, 1fr) 154px;
  }

  .top-bar {
    align-items: flex-start;
  }

  .top-actions {
    align-items: flex-end;
    flex-direction: column;
  }

  .quiet-button {
    min-width: 78px;
  }

  .product-shell {
    padding: 12px;
  }

  .product-points {
    grid-template-columns: 1fr;
  }

  .seo-section {
    grid-template-columns: 1fr;
  }

  .product-hero,
  .telegram-card {
    border-radius: 22px;
  }

  .conversation {
    grid-template-rows: 112px 310px 44px;
  }

  .speech-bubble {
    height: 96px;
  }

  .dino-wrap {
    width: min(72vw, 310px);
    height: 310px;
  }

  .talk-button {
    width: 88px;
    height: 88px;
  }

}
