/* style.css */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --bg: #1a1a2e;
  --surface: #16213e;
  --text: #e0e0e0;
  --text-dim: #8888aa;
  --accent: #e74c3c;
  --btn: #0f3460;
  --btn-hover: #1a4a8a;
}

html { height: 100%; }

body {
  font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
}

main {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.5rem;
  padding: 2rem;
  max-width: 400px;
  width: 100%;
}

h1 {
  font-size: 1.6rem;
  font-weight: 600;
  letter-spacing: -0.02em;
  color: var(--text);
}

/* ── Tomato SVG ──────────────────────────────── */
.tomato-wrap {
  position: relative;
  width: min(70vw, 260px);
}

.tomato {
  width: 100%;
  height: auto;
  filter: drop-shadow(0 8px 24px rgba(231, 76, 60, 0.25));
}

.tomato-skin {
  stroke: var(--accent);
  stroke-width: 3;
  fill: none;
}

.leaf, .stem { opacity: 0.9; }

.timer-text {
  font-family: 'SF Mono', 'Cascadia Code', 'Consolas', monospace;
  font-size: 32px;
  font-weight: 700;
  fill: #fff;
  dominant-baseline: central;
}

/* ── Overlay ─────────────────────────────────── */
.overlay {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(26, 26, 46, 0.85);
  border-radius: 50%;
  cursor: pointer;
  z-index: 2;
  transition: opacity 0.3s;
}

.overlay[hidden] { opacity: 0; pointer-events: none; }

.overlay span {
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--text);
  text-align: center;
  padding: 1rem;
}

/* ── Controls ────────────────────────────────── */
.controls {
  display: flex;
  gap: 0.75rem;
}

.btn {
  font-family: inherit;
  font-size: 1rem;
  font-weight: 600;
  padding: 0.7rem 2rem;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  transition: background 0.2s, transform 0.1s;
}

.btn:active { transform: scale(0.97); }

.btn.primary {
  background: var(--accent);
  color: #fff;
}

.btn.primary:hover { background: #c0392b; }

.btn:not(.primary) {
  background: var(--btn);
  color: var(--text);
}

.btn:not(.primary):hover { background: var(--btn-hover); }

/* ── Status ──────────────────────────────────── */
.status {
  font-size: 0.85rem;
  color: var(--text-dim);
  min-height: 1.2em;
}

/* ── Responsive tweaks ───────────────────────── */
@media (max-width: 380px) {
  h1 { font-size: 1.3rem; }
  .btn { padding: 0.6rem 1.4rem; font-size: 0.9rem; }
  .timer-text { font-size: 26px; }
}
