:root {
  color-scheme: dark;
  --navy-950: #07131c;
  --navy-900: #102432;
  --navy-850: #142b39;
  --navy-800: #183442;
  --navy-700: #29495a;
  --green: #86cf82;
  --green-strong: #67b96a;
  --green-soft: #b6e9b1;
  --white: #f8fbfc;
  --muted: #a8b7c0;
  --line: rgba(178, 206, 218, 0.18);
  --line-green: rgba(134, 207, 130, 0.38);
  --danger: #ffb0b3;
  --radius: 20px;
}

* { box-sizing: border-box; }

html { background: var(--navy-950); }

body {
  margin: 0;
  min-width: 320px;
  min-height: 100vh;
  background:
    radial-gradient(circle at 92% 12%, rgba(134, 207, 130, 0.12), transparent 28rem),
    radial-gradient(circle at 4% 55%, rgba(41, 73, 90, 0.28), transparent 32rem),
    linear-gradient(180deg, #0b1c27 0%, var(--navy-950) 52%, #050f16 100%);
  color: var(--white);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  -webkit-font-smoothing: antialiased;
}

button, input, select { font: inherit; }
button { touch-action: manipulation; }

main { width: 100%; overflow: hidden; }

.hero {
  position: relative;
  width: 100%;
  height: clamp(210px, 25vw, 360px);
  border-bottom: 1px solid rgba(134, 207, 130, 0.34);
  background: var(--navy-900);
  box-shadow: 0 22px 60px rgba(0, 0, 0, 0.35);
}

.hero-banner {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}

.hero-shade {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(7, 19, 28, 0.18), transparent 28%, transparent 72%, rgba(7, 19, 28, 0.18)),
    linear-gradient(180deg, transparent 58%, rgba(7, 19, 28, 0.66) 100%);
}

.hero-inner {
  position: relative;
  width: min(920px, calc(100% - 28px));
  height: 100%;
  margin: 0 auto;
}

.brand-logo {
  position: absolute;
  z-index: 2;
  bottom: -52px;
  left: 0;
  width: clamp(100px, 9vw, 122px);
  height: auto;
  aspect-ratio: 1;
  border: 4px solid var(--white);
  border-radius: 24px;
  outline: 2px solid rgba(134, 207, 130, 0.74);
  object-fit: cover;
  box-shadow: 0 18px 46px rgba(0, 0, 0, 0.46);
}

.shell {
  width: min(920px, calc(100% - 28px));
  margin: 0 auto;
  padding: 78px 0 32px;
}

.intro {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 28px;
  margin: 0 2px 28px;
}

.eyebrow {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 13px;
  color: var(--green-soft);
  font-size: 0.75rem;
  font-weight: 850;
  letter-spacing: 0.14em;
}

.eyebrow span { color: rgba(248, 251, 252, 0.48); }

h1, h2, h3, p { margin-top: 0; }

h1 {
  margin-bottom: 10px;
  color: var(--white);
  font-size: clamp(2.05rem, 5vw, 3.45rem);
  line-height: 0.98;
  letter-spacing: -0.052em;
}

.intro p {
  max-width: 610px;
  margin-bottom: 0;
  color: var(--muted);
  font-size: 1rem;
  line-height: 1.55;
}

.intro-actions {
  display: flex;
  flex: 0 0 auto;
  flex-direction: column;
  align-items: flex-end;
  gap: 10px;
  padding-top: 25px;
}

.status-pill, .zone-badge, .auto-label {
  flex: 0 0 auto;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(16, 36, 50, 0.82);
  color: #e6eef2;
  font-size: 0.78rem;
  font-weight: 750;
  padding: 8px 12px;
}

.status-pill {
  border-color: var(--line-green);
  background: rgba(134, 207, 130, 0.09);
}

.status-pill span {
  margin-right: 5px;
  color: var(--green);
  font-size: 0.66rem;
}

.discord-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  min-height: 43px;
  border: 1px solid var(--line-green);
  border-radius: 12px;
  background: rgba(134, 207, 130, 0.12);
  color: var(--white);
  padding: 0 14px;
  font-size: 0.86rem;
  font-weight: 800;
  text-decoration: none;
  white-space: nowrap;
  transition: background 130ms ease, color 130ms ease, transform 130ms ease;
}

.discord-link svg {
  width: 21px;
  height: 21px;
  fill: var(--green);
  transition: fill 130ms ease;
}

.discord-link:hover {
  background: var(--green);
  color: var(--navy-950);
  transform: translateY(-1px);
}

.discord-link:hover svg { fill: var(--navy-950); }
.discord-link:focus-visible { outline: 2px solid var(--white); outline-offset: 3px; }

.panel {
  position: relative;
  margin-bottom: 16px;
  padding: clamp(20px, 4vw, 30px);
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: linear-gradient(145deg, rgba(24, 52, 66, 0.97), rgba(11, 28, 39, 0.98));
  box-shadow: 0 22px 60px rgba(0, 0, 0, 0.25);
}

.panel::before {
  position: absolute;
  inset: 0 auto 0 0;
  width: 3px;
  background: linear-gradient(180deg, var(--green), rgba(134, 207, 130, 0.08));
  content: "";
}

.section-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 22px;
}

.section-heading > div { display: flex; align-items: center; gap: 11px; }
.section-heading h2 { margin: 0; font-size: 1.08rem; letter-spacing: -0.015em; }
.step { color: var(--green); font: 850 0.75rem/1 ui-monospace, SFMono-Regular, Menlo, monospace; }
.zone-badge { border-color: var(--line-green); color: var(--green-soft); }
.auto-label { border: 0; background: transparent; color: var(--muted); padding-right: 0; }

.field-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.field { display: grid; gap: 8px; color: #d9e2e7; font-size: 0.875rem; font-weight: 700; }

.field input, .ambiguity select {
  width: 100%;
  min-height: 54px;
  border: 1px solid var(--line);
  border-radius: 13px;
  outline: none;
  background: rgba(5, 15, 22, 0.8);
  color: var(--white);
  padding: 0 15px;
  font-size: 1rem;
}

.field input:focus, .ambiguity select:focus {
  border-color: var(--green);
  box-shadow: 0 0 0 3px rgba(134, 207, 130, 0.14);
}

.quick-row {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  margin-top: 15px;
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 700;
}

.quick-row > span { padding-top: 10px; white-space: nowrap; }
.chip-group { display: grid; flex: 1 1 auto; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 7px; width: 100%; }

.time-chip {
  min-width: 0;
  min-height: 37px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(24, 52, 66, 0.82);
  color: #e6eef2;
  padding: 0 8px;
  cursor: pointer;
  font-size: 0.84rem;
  transition: border-color 130ms ease, background 130ms ease, color 130ms ease;
}

.time-chip:hover, .time-chip:focus-visible { border-color: var(--green); color: var(--white); }
.time-chip:focus-visible { outline: 2px solid var(--green); outline-offset: 2px; }
.time-chip.active {
  border-color: var(--green);
  background: rgba(134, 207, 130, 0.18);
  color: var(--white);
  box-shadow: inset 0 0 0 1px rgba(182, 233, 177, 0.16);
}

.format-picker { margin: 23px 0 0; padding: 0; border: 0; }
.format-picker legend { margin-bottom: 9px; color: #d9e2e7; font-size: 0.875rem; font-weight: 700; }
.segment-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 9px; }
.segment-grid label { cursor: pointer; }
.segment-grid input { position: absolute; opacity: 0; pointer-events: none; }

.segment-grid span {
  display: grid;
  gap: 4px;
  min-height: 64px;
  padding: 11px 13px;
  border: 1px solid var(--line);
  border-radius: 13px;
  background: rgba(5, 15, 22, 0.76);
  transition: 150ms ease;
}

.segment-grid strong { font-size: 0.9rem; }
.segment-grid small { overflow: hidden; color: var(--muted); font-size: 0.75rem; text-overflow: ellipsis; white-space: nowrap; }
.segment-grid input:checked + span {
  border-color: var(--green);
  background: rgba(134, 207, 130, 0.13);
  box-shadow: inset 0 0 0 1px rgba(182, 233, 177, 0.12);
}
.segment-grid input:focus-visible + span { outline: 2px solid var(--green); outline-offset: 2px; }

.ambiguity { margin-top: 18px; }
.ambiguity label { display: block; margin-bottom: 8px; color: #ffe0a7; font-size: 0.875rem; font-weight: 700; }
.form-message { margin: 17px 0 0; color: var(--danger); font-size: 0.875rem; font-weight: 650; }

.preview-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 9px; }
.preview-card {
  min-width: 0;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 15px;
  background: rgba(5, 15, 22, 0.76);
}

.preview-card.home {
  grid-column: 1 / -1;
  border-color: var(--line-green);
  background: linear-gradient(105deg, rgba(134, 207, 130, 0.14), rgba(5, 15, 22, 0.8) 62%);
}

.location-line { display: flex; align-items: center; gap: 10px; }
.flag { font-size: 1.3rem; line-height: 1; }
.location-line h3 { margin: 0; font-size: 0.9rem; }
.location-line p { margin: 3px 0 0; color: var(--muted); font-size: 0.76rem; }
.rendered-time { display: block; overflow-wrap: anywhere; margin-top: 16px; color: var(--white); font-size: clamp(1.2rem, 4vw, 1.65rem); letter-spacing: -0.035em; }
.detail-time { display: block; margin-top: 5px; color: var(--muted); font-size: 0.76rem; }
.preview-note { margin: 15px 1px 0; color: #8fa2ad; font-size: 0.76rem; line-height: 1.55; }
.empty-state { grid-column: 1 / -1; padding: 28px; border: 1px dashed var(--line); border-radius: 14px; color: var(--muted); text-align: center; }

.code-row { display: flex; align-items: stretch; gap: 9px; }
.code-row code {
  display: flex;
  flex: 1 1 auto;
  align-items: center;
  min-width: 0;
  overflow-x: auto;
  min-height: 57px;
  padding: 0 16px;
  border: 1px solid var(--line-green);
  border-radius: 13px;
  background: #061119;
  color: var(--green-soft);
  font: 750 0.94rem/1 ui-monospace, SFMono-Regular, Menlo, monospace;
  white-space: nowrap;
}

.copy-button {
  min-height: 57px;
  border: 0;
  border-radius: 13px;
  background: linear-gradient(135deg, var(--green-strong), var(--green));
  color: #07151d;
  padding: 0 19px;
  font-weight: 850;
  cursor: pointer;
  box-shadow: 0 13px 30px rgba(73, 147, 76, 0.23);
  transition: transform 130ms ease, filter 130ms ease;
}

.copy-button:hover { transform: translateY(-1px); filter: brightness(1.06); }
.copy-button:focus-visible { outline: 2px solid var(--white); outline-offset: 3px; }
.copy-button:active { transform: translateY(1px); }
.copy-button:disabled { cursor: not-allowed; opacity: 0.48; transform: none; filter: none; }
.copy-button.copied { background: var(--white); color: var(--navy-900); }

.discord-example {
  display: flex;
  gap: 11px;
  margin-top: 18px;
  padding: 15px;
  border: 1px solid rgba(178, 206, 218, 0.09);
  border-radius: 14px;
  background: rgba(5, 15, 22, 0.58);
}

.avatar {
  display: inline-grid;
  flex: 0 0 auto;
  place-items: center;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: linear-gradient(145deg, var(--green), var(--green-strong));
  color: var(--navy-950);
  font-size: 0.84rem;
  font-weight: 900;
  box-shadow: 0 8px 24px rgba(73, 147, 76, 0.22);
}

.discord-example strong { display: block; font-size: 0.84rem; }
.discord-example strong span { margin-left: 5px; color: #81929c; font-size: 0.72rem; font-weight: 500; }
.discord-example p { margin: 5px 0 0; color: #dbe4e8; font-size: 0.84rem; line-height: 1.48; }
.discord-example mark { border-radius: 3px; background: rgba(134, 207, 130, 0.2); color: var(--green-soft); padding: 1px 3px; }

footer { padding: 11px 0 2px; color: #70848f; font-size: 0.75rem; text-align: center; }

@media (max-width: 620px) {
  .hero { height: 190px; }
  .hero-shade { background: linear-gradient(180deg, transparent 48%, rgba(7, 19, 28, 0.72) 100%); }
  .brand-logo { bottom: -39px; left: 2px; width: 88px; border-width: 3px; border-radius: 19px; }
  .shell { width: min(100% - 20px, 920px); padding-top: 61px; }
  .intro { display: block; margin-bottom: 23px; }
  .intro-actions { align-items: flex-start; padding-top: 17px; }
  .status-pill { display: inline-flex; }
  .section-heading { align-items: flex-start; }
  .zone-badge { max-width: 50%; text-align: right; }
  .field-grid { grid-template-columns: 1fr; }
  .quick-row { flex-direction: column; }
  .quick-row > span { padding-top: 0; }
  .preview-grid { grid-template-columns: 1fr; }
  .preview-card.home { grid-column: auto; }
  .code-row { flex-direction: column; }
  .copy-button { width: 100%; }
}

@media (max-width: 390px) {
  .hero { height: 172px; }
  .panel { padding: 17px; border-radius: 18px; }
  .segment-grid { grid-template-columns: 1fr; }
  .segment-grid span { min-height: 54px; }
  .auto-label { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition: none !important; }
}
