:root {
  --cream: #f7f1e6;
  --ink: #1a1a1a;
  --gold: #c4a35a;
  --gold-deep: #8c7040;
  --line: rgba(26, 26, 26, 0.12);
  --card: #fffaf3;
  --muted: #5c564c;
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  min-height: 100vh;
  background:
    radial-gradient(1200px 420px at 10% -10%, rgba(196, 163, 90, 0.18), transparent 60%),
    var(--cream);
  color: var(--ink);
  font-family: "Avenir Next", "Segoe UI", Helvetica, Arial, sans-serif;
  line-height: 1.45;
}

.top {
  border-bottom: 1px solid var(--line);
  background: rgba(247, 241, 230, 0.9);
}

.top-inner,
main,
footer {
  width: min(1080px, calc(100% - 32px));
  margin: 0 auto;
}

.top-inner { padding: 28px 0 26px; }

.eyebrow {
  margin: 0 0 8px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  font-size: 12px;
  color: var(--gold-deep);
  font-weight: 700;
}

.title-row {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

h1 {
  margin: 0;
  font-family: Palatino, "Palatino Linotype", "Iowan Old Style", Georgia, serif;
  font-size: clamp(36px, 5vw, 56px);
  font-weight: 600;
  letter-spacing: -0.03em;
  line-height: 1;
}

.pill {
  margin: 0;
  border: 1px solid var(--gold);
  color: var(--gold-deep);
  border-radius: 999px;
  padding: 4px 10px;
  font-size: 12px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.lede {
  max-width: 62ch;
  margin: 14px 0 0;
  color: var(--muted);
  font-size: 17px;
}

main { padding: 28px 0 12px; }

.section-head h2,
.request h2 {
  margin: 0;
  font-family: Palatino, "Palatino Linotype", Georgia, serif;
  font-size: 26px;
  font-weight: 600;
}

.section-head p {
  margin: 6px 0 0;
  color: var(--muted);
  max-width: 68ch;
}


.pricing-note {
  margin: 14px 0 0;
  padding: 14px 16px;
  max-width: 42rem;
  background: var(--card);
  border: 1px solid var(--gold);
  border-radius: 12px;
  box-shadow: 0 1px 0 rgba(196, 163, 90, 0.35);
}

.pricing-note strong {
  display: block;
  margin-top: 6px;
  font-family: Palatino, "Palatino Linotype", Georgia, serif;
  font-size: 22px;
  font-weight: 600;
  letter-spacing: -0.02em;
  color: var(--ink);
  line-height: 1.25;
}

.pricing-note .note {
  margin-top: 6px;
}

.shelf-updated {
  margin: 8px 0 0;
  font-size: 13px;
  letter-spacing: 0.02em;
  color: var(--gold-deep);
}

.shelf-grid {
  list-style: none;
  margin: 18px 0 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
}

.shelf-grid li,
.panel {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 16px;
}

.shelf-grid li {
  padding: 16px 16px 18px;
  box-shadow: 0 1px 0 rgba(196, 163, 90, 0.35);
}

.kicker {
  display: block;
  font-size: 12px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--gold-deep);
  font-weight: 700;
}

.shelf-grid strong {
  display: block;
  margin-top: 8px;
  font-family: Palatino, Georgia, serif;
  font-size: 40px;
  font-weight: 600;
  letter-spacing: -0.03em;
  line-height: 1;
}

.note {
  display: block;
  margin-top: 8px;
  color: var(--muted);
  font-size: 14px;
}

.workspace {
  display: grid;
  grid-template-columns: 1.3fr 0.7fr;
  gap: 12px;
  margin-top: 12px;
}

.panel { padding: 18px; }

.request { grid-column: 1 / -1; }

.fields {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  margin-top: 16px;
}

.request-fields { grid-template-columns: repeat(3, 1fr); }

label {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

select,
input {
  appearance: none;
  width: 100%;
  min-height: 48px;
  border: 1px solid rgba(26, 26, 26, 0.22);
  border-radius: 10px;
  background: #fff;
  color: var(--ink);
  font: 16px/1.3 "Avenir Next", "Segoe UI", Helvetica, Arial, sans-serif;
  letter-spacing: 0;
  text-transform: none;
  font-weight: 500;
  padding: 10px 12px;
}

select {
  background-image: linear-gradient(45deg, transparent 50%, var(--ink) 50%), linear-gradient(135deg, var(--ink) 50%, transparent 50%);
  background-position: calc(100% - 18px) 22px, calc(100% - 12px) 22px;
  background-size: 6px 6px, 6px 6px;
  background-repeat: no-repeat;
  padding-right: 32px;
}

textarea {
  width: 100%;
  min-height: 120px;
  resize: vertical;
  border: 1px solid rgba(26, 26, 26, 0.22);
  border-radius: 10px;
  background: #fff;
  color: var(--ink);
  font: 16px/1.4 "Avenir Next", "Segoe UI", Helvetica, Arial, sans-serif;
  letter-spacing: 0;
  text-transform: none;
  font-weight: 500;
  padding: 12px;
}

select:focus,
input:focus,
textarea:focus {
  outline: 2px solid var(--gold);
  outline-offset: 1px;
  border-color: var(--gold);
}

.ask { grid-column: 1 / -1; }

.ask-fields { grid-template-columns: 1fr; }

.submit {
  margin-top: 16px;
  min-height: 48px;
  border: 0;
  border-radius: 999px;
  background: var(--gold);
  color: var(--ink);
  font: 700 15px/1 "Avenir Next", "Segoe UI", Helvetica, Arial, sans-serif;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  padding: 0 22px;
  cursor: pointer;
}

.submit:hover { filter: brightness(0.96); }

.submit:focus-visible {
  outline: 2px solid var(--ink);
  outline-offset: 3px;
}

.confirmation {
  margin: 16px 0 0;
  padding: 14px 16px;
  border-radius: 12px;
  background: #fff;
  border: 1px solid var(--line);
}

.confirmation strong {
  display: block;
  font-size: 17px;
  line-height: 1.4;
}

.confirmation p {
  margin: 6px 0 0;
  color: var(--muted);
}

.confirmation.ok { border-color: var(--gold); }
.confirmation.wait { border-color: rgba(26, 26, 26, 0.28); }
.confirmation.block { border-color: rgba(26, 26, 26, 0.2); }

.request-json {
  margin: 10px 0 0;
  padding: 12px;
  overflow-x: auto;
  background: var(--cream);
  color: var(--ink);
  border: 1px solid var(--gold);
  border-radius: 10px;
  font: 500 13px/1.45 ui-monospace, "SFMono-Regular", Consolas, monospace;
  letter-spacing: 0;
  text-transform: none;
  white-space: pre-wrap;
}

footer {
  padding: 8px 0 36px;
  color: var(--muted);
  font-size: 14px;
}

footer p { margin: 4px 0; }


.purchase-line {
  margin: 14px 0 0;
  font-size: 18px;
  font-weight: 600;
}

.delivery { margin-top: 0; }

.code-field { max-width: 280px; }

.table-wrap {
  margin-top: 18px;
  overflow-x: auto;
}

.lead-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 15px;
  font-weight: 500;
  letter-spacing: 0;
  text-transform: none;
}

.lead-table th {
  text-align: left;
  font-size: 12px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--gold-deep);
  font-weight: 700;
  padding: 0 12px 10px 0;
  border-bottom: 1px solid var(--line);
  white-space: nowrap;
}

.lead-table td {
  padding: 12px 12px 12px 0;
  border-bottom: 1px solid var(--line);
  white-space: nowrap;
}

.lead-table tbody tr:last-child td { border-bottom: 0; }

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

@media (max-width: 860px) {
  .shelf-grid,
  .workspace,
  .fields,
  .request-fields,
  .ask-fields {
    grid-template-columns: 1fr;
  }

  .top-inner,
  main,
  footer {
    width: min(1080px, calc(100% - 24px));
  }

  .shelf-grid strong { font-size: 36px; }
}

.delivery-note {
  margin: 12px 0 0;
  color: var(--muted);
  font-size: 14px;
}

#download:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

.brand-row {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 10px;
}

.brand-row .eyebrow { margin: 0; }

.mark {
  display: inline-grid;
  place-items: center;
  width: 52px;
  height: 52px;
  flex: 0 0 52px;
  border-radius: 50%;
  background: var(--gold);
  color: var(--cream);
  border: 2px solid var(--ink);
  box-shadow: inset 0 0 0 4px var(--cream);
  font-family: Palatino, "Palatino Linotype", Georgia, serif;
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.06em;
  line-height: 1;
}

.fact-grid {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
}

.fact-grid li {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 16px 16px 18px;
  box-shadow: 0 1px 0 rgba(196, 163, 90, 0.35);
}

.fact-grid p {
  margin: 8px 0 0;
  color: var(--ink);
  font-size: 15px;
  font-weight: 500;
}

.register { margin-top: 12px; }

.register-fields { grid-template-columns: repeat(2, 1fr); }

#register-submit:disabled,
#login-submit:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

.gate-note {
  margin: 16px 0 0;
  color: var(--muted);
  font-size: 15px;
  font-weight: 500;
  letter-spacing: 0;
  text-transform: none;
}

.gate-note a {
  color: var(--ink);
  font-weight: 700;
  text-decoration-color: var(--gold);
  text-underline-offset: 3px;
}

@media (max-width: 860px) {
  .fact-grid,
  .register-fields {
    grid-template-columns: 1fr;
  }
}

/* Login page only: photo background under cream overlay.
   Register, index, and delivery keep the plain cream gradient on body. */
body.login-page {
  position: relative;
  isolation: isolate;
  min-height: 100vh;
  background: var(--cream);
}

body.login-page::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  background-color: var(--cream);
  background-image:
    linear-gradient(rgba(247, 241, 230, 0.82), rgba(247, 241, 230, 0.82)),
    url("assets/login-bg.jpg");
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  pointer-events: none;
}

body.login-page .top {
  background: rgba(247, 241, 230, 0.78);
}

body.login-page .panel {
  background: var(--card);
  box-shadow: 0 10px 30px rgba(26, 26, 26, 0.10), 0 1px 0 rgba(196, 163, 90, 0.35);
}

body.login-page footer {
  background: transparent;
}

/* Real NBG logo (login + register). Cream-safe variant of the transparent logo. */
.brand-logo {
  display: block;
  width: 64px;
  height: 64px;
  flex: 0 0 64px;
  object-fit: contain;
}

/* Login: photo shows in the outer left/right gutters; centered cream column
   keeps the header and form clear and readable. */
body.login-page::before {
  background-image:
    linear-gradient(90deg,
      rgba(247, 241, 230, 0.30) 0%,
      rgba(247, 241, 230, 0.42) 28%,
      rgba(247, 241, 230, 0.90) 50%,
      rgba(247, 241, 230, 0.42) 72%,
      rgba(247, 241, 230, 0.30) 100%),
    url("assets/login-bg.jpg");
  background-position: center center;
}

body.login-page .login-shell {
  width: min(620px, 100%);
  min-height: 100vh;
  margin: 0 auto;
  padding: 0 28px 24px;
  background: rgba(247, 241, 230, 0.97);
  box-shadow: 0 0 0 1px rgba(196, 163, 90, 0.18), 0 0 60px rgba(26, 26, 26, 0.12);
}

body.login-page .top {
  background: transparent;
}

body.login-page .top-inner,
body.login-page main,
body.login-page footer {
  width: 100%;
}

body.login-page .register-fields {
  grid-template-columns: 1fr;
}

@media (max-width: 660px) {
  body.login-page .login-shell {
    padding: 0 16px 20px;
    box-shadow: none;
  }
}
