/* ── Event Hub with Agenda & RSVP — architect's cyanotype blueprint ──
   Prussian-blue paper with a fine white drafting grid, 1px white line
   work everywhere, monospaced annotations, measurement ticks on the
   agenda timeline, drafting-tape yellow as the single accent, corner
   registration marks and a stamped title block footer. */

:root {
  --blueprint: #123a6d;
  --blueprint-deep: #0d2c54;
  --line: rgba(255, 255, 255, 0.85);
  --line-faint: rgba(255, 255, 255, 0.32);
  --grid: rgba(255, 255, 255, 0.07);
  --grid-major: rgba(255, 255, 255, 0.13);
  --ink: #f4f8ff;
  --ink-soft: rgba(244, 248, 255, 0.72);
  --tape: #f5c518;
  --tape-deep: #d9a90a;
  --err: #ff9d9d;
  --font-head: 'Archivo', sans-serif;
  --font-mono: 'IBM Plex Mono', monospace;
}

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

.hidden { display: none !important; }

body {
  font-family: var(--font-head);
  color: var(--ink);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  background:
    linear-gradient(var(--grid-major) 1px, transparent 1px),
    linear-gradient(90deg, var(--grid-major) 1px, transparent 1px),
    linear-gradient(var(--grid) 1px, transparent 1px),
    linear-gradient(90deg, var(--grid) 1px, transparent 1px),
    radial-gradient(ellipse at 30% 10%, var(--blueprint), var(--blueprint-deep));
  background-size: 120px 120px, 120px 120px, 24px 24px, 24px 24px, cover;
  background-attachment: fixed;
  min-height: 100vh;
}

.sheet { position: relative; min-height: 100vh; display: flex; flex-direction: column; }

.wrap { width: 100%; max-width: 680px; margin: 0 auto; padding: 0 26px; }

main { flex: 1 0 auto; }

.mono { font-family: var(--font-mono); }

/* ── Registration marks ───────────────────────────────────────────── */
.regmark {
  position: fixed;
  width: 22px;
  height: 22px;
  border: 1px solid var(--line-faint);
  z-index: 5;
  pointer-events: none;
}
.regmark::before, .regmark::after {
  content: '';
  position: absolute;
  background: var(--line-faint);
}
.regmark::before { left: 50%; top: -5px; bottom: -5px; width: 1px; }
.regmark::after { top: 50%; left: -5px; right: -5px; height: 1px; }
.rm-tl { top: 14px; left: 14px; }
.rm-tr { top: 14px; right: 14px; }
.rm-bl { bottom: 14px; left: 14px; }
.rm-br { bottom: 14px; right: 14px; }

/* ── Hero ─────────────────────────────────────────────────────────── */
.hero { text-align: center; padding: 68px 26px 20px; }

.drawing-no {
  font-size: 0.7rem;
  font-weight: 500;
  letter-spacing: 0.3em;
  color: var(--ink-soft);
  margin-bottom: 18px;
}

.hero h1 {
  font-weight: 800;
  font-size: clamp(2.2rem, 8.5vw, 3.6rem);
  line-height: 1.06;
  letter-spacing: -0.015em;
  text-transform: uppercase;
}

.hero .sub {
  margin: 16px auto 0;
  max-width: 480px;
  color: var(--ink-soft);
  font-size: 1.02rem;
}

.hero-spec {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 0;
  margin: 28px auto 30px;
  border: 1px solid var(--line);
  max-width: 560px;
}

.spec-item {
  flex: 1 1 160px;
  padding: 12px 14px;
  font-size: 0.68rem;
  letter-spacing: 0.14em;
  color: var(--ink-soft);
  border-right: 1px solid var(--line-faint);
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.spec-item:last-child { border-right: none; }

.spec-item strong { color: var(--ink); font-size: 0.85rem; letter-spacing: 0.04em; }

/* ── Buttons ──────────────────────────────────────────────────────── */
.btn {
  display: inline-block;
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 0.95rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  text-decoration: none;
  text-align: center;
  padding: 15px 32px;
  border: none;
  cursor: pointer;
  transition: transform 0.12s ease, box-shadow 0.12s ease;
  line-height: 1.2;
}

.btn-tape {
  background: var(--tape);
  color: #12233d;
  box-shadow: 0 0 0 1px var(--tape), 4px 4px 0 rgba(0, 0, 0, 0.35);
}

.btn-tape:hover:not(:disabled) { transform: translate(-1px, -1px); box-shadow: 0 0 0 1px var(--tape), 6px 6px 0 rgba(0, 0, 0, 0.35); }
.btn:disabled { opacity: 0.55; cursor: not-allowed; }
.btn:focus-visible { outline: 2px dashed var(--tape); outline-offset: 4px; }

.btn-block { width: 100%; }

/* ── Sections ─────────────────────────────────────────────────────── */
.section { margin-top: 64px; }

.section-head { display: flex; align-items: center; gap: 18px; margin-bottom: 26px; }

.section-head h2 {
  font-weight: 700;
  font-size: 1.05rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  white-space: nowrap;
}

.head-rule { flex: 1; height: 1px; background: var(--line); position: relative; }

.head-rule::after {
  content: '';
  position: absolute;
  right: 0;
  top: -4px;
  width: 1px;
  height: 9px;
  background: var(--line);
}

/* ── Agenda timeline ──────────────────────────────────────────────── */
.agenda { list-style: none; border-left: 1px solid var(--line); }

.block {
  position: relative;
  display: flex;
  gap: 22px;
  padding: 0 0 34px 26px;
}

.block:last-child { padding-bottom: 6px; }

/* measurement tick on the rail */
.block::before {
  content: '';
  position: absolute;
  left: 0;
  top: 10px;
  width: 14px;
  height: 1px;
  background: var(--line);
}

/* plotted node */
.block::after {
  content: '';
  position: absolute;
  left: -5px;
  top: 6px;
  width: 9px;
  height: 9px;
  background: var(--blueprint-deep);
  border: 1px solid var(--line);
  transform: rotate(45deg);
}

.block-time {
  flex: 0 0 58px;
  font-weight: 600;
  font-size: 0.95rem;
  letter-spacing: 0.08em;
  color: var(--tape);
  padding-top: 1px;
}

.block-body h3 {
  font-weight: 700;
  font-size: 1.18rem;
  letter-spacing: 0.02em;
  margin-bottom: 5px;
}

.block-body p { color: var(--ink-soft); font-size: 0.95rem; max-width: 460px; }

/* ── Site notes ───────────────────────────────────────────────────── */
.notes-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1px; background: var(--line-faint); border: 1px solid var(--line); }

.note-card { background: rgba(13, 44, 84, 0.82); padding: 20px 18px; }

.note-label {
  font-size: 0.66rem;
  font-weight: 600;
  letter-spacing: 0.24em;
  color: var(--tape);
  margin-bottom: 8px;
}

.note-card p:not(.note-label) { color: var(--ink-soft); font-size: 0.9rem; }

/* ── RSVP ─────────────────────────────────────────────────────────── */
.rsvp-card {
  position: relative;
  border: 1px solid var(--line);
  background: rgba(13, 44, 84, 0.82);
  padding: 32px 30px;
}

/* dimension ticks on card corners */
.rsvp-card::before, .rsvp-card::after {
  content: '';
  position: absolute;
  width: 12px;
  height: 12px;
  border: 1px solid var(--line);
}
.rsvp-card::before { top: -6px; left: -6px; border-right: none; border-bottom: none; }
.rsvp-card::after { bottom: -6px; right: -6px; border-left: none; border-top: none; }

.rsvp-sub { color: var(--ink-soft); margin-bottom: 22px; font-size: 0.95rem; }

.field-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-bottom: 16px; }

.field label {
  display: block;
  font-family: var(--font-mono);
  font-weight: 500;
  font-size: 0.68rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  margin-bottom: 7px;
  color: var(--ink);
}

.optional { color: var(--ink-soft); font-size: 0.6rem; letter-spacing: 0.14em; }

input[type="text"],
input[type="email"],
select {
  width: 100%;
  padding: 13px 14px;
  font-size: 0.98rem;
  font-family: var(--font-head);
  color: var(--ink);
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--line-faint);
  border-radius: 0;
  transition: border-color 0.15s ease, background 0.15s ease;
}

select {
  appearance: none;
  background-image: url("data:image/svg+xml;charset=UTF-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' fill='none' stroke='%23f4f8ff' stroke-width='1.5'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  cursor: pointer;
}

select option { color: #12233d; background: #fff; }

input:focus, select:focus { outline: none; border-color: var(--tape); background: rgba(255, 255, 255, 0.09); }
input.error { border-color: var(--err); }
input::placeholder { color: rgba(244, 248, 255, 0.4); }

.form-error { color: var(--err); font-weight: 600; text-align: center; margin-top: 14px; font-size: 0.92rem; }

.spinner {
  display: inline-block;
  width: 15px;
  height: 15px;
  border: 2px solid rgba(18, 35, 61, 0.35);
  border-top-color: #12233d;
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
  vertical-align: -2px;
  margin-right: 8px;
}

@keyframes spin { to { transform: rotate(360deg); } }

/* ── Confirmation ─────────────────────────────────────────────────── */
.confirmed { text-align: center; padding: 44px 30px; }

.stamp {
  display: inline-block;
  font-weight: 600;
  font-size: 1.05rem;
  letter-spacing: 0.3em;
  color: var(--tape);
  border: 2px solid var(--tape);
  padding: 6px 18px 6px 22px;
  transform: rotate(-4deg);
  margin-bottom: 20px;
}

.confirmed h3 { font-weight: 800; font-size: 1.7rem; text-transform: uppercase; letter-spacing: 0.02em; }

.confirmed p { color: var(--ink-soft); margin-top: 10px; max-width: 400px; margin-left: auto; margin-right: auto; }

.confirm-meta {
  margin-top: 20px !important;
  font-size: 0.74rem;
  letter-spacing: 0.16em;
  color: var(--ink) !important;
  border-top: 1px solid var(--line-faint);
  padding-top: 16px;
}

/* ── Title block footer ───────────────────────────────────────────── */
.titleblock { margin-top: 74px; padding-bottom: 46px; text-align: center; }

.tb-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  border: 1px solid var(--line);
  text-align: left;
  font-size: 0.8rem;
}

.tb-cell {
  padding: 10px 14px;
  border-right: 1px solid var(--line-faint);
  color: var(--ink);
}

.tb-cell:last-child { border-right: none; }

.tb-label {
  display: block;
  font-size: 0.58rem;
  letter-spacing: 0.22em;
  color: var(--ink-soft);
  margin-bottom: 2px;
}

#wbx-powered-by-slot { margin-top: 20px; }

/* ── Toast ────────────────────────────────────────────────────────── */
.toast {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--tape);
  color: #12233d;
  font-weight: 700;
  padding: 13px 26px;
  z-index: 200;
  box-shadow: 4px 4px 0 rgba(0, 0, 0, 0.35);
}

/* ── Responsive ───────────────────────────────────────────────────── */
@media (max-width: 620px) {
  .field-grid { grid-template-columns: 1fr; }
  .notes-grid { grid-template-columns: 1fr; }
  .hero-spec { flex-direction: column; }
  .spec-item { border-right: none; border-bottom: 1px solid var(--line-faint); }
  .spec-item:last-child { border-bottom: none; }
  .tb-grid { grid-template-columns: 1fr; }
  .tb-cell { border-right: none; border-bottom: 1px solid var(--line-faint); }
  .tb-cell:last-child { border-bottom: none; }
  .block { gap: 14px; }
  .regmark { display: none; }
}
