/* AnyRequests — shared theme and components.
   Palette is defined in js/themes.js (CORE) and mirrored here as the
   defaults; the punter page overrides these variables per artist theme.
   Verified by scripts/check-contrast.mjs — change colours there first. */

:root {
  --bg: #06040A;
  --card: #140E1C;
  --card-alt: #1D1528;
  --border: #3A2B52;
  --input-bg: #0D0813;
  --input-border: #3A2D52;
  --text: #F4EFF9;
  --muted: #A79FB3;
  --accent: #A939E7;
  --accent-hover: #9B2BD9;
  --accent-active: #8A1FC4;
  --accent-ink: #FFFFFF;
  --accent-text: #C07EF2;
  --accent-soft: #D9B3F5;
  --green: #3FD99A;
  --green-ink: #06040A;
  --red: #FF8A9C;
  --red-bg: #3A1620;
  --font: system-ui, -apple-system, 'Segoe UI', sans-serif;
  --radius: 14px;
  --radius-lg: 20px;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
}

.muted { color: var(--muted); }
.hidden { display: none !important; }

h1 { font-size: 36px; letter-spacing: -.04em; margin: 8px 0; }

.eyebrow {
  text-transform: uppercase;
  letter-spacing: .14em;
  font-size: 13px;
  font-weight: 700;
}

/* ------------------------------------------------------------ identity --- */

/* Torn paper edge — used as a section divider and on card bottoms.
   The SVG is the divider's own jagged silhouette, tiled horizontally. */
.torn-edge {
  height: 14px;
  background: var(--card);
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 120 14' preserveAspectRatio='none'%3E%3Cpath d='M0 0h120v4l-8 6-9-5-8 7-11-6-9 5-10-7-9 8-11-5-8 5-10-6-9 7-9-6-9 4z'/%3E%3C/svg%3E") repeat-x;
  -webkit-mask-size: 120px 14px;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 120 14' preserveAspectRatio='none'%3E%3Cpath d='M0 0h120v4l-8 6-9-5-8 7-11-6-9 5-10-7-9 8-11-5-8 5-10-6-9 7-9-6-9 4z'/%3E%3C/svg%3E") repeat-x;
  mask-size: 120px 14px;
}

/* Ruled-line motif — the slip's lines, as a quiet backdrop accent. */
.ruled {
  background-image: repeating-linear-gradient(
    to bottom,
    transparent 0 26px,
    color-mix(in srgb, var(--accent) 14%, transparent) 26px 28px
  );
}

/* Subtle paper grain for large surfaces (very low contrast, decorative). */
.paper-grain {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='140' height='140'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2'/%3E%3CfeColorMatrix values='0 0 0 0 1 0 0 0 0 1 0 0 0 0 1 0 0 0 .035 0'/%3E%3C/filter%3E%3Crect width='140' height='140' filter='url(%23n)'/%3E%3C/svg%3E");
}

.brand-row {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  color: var(--text);
  text-decoration: none;
  font-weight: 800;
}
.brand-row img { width: 26px; height: 26px; }

/* --------------------------------------------------------- components --- */

.card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 22px;
}

label { font-weight: 800; }

input, select, textarea {
  width: 100%;
  height: 58px;
  border-radius: var(--radius);
  border: 1px solid var(--input-border);
  background: var(--input-bg);
  color: var(--text);
  padding: 0 16px;
  font-size: 16px;
  font-family: var(--font);
  outline: none;
}

textarea { height: auto; padding: 12px 16px; }

input:focus, textarea:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 18%, transparent);
}

button {
  border: 0;
  border-radius: var(--radius);
  font-weight: 800;
  font-size: 16px;
  color: var(--text);
  font-family: var(--font);
  cursor: pointer;
}

button:disabled { opacity: .6; cursor: not-allowed; }

.btn-primary {
  background: var(--accent);
  color: var(--accent-ink);
}
.btn-primary:hover:not(:disabled) { background: var(--accent-hover, var(--accent)); }
.btn-primary:active:not(:disabled) { background: var(--accent-active, var(--accent)); }

.btn-quiet { background: var(--border); }

.btn-ghost {
  background: transparent;
  border: 1px solid var(--input-border);
}

.error {
  display: none;
  color: var(--red);
  margin-top: 10px;
}

.success-text { color: var(--green); }

.empty {
  text-align: center;
  color: var(--muted);
  padding: 18px;
}

a { color: var(--accent-text); }
