/* Vice Coast Cover Studio — dark neon editor UI. Deep plum panels, hot-pink and
   cyan accents, gold highlights: the editor should feel like the cover it makes. */

@font-face {
  font-family: 'Anton';
  src: url('fonts/Anton-Regular.ttf') format('truetype');
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: 'Pacifico';
  src: url('fonts/Pacifico-Regular.ttf') format('truetype');
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

:root {
  --ink-bg: #0e0718;
  --ink-bg2: #160b28;
  --ink-card: #1c1032;
  --ink-card2: #251743;
  --ink-line: #3d2563;
  --ink-text: #f5eeff;
  --ink-dim: #bca9da;
  --ink-pink: #ff2e88;
  --ink-pink-soft: #ff7ad9;
  --ink-cyan: #22e6ff;
  --ink-gold: #ffb347;
  --corner: 14px;
}

* { box-sizing: border-box; }

html, body { margin: 0; padding: 0; }

body {
  background:
    radial-gradient(900px 500px at 85% -10%, rgba(255, 46, 136, 0.22), transparent 60%),
    radial-gradient(800px 480px at -10% 10%, rgba(34, 230, 255, 0.12), transparent 60%),
    linear-gradient(180deg, var(--ink-bg), #0a0512 70%);
  color: var(--ink-text);
  font-family: system-ui, -apple-system, 'Segoe UI', sans-serif;
  min-height: 100vh;
}

.masthead {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  align-items: center;
  justify-content: space-between;
  padding: 20px 28px 8px;
  max-width: 1360px;
  margin: 0 auto;
}

.masthead-brand { display: flex; gap: 14px; align-items: center; }

.logo {
  width: 52px;
  height: 52px;
  display: grid;
  place-items: center;
  font-size: 26px;
  color: #1c1032;
  background: linear-gradient(135deg, var(--ink-gold), var(--ink-pink));
  border-radius: 14px;
  box-shadow: 0 0 24px rgba(255, 46, 136, 0.45);
}

.masthead h1 {
  font-family: Anton, 'Arial Black', sans-serif;
  font-weight: 400;
  font-size: 30px;
  letter-spacing: 1px;
  margin: 0;
  line-height: 1;
}

.masthead h1 em {
  font-style: normal;
  background: linear-gradient(90deg, var(--ink-gold), var(--ink-pink-soft));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.strapline { margin: 5px 0 0; color: var(--ink-dim); font-size: 13px; }

.assurances {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  list-style: none;
  margin: 0;
  padding: 0;
}

.assurances li {
  font-size: 12px;
  padding: 6px 11px;
  border: 1px solid var(--ink-line);
  border-radius: 999px;
  background: rgba(28, 16, 50, 0.8);
  color: var(--ink-dim);
}

.workbench {
  max-width: 1360px;
  margin: 0 auto;
  padding: 18px 28px 8px;
  display: grid;
  grid-template-columns: 380px 1fr;
  gap: 22px;
  align-items: start;
}

.panel { display: flex; flex-direction: column; gap: 16px; }

.block {
  background: linear-gradient(180deg, var(--ink-card2), var(--ink-card));
  border: 1px solid var(--ink-line);
  border-radius: var(--corner);
  padding: 16px 18px;
  box-shadow: 0 8px 28px rgba(0, 0, 0, 0.35);
}

.block h2 {
  font-family: Anton, 'Arial Black', sans-serif;
  font-weight: 400;
  font-size: 17px;
  letter-spacing: 1.5px;
  margin: 0 0 12px;
  color: #ffe9f5;
}

.note { color: var(--ink-dim); font-size: 13px; line-height: 1.5; margin: 0 0 12px; }

.actions { display: flex; gap: 8px; flex-wrap: wrap; }

.button {
  font: inherit;
  font-size: 14px;
  font-weight: 600;
  color: var(--ink-text);
  background: #2d1b4e;
  border: 1px solid var(--ink-line);
  border-radius: 10px;
  padding: 9px 14px;
  cursor: pointer;
  transition: transform 0.08s ease, box-shadow 0.15s ease, background 0.15s ease;
}

.button:hover { background: #3b2366; box-shadow: 0 0 0 1px var(--ink-pink-soft); }
.button:active { transform: translateY(1px); }

.button.accent {
  background: linear-gradient(135deg, var(--ink-pink), #b02a9e);
  border-color: transparent;
  box-shadow: 0 4px 18px rgba(255, 46, 136, 0.4);
}

.button.accent:hover { background: linear-gradient(135deg, #ff4d9c, #c933b0); }
.button.small { font-size: 12px; padding: 7px 10px; }
.button:disabled { opacity: 0.5; cursor: default; box-shadow: none; }

.tray {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
  margin-bottom: 12px;
}

.thumb {
  border: 2px solid transparent;
  border-radius: 10px;
  padding: 0;
  background: none;
  cursor: pointer;
  overflow: hidden;
  position: relative;
}

.thumb img { width: 100%; height: 64px; object-fit: cover; display: block; }
.thumb span {
  position: absolute;
  left: 0; right: 0; bottom: 0;
  font-size: 10px;
  padding: 2px 4px;
  background: rgba(13, 5, 24, 0.75);
  color: #fff;
  text-align: left;
}

.thumb:hover { border-color: var(--ink-pink-soft); }
.thumb.in-use { border-color: var(--ink-gold); }

.slots { display: flex; flex-direction: column; gap: 8px; margin-top: 14px; }

.slot-row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 10px;
  border: 1px solid var(--ink-line);
  border-radius: 10px;
  background: rgba(13, 7, 22, 0.5);
  cursor: pointer;
}

.slot-row.picked { border-color: var(--ink-gold); box-shadow: 0 0 0 1px var(--ink-gold); }

.slot-row img { width: 44px; height: 44px; object-fit: cover; border-radius: 7px; }

.slot-name { flex: 1; font-size: 13px; }
.slot-name small { display: block; color: var(--ink-dim); font-size: 11px; }

.slot-row .swap-btn {
  font: inherit;
  font-size: 11px;
  color: var(--ink-cyan);
  background: none;
  border: 1px solid var(--ink-line);
  border-radius: 7px;
  padding: 5px 8px;
  cursor: pointer;
}

.picker { display: grid; grid-template-columns: repeat(auto-fill, minmax(105px, 1fr)); gap: 8px; }

.pick {
  font: inherit;
  font-size: 13px;
  font-weight: 600;
  color: var(--ink-text);
  background: #251743;
  border: 2px solid var(--ink-line);
  border-radius: 10px;
  padding: 10px 8px;
  cursor: pointer;
  text-align: center;
}

.pick:hover { border-color: var(--ink-pink-soft); }
.pick.on { border-color: var(--ink-gold); background: #342060; box-shadow: 0 0 14px rgba(255, 179, 71, 0.25); }
.pick small { display: block; font-weight: 400; color: var(--ink-dim); font-size: 11px; margin-top: 2px; }

.swatch-picker .pick { padding: 0; overflow: hidden; }
.swatch-picker .pick .swatch { height: 34px; display: block; }
.swatch-picker .pick .swatch-label { display: block; padding: 7px 4px; font-size: 12px; }

.field { display: block; margin-bottom: 12px; }
.field > span { display: block; font-size: 13px; color: var(--ink-dim); margin-bottom: 6px; }
.field input[type="text"] {
  width: 100%;
  font: inherit;
  font-size: 15px;
  color: var(--ink-text);
  background: #12081f;
  border: 1px solid var(--ink-line);
  border-radius: 10px;
  padding: 10px 12px;
  outline: none;
}
.field input[type="text"]:focus { border-color: var(--ink-pink); box-shadow: 0 0 0 2px rgba(255, 46, 136, 0.3); }

#headlineInput { font-family: Anton, 'Arial Black', sans-serif; letter-spacing: 1px; font-size: 18px; }
#taglineInput { font-family: Pacifico, cursive; font-size: 16px; }

.ink-row { display: flex; gap: 8px; flex-wrap: wrap; }
.ink-dot {
  width: 34px; height: 34px;
  border-radius: 50%;
  border: 2px solid transparent;
  cursor: pointer;
  padding: 0;
}
.ink-dot.on { border-color: #fff; box-shadow: 0 0 0 2px var(--ink-gold), 0 0 12px rgba(255, 179, 71, 0.5); }

.slider output { float: right; color: var(--ink-gold); font-size: 12px; }
input[type="range"] { width: 100%; accent-color: var(--ink-pink); }

.export-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.export-grid .button { padding: 12px 8px; }

.export-note { font-size: 13px; color: var(--ink-cyan); min-height: 18px; margin: 10px 0 0; }

.stage { position: sticky; top: 12px; }

.stage-top { display: flex; align-items: baseline; justify-content: space-between; margin-bottom: 10px; }
.stage-top h2 {
  font-family: Anton, 'Arial Black', sans-serif;
  font-weight: 400;
  font-size: 17px;
  letter-spacing: 1.5px;
  margin: 0;
}
.stage-size { color: var(--ink-dim); font-size: 12px; }

.stage-wrap {
  position: relative;
  border: 1px solid var(--ink-line);
  border-radius: var(--corner);
  overflow: hidden;
  background: #12081f;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.5);
}

#stageCanvas { width: 100%; height: auto; display: block; cursor: grab; touch-action: none; }
#stageCanvas.grabbing { cursor: grabbing; }

.stage-hint {
  position: absolute;
  right: 10px; top: 10px;
  font-size: 11px;
  color: rgba(255, 255, 255, 0.85);
  background: rgba(13, 5, 24, 0.72);
  border-radius: 999px;
  padding: 5px 10px;
  pointer-events: none;
}

.stage-bottom { display: flex; gap: 10px; align-items: center; margin-top: 12px; }
.stage-bottom span { flex: 1; font-size: 13px; color: var(--ink-dim); }

.colophon {
  max-width: 1360px;
  margin: 0 auto;
  padding: 10px 28px 28px;
  color: var(--ink-dim);
  font-size: 12px;
  line-height: 1.6;
}

.colophon strong { color: var(--ink-text); }

@media (max-width: 980px) {
  .workbench { grid-template-columns: 1fr; }
  .stage { position: static; }
  .masthead { padding: 16px 16px 4px; }
  .workbench, .colophon { padding-left: 16px; padding-right: 16px; }
}

/* Full-frame cover scene (used by ?shot=cover): the cover is the whole page. */
body.shot-cover { background: #12081f; margin: 0; }
body.shot-cover .masthead, body.shot-cover .workbench, body.shot-cover .colophon { display: none; }
body.shot-cover #shotCanvas { display: block; width: 100vw; height: 100vh; object-fit: contain; }
