/* American Dictator: the facelift and the interactive front page.
   Loaded after style.css on the front page only. Same palette, more nerve. */

:root {
  --marker: 'Permanent Marker', 'Comic Sans MS', cursive;
  --paper: #f6efdc;
  --ease-out: cubic-bezier(.19, 1, .22, 1);
}

/* ---------- Global polish ---------- */
::selection { background: var(--gold-bright); color: #1c1710; }
:focus-visible { outline: 3px solid var(--gold-bright); outline-offset: 3px; }
.section h2 { text-wrap: balance; }
.section-sub { text-wrap: pretty; }
.kicker.center { display: flex; align-items: center; justify-content: center; gap: 14px; }
.kicker.center::before, .kicker.center::after {
  content: ''; height: 1px; width: clamp(24px, 6vw, 72px);
  background: linear-gradient(90deg, transparent, var(--gold));
}
.kicker.center::after { transform: scaleX(-1); }
.store .kicker.center::before, .store .kicker.center::after { background: linear-gradient(90deg, transparent, var(--red)); }

/* Reveal: a little more theatre */
.reveal { transition-timing-function: var(--ease-out); }

/* ---------- Hero ---------- */
.hero { min-height: 100svh; overflow: hidden; }
.hero::before {
  /* the spotlight follows whoever is in charge of the mouse */
  content: ''; position: absolute; inset: 0; pointer-events: none; z-index: 1;
  background: radial-gradient(520px circle at var(--mx, 50%) var(--my, 38%), rgba(232,201,92,.2), transparent 65%);
  mix-blend-mode: screen;
}
.hero-inner { z-index: 2; }
.hero-title { font-size: clamp(56px, min(12vw, 15.5vh), 160px); letter-spacing: .01em; line-height: .92; }
.hero-seal { width: clamp(84px, 13vh, 132px); height: auto; }
@media (max-width: 560px) { .hero-title { font-size: clamp(52px, 17vw, 96px); } }
.ht-line2 span { background: linear-gradient(180deg, #ffe9a6 10%, var(--gold-bright) 50%, #7a5f12 98%); -webkit-background-clip: text; background-clip: text; }
.hero-tag { font-style: italic; }
.hero-tag b { font-style: normal; background: var(--red); color: var(--parchment); padding: 2px 10px; display: inline-block; transform: rotate(-1.5deg); }
.hero-stats { gap: 0; margin-top: 32px; }
.hero { padding-top: 48px; }
.hero-stats .stat { padding: 0 34px; }
.hero-stats .stat + .stat { border-left: 1px solid rgba(201,162,39,.35); }
.stat-num { font-size: 48px; font-variant-numeric: tabular-nums; }
@media (max-width: 560px) {
  .hero-stats .stat { padding: 0 16px; }
  .stat-num { font-size: 34px; }
  .stat span { font-size: 10px; letter-spacing: .1em; }
}

/* ---------- The term: progress line + chip ---------- */
.x-term-line { position: fixed; top: 0; left: 0; right: 0; height: 3px; z-index: 80; pointer-events: none; }
.x-term-line i {
  display: block; height: 100%; transform-origin: 0 50%; transform: scaleX(0);
  background: linear-gradient(90deg, var(--gold-dim), var(--gold-bright) 70%, var(--red-bright));
}
.x-term-chip {
  position: fixed; left: 16px; bottom: 16px; z-index: 70; pointer-events: none;
  background: rgba(7,11,20,.92); border: 1px solid rgba(201,162,39,.5);
  padding: 8px 12px; max-width: 250px; font-family: var(--mono);
  box-shadow: 0 8px 24px rgba(0,0,0,.5);
}
.x-term-chip b { display: block; font-size: 11px; letter-spacing: .2em; color: var(--gold-bright); }
.x-term-chip span { display: block; font-size: 11px; color: var(--text-dim); margin-top: 2px; line-height: 1.4; }
@media (max-width: 760px) { .x-term-chip { display: none; } }

/* ---------- The official poll ---------- */
.x-poll {
  background: var(--red); color: var(--parchment); padding: 44px 24px 40px; text-align: center;
  background-image: repeating-linear-gradient(135deg, rgba(0,0,0,.07) 0 14px, transparent 14px 28px);
  border-bottom: 3px solid var(--gold); position: relative; z-index: 4;
}
.x-poll-tag { font-family: var(--mono); font-size: 11.5px; letter-spacing: .3em; text-transform: uppercase; opacity: .85; }
.x-poll h2 { color: #fff7e2; font-size: clamp(30px, 5vw, 54px); margin: 8px 0 20px; }
.x-poll-btns { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; position: relative; min-height: 52px; }
.x-poll-btns .btn { min-width: 150px; }
.x-poll-no { color: #fff7e2; border-color: rgba(255,247,226,.7); transition: transform .28s var(--ease-out), background .2s; }
.x-poll-result { margin-top: 20px; font-family: var(--mono); font-size: 13px; min-height: 2.8em; }

/* ---------- Take the Desk ---------- */
.x-desk {
  background:
    radial-gradient(ellipse at 50% 0%, rgba(201,162,39,.14), transparent 55%),
    linear-gradient(180deg, #0b1226, #060910);
}
.x-desk-board {
  display: grid; grid-template-columns: 300px 1fr; gap: 32px; margin-top: 44px; align-items: start;
  max-width: 1020px; margin-left: auto; margin-right: auto;
}
@media (max-width: 860px) { .x-desk-board { grid-template-columns: 1fr; gap: 20px; } }
.x-meters { background: rgba(14,23,48,.85); border: 1px solid rgba(201,162,39,.3); padding: 22px 20px; }
.x-meter { display: grid; grid-template-columns: 86px 1fr 30px; align-items: center; gap: 10px; margin-bottom: 12px; font-family: var(--mono); font-size: 11.5px; letter-spacing: .08em; text-transform: uppercase; color: var(--text-dim); }
.x-meter b { text-align: right; color: var(--parchment); font-variant-numeric: tabular-nums; }
.x-bar { height: 10px; background: rgba(255,255,255,.08); overflow: hidden; }
.x-bar i { display: block; height: 100%; width: 50%; background: linear-gradient(90deg, #5d7bd1, #9fb4ec); transition: width .7s var(--ease-out), background .3s; }
.x-bar i.low { background: linear-gradient(90deg, var(--red), var(--red-bright)); }
.x-meter-auth { padding-bottom: 14px; margin-bottom: 16px; border-bottom: 1px solid rgba(201,162,39,.3); color: var(--gold-bright); }
.x-meter-auth .x-bar { height: 14px; }
.x-meter-auth .x-bar i { width: 10%; background: linear-gradient(90deg, var(--gold-dim), var(--gold-bright)); }
.x-meters-note { font-size: 13px; font-style: italic; color: var(--text-dim); margin-top: 16px; line-height: 1.5; }
@media (max-width: 860px) {
  .x-meters { display: grid; grid-template-columns: 1fr 1fr; gap: 0 18px; padding: 16px; }
  .x-meter-auth { grid-column: 1 / -1; }
  .x-meters-note { display: none; }
  .x-meter { grid-template-columns: 70px 1fr 26px; font-size: 10.5px; }
}

.x-card {
  background: var(--paper); color: var(--ink); padding: 30px 32px 32px; position: relative;
  box-shadow: 0 30px 70px rgba(0,0,0,.65), 0 0 0 1px rgba(28,23,16,.4);
  background-image: linear-gradient(rgba(28,23,16,.045) 1px, transparent 1px); background-size: 100% 30px;
  min-height: 420px;
}
.x-card::before { /* the paperclip of state */
  content: ''; position: absolute; top: -14px; left: 40px; width: 18px; height: 46px;
  border: 3px solid #9aa0ab; border-radius: 10px; border-bottom-color: transparent; transform: rotate(-6deg);
}
.x-card.deal { animation: xDeal .55s var(--ease-out); }
@keyframes xDeal { from { transform: translateY(26px) rotate(1.6deg); opacity: 0; } to { transform: none; opacity: 1; } }
.x-card-top { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-bottom: 14px; }
.x-card-month { font-family: var(--mono); font-size: 11.5px; letter-spacing: .2em; text-transform: uppercase; color: #6c6350; }
.x-card-stamp {
  font-family: var(--mono); font-size: 10.5px; letter-spacing: .18em; text-transform: uppercase;
  color: var(--red); border: 2px solid var(--red); padding: 3px 8px; transform: rotate(3deg);
}
.x-card-who { font-family: var(--mono); font-size: 12.5px; color: var(--red); letter-spacing: .04em; }
.x-card h3 { font-family: var(--poster); font-size: clamp(30px, 4.6vw, 46px); line-height: 1; text-transform: uppercase; margin: 6px 0 12px; color: var(--ink); text-wrap: balance; }
.x-card-text { font-size: 18px; line-height: 1.6; color: #2b261c; margin-bottom: 22px; max-width: 60ch; }
.x-choices { display: grid; gap: 10px; }
.x-choice {
  text-align: left; font-family: var(--serif); font-size: 16.5px; line-height: 1.4; color: var(--ink);
  background: #fffaf0; border: 2px solid var(--ink); padding: 13px 16px 13px 46px; cursor: pointer; position: relative;
  box-shadow: 4px 4px 0 rgba(28,23,16,.85); transition: transform .15s, box-shadow .15s, background .15s;
}
.x-choice::before { content: '\2610'; position: absolute; left: 15px; top: 50%; transform: translateY(-50%); font-size: 20px; }
.x-choice:hover, .x-choice:focus-visible { transform: translate(-2px, -2px); box-shadow: 7px 7px 0 var(--red); background: #fff; }
.x-choice:hover::before, .x-choice:focus-visible::before { content: '\2611'; color: var(--red); }
.x-choice:active { transform: translate(2px, 2px); box-shadow: 1px 1px 0 rgba(28,23,16,.85); }
.x-result p span { display: block; font-size: 18px; line-height: 1.6; font-style: italic; color: #2b261c; border-left: 4px solid var(--red); padding-left: 16px; }
.x-result p small { display: block; margin: 14px 0 20px; font-family: var(--mono); font-size: 12px; letter-spacing: .06em; color: #6c6350; }
.x-card.verdict { background-image: none; border-top: 10px solid var(--ink); }
.x-card.verdict h3 { font-size: clamp(32px, 5vw, 54px); border-bottom: 3px double var(--ink); padding-bottom: 14px; }
.x-card.verdict .x-choices { display: flex; flex-wrap: wrap; gap: 14px; }
.x-card.verdict .btn-line { color: var(--ink); border-color: var(--ink); }
.x-card.verdict .x-card-stamp { display: none; }
@media (max-width: 560px) { .x-card { padding: 26px 20px; } .x-card-text { font-size: 17px; } }

/* ---------- The Signing Desk ---------- */
.x-orders {
  background: var(--parchment); color: var(--ink);
  background-image: radial-gradient(ellipse at 80% 0%, rgba(179,40,45,.08), transparent 50%);
}
.x-orders .kicker { color: var(--red); }
.x-orders .kicker.center::before, .x-orders .kicker.center::after { background: linear-gradient(90deg, transparent, var(--red)); }
.x-orders h2 { color: var(--ink); }
.x-orders .section-sub { color: #4d4636; }
.x-orders-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 44px; margin-top: 44px; align-items: start; }
@media (max-width: 900px) { .x-orders-grid { grid-template-columns: 1fr; gap: 28px; } }
.x-order-form label { display: block; font-family: var(--serif); font-style: italic; font-size: 18px; margin: 14px 0 6px; color: #2b261c; }
.x-order-form label:first-child { margin-top: 0; }
.x-order-form select {
  width: 100%; font-family: var(--serif); font-size: 17px; padding: 12px 40px 12px 14px; color: var(--ink);
  background: #fffaf0 url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8'%3E%3Cpath d='M1 1l5 5 5-5' fill='none' stroke='%231c1710' stroke-width='2'/%3E%3C/svg%3E") right 14px center no-repeat;
  border: 2px solid var(--ink); border-radius: 0; appearance: none; -webkit-appearance: none; cursor: pointer;
}
.x-order-actions { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 24px; }
.x-order-actions .btn-line { color: var(--ink); border-color: var(--ink); }
.x-order-actions .btn-line:hover { color: var(--red); border-color: var(--red); background: transparent; }
.x-order-count { margin-top: 18px; font-family: var(--mono); font-size: 12px; color: #6c6350; }
.x-order-doc {
  background: #fffdf6; border: 1px solid #b7a97f; padding: 34px 34px 28px; position: relative;
  box-shadow: 0 0 0 12px #2a1a12, 0 0 0 14px var(--gold-dim), 0 34px 60px rgba(28,23,16,.4);
  margin: 14px; transform: rotate(1.2deg); transition: transform .5s var(--ease-out);
}
.x-order-doc.signed { transform: rotate(-.6deg); }
.x-order-seal { position: absolute; top: 18px; right: 20px; opacity: .85; }
.x-order-head { font-family: var(--poster); font-size: 24px; letter-spacing: .08em; text-transform: uppercase; padding-right: 76px; }
.x-order-body { font-size: 19px; line-height: 1.65; margin: 16px 0 6px; min-height: 5em; }
.x-order-sig svg { width: min(100%, 340px); height: 90px; display: block; }
.x-order-sig span { display: block; border-top: 1px solid var(--ink); font-family: var(--mono); font-size: 10.5px; letter-spacing: .2em; text-transform: uppercase; padding-top: 4px; width: min(100%, 340px); color: #6c6350; }
.x-order-outcome {
  margin-top: 20px; font-family: var(--marker); font-size: 19px; line-height: 1.35; color: var(--red);
  border: 3px solid var(--red); padding: 10px 14px; transform: rotate(-2deg); animation: xStamp .35s var(--ease-out);
}
@keyframes xStamp { from { transform: rotate(-2deg) scale(1.5); opacity: 0; } to { transform: rotate(-2deg) scale(1); opacity: 1; } }
.x-copy {
  margin-top: 16px; font-family: var(--mono); font-size: 12px; letter-spacing: .1em; text-transform: uppercase;
  background: none; border: none; border-bottom: 2px solid currentColor; color: var(--red); cursor: pointer; padding: 2px 0;
}
.x-copy:hover { color: var(--ink); }

/* ---------- The Director of Posting ---------- */
.x-post { background: linear-gradient(180deg, var(--navy-deep), #0e1730 55%, var(--navy-deep)); }
.x-post-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 44px; margin-top: 44px; align-items: center; max-width: 1000px; margin-left: auto; margin-right: auto; }
@media (max-width: 860px) { .x-post-grid { grid-template-columns: 1fr; gap: 26px; } }
.x-post-in label { display: block; font-family: var(--mono); font-size: 12px; letter-spacing: .2em; text-transform: uppercase; color: var(--gold); margin-bottom: 8px; }
.x-post-in textarea {
  width: 100%; font-family: var(--serif); font-size: 18px; line-height: 1.55; padding: 16px; resize: vertical;
  background: var(--paper); color: var(--ink); border: 2px solid transparent; border-radius: 0;
}
.x-post-in textarea:focus { outline: none; border-color: var(--gold-bright); }
.x-post-actions { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 16px; }
.x-phone {
  background: #05070d; border: 2px solid #2a3350; border-radius: 34px; padding: 44px 14px 30px;
  box-shadow: 0 30px 60px rgba(0,0,0,.6), inset 0 0 0 2px #10162a; position: relative; max-width: 420px; margin: 0 auto; width: 100%;
}
.x-phone::before { content: ''; position: absolute; top: 16px; left: 50%; width: 84px; height: 10px; margin-left: -42px; background: #161d33; border-radius: 6px; }
.x-chirp { background: #fff; color: #14171f; border-radius: 14px; padding: 16px 16px 12px; font-family: system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif; }
.x-chirp-head { display: flex; gap: 10px; align-items: center; margin-bottom: 10px; }
.x-chirp-head img { border-radius: 50%; background: var(--navy); }
.x-chirp-head b { display: block; font-size: 15px; }
.x-chirp-head small { color: #6b7280; font-size: 12.5px; }
.x-tick { display: inline-grid; place-items: center; width: 16px; height: 16px; border-radius: 50%; background: var(--gold); color: #fff; font-size: 10px; vertical-align: 1px; }
.x-chirp-body { font-size: 17px; line-height: 1.5; font-weight: 500; overflow-wrap: anywhere; }
.x-chirp-foot { display: flex; justify-content: space-between; align-items: center; margin-top: 12px; padding-top: 10px; border-top: 1px solid #e5e7eb; color: #6b7280; font-size: 13px; }
.x-chirp-foot b { color: #b3282d; font-variant-numeric: tabular-nums; }
.x-chirp-foot .x-copy { margin: 0; }

/* ---------- The Files ---------- */
.x-files { background: #0a0d14; }
.x-folder {
  background: #d9bf8a; color: #1c1710; margin-top: 40px; padding: 40px 34px 26px; position: relative;
  box-shadow: 0 26px 50px rgba(0,0,0,.6); border-radius: 0 6px 6px 6px;
  background-image: linear-gradient(105deg, rgba(255,255,255,.14), transparent 40%);
}
.x-folder-tab {
  position: absolute; top: -28px; left: 0; background: #d9bf8a; padding: 6px 18px 4px; border-radius: 6px 6px 0 0;
  font-family: var(--mono); font-size: 11.5px; letter-spacing: .18em; text-transform: uppercase;
}
.x-folder p { font-family: var(--mono); font-size: 15.5px; line-height: 2.1; }
.x-redact {
  font: inherit; border: none; cursor: pointer; background: #0c0c0c; color: #0c0c0c; padding: 2px 8px; margin: 0 2px;
  transition: background .3s, color .3s; border-radius: 1px;
}
.x-redact:hover { background: #2b2b2b; color: #2b2b2b; }
.x-redact.done { background: #0c0c0c; color: #f3d98b; cursor: default; letter-spacing: .04em; }
.x-folder-foot { margin-top: 18px; padding-top: 14px; border-top: 1px dashed rgba(28,23,16,.5); font-style: italic; font-family: var(--serif) !important; font-size: 16px !important; line-height: 1.5 !important; }
@media (max-width: 560px) { .x-folder { padding: 34px 20px 22px; } .x-folder p { font-size: 14px; } }

/* ---------- Existing sections, sharpened ---------- */
.feature { transition: transform .25s var(--ease-out), border-color .3s, box-shadow .3s; will-change: transform; }
.feature h3 { font-size: 24px; }
.quote { border-top: 3px solid var(--gold-dim); }
.portrait-frame { outline: 10px solid #2a1a12; box-shadow: 0 0 0 12px var(--gold-dim), 0 30px 70px rgba(0,0,0,.7); margin: 12px; }
.letter p:first-child::first-letter { font-family: var(--poster); font-size: 3.4em; float: left; line-height: .85; padding: 6px 10px 0 0; color: var(--gold-bright); }
.faq-list details[open] summary { color: var(--gold-bright); }

@media (prefers-reduced-motion: reduce) {
  .x-card.deal, .x-order-outcome { animation: none; }
  .x-bar i, .x-poll-no, .x-order-doc { transition: none; }
}

/* ---------- Phone refinements ---------- */
@media (max-width: 560px) {
  .hero { padding-top: 28px; }
  .hero-seal { width: 76px; margin-bottom: 10px; }
  .hero-sub { font-size: 15.5px; margin: 12px auto 20px; }
  .hero-ctas .btn-big { padding: 13px 22px; font-size: 16px; width: 100%; }
  .x-meters { grid-template-columns: 1fr; }
  .x-meter { grid-template-columns: 84px 1fr 28px; margin-bottom: 9px; }
  .x-poll-btns .btn { min-width: 0; flex: 1 1 130px; }
  .x-order-doc { padding: 26px 20px 22px; margin: 12px 6px; }
  .x-order-body { font-size: 17px; }
}
