:root {
  color-scheme: light;
  --bg: #f5efe6;
  --bg-deep: #e6dacc;
  --ink: #1c1915;
  --muted: #6a5f54;
  --accent: #ff6b4a;
  --accent-dark: #d8573e;
  --accent-2: #35b3a4;
  --accent-3: #f2c070;
  --panel: rgba(255, 255, 255, 0.82);
  --panel-strong: rgba(255, 255, 255, 0.92);
  --stroke: rgba(28, 25, 21, 0.12);
  --shadow: 0 30px 60px rgba(24, 18, 12, 0.18);
  --radius-lg: 34px;
  --radius-md: 20px;
  --radius-sm: 14px;
  --grain: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" width="120" height="120" viewBox="0 0 120 120"><filter id="n"><feTurbulence type="fractalNoise" baseFrequency="0.75" numOctaves="2" stitchTiles="stitch"/></filter><rect width="120" height="120" filter="url(%23n)" opacity="0.08"/></svg>');
}

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

body {
  font-family: "Sora", system-ui, sans-serif;
  background: radial-gradient(circle at 15% 15%, #fff8f1 0%, var(--bg) 45%, var(--bg-deep) 100%);
  color: var(--ink);
  min-height: 100vh;
  -webkit-text-size-adjust: 100%;
}

.ambient {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  background-image: var(--grain);
  mix-blend-mode: multiply;
}

.ambient::before,
.ambient::after {
  content: "";
  position: absolute;
  border-radius: 999px;
  filter: blur(0px);
  opacity: 0.6;
  animation: float 18s ease-in-out infinite;
}

.ambient::before {
  width: 520px;
  height: 520px;
  left: -120px;
  top: -160px;
  background: radial-gradient(circle, rgba(255, 196, 150, 0.7), rgba(255, 196, 150, 0));
}

.ambient::after {
  width: 620px;
  height: 620px;
  right: -160px;
  bottom: -200px;
  background: radial-gradient(circle, rgba(73, 196, 178, 0.6), rgba(73, 196, 178, 0));
  animation-delay: 2s;
}

.page {
  position: relative;
  z-index: 1;
  max-width: 1200px;
  margin: 0 auto;
  padding: 60px clamp(20px, 4vw, 64px) 90px;
}

.masthead {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 40px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 14px;
}

.brand-mark {
  width: 46px;
  height: 46px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  font-family: "Syne", "Times New Roman", serif;
  font-weight: 700;
  background: var(--ink);
  color: #fff8f1;
  letter-spacing: 1px;
}

.brand-title {
  font-family: "Syne", "Times New Roman", serif;
  font-size: 1.2rem;
  font-weight: 700;
}

.brand-subtitle {
  font-size: 0.8rem;
  color: var(--muted);
  margin-top: 2px;
}

.meta {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.chip {
  padding: 6px 14px;
  border-radius: 999px;
  border: 1px solid var(--stroke);
  background: var(--panel);
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: var(--muted);
}

.hero {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 34px;
  align-items: start;
}

.status-strip {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 14px;
  margin-bottom: 30px;
}

.status-card {
  padding: 12px 14px;
  border-radius: var(--radius-sm);
  background: var(--panel-strong);
  border: 1px solid var(--stroke);
  box-shadow: 0 12px 24px rgba(24, 18, 12, 0.08);
  display: grid;
  gap: 4px;
}

.hero-copy {
  animation: rise 0.7s ease-out;
}

.eyebrow {
  text-transform: uppercase;
  letter-spacing: 4px;
  font-size: 0.7rem;
  color: var(--muted);
  margin-bottom: 14px;
}

.hero-copy h1 {
  font-family: "Syne", "Times New Roman", serif;
  font-size: clamp(2.4rem, 4vw, 4.2rem);
  line-height: 1.05;
  margin-bottom: 18px;
}

.lead {
  font-size: 1.05rem;
  line-height: 1.7;
  color: var(--muted);
  max-width: 40ch;
  margin-bottom: 26px;
}

.actions {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 12px;
  margin-bottom: 22px;
}

.hint {
  font-size: 0.85rem;
  color: var(--muted);
  margin-bottom: 18px;
}

.btn {
  border: none;
  padding: 12px 20px;
  border-radius: 999px;
  font-weight: 600;
  font-size: 0.95rem;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
  touch-action: manipulation;
}

.btn-small {
  padding: 8px 14px;
  font-size: 0.8rem;
}

.btn-primary {
  background: var(--accent);
  color: #fff8f1;
  box-shadow: 0 20px 40px rgba(216, 87, 62, 0.35);
}

.btn-secondary {
  background: var(--accent-2);
  color: #f5fffb;
  box-shadow: 0 20px 40px rgba(53, 179, 164, 0.35);
}

.btn-dark {
  background: var(--ink);
  color: #fff8f1;
}

.btn-ghost {
  background: transparent;
  border: 1px solid var(--stroke);
  color: var(--ink);
}

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

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

.presets {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 16px;
}

.preset {
  border: 1px solid var(--stroke);
  background: var(--panel);
  padding: 8px 16px;
  border-radius: 999px;
  font-size: 0.8rem;
  letter-spacing: 1px;
  text-transform: uppercase;
  cursor: pointer;
  transition: border 0.2s ease, transform 0.2s ease;
}

.preset:hover {
  transform: translateY(-1px);
  border-color: var(--accent);
}

.preset.is-active {
  border-color: var(--accent);
  box-shadow: inset 0 0 0 1px rgba(216, 87, 62, 0.2);
}

.gif-status {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 18px;
}

.gif-status .value {
  font-size: 0.95rem;
}

.themes {
  display: grid;
  gap: 10px;
  margin-bottom: 22px;
}

.themes-label {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: var(--muted);
}

.theme-list {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.theme {
  border: 1px solid var(--stroke);
  background: var(--panel);
  padding: 8px 14px;
  border-radius: 999px;
  font-size: 0.75rem;
  letter-spacing: 1px;
  text-transform: uppercase;
  cursor: pointer;
  transition: border 0.2s ease, transform 0.2s ease;
}

.theme.is-active,
.theme:hover {
  transform: translateY(-1px);
  border-color: var(--accent);
}

.insight {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
  gap: 16px;
  padding: 16px;
  border-radius: var(--radius-md);
  background: var(--panel-strong);
  border: 1px solid var(--stroke);
}

.shortcuts {
  margin-top: 18px;
  padding: 12px 14px;
  border-radius: var(--radius-md);
  background: var(--panel);
  border: 1px solid var(--stroke);
}

.shortcuts summary {
  cursor: pointer;
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: var(--muted);
  list-style: none;
}

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

.shortcut-grid {
  margin-top: 10px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 6px 12px;
  font-size: 0.85rem;
  color: var(--muted);
}

.label {
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: var(--muted);
  display: block;
  margin-bottom: 6px;
}

.value {
  font-size: 1.1rem;
  font-weight: 600;
}

.hero-visual {
  display: grid;
  gap: 20px;
}

.stage {
  position: relative;
  padding: 18px;
  border-radius: var(--radius-lg);
  background: linear-gradient(145deg, rgba(255, 255, 255, 0.9), rgba(235, 225, 210, 0.9));
  box-shadow: var(--shadow);
  border: 1px solid rgba(255, 255, 255, 0.6);
}

.stage:fullscreen {
  padding: 24px;
  border-radius: 0;
  background: radial-gradient(circle at 30% 20%, #fff7ed 0%, #efe3d6 70%);
  display: grid;
  place-items: center;
}

.stage:fullscreen #garden {
  width: min(92vw, 92vh);
  height: auto;
}

#garden {
  width: 100%;
  height: auto;
  border-radius: 24px;
  background: #fffdf9;
  display: block;
  box-shadow: inset 0 0 0 1px rgba(30, 22, 16, 0.08);
}

.control-panel {
  background: var(--panel);
  border-radius: var(--radius-md);
  padding: 18px;
  border: 1px solid var(--stroke);
  display: grid;
  gap: 16px;
}

details.lab {
  border: 1px solid var(--stroke);
  border-radius: var(--radius-md);
  background: rgba(255, 255, 255, 0.7);
  padding: 12px 14px;
}

details.lab summary {
  cursor: pointer;
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: var(--muted);
  list-style: none;
}

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

.lab-grid {
  margin-top: 12px;
  display: grid;
  gap: 16px;
}

textarea {
  width: 100%;
  resize: vertical;
  padding: 10px 12px;
  border-radius: 12px;
  border: 1px solid var(--stroke);
  background: #fffdf9;
  color: var(--ink);
  font-family: inherit;
  font-size: 0.85rem;
}

.control-group label {
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: var(--muted);
}

.control-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 8px;
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: var(--muted);
}

.readout {
  font-size: 0.9rem;
  color: var(--ink);
  font-weight: 600;
}

input[type="range"] {
  width: 100%;
  accent-color: var(--accent);
  cursor: pointer;
}

select {
  width: 100%;
  padding: 10px 12px;
  border-radius: 12px;
  border: 1px solid var(--stroke);
  background: #fffdf9;
  color: var(--ink);
  font-family: inherit;
  font-size: 0.9rem;
}

.audio-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 10px;
}

.audio-meter {
  height: 8px;
  background: rgba(28, 25, 21, 0.1);
  border-radius: 999px;
  overflow: hidden;
  margin-top: 8px;
}

.audio-meter-fill {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, var(--accent), var(--accent-2));
  transition: width 0.1s ease;
}

.control-group.gif label {
  margin-top: 6px;
}

.control-group.gif input[type="range"] {
  margin-bottom: 6px;
}

.performance-toggle {
  margin-top: 12px;
}

.toggle-row {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.toggle {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.85rem;
  color: var(--muted);
}

.toggle input {
  accent-color: var(--accent);
}

.details {
  margin-top: 50px;
  display: grid;
  gap: 20px;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
}

.card {
  padding: 22px;
  border-radius: var(--radius-md);
  background: var(--panel-strong);
  border: 1px solid var(--stroke);
  box-shadow: 0 18px 40px rgba(24, 18, 12, 0.12);
  animation: rise 0.7s ease-out;
}

.card h2 {
  font-family: "Syne", "Times New Roman", serif;
  font-size: 1.2rem;
  margin-bottom: 10px;
}

.card p {
  color: var(--muted);
  line-height: 1.6;
}

.gallery {
  margin-top: 50px;
}

.gallery-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 18px;
}

.gallery-header h3 {
  font-family: "Syne", "Times New Roman", serif;
  font-size: 1.5rem;
  margin-bottom: 4px;
}

.gallery-header p {
  color: var(--muted);
}

.shots {
  display: grid;
  gap: 16px;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
}

.shot {
  background: #f8f2ea;
  border-radius: var(--radius-sm);
  padding: 12px;
  border: 1px solid var(--stroke);
  min-height: 160px;
  display: grid;
  gap: 8px;
}

.shot img {
  width: 100%;
  border-radius: 12px;
  display: block;
  opacity: 0;
  transition: opacity 0.2s ease;
}

.shot figcaption {
  font-size: 0.75rem;
  color: var(--muted);
  letter-spacing: 1px;
  text-transform: uppercase;
}

.shot.is-empty {
  background: #efe7dd;
  color: var(--muted);
}

.shot.is-empty img {
  opacity: 0;
}

.shot.is-filled img {
  opacity: 1;
}

.footer {
  margin-top: 60px;
  font-size: 0.85rem;
  color: var(--muted);
}

@keyframes float {
  0%,
  100% {
    transform: translate(0, 0) scale(1);
  }
  50% {
    transform: translate(20px, -30px) scale(1.05);
  }
}

@keyframes rise {
  from {
    opacity: 0;
    transform: translateY(14px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (max-width: 860px) {
  .masthead {
    flex-direction: column;
    align-items: flex-start;
  }

  .actions {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    align-items: stretch;
  }

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

  .hero-visual {
    order: -1;
  }
}

@media (max-width: 620px) {
  .ambient::before,
  .ambient::after {
    opacity: 0.35;
    animation-duration: 28s;
  }

  .page {
    padding: 40px 20px 70px;
  }

  .gif-status {
    flex-direction: column;
    align-items: flex-start;
  }

  .hero-copy h1 {
    font-size: clamp(2rem, 8vw, 3rem);
  }

  .lead {
    font-size: 0.98rem;
  }

  .stage {
    padding: 12px;
  }

  .control-panel {
    padding: 14px;
    gap: 12px;
  }

  .presets,
  .theme-list {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

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

  .btn,
  select,
  input[type="range"] {
    min-height: 44px;
  }

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

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

  .gallery-header {
    flex-direction: column;
    align-items: flex-start;
  }
}

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

  .status-strip {
    grid-template-columns: 1fr;
  }

  .details {
    margin-top: 36px;
  }

  .gallery {
    margin-top: 36px;
  }
}

@media (max-width: 420px) {
  .brand-mark {
    width: 40px;
    height: 40px;
  }

  .chip {
    font-size: 0.65rem;
  }

  .audio-actions {
    grid-template-columns: 1fr;
  }

  .toggle-row {
    flex-direction: column;
    align-items: flex-start;
  }
}

@media (prefers-reduced-motion: reduce) {
  * {
    animation: none !important;
    transition: none !important;
  }
}
