@import url('https://fonts.googleapis.com/css2?family=Bebas+Neue&family=Inter:wght@400;500;600;700;800&family=JetBrains+Mono:wght@400;500;600&display=swap');

:root {
    --bg: #0c0a08;
    --panel: #171310;
    --panel-2: #1e1813;
    --border: #332a20;
    --text: #f3ede2;
    --sub: #a6997f;
    --amber: #ffb020;
    --amber-2: #ff8a1f;
    --teal: #00c2a0;
    --rose: #ff4d6d;
    --mono: 'JetBrains Mono', monospace;
    --sans: 'Inter', sans-serif;
    --display: 'Bebas Neue', sans-serif;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    background:
        radial-gradient(ellipse 1000px 500px at 50% -12%, rgba(255, 176, 32, .10), transparent 60%),
        var(--bg);
    color: var(--text);
    font-family: var(--sans);
    padding: 0 0 90px;
    position: relative;
}

/* sprocket-hole film strip edges */
body::before,
body::after {
    content: '';
    position: fixed;
    top: 0;
    bottom: 0;
    width: 26px;
    background-image: radial-gradient(circle, var(--panel-2) 5px, transparent 5.5px);
    background-size: 26px 34px;
    background-repeat: repeat-y;
    background-position: center 10px;
    opacity: .55;
    z-index: 0;
}

body::before {
    left: 0;
}

body::after {
    right: 0;
}

.wrap {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 34px;
    position: relative;
    z-index: 1;
}

/* ---- slate header ---- */
.slate {
    margin-top: 0;
    background:
        repeating-linear-gradient(-45deg, #17130f, #17130f 22px, #1d1710 22px, #1d1710 44px);
    border-bottom: 3px solid var(--amber);
    padding: 14px 34px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-family: var(--mono);
    font-size: 11px;
    letter-spacing: .1em;
    color: var(--sub);
}

.slate .brand {
    display: flex;
    align-items: center;
    gap: 9px;
    color: var(--text);
    font-weight: 600;
}

.slate .mark {
    width: 24px;
    height: 24px;
    border-radius: 6px;
    background: linear-gradient(135deg, var(--amber), var(--amber-2));
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
    font-size: 13px;
    color: #1a1206;
    font-family: var(--sans);
}

.slate .take {
    color: var(--amber);
}

.header {
    text-align: center;
    padding: 56px 20px 40px;
}

.eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-family: var(--mono);
    font-size: 11px;
    letter-spacing: .18em;
    color: var(--teal);
    border: 1px solid rgba(0, 194, 160, .35);
    background: rgba(0, 194, 160, .07);
    padding: 6px 14px;
    border-radius: 3px;
}

.eyebrow .dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--teal);
    box-shadow: 0 0 8px var(--teal);
}

h1 {
    font-family: var(--display);
    font-size: clamp(56px, 11vw, 96px);
    line-height: .86;
    margin: 20px 0 16px;
    letter-spacing: .01em;
    color: var(--text);
    text-transform: uppercase;
}

h1 .hl {
    color: var(--amber);
}

.tagline {
    color: var(--sub);
    font-size: 15.5px;
    max-width: 460px;
    margin: 0 auto;
    line-height: 1.6;
}

/* ---- two-column layout ---- */
.layout {
    display: grid;
    grid-template-columns: 500px 1fr;
    gap: 34px;
    align-items: start;
    margin-top: 20px;
}

.options-col {
    position: sticky;
    top: 24px;
    background: var(--panel);
    border: 1px solid var(--border);
    border-radius: 6px;
    padding: 22px 20px 26px;
}

.options-col .section-label {
    margin: 26px 0 12px;
}

.options-col .section-label:first-child {
    margin-top: 0;
}

.variations-col {
    min-width: 0;
}

@media(max-width:860px) {
    .layout {
        grid-template-columns: 1fr;
    }

    .options-col {
        position: static;
    }
}

/* ---- section label: timecode style ---- */
.section-label {
    font-family: var(--mono);
    font-size: 11.5px;
    letter-spacing: .14em;
    color: var(--sub);
    text-transform: uppercase;
    margin: 0px 0 14px;
    display: flex;
    align-items: center;
    gap: 14px;
}

.section-label .tc {
    color: var(--amber);
    font-weight: 600;
}

.section-label::after {
    content: '';
    flex: 1;
    height: 1px;
    background: var(--border);
}

/* ---- pill selectors ---- */
.pillrow {
    display: grid;
    gap: 10px;
}

.pillrow.cols-1 {
    grid-template-columns: repeat(3, 1fr);
}

.pillrow.cols-2 {
    grid-template-columns: repeat(2, 1fr);
}

.pillrow.cols-4 {
    grid-template-columns: repeat(4, 1fr);
}

.pillrow.cols-3 {
    grid-template-columns: repeat(3, 1fr);
}

.options-col .pill {
    padding: 12px 10px;
}

.pill {
    background: var(--panel-2);
    border: 1px solid var(--border);
    border-radius: 4px;
    padding: 14px 8px;
    text-align: center;
    cursor: pointer;
    transition: .15s ease;
}

.pill:hover {
    border-color: #544732;
}

.pill .val {
    font-weight: 700;
    font-size: 15px;
    font-family: var(--sans);
}

.pill .lbl {
    font-family: var(--mono);
    font-size: 9.5px;
    color: var(--sub);
    letter-spacing: .08em;
    margin-top: 3px;
}

.pill.active {
    border-color: transparent;
    color: #181206;
}

.pill.active .lbl {
    color: rgba(24, 18, 6, .65);
}

.accent-a.active {
    background: linear-gradient(135deg, var(--amber), var(--amber-2));
}

.accent-b.active {
    background: linear-gradient(135deg, var(--teal), #5df2c8);
}

.accent-c.active {
    background: linear-gradient(135deg, var(--rose), #ff8a9f);
}

/* ---- shuffle button ---- */
.shuffle-wrap {
    text-align: center;
    margin: 28px 0 0;
}

#shuffleAll {
    width: 100%;
    font-family: var(--display);
    font-weight: 400;
    font-size: 17px;
    letter-spacing: .06em;
    background: linear-gradient(135deg, var(--amber), var(--amber-2));
    color: #1a1206;
    border: none;
    border-radius: 3px;
    padding: 15px 20px;
    cursor: pointer;
    box-shadow: 0 0 0 rgba(255, 176, 32, .5);
    transition: transform .12s ease, box-shadow .2s ease;
    text-transform: uppercase;
}

#shuffleAll:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 32px -6px rgba(255, 176, 32, .5);
}

#shuffleAll:active {
    transform: translateY(0);
}

.combos {
    text-align: center;
    font-family: var(--mono);
    font-size: 10.5px;
    color: var(--sub);
    margin-top: 12px;
    letter-spacing: .03em;
    line-height: 1.5;
}

.combos b {
    color: var(--teal);
}

/* ---- trait grid ---- */
.grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    margin-top: 0;
}

@media(max-width:640px) {
    .grid {
        grid-template-columns: 1fr;
    }

    .wrap {
        padding: 0 26px;
    }

    body::before,
    body::after {
        display: none;
    }
}

.card {
    background: var(--panel);
    border: 1px solid var(--border);
    border-left: 3px solid var(--border);
    border-radius: 4px;
    padding: 15px 16px 14px;
    transition: border-color .2s;
}

.card-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 9px;
}

.card-label {
    font-family: var(--mono);
    font-size: 10px;
    letter-spacing: .1em;
    color: var(--sub);
    text-transform: uppercase;
    display: flex;
    align-items: center;
    gap: 7px;
}

.card-actions {
    display: flex;
    gap: 6px;
}

.icon-btn {
    width: 25px;
    height: 25px;
    border-radius: 4px;
    border: 1px solid var(--border);
    background: var(--panel-2);
    color: var(--sub);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12.5px;
    transition: .15s;
}

.icon-btn:hover {
    border-color: #544732;
    color: var(--text);
}

.icon-btn.locked {
    background: rgba(255, 176, 32, .14);
    border-color: rgba(255, 176, 32, .45);
    color: var(--amber);
}

.card-text {
    font-size: 14px;
    line-height: 1.5;
    color: #dcd4c4;
    min-height: 38px;
}

/* ---- output panel ---- */
.output {
    background: var(--panel);
    border: 1px solid var(--border);
    border-radius: 6px;
    margin-top: 40px;
    padding: 0;
    position: relative;
    overflow: hidden;
}

.output-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 20px;
    border-bottom: 1px solid var(--border);
    background: var(--panel-2);
}

.output-title {
    font-family: var(--mono);
    font-size: 11px;
    letter-spacing: .16em;
    color: var(--amber);
    text-transform: uppercase;
    display: flex;
    align-items: center;
    gap: 9px;
}

.output-title .rec {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: var(--rose);
    box-shadow: 0 0 8px var(--rose);
}

#copyBtn {
    font-family: var(--mono);
    font-size: 11.5px;
    font-weight: 600;
    letter-spacing: .05em;
    background: var(--teal);
    color: #062a22;
    border: none;
    border-radius: 4px;
    padding: 8px 14px;
    cursor: pointer;
    transition: .15s;
}

#copyBtn:hover {
    filter: brightness(1.08);
}

#copyBtn.copied {
    background: #9fffdf;
}

.copy-toast {
    position: fixed;
    left: 50%;
    bottom: 26px;
    transform: translateX(-50%) translateY(20px);
    background: var(--panel);
    border: 1px solid var(--teal);
    color: var(--teal);
    font-family: var(--mono);
    font-size: 12.5px;
    letter-spacing: .03em;
    padding: 10px 18px;
    border-radius: 4px;
    opacity: 0;
    pointer-events: none;
    transition: opacity .2s ease, transform .2s ease;
    box-shadow: 0 10px 30px -8px rgba(0, 0, 0, .6);
    z-index: 100;
}

.copy-toast.show {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}

.prompt-text {
    font-family: var(--mono);
    font-size: 12.5px;
    line-height: 1.75;
    color: #c9c0ab;
    white-space: pre-wrap;
    padding: 20px;
}

footer {
    text-align: center;
    margin-top: 50px;
    color: var(--sub);
    font-family: var(--mono);
    font-size: 11px;
    padding-bottom: 10px;
}

footer a {
    color: var(--teal);
    text-decoration: none;
}