/* ================================================================
   Piazza Design System — Mugugno
   Editorial protest aesthetic: ivory + oxblood + navy
   ================================================================ */

@import url('/static/fonts.css');

/* ── Tokens ─────────────────────────────────────────────────── */
:root {
  --ivory:  #f5efe0;
  --ivory2: #ece4d0;
  --ivory3: #fbf7ea;
  --ink:    #101018;
  --inkDim: #2a2a35;
  --navy:   #1e2a4a;
  --red:    #c2281e;
  --rust:   #8a2f1d;
  --ochre:  #c78420;
  --olive:  #5a6b3c;
  --muted:  #6b6459;
  --dim:    #9b9485;

  --serif: 'DM Serif Display', 'Playfair Display', Georgia, serif;
  --sans:  'Archivo', 'Helvetica Neue', sans-serif;
  --mono:  'IBM Plex Mono', monospace;
  --bodoni: 'Bodoni Moda', Georgia, serif;
}

/* ── Reset ──────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--sans);
  background: var(--ivory);
  color: var(--ink);
  -webkit-font-smoothing: antialiased;
}

body input, body textarea, body button, body select {
  font-family: inherit;
}

body a { color: inherit; text-decoration: none; }
body button { cursor: pointer; }

[x-cloak] { display: none !important; }

/* ── Grain overlay ──────────────────────────────────────────── */
.pz-grain { position: relative; }
.pz-grain::before {
  content: '';
  position: absolute; inset: 0;
  pointer-events: none;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='140' height='140'><filter id='n'><feTurbulence baseFrequency='0.9' numOctaves='2'/><feColorMatrix values='0 0 0 0 0.06 0 0 0 0 0.05 0 0 0 0 0.04 0 0 0 0.18 0'/></filter><rect width='100%25' height='100%25' filter='url(%23n)'/></svg>");
  opacity: .7;
  mix-blend-mode: multiply;
  z-index: 1;
}
.pz-grain > * { position: relative; z-index: 2; }

/* ── Shadows ────────────────────────────────────────────────── */
.pz-hard-shadow    { box-shadow: 4px 4px 0 var(--ink); }
.pz-hard-shadow-lg { box-shadow: 6px 6px 0 var(--ink); }
.pz-hard-shadow-red{ box-shadow: 4px 4px 0 var(--red); }

/* ── Buttons ────────────────────────────────────────────────── */
.pz-btn-primary {
  display: inline-block;
  background: var(--red); color: var(--ivory);
  border: 2px solid var(--ink);
  padding: 14px 22px;
  font-family: var(--sans); font-size: 12px; font-weight: 800;
  letter-spacing: .2em; text-transform: uppercase;
  box-shadow: 4px 4px 0 var(--ink);
  transition: transform .1s, box-shadow .1s;
  cursor: pointer;
}
.pz-btn-primary:hover  { transform: translate(-1px,-1px); box-shadow: 5px 5px 0 var(--ink); }
.pz-btn-primary:active { transform: translate(2px,2px);   box-shadow: 2px 2px 0 var(--ink); }
.pz-btn-primary:disabled { opacity: .4; cursor: not-allowed; transform: none; box-shadow: 4px 4px 0 var(--ink); }

.pz-btn-ink {
  display: inline-block;
  background: var(--ink); color: var(--ivory);
  border: 2px solid var(--ink);
  padding: 14px 22px;
  font-family: var(--sans); font-size: 12px; font-weight: 800;
  letter-spacing: .2em; text-transform: uppercase;
  transition: transform .1s, box-shadow .1s;
  cursor: pointer;
}
.pz-btn-ink:hover { box-shadow: 4px 4px 0 var(--red); transform: translate(-1px,-1px); }
.pz-btn-ink:disabled { opacity: .4; cursor: not-allowed; }

.pz-btn-ghost {
  display: inline-block;
  background: transparent; color: var(--ink);
  border: 2px solid var(--ink);
  padding: 10px 18px;
  font-family: var(--sans); font-size: 11px; font-weight: 700;
  letter-spacing: .16em; text-transform: uppercase;
  transition: background .1s;
  cursor: pointer;
}
.pz-btn-ghost:hover { background: var(--ink); color: var(--ivory); }

/* ── Inputs ─────────────────────────────────────────────────── */
.pz-input {
  width: 100%;
  background: var(--ivory3);
  border: 2px solid var(--ink);
  padding: 12px 14px;
  font-family: var(--serif); font-size: 18px;
  color: var(--ink); outline: none;
  transition: box-shadow .1s;
}
.pz-input:focus { box-shadow: 3px 3px 0 var(--red); }
.pz-input::placeholder { color: var(--muted); font-style: italic; }

select.pz-input { background: var(--ivory3); cursor: pointer; }

/* ── Typography classes ─────────────────────────────────────── */
.pz-label {
  font-family: var(--mono); font-size: 10px; letter-spacing: .2em;
  text-transform: uppercase; color: var(--red); font-weight: 700;
}

.pz-eyebrow {
  font-family: var(--mono); font-size: 11px; letter-spacing: .22em;
  text-transform: uppercase; font-weight: 700; color: var(--red);
}

.pz-display {
  font-family: var(--serif); font-weight: 400; font-style: italic;
  line-height: .88; letter-spacing: -.03em; color: var(--ink);
}

/* ── Checkboxes & radios ────────────────────────────────────── */
.pz-check {
  width: 22px; height: 22px;
  border: 2px solid var(--ink);
  background: var(--ivory);
  display: inline-flex; align-items: center; justify-content: center;
  flex-shrink: 0; transition: background .1s; cursor: pointer;
}
.pz-check.on { background: var(--red); color: var(--ivory); }
.pz-check.on::after { content: '✓'; font-weight: 900; font-size: 14px; }

.pz-radio {
  width: 18px; height: 18px;
  border: 2px solid var(--ink); border-radius: 50%;
  display: inline-flex; align-items: center; justify-content: center;
  flex-shrink: 0;
}
.pz-radio.on::after {
  content: ''; width: 8px; height: 8px; border-radius: 50%; background: var(--red);
}

/* ── Keyframes ──────────────────────────────────────────────── */
@keyframes pz-marquee { from { transform: translateX(0); } to { transform: translateX(-50%); } }
@keyframes pz-pulse   { 0%,100% { opacity: 1; } 50% { opacity: .35; } }
@keyframes pz-stamp {
  0%   { opacity: 0; transform: rotate(-8deg) scale(2.5); }
  65%  { opacity: 1; transform: rotate(-8deg) scale(.95); }
  100% { opacity: .88; transform: rotate(-8deg) scale(1); }
}
@keyframes pz-blink  { 0%,100% { opacity: 1; } 50% { opacity: .2; } }
@keyframes pz-fade-up { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
.pz-fade-up { animation: pz-fade-up .4s ease forwards; }
@keyframes pz-slide-in { from { opacity: 0; transform: translateY(20px); } to { opacity: 1; transform: none; } }

/* ── Scrollbars ─────────────────────────────────────────────── */
.pz-scroll::-webkit-scrollbar       { width: 10px; height: 10px; }
.pz-scroll::-webkit-scrollbar-track { background: var(--ivory2); }
.pz-scroll::-webkit-scrollbar-thumb { background: var(--ink); }

/* ================================================================
   NAV
   ================================================================ */
.pz-nav {
  display: flex; justify-content: space-between; align-items: center;
  padding: 18px 40px;
  border-bottom: 2px solid var(--ink);
  font-family: var(--sans); font-size: 12px;
  letter-spacing: .12em; text-transform: uppercase; font-weight: 600;
  background: var(--ivory);
  position: sticky; top: 0; z-index: 50;
}
.pz-nav-logo {
  display: flex; align-items: center; gap: 10px; cursor: pointer;
  text-decoration: none; color: var(--ink);
}
.pz-nav-logo-mark {
  display: inline-block; width: 14px; height: 14px; border-radius: 50%;
  background: var(--red);
  animation: pz-pulse 2.5s ease-in-out infinite;
}
.pz-nav-tagline {
  font-family: var(--serif); font-style: italic; font-size: 14px;
  color: var(--muted); font-weight: 400; letter-spacing: .04em;
  text-transform: none;
}
.pz-nav-links {
  display: flex; gap: 28px; align-items: center;
}
.pz-nav-link {
  cursor: pointer; color: var(--ink); font-weight: 500;
  position: relative; text-decoration: none;
  transition: color .1s;
}
.pz-nav-link:hover { color: var(--red); }
.pz-nav-link.active { color: var(--red); font-weight: 700; }
.pz-nav-link.active::after {
  content: ''; position: absolute;
  left: 0; right: 0; bottom: -4px;
  height: 2px; background: var(--red);
}
.pz-nav-accent { color: var(--red); cursor: pointer; font-size:12px; letter-spacing:.12em; text-transform:uppercase; font-weight:700; }
.pz-nav-muted  { color: var(--muted); font-size:11px; letter-spacing:.08em; }
.pz-nav-exit {
  background: none; border: none; padding: 0; font-family: inherit;
  font-size: 12px; letter-spacing: .12em; text-transform: uppercase;
  font-weight: 600; cursor: pointer; color: var(--red);
}

/* Lockup nav */
.pz-nav-logo {
  display: flex; align-items: center; gap: 14px;
  text-decoration: none; color: var(--ink); line-height: 1;
}
.pz-lockup-wordmark {
  font-family: var(--serif); font-style: italic; font-size: 38px;
  letter-spacing: -.02em; font-weight: 400; color: var(--ink);
}
.pz-lockup-payoff {
  border-left: 1px solid var(--muted); padding-left: 14px; margin-left: 2px;
  font-family: var(--mono); font-size: 9px; letter-spacing: .22em;
  text-transform: uppercase; color: var(--muted); font-weight: 700;
  line-height: 1.35;
}

/* ================================================================
   FOOTER
   ================================================================ */
.pz-footer {
  background: var(--ink); color: var(--ivory);
  padding: 14px 40px;
  display: flex; justify-content: space-between; align-items: center;
  font-family: var(--mono); font-size: 11px;
  letter-spacing: .12em; text-transform: uppercase;
  flex-wrap: wrap; gap: 12px;
  border-top: 2px solid var(--ink);
}
.pz-footer-right { color: var(--ochre); }

/* ================================================================
   LANDING — Hero
   ================================================================ */
.pz-hero {
  padding: 50px 40px 34px;
  position: relative;
  background: var(--ivory);
}
.pz-hero-timbro {
  position: absolute; top: 40px; right: 36px;
  opacity: .92; pointer-events: none; z-index: 2;
}
.pz-hero-meta {
  position: absolute; top: 186px; right: 40px;
  font-family: var(--mono); font-size: 11px; line-height: 1.7;
  color: var(--muted); text-align: right;
}
.pz-hero-meta-count { color: var(--red); font-weight: 700; }
.pz-hero-eyebrow { margin-bottom: 20px; }
.pz-hero-title {
  font-family: var(--serif); font-style: italic; font-weight: 400;
  font-size: clamp(34px, 6.6vw, 104px);
  line-height: .88; letter-spacing: -.03em;
  margin: 0; white-space: nowrap;
  padding-right: 170px;
}
.pz-hero-title-red    { color: var(--red); }
.pz-hero-title-normal { font-style: normal; color: var(--navy); }
.pz-hero-actions {
  margin-top: 30px;
  display: flex; gap: 22px; align-items: center; flex-wrap: wrap;
}
.pz-hero-sub {
  font-family: var(--serif); font-style: italic; font-size: 17px;
  color: var(--muted); max-width: 420px; line-height: 1.5;
  margin: 0;
}

/* ── Marquee ─────────────────────────────────────────────────── */
.pz-marquee {
  background: var(--red); color: var(--ivory);
  padding: 10px 0; overflow: hidden;
  border-top: 2px solid var(--ink); border-bottom: 2px solid var(--ink);
}
.pz-marquee-track {
  display: flex; gap: 40px; white-space: nowrap;
  animation: pz-marquee 48s linear infinite;
  font-family: var(--serif); font-style: italic; font-size: 18px;
  will-change: transform;
}
.pz-marquee-track span { flex-shrink: 0; }

/* ── 2-col form grid ─────────────────────────────────────────── */
.pz-form-grid {
  display: grid;
  grid-template-columns: 1.8fr 1fr;
  border-bottom: 1px solid var(--ink);
  background: var(--ivory2);
}
.pz-form-col {
  padding: 40px 44px;
}
.pz-form-col + .pz-form-col {
  border-left: 1px solid var(--ink);
  padding: 40px 36px;
}

/* ── Muro esempi (full-width sotto il form grid) ──────────────── */
.pz-muro {
  padding: 40px 44px 56px;
  background: var(--ivory);
  border-bottom: 2px solid var(--ink);
}
.pz-muro-header {
  display: flex; align-items: baseline; gap: 16px;
  margin-bottom: 22px; flex-wrap: wrap;
}
.pz-muro-sub {
  font-family: var(--serif); font-style: italic;
  font-size: 16px; color: var(--muted);
}
.pz-muro-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  border-top: 1px solid var(--ink);
  border-left: 1px solid var(--ink);
}
.pz-muro-item {
  padding: 18px 20px;
  border-right: 1px solid var(--ink);
  border-bottom: 1px solid var(--ink);
  cursor: pointer; background: var(--ivory3);
  transition: background .15s;
}
.pz-muro-item:hover { background: var(--ivory2); }
.pz-muro-city {
  font-family: var(--sans); font-size: 10px; letter-spacing: .18em;
  text-transform: uppercase; color: var(--navy); font-weight: 800;
  margin-bottom: 6px;
}
.pz-muro-city-use { color: var(--red); }
.pz-muro-quote {
  font-family: var(--serif); font-style: italic;
  color: var(--ink); font-size: 14.5px; line-height: 1.45;
}

/* ── How it works list ───────────────────────────────────────── */
.pz-hiw-list { list-style: none; padding: 0; margin: 0; }
.pz-hiw-item {
  display: flex; gap: 14px; align-items: baseline;
  padding: 12px 0;
  border-bottom: 1px dotted var(--muted);
}
.pz-hiw-item:last-child { border-bottom: none; }
.pz-hiw-num {
  font-family: var(--serif); font-size: 36px; font-style: italic;
  color: var(--red); min-width: 36px; line-height: 1;
}
.pz-hiw-key {
  font-family: var(--serif); font-size: 19px; font-weight: 700;
}
.pz-hiw-val {
  color: var(--muted); font-style: italic;
  font-family: var(--serif); font-size: 15px;
}

/* ── Examples wall ───────────────────────────────────────────── */
.pz-example-item {
  padding: 10px 0;
  border-bottom: 1px solid var(--ink);
  font-size: 13.5px; line-height: 1.45; cursor: pointer;
  transition: padding-left .15s;
}
.pz-example-item:last-child { border-bottom: none; }
.pz-example-item:hover { padding-left: 8px; }
.pz-example-city {
  font-family: var(--sans); font-size: 10px; letter-spacing: .18em;
  text-transform: uppercase; color: var(--navy); font-weight: 800;
}
.pz-example-city span { color: var(--red); }
.pz-example-text {
  font-family: var(--serif); font-style: italic; color: var(--ink);
}

/* ── Form inputs inside landing ──────────────────────────────── */
.pz-form-col .pz-input-row {
  display: grid; grid-template-columns: 1fr 180px; gap: 10px; margin-bottom: 14px;
}
.pz-form-title {
  font-family: var(--serif); font-style: italic; font-size: 26px; line-height: 1.1;
  margin-bottom: 16px;
}

/* ================================================================
   RESULT — Fascicolo
   ================================================================ */
.pz-result-title {
  font-family: var(--serif); font-style: italic; font-weight: 400;
  font-size: clamp(40px, 7vw, 80px);
  line-height: .9; letter-spacing: -.03em; margin: 0;
}
.pz-count-badge {
  font-family: var(--mono); font-size: 11px; font-weight: 700;
  color: var(--ink);
}

/* ── Result body (1-col) ──────────────────────────────────────── */
.pz-result-body {
  max-width: 820px;
  margin: 0 auto;
  padding: 36px 40px 60px;
}

.pz-recipients-section {
  margin-top: 40px;
}

.pz-recipients-label {
  font-family: var(--mono); font-size: 10px; letter-spacing: .2em;
  text-transform: uppercase; color: var(--red); font-weight: 700;
  margin-bottom: 12px;
  display: flex; align-items: baseline; gap: 8px;
}

.pz-letter-section { margin-bottom: 36px; }
.pz-letter-section-label { margin-bottom: 12px; }

.pz-original-block {
  border-left: 4px solid var(--red);
  padding-left: 22px; margin-bottom: 36px;
}
.pz-original-label {
  font-family: var(--mono); font-size: 10px; letter-spacing: .2em;
  text-transform: uppercase; color: var(--muted); margin-bottom: 6px;
}
.pz-original-quote {
  font-family: var(--serif); font-style: italic;
  font-size: 20px; line-height: 1.45; color: var(--ink);
}

.pz-letter-wrapper { position: relative; }
.pz-letter-stamp {
  position: absolute; top: 18px; right: 22px;
  transform-origin: center;
  opacity: 0;
  animation: pz-stamp .65s cubic-bezier(.175,.885,.32,1.275) forwards;
  animation-play-state: paused;
  pointer-events: none;
}
.pz-letter-stamp.visible { animation-play-state: running; }

.pz-letter-box {
  padding: 28px 32px;
  background: var(--ivory3);
  border: 2px solid var(--ink);
}
.pz-proto-header {
  display: flex; justify-content: space-between; align-items: baseline;
  padding-bottom: 14px; margin-bottom: 22px;
  border-bottom: 1.5px solid var(--ink);
  font-family: var(--mono); font-size: 11px; font-weight: 700;
  letter-spacing: .18em; text-transform: uppercase; color: var(--ink);
  gap: 16px; flex-wrap: wrap;
}
.pz-letter-text {
  font-family: var(--bodoni); font-size: 15px; line-height: 1.85;
  font-style: italic;
  color: var(--ink); white-space: pre-wrap;
  min-height: 280px;
}
.pz-letter-caret {
  display: inline-block;
  background: var(--red); width: 2px; height: 1.1em;
  vertical-align: text-bottom;
  animation: pz-blink .8s step-end infinite;
}

/* Refine section */
.pz-refine-section { margin-top: 20px; }
.pz-refine-form { margin-top: 12px; padding: 20px; background: var(--ivory2); border: 2px solid var(--ink); }
.pz-refine-form .pz-input { font-size: 15px; }

/* Recipient card */
.pz-recipient-card {
  border-bottom: 1px solid var(--ink);
  background: var(--ivory3);
}
.pz-recipient-head {
  display: flex; align-items: center; gap: 8px;
  padding: 12px 20px 8px;
  font-family: var(--sans);
}
.pz-badge-pa {
  font-size: 9px; letter-spacing: .18em; font-weight: 800;
  text-transform: uppercase; padding: 2px 6px;
  background: var(--navy); color: var(--ivory);
}
.pz-badge-priv {
  font-size: 9px; letter-spacing: .18em; font-weight: 800;
  text-transform: uppercase; padding: 2px 6px;
  background: var(--ochre); color: var(--ink);
}
.pz-recipient-name {
  font-weight: 700; font-size: 13px; color: var(--ink);
}
.pz-recipient-role {
  font-size: 11px; color: var(--muted); font-style: italic;
  font-family: var(--serif);
}
.pz-recipient-emails { padding: 0 20px 12px; }
.pz-email-row {
  display: flex; align-items: center; gap: 10px;
  padding: 6px 0; cursor: pointer;
  border-bottom: 1px dotted var(--dim);
}
.pz-email-row:last-child { border-bottom: none; }
.pz-ai-check-wrap {
  display: flex; align-items: center; gap: 10px; flex: 1;
}
.pz-email-mono {
  font-family: var(--mono); font-size: 13px; color: var(--ink); flex: 1;
}
.pz-badge-ipa   { font-size: 9px; font-weight: 700; color: var(--olive); letter-spacing: .06em; }
.pz-badge-ai    { font-size: 9px; font-weight: 700; color: var(--ochre); letter-spacing: .06em; }
.pz-badge-manual{ font-size: 9px; font-weight: 700; color: var(--navy); letter-spacing: .06em; }

/* Custom checkbox for AI emails */
.pz-ai-checkbox {
  appearance: none; -webkit-appearance: none;
  width: 20px; height: 20px; flex-shrink: 0;
  border: 2px solid var(--ink); background: var(--ivory);
  cursor: pointer; position: relative; transition: background .1s;
}
.pz-ai-checkbox:checked {
  background: var(--red);
}
.pz-ai-checkbox:checked::after {
  content: '✓'; position: absolute;
  top: 50%; left: 50%; transform: translate(-50%,-50%);
  font-size: 12px; font-weight: 900; color: var(--ivory);
}
.pz-ai-checkbox:disabled { opacity: .4; cursor: not-allowed; }

/* Manual slots */
.pz-manual-slots { padding: 16px 20px; border-top: 1px solid var(--ink); background: var(--ivory2); }
.pz-manual-title {
  font-family: var(--mono); font-size: 9px; letter-spacing: .2em;
  text-transform: uppercase; color: var(--muted); font-weight: 700;
  margin-bottom: 10px;
}
.pz-slot-row { margin-bottom: 8px; }
.pz-slot-input { flex: 1; min-width: 0; font-family: var(--mono); font-size: 13px; }
.pz-slot-confirm-btn {
  background: var(--ink); color: var(--ivory);
  border: 2px solid var(--ink);
  padding: 8px 14px; font-size: 11px; font-weight: 700;
  letter-spacing: .1em; text-transform: uppercase; cursor: pointer;
  transition: background .1s;
  white-space: nowrap;
}
.pz-slot-confirm-btn:hover { background: var(--red); border-color: var(--red); }
.pz-slot-confirm-btn:disabled { opacity: .4; cursor: not-allowed; }
.pz-slot-edit-btn {
  background: transparent; color: var(--muted);
  border: 1px solid var(--muted);
  padding: 4px 10px; font-size: 10px; letter-spacing: .1em;
  text-transform: uppercase; cursor: pointer;
}
.pz-slot-edit-btn:hover { border-color: var(--red); color: var(--red); }
.pz-manual-hint {
  font-family: var(--serif); font-style: italic;
  font-size: 12px; color: var(--dim); margin: 8px 0 0;
}

/* Send panel */
.pz-send-panel {
  border: 2px solid var(--ink);
  background: var(--ivory2);
  padding: 24px;
  margin-top: 28px;
  box-shadow: 4px 4px 0 var(--ink);
}
.pz-send-label { margin-bottom: 14px; }
.pz-send-mode-grid {
  display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-bottom: 16px;
}
.pz-send-mode-card {
  border: 2px solid var(--ink); padding: 14px 16px;
  cursor: pointer; background: var(--ivory2);
  transition: border-color .1s, background .1s;
  display: flex; flex-direction: column; gap: 4px;
}
.pz-send-mode-card input[type=radio] { display: none; }
.pz-send-mode-card.selected {
  border-color: var(--red);
  box-shadow: 3px 3px 0 var(--red);
  background: rgba(194,40,30,.06);
}
.pz-send-mode-name {
  font-family: var(--sans); font-size: 12px; font-weight: 800;
  letter-spacing: .04em;
}
.pz-send-mode-sub {
  font-family: var(--serif); font-style: italic; font-size: 12px; color: var(--muted);
}
.pz-send-mode-locked {
  border: 2px dashed var(--dim); padding: 14px 16px;
  background: var(--ivory2); opacity: .7;
  text-decoration: none;
}

.pz-signature-panel {
  padding: 16px; margin-bottom: 16px;
  background: var(--ivory2); border: 2px solid var(--ink);
}
.pz-signature-title { margin-bottom: 12px; }
.pz-sig-grid {
  display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-bottom: 10px;
}
.pz-sig-grid input, .pz-sig-note-input {
  width: 100%; font-family: var(--mono); font-size: 13px;
  background: var(--ivory3); border: 2px solid var(--ink);
  padding: 9px 12px; color: var(--ink); outline: none;
}
.pz-sig-grid input:focus, .pz-sig-note-input:focus { box-shadow: 3px 3px 0 var(--red); }
.pz-sig-note {
  font-family: var(--serif); font-style: italic; font-size: 12px;
  color: var(--olive); margin: 4px 0 0;
}

/* PDF option */
.pz-pdf-option {
  display: flex; align-items: center; gap: 12px; cursor: pointer;
  padding: 12px 14px; margin-top: 12px;
  border: 2px solid var(--ink); background: var(--ivory2);
}
.pz-pdf-option:hover { background: var(--ivory); }
.pz-pdf-option-text { display: flex; flex-direction: column; gap: 2px; }
.pz-pdf-option-name {
  font-family: var(--serif); font-weight: 700; font-size: 16px; color: var(--ink);
}
.pz-pdf-option-sub {
  font-family: var(--serif); font-style: italic; font-size: 12px; color: var(--muted);
}

/* Searching state */
.pz-searching {
  display: flex; align-items: center; gap: 12px;
  padding: 24px 20px;
  font-family: var(--serif); font-style: italic; font-size: 16px; color: var(--muted);
}
.pz-searching-dot {
  width: 8px; height: 8px; border-radius: 50%; background: var(--red);
  animation: pz-blink 1s ease-in-out infinite;
}
.pz-searching-dot:nth-child(2) { animation-delay: .2s; }
.pz-searching-dot:nth-child(3) { animation-delay: .4s; }

.pz-no-recipients {
  padding: 24px 20px;
  font-family: var(--serif); font-style: italic; color: var(--muted);
}

/* Alerts */
.pz-success-box {
  padding: 14px 20px; margin-bottom: 20px;
  background: rgba(90,107,60,.12);
  border: 2px solid var(--olive); color: var(--olive);
  font-family: var(--mono); font-size: 12px; letter-spacing: .08em;
}
.pz-error-box {
  padding: 14px 20px; margin-bottom: 20px;
  background: rgba(194,40,30,.08);
  border: 2px solid var(--red); color: var(--red);
  font-family: var(--mono); font-size: 12px; letter-spacing: .08em;
}

/* Back link */
.pz-back-link {
  font-family: var(--mono); font-size: 11px; letter-spacing: .12em;
  text-transform: uppercase; color: var(--red); cursor: pointer;
  text-decoration: none;
}
.pz-back-link:hover { text-decoration: underline; }

/* ================================================================
   HISTORY
   ================================================================ */
.pz-history-header {
  padding: 40px 40px 28px;
  background: var(--ivory);
  border-bottom: 2px solid var(--ink);
}
.pz-stats-strip {
  display: grid; grid-template-columns: repeat(3, 1fr);
  border: 2px solid var(--ink);
  background: var(--ivory3); margin-bottom: 32px;
}
.pz-stat-cell {
  padding: 24px 22px;
  border-right: 2px solid var(--ink);
}
.pz-stat-cell:last-child { border-right: none; }
.pz-stat-num {
  font-family: var(--serif); font-style: italic;
  font-size: 54px; line-height: 1; color: var(--ink);
}
.pz-stat-num.accent { color: var(--red); }

.pz-filter-bar { display: flex; gap: 8px; margin-bottom: 20px; }
.pz-filter-btn {
  padding: 8px 16px; font-size: 11px; letter-spacing: .16em;
  text-transform: uppercase; font-weight: 700;
  background: transparent; color: var(--ink);
  border: 2px solid var(--ink); cursor: pointer;
  transition: background .1s, color .1s;
}
.pz-filter-btn.active, .pz-filter-btn:hover {
  background: var(--ink); color: var(--ivory);
}

.pz-complaint-row {
  display: grid; grid-template-columns: 100px 1fr auto;
  gap: 20px; padding: 20px;
  background: var(--ivory3); border: 2px solid var(--ink);
  margin-bottom: -2px; cursor: pointer;
  transition: transform .1s, box-shadow .1s;
  align-items: center; text-decoration: none; color: var(--ink);
  position: relative;
}
.pz-complaint-row:hover {
  transform: translate(-2px,-2px);
  box-shadow: 4px 4px 0 var(--red);
  z-index: 2;
}
.pz-complaint-date-num {
  font-family: var(--mono); font-size: 10px;
  letter-spacing: .14em; color: var(--muted); text-transform: uppercase;
}
.pz-complaint-date-day {
  font-family: var(--serif); font-size: 24px; font-style: italic; color: var(--red);
}
.pz-complaint-date-time {
  font-family: var(--mono); font-size: 10px; color: var(--muted);
}
.pz-complaint-cat {
  font-family: var(--sans); font-size: 10px; letter-spacing: .14em;
  font-weight: 800; text-transform: uppercase; color: var(--navy); margin-bottom: 4px;
}
.pz-complaint-preview {
  font-family: var(--serif); font-size: 17px; line-height: 1.35;
  font-style: italic; color: var(--ink); margin-bottom: 4px;
}
.pz-complaint-recipients {
  font-size: 11px; color: var(--muted); letter-spacing: .04em;
}
.pz-status-sent {
  display: inline-block; padding: 4px 10px;
  border: 2px solid var(--olive); color: var(--olive);
  font-family: var(--sans); font-size: 10px;
  letter-spacing: .18em; text-transform: uppercase; font-weight: 800;
}
.pz-status-draft {
  display: inline-block; padding: 4px 10px;
  border: 2px solid var(--ochre); color: var(--ochre);
  font-family: var(--sans); font-size: 10px;
  letter-spacing: .18em; text-transform: uppercase; font-weight: 800;
}
.pz-complaint-arrow { font-size: 20px; color: var(--red); margin-top: 8px; }

.pz-empty-state {
  padding: 48px 32px; text-align: center;
  border: 2px dashed var(--ink); background: var(--ivory2);
  font-family: var(--serif); font-style: italic; font-size: 20px; color: var(--muted);
}
.pz-empty-link { color: var(--red); text-decoration: underline; }

/* ================================================================
   AUTH — Split layout
   ================================================================ */
.pz-auth-grid {
  display: grid; grid-template-columns: 1fr 1fr;
  min-height: calc(100vh - 120px);
}
.pz-auth-poster {
  background: var(--ink); color: var(--ivory);
  padding: 60px 50px;
  border-right: 2px solid var(--ink);
  display: flex; flex-direction: column; justify-content: space-between;
}
.pz-auth-poster-eyebrow {
  font-family: var(--mono); font-size: 11px; letter-spacing: .22em;
  color: var(--ochre); font-weight: 700; text-transform: uppercase;
}
.pz-auth-poster-title {
  font-family: var(--serif); font-style: italic; font-weight: 400;
  font-size: clamp(44px, 6vw, 76px);
  line-height: .9; letter-spacing: -.03em;
  margin: 24px 0 30px; color: var(--ivory);
}
.pz-auth-poster-title .red { color: var(--red); }
.pz-auth-poster-title .ochre { color: var(--ochre); }
.pz-auth-poster-sub {
  font-family: var(--serif); font-size: 19px; font-style: italic;
  line-height: 1.5; max-width: 360px; color: #d8cfbb;
}
.pz-auth-stamp {
  align-self: flex-start; margin-top: 60px;
  border: 3px solid var(--red); color: var(--red);
  padding: 10px 20px 12px; transform: rotate(-6deg);
  font-family: var(--sans); font-size: 13px; letter-spacing: .22em; font-weight: 800;
}
.pz-auth-stamp-sub {
  font-size: 10px; margin-top: 4px; letter-spacing: .14em; color: #d8cfbb;
}
.pz-auth-form-col {
  padding: 60px 50px; display: flex; align-items: center; background: var(--ivory);
}
.pz-auth-form-inner { width: 100%; max-width: 420px; }

.pz-tab-bar {
  display: flex; gap: 4px; margin-bottom: 28px;
  border: 2px solid var(--ink);
}
.pz-tab-btn {
  flex: 1; padding: 12px 0; font-size: 11px;
  letter-spacing: .18em; text-transform: uppercase; font-weight: 800;
  background: var(--ivory3); color: var(--ink);
  border: none; cursor: pointer; transition: background .1s, color .1s;
}
.pz-tab-btn.active {
  background: var(--ink); color: var(--ivory);
}

.pz-field-label {
  font-family: var(--mono); font-size: 10px; letter-spacing: .2em;
  text-transform: uppercase; color: var(--red); font-weight: 700;
  display: block; margin-bottom: 6px;
}
.pz-field-group { margin-bottom: 12px; }
.pz-auth-input {
  width: 100%; font-size: 16px;
  background: var(--ivory3); border: 2px solid var(--ink);
  padding: 12px 14px; color: var(--ink); outline: none;
  font-family: var(--serif); transition: box-shadow .1s;
}
.pz-auth-input:focus { box-shadow: 3px 3px 0 var(--red); }
.pz-auth-input::placeholder { color: var(--muted); font-style: italic; }
.pz-auth-name-row {
  display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-bottom: 12px;
}
.pz-auth-footer {
  margin-top: 18px; font-family: var(--serif); font-style: italic;
  font-size: 13px; color: var(--muted); text-align: center;
}
.pz-auth-footer a { color: var(--red); text-decoration: underline; }

/* ================================================================
   PROFILE
   ================================================================ */
.pz-profile-wrap {
  max-width: 600px; margin: 0 auto; padding: 60px 40px;
}
.pz-profile-card {
  background: var(--ivory3); border: 2px solid var(--ink);
  padding: 36px 40px;
}

/* ================================================================
   RESPONSIVE
   ================================================================ */
@media (max-width: 900px) {
  .pz-form-grid { grid-template-columns: 1fr; }
  .pz-form-col + .pz-form-col { border-left: none; border-top: 1px solid var(--ink); }
  .pz-auth-grid { grid-template-columns: 1fr; }
  .pz-auth-poster { min-height: 260px; }
  .pz-hero-meta { display: none; }
  .pz-stats-strip { grid-template-columns: 1fr; }
  .pz-stat-cell { border-right: none; border-bottom: 2px solid var(--ink); }
  .pz-stat-cell:last-child { border-bottom: none; }
  .pz-complaint-row { grid-template-columns: 80px 1fr; }
  .pz-complaint-row > div:last-child { grid-column: 2; }
  .pz-nav { padding: 14px 20px; }
  .pz-nav-tagline { display: none; }
  .pz-hero { padding: 40px 20px 28px; }
  .pz-form-col { padding: 24px 20px; }
}
