:root {
  --bg: #0d1014;
  --panel: rgba(22, 27, 34, 0.72);
  --panel-solid: #161b22;
  --border: rgba(255, 255, 255, 0.08);
  --text: #e8edf2;
  --muted: #93a1b0;
  --faint: #5d6b7a;
  --accent: #3ddc91;
  --accent-2: #ffb648;
  --danger: #ff6b6b;
  --radius: 18px;
  --shadow: 0 24px 60px rgba(0, 0, 0, 0.45);
  font-synthesis: none;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html, body { height: 100%; }

body {
  font-family: "Inter", "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;
  padding: 32px 20px;
  position: relative;
  overflow-x: hidden;
}

.bg-orbs {
  position: fixed;
  inset: 0;
  z-index: 0;
  background:
    radial-gradient(40rem 40rem at 12% -10%, rgba(61, 220, 145, 0.16), transparent 60%),
    radial-gradient(36rem 36rem at 100% 110%, rgba(255, 182, 72, 0.14), transparent 60%);
  pointer-events: none;
}

.shell {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 980px;
}

.masthead {
  display: flex;
  align-items: baseline;
  gap: 18px;
  flex-wrap: wrap;
  margin-bottom: 22px;
  padding-left: 4px;
}

.brand { display: flex; align-items: center; gap: 10px; }
.brand-mark { font-size: 26px; }
.brand-name { font-size: 22px; font-weight: 800; letter-spacing: -0.02em; }
.tagline { color: var(--muted); font-size: 15px; }

.grid {
  display: grid;
  grid-template-columns: 1fr 1.05fr;
  gap: 20px;
}

@media (max-width: 760px) {
  .grid { grid-template-columns: 1fr; }
}

.card {
  background: var(--panel);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 26px;
  box-shadow: var(--shadow);
}

.card-title {
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--faint);
  margin-bottom: 18px;
  font-weight: 700;
}

.field { margin-bottom: 16px; }
.field label {
  display: block;
  font-size: 13px;
  color: var(--muted);
  margin-bottom: 6px;
  font-weight: 600;
}

select, input {
  width: 100%;
  background: #0f1419;
  border: 1px solid var(--border);
  border-radius: 10px;
  color: var(--text);
  padding: 11px 12px;
  font-size: 15px;
  font-family: inherit;
  transition: border-color 0.15s, box-shadow 0.15s;
}
select:focus, input:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(61, 220, 145, 0.16);
}

.hint { font-size: 12px; color: var(--faint); margin-top: 6px; }

.attendees { display: flex; flex-direction: column; gap: 12px; margin-bottom: 14px; }

.attendee-row {
  display: grid;
  grid-template-columns: 1fr 84px 96px 34px;
  gap: 8px;
  align-items: center;
}
.attendee-row input { padding: 9px 10px; font-size: 14px; }
.attendee-row .col-label { font-size: 11px; color: var(--faint); }

.remove-btn {
  width: 34px; height: 34px;
  border-radius: 9px;
  border: 1px solid var(--border);
  background: transparent;
  color: var(--faint);
  cursor: pointer;
  font-size: 18px;
  line-height: 1;
  transition: all 0.15s;
}
.remove-btn:hover { color: var(--danger); border-color: rgba(255, 107, 107, 0.4); }

.btn-ghost {
  background: transparent;
  border: 1px dashed var(--border);
  color: var(--muted);
  padding: 10px 14px;
  border-radius: 10px;
  cursor: pointer;
  font-size: 14px;
  font-weight: 600;
  font-family: inherit;
  transition: all 0.15s;
  width: 100%;
}
.btn-ghost:hover { border-color: var(--accent); color: var(--accent); }

.summary-line {
  display: flex;
  justify-content: space-between;
  margin-top: 18px;
  padding-top: 16px;
  border-top: 1px solid var(--border);
  font-size: 14px;
  color: var(--muted);
}
.summary-line span:last-child { color: var(--accent); font-weight: 700; }

/* Ticker */
.ticker { display: flex; flex-direction: column; }
.ticker-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 6px;
}
.ticker-label {
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--faint);
  font-weight: 700;
}
.elapsed {
  font-variant-numeric: tabular-nums;
  color: var(--muted);
  font-size: 15px;
  font-weight: 600;
}

.cost-display {
  font-size: clamp(46px, 9vw, 76px);
  font-weight: 800;
  letter-spacing: -0.03em;
  font-variant-numeric: tabular-nums;
  background: linear-gradient(120deg, var(--accent), var(--accent-2));
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  margin: 14px 0 22px;
  line-height: 1;
}
.cost-display.running { animation: pulse 1s ease-in-out infinite; }
@keyframes pulse { 50% { opacity: 0.82; } }

.ticker-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  margin-bottom: 22px;
}
.stat {
  background: #0f1419;
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 12px 10px;
  text-align: center;
}
.stat-value {
  display: block;
  font-size: 18px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}
.stat-label { font-size: 11px; color: var(--faint); text-transform: uppercase; letter-spacing: 0.06em; }

.controls { display: flex; gap: 10px; margin-top: auto; }
.btn-primary {
  flex: 1;
  background: linear-gradient(120deg, var(--accent), #2bb877);
  color: #04130b;
  border: none;
  padding: 14px;
  border-radius: 12px;
  font-size: 16px;
  font-weight: 800;
  cursor: pointer;
  font-family: inherit;
  transition: transform 0.1s, filter 0.15s;
}
.btn-primary:hover { filter: brightness(1.06); }
.btn-primary:active { transform: translateY(1px); }
.btn-primary.running { background: linear-gradient(120deg, var(--danger), #d8463f); color: #fff; }
.controls .btn-ghost { width: auto; padding: 14px 20px; }

.verdict {
  margin-top: 16px;
  font-size: 14px;
  color: var(--accent-2);
  min-height: 20px;
  text-align: center;
  font-weight: 600;
}

.foot {
  text-align: center;
  margin-top: 26px;
  color: var(--faint);
  font-size: 13px;
}
