:root {
  --ink: #0f172a;
  --muted: #64748b;
  --paper: #f1f5f9;
  --card: #ffffff;
  --line: #e2e8f0;
  --stamp: #2563eb;
  --good: #15803d;
  --hold: #be123c;
  --focus: #2563eb;
  --navy: #0b1f4d;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  min-height: 100%;
}

body {
  font-family: "Segoe UI", system-ui, sans-serif;
  color: var(--ink);
  background: var(--paper);
  line-height: 1.45;
}

body.admin {
  background: #ece7dc;
}

a { color: var(--focus); }

.wrap {
  width: min(920px, calc(100% - 32px));
  margin: 0 auto;
  padding: 24px 0 48px;
}

.site-header, .site-footer {
  width: min(920px, calc(100% - 32px));
  margin: 0 auto;
}

.site-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 0;
  border-bottom: 1px solid var(--line);
}

.brand {
  font-size: 1.4rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  text-decoration: none;
  color: var(--navy);
}

.brand span { color: var(--stamp); }

.nav { display: flex; align-items: center; }

.nav a, .nav button.link {
  margin-left: 16px;
  font-size: 0.95rem;
}

.nav a {
  color: var(--navy);
  font-weight: 600;
  text-decoration: none;
}

.nav a:hover { color: var(--stamp); }

.hero h1, .page-title {
  font-family: Georgia, "Times New Roman", serif;
  font-weight: 600;
  font-size: clamp(1.8rem, 4vw, 2.4rem);
  margin: 8px 0 8px;
}

.lede, .hint, .muted { color: var(--muted); }

.card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 20px;
  margin: 16px 0;
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.06);
}

label {
  display: block;
  font-weight: 600;
  margin-bottom: 6px;
}

input[type="text"],
input[type="email"],
input[type="password"],
select,
textarea {
  width: 100%;
  min-height: 44px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  font: inherit;
}

textarea { min-height: 80px; resize: vertical; }

.row-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

button, .btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0 16px;
  border: 0;
  border-radius: 8px;
  background: var(--ink);
  color: #fff;
  font: inherit;
  font-weight: 600;
  cursor: pointer;
  text-decoration: none;
}

button.secondary, .btn.secondary {
  background: transparent;
  color: var(--ink);
  border: 1px solid var(--line);
}

.flash {
  padding: 10px 12px;
  border-radius: 8px;
  margin: 12px 0;
}

.flash.error { background: #fde8e8; color: var(--hold); }
.flash.ok { background: #e8f5e9; color: var(--good); }

.send-card { border-color: var(--stamp); }
.code-xl { font-size: 1.8rem; margin: 8px 0 16px; }
.send-card .btn, .send-card button { margin: 0 8px 8px 0; }

.stamp {
  display: inline-block;
  padding: 4px 10px;
  border: 2px solid currentColor;
  border-radius: 4px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 0.75rem;
  font-weight: 700;
}

.stamp.received, .stamp.processing { color: var(--focus); }
.stamp.in_transit, .stamp.out_for_delivery { color: var(--stamp); }
.stamp.delivered { color: var(--good); }
.stamp.on_hold { color: var(--hold); }

.steps {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
  margin-top: 20px;
}

.step {
  text-align: center;
  font-size: 0.85rem;
  color: var(--muted);
}

.step .bar {
  height: 6px;
  border-radius: 99px;
  background: var(--line);
  margin-bottom: 8px;
}

.step.done .bar, .step.current .bar { background: var(--stamp); }
.step.hold .bar { background: var(--hold); }
.step.current, .step.done { color: var(--ink); font-weight: 600; }
.step.hold { color: var(--hold); font-weight: 600; }

.timeline {
  list-style: none;
  margin: 0;
  padding: 0;
}

.timeline li {
  position: relative;
  padding: 0 0 22px 24px;
  border-left: 2px solid var(--line);
}

.timeline li:last-child {
  border-left-color: transparent;
  padding-bottom: 0;
}

.timeline li::before {
  content: "";
  position: absolute;
  left: -7px;
  top: 3px;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--stamp);
  box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.15);
}

.timeline li strong {
  display: block;
  color: var(--navy);
}

.timeline li .muted { font-size: 0.9rem; }

.table-wrap { overflow-x: auto; }

table {
  width: 100%;
  border-collapse: collapse;
}

th, td {
  text-align: left;
  padding: 10px 8px;
  border-bottom: 1px solid var(--line);
  vertical-align: middle;
}

th { font-size: 0.8rem; text-transform: uppercase; letter-spacing: 0.04em; color: var(--muted); }

code.track {
  font-family: ui-monospace, Consolas, monospace;
  font-weight: 700;
}

.site-footer {
  width: min(920px, calc(100% - 32px));
  margin: 48px auto 0;
  padding: 32px 0 24px;
  border-top: 1px solid var(--line);
  font-size: 0.9rem;
  color: var(--muted);
}

.footer-inner {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 32px;
}

.footer-inner strong { display: block; color: var(--ink); margin-bottom: 8px; }
.footer-inner p { margin: 0 0 6px; }

.footer-links { display: flex; flex-direction: column; gap: 8px; }
.footer-links a { color: var(--muted); text-decoration: none; }
.footer-links a:hover { color: var(--stamp); }

.footer-copy { margin: 24px 0 0; font-size: 0.8rem; }

@media (max-width: 640px) {
  .footer-inner { grid-template-columns: 1fr; gap: 20px; }
}

@media (max-width: 640px) {
  .row-2, .steps { grid-template-columns: 1fr; }
  .nav a { margin-left: 10px; }
}


.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

.hero-panel {
  background:
    linear-gradient(rgba(11, 31, 77, 0.82), rgba(11, 31, 77, 0.82)),
    url("../images/hero.jpg") center / cover no-repeat;
  color: #fff;
  border-radius: 16px;
  padding: 64px 28px;
  margin: 16px 0;
}

.hero-panel h1 { color: #fff; }
.hero-panel .lede { color: #cbd5e1; margin: 0 0 20px; }

.search { display: flex; gap: 10px; flex-wrap: wrap; }
.search input { flex: 1 1 240px; min-height: 52px; font-size: 1.1rem; border: 0; }
.search button { min-height: 52px; padding: 0 28px; background: var(--stamp); }


.how { margin: 32px 0; }
.how h2 { text-align: center; margin: 0 0 20px; }

.how-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}

.how-step {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 20px;
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.06);
}

.how-step h3 { margin: 12px 0 6px; }
.how-step p { margin: 0; color: var(--muted); }

.how-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--stamp);
  color: #fff;
  font-weight: 700;
}

@media (max-width: 640px) {
  .how-grid { grid-template-columns: 1fr; }
}

.status-list {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
}

.status-item {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 16px 20px;
}

.status-item p { margin: 10px 0 0; color: var(--muted); }

@media (max-width: 640px) {
  .status-list { grid-template-columns: 1fr; }
}


.about {
  display: grid;
  grid-template-columns: 1.3fr 1fr;
  gap: 40px;
  align-items: center;
  margin: 64px 0;
}

.about img {
  width: 100%;
  height: auto;
  border-radius: 16px;
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.12);
}

.about-text h2 { margin: 0 0 16px; font-size: clamp(1.6rem, 3vw, 2.1rem); line-height: 1.2; }
.about-text p { font-size: 1.05rem; }

@media (max-width: 640px) {
  .about { grid-template-columns: 1fr; }
}

.band {
  background: var(--navy);
  color: #fff;
  border-radius: 16px;
  padding: 56px 28px;
  margin: 48px 0;
}

.band-inner { max-width: 760px; margin: 0 auto; }
.band h2 { text-align: center; margin: 0 0 8px; font-size: clamp(1.6rem, 3vw, 2.1rem); }
.band-lede { text-align: center; color: #cbd5e1; margin: 0 0 32px; }

.band-list { list-style: none; margin: 0; padding: 0; }

.band-list li {
  display: grid;
  grid-template-columns: 190px 1fr;
  gap: 16px;
  align-items: center;
  padding: 16px 0;
  border-top: 1px solid rgba(255, 255, 255, 0.15);
}

.band-list p { margin: 0; color: #e2e8f0; }

.band .stamp { background: #fff; justify-self: start; }

@media (max-width: 640px) {
  .band-list li { grid-template-columns: 1fr; gap: 8px; }
}

.faq { max-width: 760px; margin: 48px auto; }
.faq h2 { text-align: center; margin: 0 0 20px; font-size: clamp(1.6rem, 3vw, 2.1rem); }

.faq details {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 16px 20px;
  margin-bottom: 12px;
}

.faq summary { cursor: pointer; font-weight: 600; }
.faq details[open] summary { color: var(--stamp); }
.faq details p { margin: 12px 0 0; color: var(--muted); }