

*::-webkit-scrollbar-track{
    -moz-box-shadow: 0;
    -webkit-box-shadow: inset 0 0 2px rgba(0,0,0,0.9);
    box-shadow: inset 0 0 2px rgba(0,0,0,0.9);
    border-radius: 5px;
    background-color: silver;
}
*::-webkit-scrollbar{
    width: 11px;
}
*::-webkit-scrollbar-thumb{
    border-radius: 5px;
    background-color: limegreen;
    background-image: -webkit-linear-gradient(90deg,
    transparent,
    rgba(0, 0, 0, 0.4) 50%,
    transparent,
    transparent);
}

a { text-decoration: none; color: inherit; }

a:focus,
select:focus,
textarea:focus,
button:focus,
input:focus{ outline: none; }

button {
    letter-spacing: 0.05em;
    font-family: Georgia, sans-serif;
    font-size: 18px;
    border: none;
    border-radius: 5px;
    padding: 5px 15px;
    cursor: pointer;
}

select,
input[type="text"],
input[type="email"],
input[type="password"] {
    font-size: 16px;
    padding: 10px;
    border: none;
    border-radius: 5px;
}
select { padding: 5px 10px; }
input[type="checkbox"] {
    height: 20px;
    width: 20px;
}

body, html {
    background-color: #0d0d0d;
    color: #e0e0e0;
    letter-spacing: 0.05em;
    font-family: Georgia, serif;
    font-size: 16px;
    margin: 0;
    padding: 0;
}

/* BUTTONS */
.btn-gold {
    background: linear-gradient(135deg, #d4af37, #8c681f);
    color: #000;
    font-weight: bold;
    padding: 12px 24px;
    border-radius: 4px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    box-shadow: 0 0 10px rgba(212, 175, 55, 0.3);
}

.btn-outline {
    background: linear-gradient(135deg, #111, #333);
    border: 1px solid #d4af37;
    color: #d4af37;
    padding: 12px 24px;
    border-radius: 4px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}
/* END BUTTONS */



/* HEADER */
#game-header {
    position: fixed;
    top: 0;
    height: 180px;
    width: 100%;
    background-image: url('../imgs/AI-nimated.jpg');
    background-position: center 42%;
    background-size: cover;
    background-repeat: no-repeat;
    display: flex;
    align-items: center;
    justify-content: center;
    border-bottom: 2px solid #d4af37;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.85);
    z-index: 77;
}

#game-header::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    height: 180px;
    width: 100%;
    background: rgba(0, 0, 0, 0.55);
    z-index: 1;
}
/* END HEADER */



/* HEADER CONTENT */
#header-content {
    position: relative;
    text-align: center;
    z-index: 2;
}

#header-title {
    margin: 0;
    font-size: 2.2rem;
    color: #f3e5ab;
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.9), 0 0 12px rgba(212, 175, 55, 0.4);
    letter-spacing: 0.08em;
    cursor: default;
}

#header-slogan {
    margin: 6px 0 0 0;
    font-size: 1rem;
    color: #d4af37;
    text-shadow: 0 2px 6px rgba(0, 0, 0, 0.9);
    cursor: default;
}
/* END HEADER CONTENT */



/* HEADER ICONS */
#icon-root { position: absolute; top: 15px; left: 20px; width: 32px; height: 32px; z-index: 2; cursor: pointer; }
#icon-menu { position: absolute; top: 15px; right: 20px; width: 32px; height: 32px; border: 1px solid #f94; border-radius: 100%; z-index: 2; cursor: pointer; transition: transform 0.3s ease; }
#icon-menu.open { transform: rotate(90deg); }
/* END HEADER ICONS */



/* FOOTER */
#game-footer {
    background-color: #000;
    position: fixed;
    bottom: 0;
    height: auto;
    width: 100%;
    text-align: center;
    z-index: 77;
}



/* GAME MENU */
#game-menu {
    position: fixed;
    top: 65px;
    right: 50px;
    width: 200px;
    max-width: 90vw;
    padding: 30px 25px;
    z-index: 99;
    background: radial-gradient(ellipse at center, rgba(35, 25, 15, 0.95) 0%, rgba(15, 10, 5, 0.98) 100%) , linear-gradient(to bottom, #1c140a, #0a0704);
    color: #f3e5ab;
    border-left: 3px solid #d4af37;
    border-right: 3px solid #d4af37;
    box-shadow: inset 0 0 30px rgba(0, 0, 0, 0.9) , 0 10px 25px rgba(0, 0, 0, 0.95) , 0 0 15px rgba(212, 175, 55, 0.2);
    opacity: 0;
    visibility: hidden;
    transform-origin: top center;
    transform: translateX(120%) scaleY(0.02);
}

#game-menu h2 { text-align: center; margin-top: 0; color: #d4af37; border-bottom: 1px solid #652; padding: 0px; cursor: default; }

#game-menu.open { visibility: visible; animation: reelAndUnroll 0.2s forwards cubic-bezier(0.25, 1, 0.5, 1); }
#game-menu.close { visibility: visible; animation: rollAndRetract 0.6s forwards cubic-bezier(0.25, 1, 0.5, 1); }

#game-menu::before {
    content: '';
    position: absolute;
    top: -12px;
    left: -10px;
    right: -10px;
    height: 14px;
    background: linear-gradient(to right, #4a3511, #d4af37, #8c681f, #d4af37, #4a3511);
    border-radius: 6px;
    box-shadow: 0 3px 6px rgba(0, 0, 0, 0.8);
}

#game-menu::after {
    content: '';
    position: absolute;
    bottom: -12px;
    left: -10px;
    right: -10px;
    height: 14px;
    background: linear-gradient(to right, #4a3511, #d4af37, #8c681f, #d4af37, #4a3511);
    border-radius: 6px;
    box-shadow: 0 -3px 6px rgba(0, 0, 0, 0.8);
}

@keyframes reelAndUnroll {
    0% { opacity: 0; transform: translateX(120%) scaleY(0.02); }
    50% { opacity: 1; transform: translateX(0) scaleY(0.02); }
    100% { opacity: 1; transform: translateX(0) scaleY(1); }
}

@keyframes rollAndRetract {
    0% { opacity: 1; transform: translateX(0) scaleY(1); }
    50% { opacity: 1; transform: translateX(0) scaleY(0.02); }
    100% { opacity: 0; transform: translateX(120%) scaleY(0.02); }
}

#game-menu-link { width: 100%; text-align: left; font-style: italic; color: #aaa; margin: auto; padding: 10px; border-bottom: 1px solid #652;
                  display: grid; grid-template-columns: 1.4em 1fr; column-gap: 0.6em; align-items: baseline; }
#game-menu-link .menu-icon { text-align: center; }   /* every icon centered in the same-width cell */
#game-menu-link:hover { color: #652; border-bottom: 1px solid #666; }
/* END GAME MENU */



/* GAME BOARD / MAIN DISPLAY */
#game-board { position: relative; max-width: 1200px; margin: 20px auto; margin-top: 170px; margin-bottom: 125px; padding: 20px; min-height: 500px; }



/* LANDING PAGE */
.landing-hero { text-align: center; padding: 40px 20px; background: radial-gradient(circle, rgba(212, 175, 55, 0.08) 0%, rgba(0,0,0,0) 70%); border-bottom: 1px solid #222; }

.origin-badge { display: inline-block; background: rgba(212, 175, 55, 0.15); color: #d4af37; border: 1px solid #d4af37; padding: 6px 14px; border-radius: 20px; font-size: 0.85rem; margin-bottom: 20px; cursor: default; }

.hero-title { font-size: 2.4rem; margin: 0 0 15px 0; color: #fff; line-height: 1.2; }
.hero-title span { color: #d4af37; }
.hero-subtext { font-size: 1.1rem; color: #aaa; max-width: 700px; margin: 0 auto 30px auto; }
.hero-actions { display: flex; justify-content: center; gap: 15px; flex-wrap: wrap; }
.active-hero-img { box-shadow: 0 0 25px rgba(212, 175, 55, 0.2); max-width: 300px; height: auto; text-align: center; border: 1px solid #d4af37; border-radius: 10px; cursor: pointer; }

.landing-section { padding: 40px 0; border-bottom: 1px solid #222; }
.section-title { text-align: center; color: #d4af37; font-size: 1.8rem; margin-bottom: 30px; }

.grid-2 { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 15px; }
.grid-3 { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 15px; }
.grid-5 { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 15px; justify-content: center; }

.hero-img-wrap { width: 100%; max-width: 160px; height: auto; margin-top: 10px; padding-top: 0; padding-bottom: 8px; border-radius: 8px; border: 1px solid #333; }
.hero-img-wrap img { width: 100%; max-width: 160px; height: auto; margin-top: 0px; margin-bottom: 2px; padding-top: 0; border-radius: 8px; border: 0px solid #333; }

.codex-card { background: #141414; border: 1px solid #333; padding: 25px; border-radius: 6px; }
.black-codex { border-top: 3px solid #8a2be2; }
.blood-codex { border-top: 3px solid #b22222; }

.codex-header { font-size: 1.4rem; color: #f3e5ab; margin-bottom: 10px; }
.codex-quote { font-style: italic; color: #d4af37; margin-bottom: 15px; }

.showcase-card { background: #141414; border: 1px solid #2a2a2a; text-align: center; padding: 20px; border-radius: 6px; position: relative; }
.showcase-card h4 { margin: 5px 0; font-size: 1.3rem; }

.card-type { font-size: 0.75rem; text-transform: uppercase; letter-spacing: 0.1em; color: #d4af37; }


.card-role { color: #888; font-size: 0.9rem; margin-top: 0; }

/* Boxes fill the row: as many as fit, never narrower than 88px (3 per line on phones, 6 on desktop = 2 even rows of 12) */
.stat-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(88px, 1fr)); gap: 6px; margin: 15px 0; }
.stat { background: #652; font-family: Georgia, sans-serif; color: #ccc; padding: 6px 4px; border: 1px solid #d4af37; border-radius: 3px; cursor: default; text-align: center; display: flex; flex-direction: column; gap: 2px; }
.stat span { font-size: 0.7rem; color: #e8d9a8; letter-spacing: 0.08em; }
.stat strong { font-size: 1rem; color: #fff; }
@media (max-width: 600px) { .stat-grid { grid-template-columns: repeat(auto-fill, minmax(72px, 1fr)); } }

.equipped-attachment { background: #1f1f1f; border-left: 2px solid #d4af37; padding: 8px 12px; font-size: 0.85rem; border-radius: 0 4px 4px 0; }
.equipped-attachment small { display: block; color: #888; }

.feature-card { background: #141414; border: 1px solid #222; padding: 25px; border-radius: 6px; text-align: center; }
.feature-icon { font-size: 2rem; color: #d4af37; margin-bottom: 15px; }
.feature-card h4 { margin: 0 0 10px 0; font-size: 1.2rem; }
.feature-card p { color: #aaa; font-size: 0.9rem; line-height: 1.4; margin: 0; }

.landing-cta { text-align: center; padding: 50px 20px 20px 20px; }
.landing-cta h3 { font-size: 1.8rem; color: #d4af37; margin-bottom: 10px; }
.landing-cta p { color: #aaa; margin-bottom: 25px; }
/* END LANDING PAGE */



/* Auth Modal Styles */
.modal-overlay { position: fixed; top: 0; left: 0; width: 100vw; height: 100vh; background: rgba(0, 0, 0, 0.85); display: flex; align-items: center; justify-content: center; z-index: 100; }
.modal-card { background: #141414; position: relative; width: 360px; max-width: 90vw; box-shadow: 0 0 25px rgba(212, 175, 55, 0.2); padding: 30px; border: 1px solid #d4af37; border-radius: 8px; }
.modal-close { position: absolute; top: 10px; right: 15px; background: none; color: #aaa; font-size: 24px; padding: 0; }
.modal-tabs { display: flex; gap: 10px; margin-bottom: 20px; border-bottom: 1px solid #333; }
.tab-btn { flex: 1; background: none; color: #888; padding: 10px; border-bottom: 2px solid transparent; }
.tab-btn.active { color: #d4af37; border-bottom: 2px solid #d4af37; }

.auth-form { display: flex; flex-direction: column; gap: 15px; }
.form-group { display: flex; flex-direction: column; gap: 5px; }
.form-group label { font-size: 0.85rem; color: #ccc; }
.form-group input { background: #0a0a0a; border: 1px solid #333; color: #fff; }
.form-submit-btn { width: 100%; justify-content: center; margin-top: 10px; }
.form-error { color: #ff4d4d; font-size: 0.85rem; text-align: center; }
.form-error.form-ok { color: #7fd37f; }
.form-hint { font-size: 0.8rem; opacity: 0.75; }
/* Show / hide password (menu.js) */
.pw-wrap { position: relative; display: block; width: 100%; }
.pw-wrap input { width: 100%; padding-right: 42px; box-sizing: border-box; }
.pw-toggle { position: absolute; right: 4px; top: 50%; transform: translateY(-50%); background: none; border: none;
             color: inherit; opacity: 0.7; cursor: pointer; padding: 6px 8px; font-size: 1rem; line-height: 1; }
.pw-toggle:hover, .pw-toggle:focus-visible { opacity: 1; }
/* END Auth Modal Styles */



/* Hero Selection Modal Styles */
.hero-modal-card { width: 680px; max-width: 94vw; max-height: 92vh; overflow-y: auto; box-sizing: border-box; }
.admin-btn { position: absolute; top: 12px; left: 15px; background: #2a0d0d; border: 1px dashed #c44; color: #e88; font-size: 0.7rem; padding: 4px 8px; border-radius: 4px; align-items: center; gap: 5px; }
.admin-btn:hover { background: #3a1212; color: #fbb; }
.hero-modal-title { color: #d4af37; text-align: center; margin-top: 0; }
.hero-modal-sub { text-align: center; color: #aaa; font-size: 0.9rem; margin: 0 0 18px 0; }
.hero-lock-note { text-align: center; color: #888; font-size: 0.8rem; font-style: italic; margin: -8px 0 14px 0; }

.archetype-picker { display: grid; grid-template-columns: repeat(5, 1fr); gap: 8px; margin-bottom: 16px; }
.archetype-col { display: flex; flex-direction: column; gap: 6px; text-align: center; }
.archetype-col-name { font-size: 0.8rem; color: #f3e5ab; }
.archetype-btn { background: #0a0a0a; border: 1px solid #333; color: #aaa; padding: 6px 8px; font-size: 0.8rem; border-radius: 4px; transition: all 0.2s ease; }
.archetype-btn small { display: block; color: #777; font-size: 0.7rem; }
.archetype-btn:hover:not(:disabled) { border-color: #d4af37; color: #f3e5ab; }
.archetype-btn.active { background: rgba(212, 175, 55, 0.15); border: 1px solid #d4af37; color: #d4af37; font-weight: bold; }
.archetype-btn:disabled { cursor: default; opacity: 0.35; }
.archetype-btn.active:disabled { opacity: 1; }

.hero-roll-box { background: #0a0a0a; border: 1px solid #222; border-radius: 6px; padding: 16px; margin-bottom: 14px; }
.hero-roll-layout { display: flex; gap: 16px; align-items: flex-start; }
#roll-hero-link { flex-shrink: 0; }
#roll-hero-img { cursor: zoom-in; width: 140px; height: auto; border: 1px solid #d4af37; border-radius: 8px; }
.hero-roll-info { flex: 1; min-width: 0; }
#roll-archetype-title { color: #f3e5ab; margin: 0 0 2px 0; }
#roll-archetype-sub { color: #888; font-size: 0.85rem; margin: 0 0 10px 0; }

.stat-roll-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; }
.stat-roll-item { background: #141414; border: 1px solid #333; padding: 6px 4px; border-radius: 4px; text-align: center; display: flex; flex-direction: column; gap: 2px; }
.stat-roll-item span { font-size: 0.7rem; color: #888; text-transform: uppercase; letter-spacing: 0.05em; }
.stat-roll-item strong { font-size: 1.15rem; color: #d4af37; }
.stat-roll-item em { font-size: 0.65rem; color: #6c6; font-style: normal; min-height: 0.8rem; }
.stat-roll-item.is-primary { border-color: #6a6; }
.stat-roll-item.is-weak { border-color: #a55; }
.stat-roll-item.is-fixed strong { color: #aaa; }
.stat-roll-item.rolling strong { color: #fff; }
.stat-legend { font-size: 0.7rem; color: #777; margin: 8px 0 0 0; }
.tag-primary { color: #6c6; margin-right: 10px; }
.tag-weak { color: #c66; }

.roll-set { display: flex; align-items: center; justify-content: space-between; gap: 10px; background: #0a0a0a; border: 1px solid #222; border-radius: 6px; padding: 10px 14px; margin-bottom: 8px; }
.roll-set.is-locked { border-color: #d4af37; }
.roll-set.is-disabled { opacity: 0.45; }
.roll-set-label small { color: #777; margin-left: 6px; }
.roll-set-status { display: block; font-size: 0.75rem; color: #aaa; margin-top: 2px; }
.roll-set-actions { display: flex; gap: 8px; }
.roll-set-actions button { padding: 8px 14px; font-size: 0.85rem; }
button:disabled { cursor: default; opacity: 0.5; }

.hero-modal-actions { display: flex; gap: 10px; justify-content: center; margin-top: 10px; }
.hero-modal-actions button { flex: 1; justify-content: center; }

@media (max-width: 600px) {
    .archetype-picker { grid-template-columns: repeat(2, 1fr); }
    .hero-roll-layout { flex-direction: column; align-items: center; }
    .roll-set { flex-direction: column; align-items: stretch; }
}
/* END Hero Selection Modal Styles */



.card-flip-scene { perspective: 1000px; display: inline-block; }
.card-flip-inner { position: relative; transition: transform 1.2s cubic-bezier(0.22, 1, 0.36, 1); transform-style: preserve-3d; }
.card-flip-scene.is-flipped .card-flip-inner { transform: rotateY(180deg); }

.card-face { backface-visibility: hidden; -webkit-backface-visibility: hidden; }
.card-face-back { position: absolute; inset: 0; transform: rotateY(180deg); }

.starter-toggle-btn {
    background-color: #000;
    position: absolute;
    top: 50%;
    right: -25px;
    font-size: 75%;
    font-weight: 100;
    color: white;
    margin: 0;
    padding: 3px 10px;
    z-index: 2;
    opacity: 65%;
}


.sold-out-icon { position: absolute; top: -5px; right: -30px; z-index: 10; }
.sold-out-icon img { width: 65px; }

/* STAT INFO POP-UPS */
[data-stat-info] { cursor: help; }
[data-stat-info] > span { text-decoration: underline dotted rgba(255, 255, 255, 0.45); text-underline-offset: 3px; }
.stat-info-pop { position: fixed; z-index: 10000; width: 240px; max-width: calc(100vw - 20px); box-sizing: border-box; background: #120e0a; border: 1px solid #d4af37; border-radius: 6px; padding: 10px 12px; box-shadow: 0 6px 20px rgba(0, 0, 0, 0.8); text-align: left; }
.stat-info-pop strong { color: #f3e5ab; font-size: 0.95rem; }
.stat-info-pop strong span { color: #888; font-weight: normal; font-size: 0.8rem; }
.stat-info-pop p { margin: 6px 0 0 0; color: #ccc; font-size: 0.82rem; line-height: 1.4; }


/* ADMIN PANEL (admin.php) */
.admin-page { min-height: 100vh; }
.admin-header { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; padding: 16px 24px; border-bottom: 2px solid #d4af37; background: #120e0a; }
.admin-header h1 { margin: 0; font-size: 1.5rem; color: #f3e5ab; }
.admin-main { max-width: 1200px; margin: 0 auto; padding: 20px 16px 60px; }
.admin-section { background: #141414; border: 1px solid #2a2a2a; border-radius: 6px; padding: 20px; margin-bottom: 24px; }
.admin-section h2 { margin: 0 0 14px 0; color: #d4af37; }
.admin-section h2 small, .admin-section h3 small { color: #777; font-size: 0.75rem; font-weight: normal; }
.admin-section h3 { color: #f3e5ab; font-size: 1rem; margin: 20px 0 10px; }
.admin-warning { background: #2a1d0a; border: 1px solid #d4af37; color: #f3e5ab; padding: 12px 14px; border-radius: 6px; margin-bottom: 20px; font-size: 0.9rem; }
.admin-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 12px; }
.admin-stats { grid-template-columns: repeat(auto-fill, minmax(100px, 1fr)); }
.admin-moves { display: flex; flex-direction: column; gap: 8px; margin-bottom: 14px; }
.admin-move { display: grid; grid-template-columns: 24px minmax(140px, 2fr) minmax(120px, 1.3fr) 70px minmax(110px, 1.2fr); gap: 8px; align-items: end; }
.admin-move label { display: flex; flex-direction: column; gap: 4px; font-size: 0.85rem; }
.admin-move-num { color: #d4af37; font-weight: bold; padding-bottom: 8px; }
@media (max-width: 700px) { .admin-move { grid-template-columns: 24px 1fr 1fr; } }
.admin-text { grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); margin-top: 16px; }
.admin-form label { display: flex; flex-direction: column; gap: 4px; font-size: 0.8rem; color: #aaa; }
.admin-form input[type="text"], .admin-form input[type="number"], .admin-form select, .admin-form textarea {
    background: #0a0a0a; border: 1px solid #333; color: #fff; border-radius: 4px; padding: 8px; font-size: 0.9rem; font-family: inherit; width: 100%; box-sizing: border-box; }
.admin-form input:disabled, .admin-form select:disabled { opacity: 0.5; }
.admin-form input[type="file"] { color: #ccc; font-size: 0.8rem; max-width: 100%; }
.admin-check { flex-direction: row !important; align-items: center; gap: 8px !important; align-self: end; }
.admin-filename { margin-top: 16px; font-size: 0.8rem; color: #888; overflow-wrap: anywhere; }
.admin-filename code { display: block; margin-top: 4px; color: #6c6; background: #0a0a0a; padding: 8px; border-radius: 4px; }
.admin-message { min-height: 1.2em; margin: 12px 0 0; font-size: 0.9rem; }
.admin-message.is-ok { color: #6c6; }
.admin-message.is-error { color: #ff4d4d; }
.admin-actions { display: flex; gap: 10px; margin-top: 12px; flex-wrap: wrap; }
.admin-filter { margin-bottom: 10px; }
.admin-filter label { font-size: 0.85rem; color: #aaa; }
.admin-filter select { background: #0a0a0a; color: #fff; border: 1px solid #333; margin-left: 6px; }
.admin-filter { display: flex; flex-wrap: wrap; gap: 10px 20px; align-items: center; }
.admin-filter input[type="search"] { background: #0a0a0a; color: #fff; border: 1px solid #333; margin-left: 6px; padding: 4px 8px; width: 240px; max-width: 60vw; }
/* Card Catalog: fixed-height box that scrolls, column names stay at the top */
.catalog-scroll { max-height: 60vh; overflow-y: auto; border: 1px solid #2a2a2a; border-radius: 4px; }
.catalog-scroll thead th { position: sticky; top: 0; z-index: 1; background: #141414; box-shadow: 0 1px 0 #333; }
@media (max-width: 700px) { .catalog-scroll { max-height: 50vh; } }
.admin-table-wrap { overflow-x: auto; }
.admin-table { width: 100%; border-collapse: collapse; font-size: 0.85rem; }
.admin-table th { text-align: left; color: #d4af37; border-bottom: 1px solid #333; padding: 8px; white-space: nowrap; }
.admin-table td { border-bottom: 1px solid #222; padding: 6px 8px; vertical-align: middle; }
.admin-thumb { width: 44px; height: auto; border-radius: 4px; border: 1px solid #333; display: block; }
.admin-edit { padding: 4px 12px; font-size: 0.8rem; }
#admin-menu-link { display: none; }

.admin-tag { display: inline-block; margin-left: 6px; padding: 1px 6px; font-size: 0.7rem; border: 1px dashed #888; border-radius: 3px; color: #aaa; }

/* COMBAT TEST ARENA (arena.html) */
.arena-page { min-height: 100vh; }
.arena-header-actions { display: flex; gap: 10px; flex-wrap: wrap; }
.arena-main { max-width: 1200px; margin: 0 auto; padding: 16px 16px 60px; }
.arena-message { min-height: 1.2em; color: #aaa; margin-bottom: 8px; }
.arena-message.is-error { color: #ff4d4d; }
.arena-empty { text-align: center; padding: 60px 20px; color: #aaa; }
.arena-side, .arena-hand-wrap, .arena-log-wrap { background: #141414; border: 1px solid #2a2a2a; border-radius: 6px; padding: 12px; margin-bottom: 12px; }
.arena-side h3, .arena-hand-wrap h3, .arena-log-wrap h3 { margin: 0 0 8px; color: #d4af37; font-size: 0.95rem; text-transform: uppercase; letter-spacing: 0.08em; }
.arena-enemy { border-top: 3px solid #b22222; }
.arena-player { border-top: 3px solid #d4af37; }
.arena-units { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 10px; }
.arena-unit { background: #0a0a0a; border: 1px solid #333; border-radius: 6px; padding: 10px; cursor: pointer; transition: border-color 0.15s, box-shadow 0.15s; }
.arena-unit:hover { border-color: #777; }
.arena-unit.is-target { border-color: #ff4d4d; box-shadow: 0 0 10px rgba(255, 77, 77, 0.5); }
.arena-unit.side-player.is-target { border-color: #6c6; box-shadow: 0 0 10px rgba(102, 204, 102, 0.5); }
.arena-unit.is-selected { border-color: #d4af37; box-shadow: 0 0 10px rgba(212, 175, 55, 0.5); }
.arena-unit.is-acted { opacity: 0.55; }
.arena-unit.is-dead { opacity: 0.3; cursor: default; }
.arena-unit-top { display: flex; flex-direction: column; gap: 2px; }
.arena-unit-top strong { color: #f3e5ab; font-size: 0.9rem; }
.arena-kind { font-size: 0.65rem; text-transform: uppercase; letter-spacing: 0.1em; color: #888; }
.arena-hp { position: relative; height: 16px; background: #2a0d0d; border-radius: 3px; margin: 6px 0; overflow: hidden; }
.arena-hp div { height: 100%; background: linear-gradient(90deg, #7a1d1d, #c43b3b); transition: width 0.3s; }
.arena-hp span { position: absolute; inset: 0; text-align: center; font-size: 0.7rem; line-height: 16px; color: #fff; }
.arena-unit-stats { font-size: 0.75rem; color: #ccc; font-family: monospace; }
.arena-statuses { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 4px; min-height: 4px; }
.arena-status { font-size: 0.65rem; background: #3a1a4a; border: 1px solid #a5f; color: #dcf; border-radius: 3px; padding: 1px 5px; }
.arena-unit-note { font-size: 0.7rem; color: #888; margin-top: 4px; font-style: italic; }
.arena-moves { display: flex; flex-direction: column; gap: 4px; margin-top: 6px; }
.arena-moves button { padding: 4px 8px; font-size: 0.75rem; justify-content: space-between; }
.arena-moves small { color: #aaa; font-size: 0.65rem; }
.arena-gear { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 10px; margin-top: 10px; }
.arena-gear-slot { border: 1px dashed #444; border-radius: 6px; padding: 8px; font-size: 0.75rem; display: flex; flex-direction: column; gap: 2px; }
.arena-gear-slot span { text-transform: uppercase; color: #888; font-size: 0.65rem; letter-spacing: 0.1em; }
.arena-gear-slot strong { color: #f3e5ab; }
.arena-gear-slot small { color: #aaa; }
.arena-gear-slot.is-empty { opacity: 0.5; }
.arena-status-bar { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; padding: 8px 12px; background: #120e0a; border: 1px solid #d4af37; border-radius: 6px; margin-bottom: 6px; }
.arena-status-bar span { color: #f3e5ab; font-size: 0.9rem; }
.arena-status-bar button { margin-left: auto; padding: 8px 16px; }
.arena-hint { font-size: 0.85rem; color: #ccc; margin: 0 0 12px 4px; min-height: 1.2em; }
.arena-win { color: #6c6; }
.arena-lose { color: #ff4d4d; }
.arena-hand { display: flex; gap: 8px; overflow-x: auto; padding-bottom: 6px; }
.arena-card { position: relative; flex: 0 0 150px; min-height: 150px; text-align: left; background: #1c1712; border: 1px solid #5a4a2a; border-radius: 8px; padding: 10px; display: flex; flex-direction: column; gap: 4px; color: #ddd; font-size: 0.8rem; }
.arena-card strong { color: #f3e5ab; font-size: 0.85rem; padding-right: 22px; }
.arena-card em { color: #888; font-size: 0.65rem; text-transform: uppercase; font-style: normal; letter-spacing: 0.08em; }
.arena-card small { color: #bbb; font-size: 0.7rem; line-height: 1.3; }
.arena-card-cost { position: absolute; top: 6px; right: 6px; width: 22px; height: 22px; border-radius: 50%; background: #d4af37; color: #000; font-weight: bold; text-align: center; line-height: 22px; font-size: 0.8rem; }
.arena-card:hover:not(:disabled) { border-color: #d4af37; }
.arena-card.is-selected { border-color: #d4af37; box-shadow: 0 0 12px rgba(212, 175, 55, 0.6); }
.arena-card.type-spell { background: #14121c; border-color: #4a3a6a; }
.arena-card.type-creature, .arena-card.type-companion { background: #121a14; border-color: #3a5a3a; }
.arena-muted { color: #777; }
.arena-log { max-height: 260px; overflow-y: auto; font-family: monospace; font-size: 0.75rem; display: flex; flex-direction: column; gap: 2px; }
.arena-log div { color: #bbb; }
.arena-log span { color: #666; margin-right: 4px; }
.arena-log .log-system { color: #d4af37; }
.arena-log .log-hit, .arena-log .log-damage { color: #f88; }
.arena-log .log-crit { color: #ff4d4d; font-weight: bold; }
.arena-log .log-miss { color: #888; }
.arena-log .log-heal { color: #6c6; }
.arena-log .log-status { color: #c9f; }
.arena-log .log-defeat { color: #fff; font-weight: bold; }
.arena-log .log-action { color: #9cf; }

.arena-history h3 small { color: #888; font-size: 0.75rem; text-transform: none; letter-spacing: 0; margin-left: 8px; }
.arena-log-modal { width: 760px; max-width: 94vw; max-height: 88vh; display: flex; flex-direction: column; box-sizing: border-box; }
.arena-log-modal h3 { color: #f3e5ab; margin: 0 30px 10px 0; }
.arena-log-modal .arena-log { max-height: none; flex: 1; min-height: 0; }
.result-victory { color: #6c6; }
.result-defeat { color: #ff4d4d; }
.result-abandoned, .result-in_progress { color: #888; }

.arena-difficulty { display: inline-flex; align-items: center; gap: 6px; color: #aaa; font-size: 0.85rem; }
.arena-difficulty select { background: #0a0a0a; color: #fff; border: 1px solid #333; }
.arena-enemy h3 small { color: #888; font-size: 0.72rem; text-transform: none; letter-spacing: 0; margin-left: 8px; }
.arena-log .log-ai { color: #6a8a9a; font-style: italic; }

/* Arena: Battle Setup & Deck Builder */
.arena-panel > summary { cursor: pointer; color: #d4af37; font-size: 0.95rem; text-transform: uppercase; letter-spacing: 0.08em; list-style: none; }
.arena-panel > summary::-webkit-details-marker { display: none; }
.arena-panel > summary small { color: #888; text-transform: none; letter-spacing: 0; font-size: 0.75rem; }
.arena-panel[open] > summary { margin-bottom: 12px; }
.arena-setup label, .builder-top label { display: flex; flex-direction: column; gap: 4px; font-size: 0.8rem; color: #aaa; }
.arena-setup select, .builder-top select, .builder-top input, .builder-filters select, .builder-filters input {
    background: #0a0a0a; border: 1px solid #333; color: #fff; border-radius: 4px; padding: 8px; font-size: 0.85rem; font-family: inherit; width: 100%; box-sizing: border-box; }
.builder-top { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 12px; align-items: end; }
.builder-top .admin-actions { grid-column: 1 / -1; margin-top: 0; }
.builder-top .admin-actions button { padding: 8px 12px; font-size: 0.8rem; }
.builder-summary { display: flex; flex-wrap: wrap; gap: 8px; margin: 12px 0; font-size: 0.8rem; }
.builder-summary span { padding: 2px 8px; border-radius: 3px; border: 1px solid #333; }
.builder-summary .ok { color: #6c6; border-color: #3a5a3a; }
.builder-summary .warn { color: #d4af37; border-color: #5a4a2a; }
.builder-warn { flex-basis: 100%; color: #d4af37; font-size: 0.8rem; }
.builder-columns { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 16px; }
.builder-columns h4 { margin: 0 0 8px; color: #f3e5ab; }
.builder-columns h4 small { color: #888; font-weight: normal; }
.builder-filters { display: grid; grid-template-columns: 140px 1fr; gap: 8px; margin-bottom: 8px; }
.builder-list { max-height: 420px; overflow-y: auto; display: flex; flex-direction: column; gap: 4px; }
.builder-row { display: grid; grid-template-columns: 26px 1fr auto auto; align-items: center; gap: 8px; background: #1c1712; border: 1px solid #3a3020; border-radius: 6px; padding: 6px 8px; }
.builder-row .arena-card-cost { position: static; }
.builder-row strong { color: #f3e5ab; font-size: 0.85rem; }
.builder-row small { display: block; color: #999; font-size: 0.7rem; }
.builder-row button { padding: 2px 12px; font-size: 1rem; }
.builder-row.type-spell { background: #14121c; border-color: #3a2f50; }
.builder-row.type-creature, .builder-row.type-companion { background: #121a14; border-color: #2f4a2f; }
.builder-qty { color: #d4af37; font-weight: bold; font-size: 0.85rem; }
@media (max-width: 600px) { .builder-filters { grid-template-columns: 1fr; } }

/* PLAYER SETTINGS (settings.js adds these classes to <html>) */
html.text-small, html.text-small body { font-size: 14px; }
html.text-large, html.text-large body { font-size: 18px; }
html.text-x-large, html.text-x-large body { font-size: 20px; }
html.high-contrast body { color: #fff; }
html.high-contrast small, html.high-contrast em, html.high-contrast p, html.high-contrast .card-role, html.high-contrast .hero-subtext,
html.high-contrast .arena-muted, html.high-contrast .arena-log div, html.high-contrast label { color: #e8e8e8 !important; }
html.high-contrast .showcase-card, html.high-contrast .feature-card, html.high-contrast .admin-section, html.high-contrast .arena-side,
html.high-contrast .arena-unit, html.high-contrast .stat-roll-item { border-color: #bbb !important; }
html.high-contrast .btn-outline { color: #ffe27a; border-color: #ffe27a; }
html.reduce-motion *, html.reduce-motion *::before, html.reduce-motion *::after { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; scroll-behavior: auto !important; }

.settings-main { max-width: 900px; margin: 0 auto; padding: 20px 16px 60px; }
.settings-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 16px; }
.settings-item { display: flex; flex-direction: column; gap: 4px; }
.settings-item small { color: #888; font-size: 0.75rem; }
.settings-item .settings-later { color: #a08a4a; font-style: italic; }
.settings-item select, .settings-item input[type="range"] { width: 100%; }
.settings-toggle { flex-direction: row !important; align-items: center; gap: 10px !important; font-size: 0.95rem !important; color: #ddd !important; cursor: pointer; }
.settings-note { color: #aaa; font-size: 0.85rem; background: #141414; border: 1px solid #2a2a2a; border-radius: 6px; padding: 10px 14px; }
.settings-privacy { margin-top: 24px; }

/* Admin: Mass Simulation */
.admin-help { color: #aaa; font-size: 0.85rem; margin: -6px 0 14px; }
.sim-summary { display: grid; grid-template-columns: repeat(auto-fill, minmax(130px, 1fr)); gap: 10px; margin: 16px 0; }
.sim-summary div { background: #0a0a0a; border: 1px solid #333; border-radius: 6px; padding: 10px; text-align: center; display: flex; flex-direction: column; gap: 4px; }
.sim-summary span { font-size: 0.7rem; color: #888; text-transform: uppercase; letter-spacing: 0.08em; }
.sim-summary strong { font-size: 1.3rem; color: #f3e5ab; }
#sim-results h3 { color: #f3e5ab; font-size: 1rem; margin: 20px 0 8px; }
#sim-results h3 small { color: #888; font-weight: normal; font-size: 0.75rem; }
.sim-high { color: #6c6 !important; }
.sim-mid { color: #f3e5ab !important; }
.sim-low { color: #ff6b6b !important; }
.sim-sample { margin-top: 16px; }
.sim-sample summary { cursor: pointer; color: #d4af37; }
.sim-sample .arena-log { max-height: 320px; margin-top: 8px; }

/* Arena: Graveyard picker (Recall / Revive spells) */
.grave-list { display: flex; flex-direction: column; gap: 8px; max-height: 60vh; overflow-y: auto; }
.grave-choice { text-align: left; background: #1a1a1a; border: 1px solid #444; color: #ddd; padding: 10px 12px; border-radius: 6px; cursor: pointer; display: flex; flex-direction: column; gap: 2px; }
.grave-choice:hover { border-color: #d4af37; }
.grave-choice span { color: #aaa; font-size: 0.85rem; text-transform: capitalize; }
.grave-choice small { color: #888; }

/* Main menu (menu.js): icon inside the slim headers, & the page you're on */
.admin-header #icon-menu { position: static; flex: 0 0 auto; }
#game-menu a.menu-current #game-menu-link { color: #d4af37; }

/* Arena: Perks (Notes 7.5) */
.arena-perks { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 10px; }
.arena-perk { flex: 1 1 220px; max-width: 340px; text-align: left; background: #17120c; border: 1px solid #554; border-radius: 6px; color: #ccc; padding: 8px 10px; display: flex; flex-direction: column; gap: 2px; cursor: pointer; }
.arena-perk:disabled { cursor: default; opacity: 0.75; }
.arena-perk.is-ready.perk-active:not(:disabled) { border-color: #d4af37; box-shadow: 0 0 8px rgba(212, 175, 55, 0.35); }
.arena-perk.perk-passive.is-ready { border-color: #4a7; }
.arena-perk.is-selected { border-color: #f94; box-shadow: 0 0 10px rgba(255, 153, 68, 0.5); }
.arena-perk strong { color: #f3e5ab; }
.arena-perk small { color: #d4af37; }
.arena-perk em { color: #999; font-size: 0.8rem; }
.arena-perk-type { text-transform: uppercase; font-size: 0.7rem; letter-spacing: 1px; color: #888; }
.arena-status.arena-mark { background: #2a4a2a; }

/* Admin Mass Simulation: player & enemy setup groups */
.sim-group { border: 1px solid #444; border-radius: 8px; padding: 10px 14px 14px; margin: 0 0 14px; }
.sim-group legend { padding: 0 8px; font-weight: bold; }
.sim-group legend small { font-weight: normal; color: #999; }
.sim-player { border-color: #4a7a4a; background: rgba(60, 120, 60, 0.06); }
.sim-player legend { color: #8c8; }
.sim-enemy { border-color: #8a3a3a; background: rgba(140, 50, 50, 0.06); }
.sim-enemy legend { color: #e88; }
.sim-run-row { margin-bottom: 6px; }

/* Hero claim: Perk choice (Notes 15.4) & Dashboard Perks */
.perk-choice { border: 1px solid #443; border-radius: 8px; padding: 12px; margin: 12px 0; background: rgba(20, 15, 8, 0.6); }
.perk-choice-note { color: #aaa; font-size: 0.85rem; margin: 6px 0 10px; }
.perk-choice-cols { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 12px; }
.perk-choice-cols h4 { margin: 0 0 6px; color: #f3e5ab; }
.perk-choice-cols h4 small { color: #888; font-weight: normal; }
.perk-options { display: flex; flex-direction: column; gap: 6px; }
.perk-option { text-align: left; background: #17120c; border: 1px solid #554; border-radius: 6px; color: #ccc; padding: 8px 10px; cursor: pointer; display: flex; flex-direction: column; gap: 2px; }
.perk-option:hover { border-color: #a83; }
.perk-option.is-picked { border-color: #d4af37; box-shadow: 0 0 8px rgba(212, 175, 55, 0.4); background: #231a0d; }
.perk-option strong { color: #f3e5ab; }
.perk-option small { color: #d4af37; }
.perk-option em { color: #999; font-size: 0.8rem; }
.perk-favored { display: inline-block; font-size: 0.7rem; color: #111; background: #8c8; border-radius: 3px; padding: 0 5px; margin-left: 4px; font-style: normal; }
.dash-perks { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 10px; margin: 0 0 15px; text-align: left; }
.dash-perk { border: 1px solid #554; border-radius: 6px; padding: 8px 10px; display: flex; flex-direction: column; gap: 3px; background: #17120c; }
.dash-perk.is-open { border-color: #d4af37; }
.dash-perk strong { color: #f3e5ab; }
.dash-perk small { color: #d4af37; }
.dash-perk em { color: #999; font-size: 0.8rem; }
.dash-perk-slot { text-transform: uppercase; font-size: 0.7rem; letter-spacing: 1px; color: #888; }
.dash-perk select { max-width: 100%; }

/* Arena: Specialization Traits (Notes 7.6) */
.arena-trait { border-color: #6a5a9a; cursor: default; }
.arena-trait .arena-perk-type { color: #a9f; }
.arena-trait-campaign { color: #777 !important; font-size: 0.75rem !important; }
.arena-trait-btn { margin-top: 6px; align-self: flex-start; padding: 4px 10px; font-size: 0.85rem; }
.arena-gear-slot.is-off { opacity: 0.5; border-style: dashed; }
.arena-gear-slot.is-off span { color: #f66; }

/* Admin: Card Text & Flavor Text boxes line up even when a hint wraps */
.admin-text label { display: flex; flex-direction: column; }
.admin-text label textarea { margin-top: auto; }

/* My Decks page (Phase 1) */
.decks-main { max-width: 1200px; margin: 0 auto; padding: 20px 16px 60px; }
.deck-slots { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 10px; margin: 12px 0 16px; }
.deck-slot { text-align: left; background: #17120c; border: 1px solid #554; border-radius: 8px; color: #ccc; padding: 10px 12px; cursor: pointer; display: flex; flex-direction: column; gap: 3px; }
.deck-slot span { font-size: 0.75rem; text-transform: uppercase; letter-spacing: 1px; color: #888; }
.deck-slot strong { color: #f3e5ab; }
.deck-slot small { color: #999; }
.deck-slot.is-active span { color: #d4af37; }
.deck-slot.is-current { border-color: #d4af37; box-shadow: 0 0 8px rgba(212, 175, 55, 0.35); }

/* Companion claim (Dashboard) */
.companion-choices { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 12px; margin: 12px 0; }
.companion-choice { text-align: left; background: #17120c; border: 1px solid #554; border-radius: 8px; color: #ccc; padding: 10px; cursor: pointer; display: flex; gap: 10px; }
.companion-choice img { width: 70px; height: 98px; object-fit: cover; border-radius: 4px; }
.companion-choice strong { color: #f3e5ab; display: block; }
.companion-choice small { color: #999; display: block; font-size: 0.75rem; }
.companion-choice.is-picked { border-color: #d4af37; box-shadow: 0 0 8px rgba(212, 175, 55, 0.4); background: #231a0d; }
.companion-choice:disabled { cursor: default; }
.dash-companion { border: 1px solid #554; border-radius: 6px; padding: 8px 10px; margin: 0 0 15px; background: #17120c; text-align: left; }
.dash-companion strong { color: #f3e5ab; }
.dash-companion small { color: #999; display: block; }

/* Admin Panel: Testing Tools */
.tools-status { display: flex; flex-wrap: wrap; gap: 6px 14px; font-size: 0.85rem; color: #bbb; margin-bottom: 10px; }
.tools-status strong { color: #f3e5ab; }
.tools-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 14px; }
.tools-group { border: 1px solid #443; border-radius: 8px; padding: 10px 12px; display: flex; flex-direction: column; gap: 8px; background: rgba(20, 15, 8, 0.5); }
.tools-group h3 { margin: 0 0 2px; font-size: 1rem; color: #f3e5ab; }
.tools-group h3 small { color: #888; font-weight: normal; }
.tools-group label { display: flex; flex-direction: column; gap: 4px; font-size: 0.8rem; color: #aaa; }
.tools-group button { text-align: left; }
.tools-danger { border-color: #8a3a3a !important; color: #e88 !important; }
.tools-inline { display: grid; grid-template-columns: 70px 1fr; gap: 6px; }
.tools-inline select { grid-column: 1 / -1; }
.tools-group select, .tools-group input { width: 100%; min-width: 0; box-sizing: border-box; background: #0f0f0f; color: #eee; border: 1px solid #444; border-radius: 4px; padding: 6px 8px; font-family: inherit; }
.tools-note { color: #888; font-size: 0.75rem; }

/* Campaign page (Phase 2) */
.camp-panel { margin-bottom: 16px; }
.camp-panel h2 { margin-top: 0; color: #f3e5ab; }
/* Start a Campaign: label above each dropdown, all the same width */
#camp-start-form .admin-grid label { display: flex; flex-direction: column; gap: 4px; }
#camp-start-form .admin-grid select { width: 100%; box-sizing: border-box; }
#camp-start h3 { margin-top: 24px; }

/* Currency overlay (menu.js) - sits under the header, top-left, stays visible while scrolling */
#currency-overlay { position: sticky; top: 0; z-index: 900; display: flex; gap: 16px; width: max-content;
    margin: 0 0 0 16px; padding: 6px 14px; background: #120e0a; border: 1px solid #d4af37; border-top: none;
    border-radius: 0 0 8px 8px; color: #f3e5ab; font-size: 0.95rem; font-weight: bold; }
#currency-overlay.is-fixed { position: fixed; left: 0; margin: 0 0 0 16px; z-index: 78; }
#currency-overlay i { color: #d4af37; margin-right: 4px; }
.camp-header { display: flex; flex-direction: column; gap: 10px; margin-bottom: 12px; }
.camp-track { display: flex; flex-wrap: wrap; gap: 6px; }
.camp-step { padding: 4px 10px; border: 1px solid #444; border-radius: 14px; font-size: 0.8rem; color: #888; }
.camp-step.is-done { color: #6c6; border-color: #3a5a3a; }
.camp-step.is-current { color: #111; background: #d4af37; border-color: #d4af37; font-weight: bold; }
.camp-stats { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 14px; color: #ccc; font-size: 0.9rem; }
.camp-stats strong { color: #f3e5ab; }
.camp-hp { width: 220px; }
.camp-choices { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 10px; margin: 10px 0 14px; }
.camp-choice { text-align: left; background: #17120c; border: 1px solid #554; border-radius: 8px; color: #ccc; padding: 10px 12px; cursor: pointer; display: flex; flex-direction: column; gap: 4px; }
.camp-choice:hover { border-color: #d4af37; }
.camp-choice strong { color: #f3e5ab; }
.camp-choice small { color: #d4af37; }
.camp-good { color: #6c6; }
.camp-warn { color: #e88; }
.camp-rewards { list-style: none; padding: 0; display: flex; flex-direction: column; gap: 6px; }
.camp-rewards li { color: #ddd; }
.camp-rewards i { color: #d4af37; width: 20px; }
.camp-swap { display: grid; grid-template-columns: 1fr 1fr auto; gap: 8px; align-items: end; margin-bottom: 12px; }
.camp-swap label { display: flex; flex-direction: column; gap: 4px; font-size: 0.8rem; color: #aaa; }
.camp-swap select { background: #0f0f0f; color: #eee; border: 1px solid #444; border-radius: 4px; padding: 6px; }
.camp-abandon { margin-left: auto; font-size: 0.8rem; border-color: #8a3a3a !important; color: #e88 !important; }
@media (max-width: 600px) { .camp-swap { grid-template-columns: 1fr; } }

.tools-group textarea { width: 100%; box-sizing: border-box; background: #0f0f0f; color: #eee; border: 1px solid #444; border-radius: 4px; padding: 6px 8px; font-family: inherit; }
.tools-qwen-answer { white-space: pre-wrap; color: #ddd; font-size: 0.85rem; font-style: italic; }
.tools-qwen-answer:empty { display: none; }

/* Campaign: the Qwen Dungeon Master (Phase 3) */
.dm-text { color: #eee; font-size: 1.02rem; line-height: 1.55; font-style: italic; border-left: 3px solid #d4af37; padding-left: 12px; }
.dm-new { animation: dmFade 0.8s ease-in; }
@keyframes dmFade { from { opacity: 0; } to { opacity: 1; } }
.reduce-motion .dm-new { animation: none; }
.dm-placeholder { color: #aaa; }
.dm-writing { color: #d4af37; font-size: 0.8rem; margin-left: 6px; }
.dm-speak { background: none; border: none; color: #d4af37; cursor: pointer; font-size: 0.9rem; }
.dm-story { margin-top: 14px; border-top: 1px solid #333; padding-top: 8px; }
.dm-story summary { cursor: pointer; color: #d4af37; }
.dm-story p { color: #ccc; font-size: 0.9rem; }
.dm-story strong { color: #f3e5ab; margin-right: 6px; }
.dm-custom { border: 1px dashed #554; border-radius: 8px; padding: 10px 12px; margin: 10px 0; display: flex; flex-direction: column; gap: 6px; }
.dm-custom label { display: flex; flex-direction: column; gap: 4px; font-size: 0.85rem; color: #aaa; }
.dm-custom input, .dm-custom select { background: #0f0f0f; color: #eee; border: 1px solid #444; border-radius: 4px; padding: 6px 8px; font-family: inherit; }
.dm-custom > button { align-self: flex-start; }
.camp-choice-line { color: #d4af37; }
