@import url("https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&family=JetBrains+Mono:wght@400;600;700&display=swap");

:root {
  --bg: #050506;
  --panel: #0d0d10;
  --panel-2: #111116;
  --text: #f4f4f5;
  --muted: #8b8b92;
  --soft: #5a5a62;
  --red: #ff2832;
  --red-soft: rgba(255, 40, 50, .14);
  --line: rgba(255, 255, 255, .08);
  --line-red: rgba(255, 40, 50, .35);
  --radius: 18px;
  --mono: "JetBrains Mono", monospace;
  --sans: Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* { box-sizing: border-box; }
html { background: var(--bg); }
body {
  margin: 0;
  min-height: 100vh;
  color: var(--text);
  font-family: var(--sans);
  background:
    radial-gradient(circle at 20% 12%, rgba(255, 40, 50, .12), transparent 24rem),
    radial-gradient(circle at 85% 0%, rgba(255, 40, 50, .08), transparent 22rem),
    linear-gradient(135deg, #050506, #08080a 45%, #030304);
}
body::before {
  content: "creative=true; function build(); document.querySelector(); born with yeell;";
  position: fixed;
  inset: 0;
  z-index: -1;
  overflow: hidden;
  padding: 4rem;
  color: rgba(255, 40, 50, .035);
  font: clamp(1rem, 2vw, 1.6rem)/3 var(--mono);
  word-spacing: 2.5rem;
  pointer-events: none;
}

.page {
  width: 100%;
  min-height: 100vh;
  padding: clamp(1rem, 3vw, 2.5rem);
  display: grid;
  place-items: start center;
}
.shell { width: min(100%, 820px); }

.brand {
  display: flex;
  align-items: center;
  gap: .8rem;
  margin: 0 0 clamp(1rem, 2vw, 1.35rem);
}
.brand__mark {
  width: clamp(2.5rem, 5vw, 3.15rem);
  aspect-ratio: 1;
  display: grid;
  place-items: center;
  border-radius: .9rem;
  background: linear-gradient(145deg, #17171c, #0b0b0e);
  border: 1px solid var(--line);
  color: var(--red);
  font: 800 clamp(1rem, 2vw, 1.2rem) var(--mono);
  box-shadow: 0 0 1.6rem rgba(255, 40, 50, .1);
}
.brand__name {
  font-size: clamp(1.35rem, 4vw, 2.1rem);
  font-weight: 800;
  line-height: 1;
  letter-spacing: -.05em;
  color: var(--red);
}
.brand__name span { color: var(--text); }
.brand__tag {
  margin-top: .25rem;
  color: var(--muted);
  font: .72rem var(--mono);
  letter-spacing: .22em;
  text-transform: uppercase;
}

.card {
  width: 100%;
  border-radius: var(--radius);
  background: color-mix(in srgb, var(--panel) 92%, transparent);
  border: 1px solid var(--line);
  box-shadow: 0 1rem 4rem rgba(0, 0, 0, .34);
  padding: clamp(1rem, 3vw, 1.65rem);
}
.card__top { display: grid; gap: .25rem; margin-bottom: clamp(1rem, 2vw, 1.3rem); }
.eyebrow { margin: 0; color: rgba(255, 40, 50, .62); font: .78rem var(--mono); }
h1 { margin: 0; font-size: clamp(1.45rem, 4vw, 2.25rem); line-height: 1.05; letter-spacing: -.04em; }

.stepper {
  position: relative;
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: .4rem;
  margin: 0 0 clamp(1.1rem, 3vw, 1.6rem);
  padding-top: .45rem;
}
.stepper__line {
  position: absolute;
  top: 1.38rem;
  left: 7%;
  right: 7%;
  height: 1px;
  background: var(--line);
  overflow: hidden;
}
.stepper__line span { display: block; width: 0%; height: 100%; background: var(--red); transition: width .25s ease; }
.stepper__item {
  position: relative;
  z-index: 1;
  min-width: 0;
  border: 0;
  padding: 0;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  display: grid;
  justify-items: center;
  gap: .4rem;
  font-family: var(--sans);
}
.stepper__item span {
  width: clamp(2rem, 5vw, 2.35rem);
  aspect-ratio: 1;
  display: grid;
  place-items: center;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--panel-2);
  color: var(--soft);
  font: 700 .72rem var(--mono);
  transition: .2s ease;
}
.stepper__item b { font-size: .72rem; font-weight: 600; line-height: 1; }
.stepper__item.is-done span { border-color: rgba(255, 40, 50, .45); color: rgba(255, 255, 255, .76); }
.stepper__item.is-active span { border-color: var(--red); background: var(--red); color: #fff; box-shadow: 0 0 0 .25rem var(--red-soft); }
.stepper__item.is-active b { color: var(--text); }

.form-step { display: none; }
.form-step.is-active { display: block; animation: fade .18s ease; }
@keyframes fade { from { opacity: 0; transform: translateY(.25rem); } to { opacity: 1; transform: translateY(0); } }

h2 {
  margin: 0 0 1rem;
  color: var(--text);
  font: 700 clamp(.98rem, 2vw, 1.08rem) var(--mono);
  letter-spacing: -.03em;
}
.form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(min(100%, 14rem), 1fr));
  gap: clamp(.75rem, 2vw, 1rem);
}
label { display: grid; gap: .42rem; min-width: 0; align-content: start; }
label.wide { grid-column: 1 / -1; }
label span { color: #c8c8ce; font-size: .82rem; font-weight: 600; display: inline-flex; align-items: center; gap: .35rem; }

input, textarea {
  width: 100%;
  min-width: 0;
  border: 1px solid transparent;
  border-radius: .8rem;
  background: #09090c;
  color: var(--text);
  outline: none;
  padding: .82rem .9rem;
  font: 500 .94rem var(--sans);
  box-shadow: inset 0 0 0 1px var(--line);
  transition: border-color .16s ease, box-shadow .16s ease, background .16s ease;
}
textarea { resize: vertical; }
input::placeholder, textarea::placeholder { color: #56565d; }
input:focus, textarea:focus {
  border-color: var(--red);
  box-shadow: 0 0 0 .18rem var(--red-soft);
  background: #0b0b0f;
}

.is-invalid,
.custom-select.is-invalid .select-trigger {
  border-color: var(--red) !important;
  box-shadow: 0 0 0 .18rem var(--red-soft) !important;
}

.field-error {
  min-height: .9rem;
  color: #ff6970;
  font: .72rem var(--mono);
}

.hint {
  width: 1rem;
  aspect-ratio: 1;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,.14);
  background: transparent;
  color: var(--muted);
  font: 700 .62rem var(--mono);
  cursor: help;
  position: relative;
}
.hint::after {
  content: attr(data-hint);
  position: absolute;
  left: 50%;
  bottom: calc(100% + .6rem);
  width: min(16rem, 74vw);
  transform: translateX(-50%) translateY(.2rem);
  opacity: 0;
  pointer-events: none;
  padding: .65rem .75rem;
  border-radius: .75rem;
  background: #15151a;
  color: #d7d7dd;
  border: 1px solid var(--line);
  font: .75rem/1.35 var(--sans);
  box-shadow: 0 .8rem 2rem rgba(0,0,0,.4);
  transition: .15s ease;
  z-index: 30;
}
.hint:hover::after, .hint:focus-visible::after { opacity: 1; transform: translateX(-50%) translateY(0); }

.custom-select { position: relative; }
.select-trigger {
  width: 100%;
  min-height: 2.85rem;
  border: 1px solid transparent;
  border-radius: .8rem;
  background: #09090c;
  color: var(--text);
  padding: .82rem 2.4rem .82rem .9rem;
  font: 600 .94rem var(--sans);
  box-shadow: inset 0 0 0 1px var(--line);
  text-align: left;
  cursor: pointer;
  position: relative;
}
.select-trigger::after {
  content: "";
  position: absolute;
  right: .9rem;
  top: 50%;
  width: .55rem;
  height: .55rem;
  border-right: 1px solid var(--muted);
  border-bottom: 1px solid var(--muted);
  transform: translateY(-60%) rotate(45deg);
}
.custom-select.is-open .select-trigger {
  border-color: var(--red);
  box-shadow: 0 0 0 .18rem var(--red-soft);
}
.select-menu {
  position: absolute;
  z-index: 20;
  inset-inline: 0;
  top: calc(100% + .35rem);
  max-height: 17rem;
  overflow: auto;
  padding: .4rem;
  border: 1px solid var(--line);
  border-radius: .9rem;
  background: #08080b;
  box-shadow: 0 1rem 2.2rem rgba(0,0,0,.52);
}
.select-option {
  width: 100%;
  border: 0;
  border-radius: .6rem;
  background: transparent;
  color: #f0f0f4;
  padding: .7rem .75rem;
  text-align: left;
  cursor: pointer;
  font: 600 .9rem var(--sans);
}
.select-option:hover, .select-option.is-active {
  background: rgba(255,40,50,.12);
  color: #fff;
}
.select-option small {
  display: block;
  margin-top: .15rem;
  color: var(--muted);
  font-weight: 500;
}

.mini-fill, .calendar-trigger {
  width: fit-content;
  border: 1px solid var(--line);
  border-radius: .65rem;
  background: transparent;
  color: var(--muted);
  padding: .48rem .6rem;
  font: 700 .72rem var(--mono);
  cursor: pointer;
}
.mini-fill:hover, .calendar-trigger:hover {
  border-color: var(--line-red);
  color: #fff;
}

.preview {
  display: grid;
  grid-template-columns: 9rem 1fr;
  gap: 1rem;
  padding: .85rem;
  border-radius: 1rem;
  border: 1px solid var(--line);
  background: #09090c;
}
.preview__visual {
  min-height: 5.4rem;
  border-radius: .8rem;
  background:
    radial-gradient(circle at 25% 30%, rgba(255,40,50,.45), transparent 2.5rem),
    linear-gradient(135deg, #111116, #050506);
  position: relative;
  overflow: hidden;
}
.preview__visual span { position: absolute; height: 1px; background: rgba(255,40,50,.55); }
.preview__visual span:nth-child(1) { width: 70%; left: 10%; top: 35%; }
.preview__visual span:nth-child(2) { width: 46%; left: 28%; top: 55%; }
.preview__visual span:nth-child(3) { width: 30%; left: 45%; top: 72%; }
.preview b { display: block; margin-bottom: .35rem; }
.preview p { margin: 0; color: var(--muted); font-size: .9rem; line-height: 1.45; }

.calendar {
  margin-top: 1rem;
  max-width: 23rem;
  border: 1px solid var(--line);
  border-radius: 1rem;
  background: #09090c;
  padding: .8rem;
}
.calendar__head {
  display: grid;
  grid-template-columns: 2.2rem 1fr 2.2rem;
  align-items: center;
  gap: .5rem;
  margin-bottom: .65rem;
}
.calendar__head button, .calendar__time button {
  border: 1px solid var(--line);
  border-radius: .65rem;
  background: #111116;
  color: #fff;
  min-height: 2.2rem;
  cursor: pointer;
}
.calendar__head b { text-align: center; font-size: .9rem; }
.calendar__week, .calendar__days {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: .25rem;
}
.calendar__week span {
  color: var(--muted);
  text-align: center;
  font: .68rem var(--mono);
}
.day {
  aspect-ratio: 1;
  border: 1px solid transparent;
  border-radius: .55rem;
  background: transparent;
  color: #d7d7dd;
  cursor: pointer;
}
.day:hover { background: rgba(255,40,50,.12); }
.day.is-muted { opacity: .25; pointer-events: none; }
.day.is-selected { background: var(--red); color: #fff; }
.calendar__time {
  display: grid;
  grid-template-columns: 1fr 8rem;
  gap: .65rem;
  align-items: end;
  margin-top: .75rem;
}
.calendar__time input { padding: .65rem .75rem; }

.actions {
  display: flex;
  justify-content: flex-end;
  gap: .7rem;
  margin-top: clamp(1rem, 3vw, 1.35rem);
}
.btn {
  border: 1px solid transparent;
  border-radius: .85rem;
  padding: .78rem 1.1rem;
  min-width: 8.5rem;
  font: 700 .86rem var(--mono);
  text-transform: uppercase;
  cursor: pointer;
  display: inline-flex;
  justify-content: center;
  align-items: center;
  transition: transform .15s ease, background .15s ease, border-color .15s ease;
}
.btn:hover { transform: translateY(-1px); }
.btn--primary { color: #fff; background: var(--red); border-color: var(--red); }
.btn--ghost { color: #d9d9de; background: transparent; border-color: var(--line); }
#submitBtn { display: none; }

#status { min-height: 1.2rem; margin: .85rem 0 0; color: var(--muted); font: .78rem var(--mono); }
#status.ok { color: #76f0a0; }
#status.err { color: #ff6970; }

footer { margin-top: 1.1rem; text-align: center; color: rgba(255, 255, 255, .22); font: .72rem var(--mono); }
footer span { color: rgba(255, 40, 50, .4); }

.success-modal {
  position: fixed;
  inset: 0;
  display: none;
  place-items: center;
  padding: 1rem;
  background: rgba(0,0,0,.72);
  backdrop-filter: blur(8px);
  z-index: 100;
  pointer-events: none;
}

.success-modal.is-open {
  display: grid;
  pointer-events: auto;
}
.success-box {
  width: min(100%, 23rem);
  border-radius: 1.2rem;
  border: 1px solid var(--line);
  background: #0d0d10;
  padding: 1.6rem;
  text-align: center;
  box-shadow: 0 1rem 4rem rgba(0,0,0,.45);
}
.success-ring {
  width: 4.2rem;
  aspect-ratio: 1;
  margin: 0 auto 1rem;
  border-radius: 999px;
  border: 2px solid var(--red);
  display: grid;
  place-items: center;
  animation: ring .5s ease;
}
.success-ring span {
  color: var(--red);
  font-size: 2rem;
  animation: check .35s ease .25s both;
}
.success-box h3 { margin: 0 0 .4rem; }
.success-box p { margin: 0 0 1.2rem; color: var(--muted); }
@keyframes ring { from { transform: scale(.65); opacity: 0; } to { transform: scale(1); opacity: 1; } }
@keyframes check { from { transform: scale(.25); opacity: 0; } to { transform: scale(1); opacity: 1; } }

@media (max-width: 720px) {
  .page { place-items: start stretch; }
  .shell { width: 100%; }
  .card { border-radius: 1rem; }
  .form-grid { grid-template-columns: 1fr; }
  .stepper { gap: .25rem; }
  .stepper__item b { display: none; }
  .stepper__line { left: 9%; right: 9%; }
  .actions { display: grid; grid-template-columns: 1fr; }
  .btn { width: 100%; min-width: 0; }
  .preview { grid-template-columns: 1fr; }
  .calendar { max-width: none; }
}
@media (max-width: 420px) {
  .page { padding: .75rem; }
  .brand__tag { letter-spacing: .16em; }
  .card { padding: .9rem; }
  .stepper__item span { width: 1.85rem; font-size: .66rem; }
  .stepper__line { top: 1.36rem; }
  .calendar__time { grid-template-columns: 1fr; }
}


.file-drop {
  min-height: 5.95rem;
  border-radius: .9rem;
  border: 1px dashed rgba(255,255,255,.14);
  background: #09090c;
  display: grid;
  place-items: center;
  text-align: center;
  padding: .9rem;
  position: relative;
  cursor: pointer;
  transition: .16s ease;
}

.file-drop:hover,
.file-drop.is-drag {
  border-color: var(--line-red);
  background: rgba(255, 40, 50, .06);
}

.file-drop input {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
}

.file-drop b {
  display: block;
  margin-bottom: .25rem;
  font-size: .9rem;
}

.file-drop p {
  margin: 0;
  color: var(--muted);
  font-size: .78rem;
}

.file-drop.is-invalid {
  border-color: var(--red) !important;
}
