/**
 * RIFT v2 - Modern Dice Roller
 * Full-featured with themes, multiplayer, swipe support
 */

/* ========================================
   PAGE HEADER
   ======================================== */

.page-header {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 24px 24px 0 24px;
}

.page-header__icon {
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-primary);
}

.page-header__icon svg {
    width: 20px;
    height: 20px;
}

.page-header__divider {
    width: 1px;
    height: 28px;
    background: rgba(255, 255, 255, 0.2);
}

.page-header__title {
    font-style: italic;
    font-family: 'Dharma Gothic', sans-serif;
    font-size: 56px;
    font-weight: 700;
    color: var(--text-primary);
    margin: 0;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.page-header__tagline {
    color: var(--accent);
    font-family: 'Dharma Gothic', sans-serif;
    font-size: 24px;
    font-weight: 400;
    font-style: italic;
}

.section-divider {
    height: 1px;
    background: rgba(255, 255, 255, 0.1);
    margin: 24px 24px 0 24px;
}

/* ========================================
   CSS VARIABLES - DICE THEMES
   ======================================== */

:root {
    /* Default Theme - Classic Dark */
    --dice-primary: #1a1a1a;
    --dice-secondary: #f0f0f0;
    --dice-accent: var(--accent);
}

[data-dice-theme="blood"] {
    --dice-primary: #8b0000;
    --dice-secondary: #ffd700;
    --dice-accent: #ff4655;
}

[data-dice-theme="ice"] {
    --dice-primary: #1a3a5c;
    --dice-secondary: #a8d8ff;
    --dice-accent: #00d4ff;
}

[data-dice-theme="nature"] {
    --dice-primary: #2d4a1c;
    --dice-secondary: #c8e6c9;
    --dice-accent: #4caf50;
}

[data-dice-theme="royal"] {
    --dice-primary: #2a1a4a;
    --dice-secondary: #e8d5ff;
    --dice-accent: #9c27b0;
}

[data-dice-theme="gold"] {
    --dice-primary: #3d2c0a;
    --dice-secondary: #ffd700;
    --dice-accent: #ffab00;
}

/* ========================================
   LAYOUT - Nutzt main__content aus core.css (1500px mit 50px padding = 1400px Content)
   ======================================== */

.dice-page {
    display: flex;
    flex-direction: column;
    gap: 16px;
    padding: 24px 0;
    width: 100%;
}

/* ========================================
   3D ARENA
   ======================================== */

.dice-arena {
    position: relative;
    width: 100%;
    height: 500px;
    background: #1b1b1b;
    border: none;
    border-radius: 12px;
    overflow: hidden;
    cursor: grab;
    touch-action: none;
}

.dice-arena:hover {
    /* keine Border-Änderung mehr */
}

/* Remote Player Indicator - zeigt wer gerade würfelt */
.dice-remote-indicator {
    position: absolute;
    top: 20px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(0, 0, 0, 0.85);
    padding: 10px 20px;
    border-radius: 20px;
    font-family: 'Inter', sans-serif;
    font-size: 14px;
    font-weight: 600;
    color: var(--text);
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    z-index: 100;
    white-space: nowrap;
}

.dice-remote-indicator.visible {
    opacity: 1;
    visibility: visible;
}

.dice-arena:active {
    cursor: grabbing;
}

.dice-arena.drag-over {
    border-color: var(--dice-accent, var(--accent));
    box-shadow: inset 0 0 30px rgba(255, 70, 85, 0.2);
}

.dice-arena::before {
    content: '';
    position: absolute;
    inset: 0;
    background: transparent;
    pointer-events: none;
    z-index: 1;
}

/* Theme-specific arena backgrounds - DEAKTIVIERT */
[data-dice-theme="blood"] .dice-arena::before,
[data-dice-theme="ice"] .dice-arena::before,
[data-dice-theme="nature"] .dice-arena::before,
[data-dice-theme="royal"] .dice-arena::before,
[data-dice-theme="gold"] .dice-arena::before {
    background: transparent;
}

.dice-arena::after {
    content: '';
    position: absolute;
    inset: 0;
    pointer-events: none;
    z-index: 1;
}

/* Grid Pattern NUR für grid-theme */
.dice-arena[data-arena-theme="grid"]::after {
    background-image: 
        linear-gradient(rgba(255,255,255,0.01) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255,255,255,0.01) 1px, transparent 1px);
    background-size: 40px 40px;
}

.dice-arena canvas {
    position: absolute !important;
    top: 0 !important;
    left: 0 !important;
    width: 100% !important;
    height: 100% !important;
    z-index: 5;
}

/* Swipe Indicator */
.dice-arena__swipe-hint {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    background: rgba(0,0,0,0.6);
    border-radius: 20px;
    color: var(--text-muted);
    font-size: 12px;
    z-index: 5;
    opacity: 0.7;
    transition: opacity 0.3s ease;
}

.dice-arena:not(.empty) .dice-arena__swipe-hint {
    opacity: 0;
    pointer-events: none;
}

.dice-arena__swipe-hint svg {
    width: 16px;
    height: 16px;
    animation: swipeHint 2s ease-in-out infinite;
}

@keyframes swipeHint {
    0%, 100% { transform: translateX(0); }
    50% { transform: translateX(10px); }
}

/* Empty State */
.dice-arena__empty {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 16px;
    color: var(--text-dim);
    text-align: center;
    z-index: 5;
    transition: opacity 0.3s ease;
}

.dice-arena:not(.empty) .dice-arena__empty {
    opacity: 0;
    pointer-events: none;
}

.dice-arena__empty-icon {
    width: 80px;
    height: 80px;
    opacity: 0.3;
    animation: floatDice 3s ease-in-out infinite;
}

@keyframes floatDice {
    0%, 100% { transform: translateY(0) rotate(0deg); }
    50% { transform: translateY(-10px) rotate(5deg); }
}

/* Dice Value Labels (floating above dice) */
.dice-labels {
    position: absolute;
    inset: 0;
    pointer-events: none;
    z-index: 15;
}

.dice-label {
    position: absolute;
    transform: translate(-50%, -100%);
    padding: 6px 12px;
    background: white;
    border: 2px solid rgba(0, 0, 0, 0.2);
    border-radius: 8px;
    font-family: 'Roboto', sans-serif;
    font-size: 28px;
    font-weight: 700;
    color: #1a1a1a;
    white-space: nowrap;
    opacity: 0;
    animation: labelFadeIn 0.3s ease-out forwards;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

.dice-label::after {
    content: '';
    position: absolute;
    bottom: -8px;
    left: 50%;
    transform: translateX(-50%);
    border-left: 6px solid transparent;
    border-right: 6px solid transparent;
    border-top: 8px solid white;
}

.dice-label--crit-success {
    background: #4caf50;
    border-color: white;
    color: white;
    animation: labelFadeIn 0.3s ease-out forwards, labelPulseSuccess 1s ease-in-out infinite 0.3s;
}

.dice-label--crit-success::after {
    border-top-color: #4caf50;
}

.dice-label--crit-failure {
    background: #f44336;
    border-color: white;
    color: white;
    animation: labelFadeIn 0.3s ease-out forwards, labelPulseFailure 1s ease-in-out infinite 0.3s;
}

.dice-label--crit-failure::after {
    border-top-color: #f44336;
}

@keyframes labelPulseSuccess {
    0%, 100% { transform: translate(-50%, -100%) scale(1); box-shadow: 0 0 10px rgba(76, 175, 80, 0.5); }
    50% { transform: translate(-50%, -100%) scale(1.1); box-shadow: 0 0 20px rgba(76, 175, 80, 0.8); }
}

@keyframes labelPulseFailure {
    0%, 100% { transform: translate(-50%, -100%) scale(1); box-shadow: 0 0 10px rgba(244, 67, 54, 0.5); }
    50% { transform: translate(-50%, -100%) scale(1.1); box-shadow: 0 0 20px rgba(244, 67, 54, 0.8); }
}

/* Alle Würfel-Labels - immer weiß mit schwarzer Schrift */
.dice-label--d4,
.dice-label--d6,
.dice-label--d8,
.dice-label--d10,
.dice-label--d12,
.dice-label--d20,
.dice-label--d100 { 
    background: white;
    border-color: rgba(0, 0, 0, 0.15);
    color: #1a1a1a;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.25); 
}

.dice-label--d4::after,
.dice-label--d6::after,
.dice-label--d8::after,
.dice-label--d10::after,
.dice-label--d12::after,
.dice-label--d20::after,
.dice-label--d100::after { 
    border-top-color: white; 
}

@keyframes labelFadeIn {
    0% { opacity: 0; transform: translate(-50%, -80%); }
    100% { opacity: 1; transform: translate(-50%, -100%); }
}

@keyframes labelPulse {
    0%, 100% { transform: translate(-50%, -100%) scale(1); }
    50% { transform: translate(-50%, -100%) scale(1.1); }
}

/* Result Display - Bottom positioned to not cover dice */
.dice-result {
    position: absolute;
    bottom: 24px;
    left: 50%;
    transform: translateX(-50%) translateY(20px);
    z-index: 20;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    padding: 20px 40px;
    background: linear-gradient(135deg, rgba(20, 20, 20, 0.95), rgba(30, 30, 30, 0.9));
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 20px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
    opacity: 0;
    pointer-events: none;
}

.dice-result.visible {
    animation: resultSlideUp 0.4s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
}

@keyframes resultSlideUp {
    0% { opacity: 0; transform: translateX(-50%) translateY(40px) scale(0.9); }
    100% { opacity: 1; transform: translateX(-50%) translateY(0) scale(1); }
}

.dice-result__total {
    font-family: var(--font-display);
    font-size: 56px;
    font-weight: 900;
    color: white;
    line-height: 1;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

.dice-result__breakdown {
    font-family: var(--font-mono);
    font-size: 13px;
    color: var(--text-muted);
    letter-spacing: 0.5px;
}

.dice-result__player {
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    margin-bottom: 4px;
}

/* Secret Roll */
.dice-result.secret {
    border-color: var(--text-primary);
    background: rgba(255, 70, 85, 0.15);
}

.dice-result.secret::before {
    content: '🔒';
    font-size: 18px;
    margin-right: 8px;
}

/* Critical */
/* Critical Success - Grün */
.dice-result.critical {
    border-color: #4caf50;
    background: rgba(76, 175, 80, 0.15);
    box-shadow: 0 0 40px rgba(76, 175, 80, 0.5);
    animation: resultSlideUp 0.4s forwards, critGlowSuccess 1.5s ease-in-out infinite 0.4s;
}

@keyframes critGlowSuccess {
    0%, 100% { box-shadow: 0 0 40px rgba(76, 175, 80, 0.4); }
    50% { box-shadow: 0 0 60px rgba(76, 175, 80, 0.7); }
}

.dice-result.critical .dice-result__total {
    color: #4caf50;
}

.dice-result.critical::after {
    content: '🎲 KRITISCHER ERFOLG!';
    margin-left: 12px;
    padding: 4px 10px;
    background: #4caf50;
    border-radius: 8px;
    font-size: 11px;
    font-weight: 700;
    color: white;
    white-space: nowrap;
}

/* Critical Failure / Fumble - Rot */
.dice-result.fumble {
    border-color: #f44336;
    background: rgba(244, 67, 54, 0.15);
    box-shadow: 0 0 40px rgba(244, 67, 54, 0.5);
    animation: resultSlideUp 0.4s forwards, critGlowFail 1.5s ease-in-out infinite 0.4s;
}

@keyframes critGlowFail {
    0%, 100% { box-shadow: 0 0 40px rgba(244, 67, 54, 0.4); }
    50% { box-shadow: 0 0 60px rgba(244, 67, 54, 0.7); }
}

.dice-result.fumble .dice-result__total {
    color: #f44336;
}

.dice-result.fumble::after {
    content: '💀 KRITISCHER FEHLSCHLAG!';
    margin-left: 12px;
    padding: 4px 10px;
    background: #f44336;
    border-radius: 8px;
    font-size: 11px;
    font-weight: 700;
    color: white;
    white-space: nowrap;
}

/* ========================================
   CRITICAL SCREEN FLASH
   ======================================== */
   
.crit-flash {
    position: fixed;
    inset: 0;
    pointer-events: none;
    z-index: 9999;
    animation: critFlash 0.6s ease-out forwards;
}

.crit-flash--success {
    background: radial-gradient(circle at center, rgba(76, 175, 80, 0.4) 0%, rgba(76, 175, 80, 0) 70%);
}

.crit-flash--failure {
    background: radial-gradient(circle at center, rgba(244, 67, 54, 0.4) 0%, rgba(244, 67, 54, 0) 70%);
}

@keyframes critFlash {
    0% {
        opacity: 0;
        transform: scale(0.8);
    }
    20% {
        opacity: 1;
        transform: scale(1.1);
    }
    100% {
        opacity: 0;
        transform: scale(1.5);
    }
}

/* ========================================
   MULTIPLAYER FEED
   ======================================== */

.dice-feed {
    position: absolute;
    top: 16px;
    right: 16px;
    display: flex;
    flex-direction: column;
    gap: 8px;
    z-index: 15;
    max-height: 200px;
    overflow: hidden;
}

.dice-feed__item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 14px;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(10px);
    border-radius: 12px;
    animation: feedSlide 0.3s ease;
}

@keyframes feedSlide {
    from { opacity: 0; transform: translateX(20px); }
    to { opacity: 1; transform: translateX(0); }
}

.dice-feed__avatar {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: 600;
    color: white;
}

.dice-feed__info {
    flex: 1;
}

.dice-feed__name {
    font-size: 11px;
    color: var(--text-muted);
}

.dice-feed__roll {
    font-family: var(--font-mono);
    font-size: 13px;
    color: var(--text);
    display: flex;
    align-items: center;
    gap: 6px;
}

.dice-feed__dice-color {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    flex-shrink: 0;
    box-shadow: 0 0 4px currentColor;
}

.dice-feed__result {
    font-family: var(--font-display);
    font-size: 24px;
    font-weight: 700;
    color: var(--text-primary);
}

.dice-feed__item.secret .dice-feed__result {
    color: var(--text-dim);
}

.dice-feed__item.secret .dice-feed__result::before {
    content: '🔒';
    margin-right: 4px;
}

/* Critical Success Feed */
.dice-feed__item.critical {
    background: rgba(76, 175, 80, 0.2);
    border: 1px solid rgba(76, 175, 80, 0.4);
}

.dice-feed__item.critical .dice-feed__result {
    color: #4caf50;
}

/* Critical Failure Feed */
.dice-feed__item.fumble {
    background: rgba(244, 67, 54, 0.2);
    border: 1px solid rgba(244, 67, 54, 0.4);
}

.dice-feed__item.fumble .dice-feed__result {
    color: #f44336;
}

/* Feed Label für Skill/Fokus/Zweite Chance */
.dice-feed__label {
    font-weight: 500;
    color: rgba(255, 255, 255, 0.9);
}

/* Success/Failure Indicator im Feed */
.dice-feed__success {
    color: #22c55e;
    font-weight: bold;
    margin-left: 4px;
}

.dice-feed__failure {
    color: #ef4444;
    font-weight: bold;
    margin-left: 4px;
}

/* ========================================
   CONTROLS
   ======================================== */

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

.dice-toolbar__left,
.dice-toolbar__right {
    display: flex;
    align-items: center;
    gap: 8px;
}

/* Theme Selector */
.dice-themes {
    display: flex;
    gap: 6px;
}

.dice-theme-btn {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    border: 2px solid transparent;
    cursor: pointer;
    transition: all 0.2s ease;
}

.dice-theme-btn:hover {
    transform: scale(1.15);
}

.dice-theme-btn.active {
    border-color: white;
    box-shadow: 0 0 10px rgba(255,255,255,0.3);
}

.dice-theme-btn--classic { background: linear-gradient(135deg, #1a1a1a, #333); }
.dice-theme-btn--blood { background: linear-gradient(135deg, #8b0000, #ff4655); }
.dice-theme-btn--ice { background: linear-gradient(135deg, #1a3a5c, #00d4ff); }
.dice-theme-btn--nature { background: linear-gradient(135deg, #2d4a1c, #4caf50); }
.dice-theme-btn--royal { background: linear-gradient(135deg, #2a1a4a, #9c27b0); }
.dice-theme-btn--gold { background: linear-gradient(135deg, #3d2c0a, #ffd700); }

/* Toggle Buttons */
.dice-toggle {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: 8px;
    color: var(--text-muted);
    font-size: 12px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.dice-toggle:hover {
    border-color: var(--text-muted);
}

.dice-toggle.active {
    background: var(--red-dim);
    border-color: var(--text-primary);
    color: var(--text-primary);
}

.dice-toggle svg {
    width: 16px;
    height: 16px;
}

/* ========================================
   DICE SELECTOR - Kompaktes Card Layout
   ======================================== */

.dice-orbit {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    flex-wrap: wrap;
    padding: 16px 24px;
    background: #1b1b1b;
    border: none;
    border-radius: 12px;
    overflow: visible;
    position: relative;
}

.dice-orbit:hover {
    /* keine Border-Änderung */
}

.dice-orb {
    position: relative;
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.3);
    border: 2px solid rgba(255, 255, 255, 0.1);
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 2px;
}

.dice-orb:hover {
    transform: scale(1.15) translateY(-4px);
    border-color: var(--dice-color);
    background: rgba(0, 0, 0, 0.5);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.3);
}

.dice-orb.selected {
    border-color: var(--dice-color);
    background: color-mix(in srgb, var(--dice-color) 15%, transparent);
    box-shadow: 0 0 25px color-mix(in srgb, var(--dice-color) 40%, transparent);
}

.dice-orb__svg {
    width: 24px;
    height: 24px;
    fill: none;
    stroke: var(--dice-color);
    stroke-width: 1.5;
}

.dice-orb__label {
    font-size: 10px;
    font-weight: 700;
    color: var(--text-muted);
}

.dice-orb__count {
    position: absolute;
    top: -6px;
    right: -6px;
    min-width: 20px;
    height: 20px;
    padding: 0 5px;
    background: var(--accent);
    border-radius: 10px;
    font-size: 11px;
    font-weight: 700;
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    transform: scale(0);
    transition: transform 0.2s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.dice-orb.selected .dice-orb__count {
    transform: scale(1);
}

.dice-orb--d4,
.dice-orb--d6,
.dice-orb--d8,
.dice-orb--d10,
.dice-orb--d12,
.dice-orb--d20,
.dice-orb--d100 { --dice-color: var(--dice-accent); }

/* ========================================
   QUICK ACTIONS
   ======================================== */

.dice-quick-row {
    display: flex;
    justify-content: center;
    gap: 8px;
    flex-wrap: wrap;
}

.dice-preset {
    padding: 8px 14px;
    background: var(--bg-elevated);
    border: 1px solid var(--border);
    border-radius: 20px;
    color: var(--text-muted);
    font-family: var(--font-mono);
    font-size: 13px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.dice-preset:hover {
    border-color: var(--text-primary);
    color: var(--text-primary);
}

/* Advantage/Disadvantage */
.dice-adv-btn {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 8px 14px;
    background: var(--bg-elevated);
    border: 1px solid var(--border);
    border-radius: 20px;
    color: var(--text-muted);
    font-size: 12px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.dice-adv-btn:hover {
    border-color: var(--success);
    color: var(--success);
}

.dice-adv-btn--dis:hover {
    border-color: #f44336;
    color: #f44336;
    background: rgba(244, 67, 54, 0.1);
}

.dice-adv-btn svg {
    width: 16px;
    height: 16px;
}

/* Repeat Button */
.dice-repeat-btn {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 8px 14px;
    background: var(--bg-elevated);
    border: 1px solid var(--border);
    border-radius: 20px;
    color: var(--text-muted);
    font-size: 12px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.dice-repeat-btn:hover {
    border-color: var(--text-primary);
    color: var(--text-primary);
}

.dice-repeat-btn:disabled {
    opacity: 0.4;
    cursor: not-allowed;
}

.dice-repeat-btn svg {
    width: 16px;
    height: 16px;
}

/* ========================================
   ROLL ZONE
   ======================================== */

.dice-roll-zone-OLD-HIDDEN {
    display: grid;
    grid-template-columns: 1fr auto auto;
    gap: 12px;
    align-items: center;
    padding: 16px;
    background: var(--bg-elevated);
    border: 1px solid var(--border);
    border-radius: 16px;
}

/* Custom Notation Input */
.dice-notation {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 0 12px;
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: 12px;
    transition: border-color 0.2s ease;
}

.dice-notation:focus-within {
    border-color: var(--text-primary);
}

.dice-notation__input {
    flex: 1;
    min-width: 0;
    padding: 12px 0;
    background: transparent;
    border: none;
    color: var(--text);
    font-family: var(--font-mono);
    font-size: 16px;
}

.dice-notation__input::placeholder {
    color: var(--text-dim);
}

.dice-notation__input:focus {
    outline: none;
}

.dice-notation__clear {
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: transparent;
    border: none;
    color: var(--text-dim);
    cursor: pointer;
    opacity: 0;
    transition: opacity 0.2s ease;
}

.dice-notation:focus-within .dice-notation__clear,
.dice-notation__input:not(:placeholder-shown) + .dice-notation__clear {
    opacity: 1;
}

.dice-notation__clear:hover {
    color: var(--text-primary);
}

/* Modifier */
.dice-modifier {
    display: flex;
    align-items: center;
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: 10px;
}

.dice-modifier__btn {
    width: 40px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: transparent;
    border: none;
    color: var(--text-muted);
    font-size: 18px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.dice-modifier__btn:hover {
    color: var(--text-primary);
}

.dice-modifier__value {
    width: 50px;
    padding: 8px 0;
    background: transparent;
    border: none;
    border-left: 1px solid var(--border);
    border-right: 1px solid var(--border);
    color: var(--text);
    font-family: var(--font-mono);
    font-size: 16px;
    text-align: center;
}

.dice-modifier__value:focus {
    outline: none;
}

/* Roll Button */
.dice-roll-btn {
    height: 52px;
    padding: 0 32px;
    background: linear-gradient(135deg, var(--accent) 0%, #c73847 100%);
    border: none;
    border-radius: 16px;
    color: white;
    font-family: var(--font-display);
    font-size: 22px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    box-shadow: 0 4px 20px rgba(255, 70, 85, 0.3);
    position: relative;
    overflow: hidden;
}

.dice-roll-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
    transition: left 0.5s ease;
}

.dice-roll-btn:hover::before {
    left: 100%;
}

.dice-roll-btn:hover {
    transform: translateY(-3px) scale(1.02);
    box-shadow: 0 12px 35px rgba(255, 70, 85, 0.5);
}

.dice-roll-btn:active {
    transform: translateY(-1px) scale(0.98);
}

.dice-roll-btn:disabled {
    opacity: 0.4;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

.dice-roll-btn.rolling {
    animation: rollPulse 0.3s ease infinite;
    box-shadow: 0 0 40px rgba(255, 70, 85, 0.6);
}

@keyframes rollPulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.03); }
}

/* ========================================
   HISTORY
   ======================================== */

.dice-history {
    padding: 16px;
    background: #1b1b1b;
    border: 1px solid var(--border);
    border-radius: 12px;
    overflow: hidden;
    max-width: 100%;
}

.dice-history:hover {
    border-color: var(--border-hover);
}

.dice-history__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 12px;
}

.dice-history__title {
    font-size: 11px;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.5);
    text-transform: uppercase;
    letter-spacing: 1px;
}

.dice-history__actions {
    display: flex;
    gap: 6px;
    align-items: center;
}

.dice-history__export {
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #252525;
    border: 1px solid transparent;
    border-radius: 8px;
    color: rgba(255, 255, 255, 0.5);
    cursor: pointer;
    transition: all 0.2s ease;
}

.dice-history__export:hover {
    background: rgba(76, 175, 80, 0.1);
    border-color: #4caf50;
    color: #4caf50;
}

.dice-history__export svg {
    width: 14px;
    height: 14px;
}

.dice-history__stats {
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #252525;
    border: 1px solid transparent;
    border-radius: 8px;
    color: rgba(255, 255, 255, 0.5);
    cursor: pointer;
    transition: all 0.2s ease;
}

.dice-history__stats:hover,
.dice-history__stats.active {
    background: rgba(156, 39, 176, 0.1);
    border-color: #9c27b0;
    color: #9c27b0;
}

.dice-history__stats svg {
    width: 14px;
    height: 14px;
}

/* Stats Panel */
.dice-stats {
    display: none;
    gap: 12px;
    padding: 12px;
    background: #1a1a1a;
    border-radius: 10px;
    margin-bottom: 12px;
}

.dice-stats.visible {
    display: flex;
}

.dice-stats__item {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
    padding: 8px;
    background: #252525;
    border-radius: 8px;
}

.dice-stats__value {
    font-family: 'Dharma Gothic', sans-serif;
    font-size: 24px;
    font-weight: 700;
    color: var(--text-primary);
}

.dice-stats__label {
    font-size: 10px;
    color: rgba(255, 255, 255, 0.5);
    text-transform: uppercase;
}

.dice-stats__item--success .dice-stats__value {
    color: #4caf50;
}

.dice-stats__item--failure .dice-stats__value {
    color: #f44336;
}

/* Probability Tooltip */
.dice-probability-tooltip {
    position: fixed;
    z-index: 10000;
    background: #1a1a1a;
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 10px;
    padding: 12px 16px;
    min-width: 160px;
    opacity: 0;
    visibility: hidden;
    transform: translateX(-50%) translateY(-100%);
    transition: all 0.2s ease;
    pointer-events: none;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4);
}

.dice-probability-tooltip.visible {
    opacity: 1;
    visibility: visible;
}

.dice-probability-tooltip__title {
    font-family: 'Inter', sans-serif;
    font-size: 18px;
    font-weight: 700;
    color: white;
    text-align: center;
    margin-bottom: 10px;
    padding-bottom: 8px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.dice-probability-tooltip__content {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.prob-row {
    display: flex;
    justify-content: space-between;
    font-size: 12px;
    color: rgba(255, 255, 255, 0.7);
}

.prob-row span:last-child {
    font-weight: 600;
    color: var(--text-primary);
}

.prob-row--crit span:last-child {
    color: #4caf50;
}

.prob-row--fumble span:last-child {
    color: #f44336;
}

.prob-row--adv span:last-child {
    color: #64b5f6;
}

.prob-section {
    font-size: 10px;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.5);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-top: 8px;
    margin-bottom: 4px;
    padding-top: 6px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.prob-section:first-of-type {
    margin-top: 4px;
    padding-top: 0;
    border-top: none;
}

.prob-hint {
    font-size: 10px;
    color: rgba(255, 255, 255, 0.4);
    font-style: italic;
    margin-top: 6px;
    padding-top: 6px;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.dice-history__clear {
    padding: 6px 10px;
    background: #252525;
    border: 1px solid transparent;
    border-radius: 8px;
    color: rgba(255, 255, 255, 0.5);
    font-size: 10px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.dice-history__clear:hover {
    background: rgba(255, 70, 85, 0.1);
    border-color: var(--text-primary);
    color: var(--text-primary);
}

.dice-history__list {
    display: flex;
    gap: 10px;
    overflow-x: auto;
    padding-bottom: 6px;
    scrollbar-width: thin;
}

.dice-history__item {
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
    padding: 8px 12px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 8px;
    min-width: 70px;
    max-width: 100px;
    transition: all 0.2s ease;
}

.dice-history__item:hover {
    background: #2a2a2a;
    border-color: rgba(255, 255, 255, 0.1);
    transform: translateY(-2px);
}

.dice-history__item--crit {
    background: rgba(76, 175, 80, 0.1);
    border: 1px solid rgba(76, 175, 80, 0.3);
}

.dice-history__item--fumble {
    background: rgba(244, 67, 54, 0.1);
    border: 1px solid rgba(244, 67, 54, 0.3);
}

.dice-history__player {
    font-size: 11px;
    font-weight: 600;
    color: var(--text-primary);
    max-width: 100%;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.dice-history__value {
    font-family: var(--font-display);
    font-size: 24px;
    font-weight: 700;
    color: white;
}

.dice-history__item--crit .dice-history__value {
    color: #4caf50;
}

.dice-history__item--fumble .dice-history__value {
    color: #f44336;
}

.dice-history__notation {
    font-family: var(--font-mono);
    font-size: 10px;
    color: rgba(255, 255, 255, 0.5);
    max-width: 100%;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.dice-history__time {
    font-size: 9px;
    color: rgba(255, 255, 255, 0.3);
}

.dice-history__empty {
    text-align: center;
    padding: 12px;
    color: rgba(255, 255, 255, 0.3);
    font-size: 12px;
}

/* ========================================
   PARTICLES
   ======================================== */

.dice-particles {
    position: absolute;
    top: 50%;
    left: 50%;
    pointer-events: none;
    z-index: 25;
}

.dice-particle {
    position: absolute;
    border-radius: 50%;
    animation: particleExplode 0.8s ease-out forwards;
}

@keyframes particleExplode {
    0% { opacity: 1; transform: translate(0, 0) scale(1); }
    100% { opacity: 0; transform: translate(var(--tx), var(--ty)) scale(0); }
}

/* Arena Effects */
.dice-arena.throwing {
    animation: arenaThrow 0.3s ease;
}

@keyframes arenaThrow {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(0.99); }
}

.dice-arena.shake {
    animation: arenaShake 0.5s ease;
}

@keyframes arenaShake {
    0%, 100% { transform: translateX(0); }
    20% { transform: translateX(-6px); }
    40% { transform: translateX(6px); }
    60% { transform: translateX(-4px); }
    80% { transform: translateX(4px); }
}

/* ========================================
   RESPONSIVE
   ======================================== */

@media (max-width: 768px) {
    .dice-page {
        padding: 16px;
        gap: 12px;
    }
    
    .dice-toolbar {
        flex-wrap: wrap;
        gap: 10px;
    }
    
    .dice-orbit {
        gap: 6px;
        padding: 12px;
    }
    
    .dice-orb {
        width: 46px;
        height: 46px;
    }
    
    .dice-orb__svg {
        width: 20px;
        height: 20px;
    }
    
    .dice-orb__label {
        font-size: 8px;
    }
    
    .dice-roll-zone {
        grid-template-columns: 1fr;
        gap: 10px;
    }
    
    .dice-modifier {
        justify-self: center;
    }
    
    .dice-roll-btn {
        width: 100%;
    }
    
    .dice-quick-row {
        gap: 6px;
    }
    
    .dice-preset,
    .dice-adv-btn,
    .dice-repeat-btn {
        padding: 6px 10px;
        font-size: 11px;
    }
    
    .dice-result__total {
        font-size: 40px;
    }
    
    .dice-feed {
        top: 10px;
        right: 10px;
    }
    
    .dice-feed__item {
        padding: 6px 10px;
    }
    
    .dice-feed__result {
        font-size: 20px;
    }
}

/* ========================================
   SIMPLIFIED MODE - HIDE CLUTTER
   ======================================== */

/* Hide toolbar - move themes to a settings panel later */
.dice-toolbar {
    display: none !important;
}

/* Hide quick actions row */
.dice-quick-row {
    display: none !important;
}

/* Hide custom notation input area */
.dice-notation {
    display: none !important;
}

/* Compact dice orbit */
.dice-orbit {
    padding: 14px 16px;
    gap: 8px;
}

.dice-orb {
    width: 50px;
    height: 50px;
}

.dice-orb__svg {
    width: 22px;
    height: 22px;
}

.dice-orb__label {
    font-size: 9px;
}

/* Compact roll zone */
.dice-roll-zone {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 12px;
    padding: 14px 20px;
    background: rgba(30, 30, 30, 0.6);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 18px;
}

/* Bigger, more prominent roll button */
.dice-roll-btn {
    height: 52px;
    padding: 0 40px;
    font-size: 22px;
    min-width: 160px;
}

/* Better modifier styling */
.dice-modifier {
    display: flex;
    align-items: center;
    gap: 4px;
    background: rgba(0, 0, 0, 0.3);
    border-radius: 14px;
    padding: 4px;
}

.dice-modifier__btn {
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: transparent;
    border: none;
    border-radius: 10px;
    color: var(--text-muted);
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.dice-modifier__btn:hover {
    background: rgba(255, 255, 255, 0.1);
    color: var(--text);
}

.dice-modifier__btn--md {
    font-size: 12px;
    color: var(--text-dim);
}

.dice-modifier__btn--lg {
    font-size: 11px;
}

.dice-modifier__btn--lg:hover {
    /* Normal hover, keine opacity Änderung */
}

.dice-modifier__value {
    width: 50px;
    height: 36px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    color: var(--text);
    font-family: var(--font-mono);
    font-size: 16px;
    font-weight: 600;
    text-align: center;
    -moz-appearance: textfield;
}

.dice-modifier__value::-webkit-outer-spin-button,
.dice-modifier__value::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

.dice-modifier__value:focus {
    outline: none;
    border-color: var(--text-primary);
}

/* Show settings via a floating button */
.dice-page::after {
    content: '';
    display: none; /* Placeholder for future settings button */
}

/* ========================================
   MOBILE ADJUSTMENTS
   ======================================== */

@media (max-width: 600px) {
    .dice-page {
        padding: 16px;
        gap: 10px;
    }
    
    .dice-orbit {
        padding: 12px;
        gap: 6px;
        flex-wrap: wrap;
        justify-content: center;
    }
    
    .dice-orb {
        width: 44px;
        height: 44px;
    }
    
    .dice-orb__svg {
        width: 18px;
        height: 18px;
    }
    
    .dice-orb__label {
        font-size: 8px;
    }
    
    .dice-roll-zone {
        flex-wrap: wrap;
        padding: 12px;
        gap: 10px;
    }
    
    .dice-roll-btn {
        width: 100%;
        order: -1;
    }
    
    .dice-modifier {
        order: 1;
    }
    
    /* Hide large modifier buttons on mobile */
    .dice-modifier__btn--lg {
        display: none;
    }
    
    .dice-modifier__btn--md {
        font-size: 11px;
    }
    
    .dice-action-group {
        order: 2;
    }
}

/* ========================================
   ACTION GROUP (Vorteil/Nachteil/Reset/Settings)
   ======================================== */

.dice-action-group {
    display: flex;
    align-items: center;
    gap: 6px;
    background: rgba(0, 0, 0, 0.3);
    border-radius: 14px;
    padding: 4px;
}

.dice-action-btn {
    width: 40px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: transparent;
    border: none;
    border-radius: 10px;
    color: var(--text-muted);
    cursor: pointer;
    transition: all 0.2s ease;
}

.dice-action-btn:hover {
    background: rgba(255, 255, 255, 0.1);
    color: var(--text);
}

.dice-action-btn--adv {
    color: #22c55e;
}

.dice-action-btn--adv:hover {
    background: rgba(34, 197, 94, 0.15);
    color: #22c55e;
}

.dice-action-btn--dis {
    color: #f44336;
}

.dice-action-btn--dis:hover {
    background: rgba(244, 67, 54, 0.15);
    color: #f44336;
}

.dice-action-btn--reset:hover {
    background: rgba(255, 70, 85, 0.15);
    color: var(--text-primary);
}

.dice-action-btn svg {
    width: 20px;
    height: 20px;
}

.dice-action-divider {
    width: 1px;
    height: 24px;
    background: rgba(255, 255, 255, 0.1);
    margin: 0 2px;
}

/* ========================================
   SETTINGS DRAWER
   ======================================== */

/* ========================================
   SETTINGS POPUP
   ======================================== */

.dice-settings-wrapper {
    position: relative;
    z-index: 100;
}

/* Popup - IMMER im Vordergrund */
.dice-settings-popup {
    display: none;
    position: fixed !important;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 500px;
    height: 600px;
    padding: 20px;
    background: #1b1b1b;
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 12px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.6);
    z-index: 99999 !important;
    overflow: hidden;
    isolation: isolate;
    flex-direction: column;
}

/* Scrollbar styling for popup */
.dice-settings-popup::-webkit-scrollbar {
    width: 6px;
}
.dice-settings-popup::-webkit-scrollbar-track {
    background: transparent;
}
.dice-settings-popup::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.2);
    border-radius: 3px;
}
.dice-settings-popup::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.3);
}

.dice-settings-popup.open {
    display: flex;
}

@keyframes popupFadeIn {
    from {
        opacity: 0;
        transform: translateY(8px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.dice-settings-popup__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 16px;
    padding-bottom: 12px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    flex-shrink: 0;
}

.dice-settings-popup__header span {
    font-size: 14px;
    font-weight: 600;
    color: white;
}

.dice-settings-popup__close {
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: transparent;
    border: none;
    border-radius: 6px;
    color: rgba(255, 255, 255, 0.5);
    cursor: pointer;
    transition: all 0.2s ease;
}

.dice-settings-popup__close:hover {
    background: rgba(255, 255, 255, 0.1);
    color: white;
}

/* Settings Tabs */
.dice-settings-tabs {
    display: flex;
    gap: 4px;
    padding: 0 16px 12px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    margin-bottom: 0;
    flex-shrink: 0;
}

.dice-settings-tab {
    flex: 1;
    padding: 10px 16px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    color: rgba(255, 255, 255, 0.6);
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
}

.dice-settings-tab:hover {
    background: rgba(255, 255, 255, 0.1);
    color: rgba(255, 255, 255, 0.8);
}

.dice-settings-tab.active {
    background: rgba(255, 255, 255, 0.15);
    border-color: rgba(255, 255, 255, 0.2);
    color: white;
}

/* Tab Content */
.dice-settings-tab-content {
    display: none;
}

.dice-settings-tab-content.active {
    display: block;
    flex: 1;
    overflow-y: auto;
    min-height: 0;
}

.dice-settings-tab-content.active::-webkit-scrollbar {
    width: 5px;
}
.dice-settings-tab-content.active::-webkit-scrollbar-track {
    background: transparent;
}
.dice-settings-tab-content.active::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.15);
    border-radius: 3px;
}
.dice-settings-tab-content.active::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.25);
}

/* Label Color Grid */
.dice-label-color-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 10px;
}

.dice-label-color-btn {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    padding: 12px 8px;
    background: rgba(255, 255, 255, 0.05);
    border: 2px solid transparent;
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.dice-label-color-btn:hover {
    background: rgba(255, 255, 255, 0.1);
    transform: translateY(-2px);
}

.dice-label-color-btn.active {
    background: rgba(255, 255, 255, 0.15);
    border-color: #8b5cf6;
}

.dice-label-color-preview {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: 2px solid rgba(255, 255, 255, 0.2);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

.dice-label-color-preview--auto {
    background: linear-gradient(135deg, #ffffff 0%, #ffffff 50%, #1a1a1a 50%, #1a1a1a 100%);
}

.dice-label-color-btn span {
    font-size: 11px;
    color: rgba(255, 255, 255, 0.7);
    font-weight: 500;
}

.dice-label-color-btn.active span {
    color: white;
}

/* ========================================
   ARENA THEME SELECTOR
   ======================================== */

.dice-arena-theme-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
}

.dice-arena-theme-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    padding: 12px;
    background: rgba(255, 255, 255, 0.05);
    border: 2px solid transparent;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.dice-arena-theme-card:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.2);
}

.dice-arena-theme-card.active {
    background: rgba(255, 70, 85, 0.15);
    border-color: var(--accent);
}

.dice-arena-theme-preview {
    width: 100%;
    height: 60px;
    border-radius: 8px;
    overflow: hidden;
    position: relative;
}

.dice-arena-theme-card span {
    font-size: 12px;
    color: rgba(255, 255, 255, 0.7);
    font-weight: 500;
}

.dice-arena-theme-card.active span {
    color: white;
}

/* Arena Theme Previews */
.dice-arena-theme-preview--rift {
    background: url('https://res.cloudinary.com/dza4jgreq/image/upload/v1770181215/rift-assets/cf0ew69drn3yd5max2jr.png') center/cover no-repeat;
}
.dice-arena-theme-preview--rift-negative {
    background: url('https://res.cloudinary.com/dza4jgreq/image/upload/v1770217425/rift-assets/ppyadxq8t37oj5nfytvb.png') center/cover no-repeat;
}
.dice-arena-theme-preview--rift-tag {
    background: url('https://res.cloudinary.com/dza4jgreq/image/upload/v1770217429/rift-assets/cqrjsukgmwlpwyezcbdl.png') center/cover no-repeat;
}
.dice-arena-theme-preview--rift-tag-negative {
    background: url('https://res.cloudinary.com/dza4jgreq/image/upload/v1770217434/rift-assets/ee5vhoakgzxfsez5d5w9.png') center/cover no-repeat;
}
.dice-arena-theme-preview--rift-rest-easy {
    background: url('https://res.cloudinary.com/dza4jgreq/image/upload/v1770217435/rift-assets/mjim6aws4nagnnxrxlae.png') center/cover no-repeat;
}
.dice-arena-theme-preview--rift-rest-easy-negative {
    background: url('https://res.cloudinary.com/dza4jgreq/image/upload/v1770217436/rift-assets/d3nh07m2gyxer7wdtvzv.png') center/cover no-repeat;
}
.dice-arena-theme-preview--rift-punk {
    background: url('https://res.cloudinary.com/dza4jgreq/image/upload/v1770217439/rift-assets/ttxtvwpvcicohknluxi5.png') center/cover no-repeat;
}
.dice-arena-theme-preview--rift-punk-alt {
    background: url('https://res.cloudinary.com/dza4jgreq/image/upload/v1770217441/rift-assets/tgt9azhgs7sqkxbrdh0d.png') center/cover no-repeat;
}
.dice-arena-theme-preview--rift-leather {
    background: url('https://res.cloudinary.com/dza4jgreq/image/upload/v1770217443/rift-assets/mmt55vukt4tbbpek8hlw.png') center/cover no-repeat;
}
.dice-arena-theme-preview--rift-leather-negative {
    background: url('https://res.cloudinary.com/dza4jgreq/image/upload/v1770217445/rift-assets/dlx8hdckjzuw6ijrtrjt.png') center/cover no-repeat;
}
.dice-arena-theme-preview--rift-the-dice {
    background: url('https://res.cloudinary.com/dza4jgreq/image/upload/v1770221299/rift-assets/njzk9ipytyvsyixmmjka.png') center/cover no-repeat;
}
.dice-arena-theme-preview--rift-the-dice-alt {
    background: url('https://res.cloudinary.com/dza4jgreq/image/upload/v1770221300/rift-assets/vkspd72cmbmydflhd4qk.png') center/cover no-repeat;
}

.dice-arena-theme-preview--grid {
    background: #1b1b1b;
    background-image: 
        linear-gradient(rgba(255,255,255,0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255,255,255,0.03) 1px, transparent 1px);
    background-size: 12px 12px;
}

.dice-arena-theme-preview--tavern {
    background: linear-gradient(135deg, #3d2817 0%, #5c3d2a 50%, #2a1a0f 100%);
    position: relative;
}
.dice-arena-theme-preview--tavern::after {
    content: '';
    position: absolute;
    inset: 0;
    background-image: 
        repeating-linear-gradient(90deg, transparent, transparent 15px, rgba(0,0,0,0.15) 15px, rgba(0,0,0,0.15) 16px);
}

.dice-arena-theme-preview--casino {
    background: #0d5c36;
    background-image: radial-gradient(circle, rgba(255,255,255,0.03) 1px, transparent 1px);
    background-size: 6px 6px;
}

.dice-arena-theme-preview--dungeon {
    background: linear-gradient(135deg, #2a2a2a 0%, #1a1a1a 50%, #0f0f0f 100%);
    background-image: 
        repeating-linear-gradient(0deg, transparent, transparent 6px, rgba(0,0,0,0.3) 6px, rgba(0,0,0,0.3) 7px),
        repeating-linear-gradient(90deg, transparent, transparent 6px, rgba(0,0,0,0.3) 6px, rgba(0,0,0,0.3) 7px);
}

.dice-arena-theme-preview--arcane {
    background: radial-gradient(circle at center, #1a0a2e 0%, #0d0518 100%);
    position: relative;
}
.dice-arena-theme-preview--arcane::after {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at center, transparent 30%, rgba(138, 43, 226, 0.2) 50%, transparent 70%);
}

.dice-arena-theme-preview--cyber {
    background: #0a0a12;
    background-image: 
        linear-gradient(rgba(0, 255, 255, 0.1) 1px, transparent 1px),
        linear-gradient(90deg, rgba(0, 255, 255, 0.1) 1px, transparent 1px);
    background-size: 10px 10px;
}

.dice-arena-theme-preview--nebula {
    background: linear-gradient(135deg, #0d0221 0%, #1a0533 30%, #2d1b4e 60%, #1a0533 100%);
    position: relative;
}
.dice-arena-theme-preview--nebula::after {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at 30% 50%, rgba(255, 100, 200, 0.2) 0%, transparent 40%),
                radial-gradient(circle at 70% 30%, rgba(100, 150, 255, 0.2) 0%, transparent 30%);
}

.dice-arena-theme-preview--lava {
    background: linear-gradient(180deg, #1a0500 0%, #2d0800 50%, #1a0500 100%);
    position: relative;
}
.dice-arena-theme-preview--lava::after {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(ellipse at 50% 100%, rgba(255, 50, 0, 0.5) 0%, transparent 60%);
}

.dice-arena-theme-preview--frost {
    background: linear-gradient(180deg, #0a1a2e 0%, #1a3050 50%, #0a1a2e 100%);
    position: relative;
}
.dice-arena-theme-preview--frost::after {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at 50% 0%, rgba(150, 220, 255, 0.2) 0%, transparent 50%);
}

.dice-arena-theme-preview--parchment {
    background: linear-gradient(135deg, #b8a080 0%, #a89070 50%, #9a8262 100%);
    position: relative;
}
.dice-arena-theme-preview--parchment::after {
    content: '';
    position: absolute;
    inset: 0;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 100 100' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9'/%3E%3C/filter%3E%3Crect width='100' height='100' filter='url(%23n)' opacity='0.12'/%3E%3C/svg%3E");
}

/* Additional Theme Previews */
.dice-arena-theme-preview--ocean {
    background: linear-gradient(180deg, #0a1628 0%, #0d2847 50%, #0a1628 100%);
    position: relative;
}
.dice-arena-theme-preview--ocean::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, transparent 40%, rgba(30, 144, 255, 0.2) 100%);
}

.dice-arena-theme-preview--forest {
    background: linear-gradient(180deg, #0a1a0a 0%, #0d260d 50%, #081408 100%);
    position: relative;
}
.dice-arena-theme-preview--forest::after {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at 50% 100%, rgba(34, 139, 34, 0.3) 0%, transparent 60%);
}

.dice-arena-theme-preview--bloodmoon {
    background: linear-gradient(180deg, #1a0a0a 0%, #2d0d0d 50%, #1a0505 100%);
    position: relative;
}
.dice-arena-theme-preview--bloodmoon::after {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at 70% 20%, rgba(180, 0, 0, 0.3) 0%, transparent 40%);
}

.dice-arena-theme-preview--desert {
    background: linear-gradient(180deg, #3d3020 0%, #5c4a30 50%, #3d3020 100%);
}

.dice-arena-theme-preview--void {
    background: #050505;
}

.dice-arena-theme-preview--marble {
    background: linear-gradient(135deg, #e8e8e8 0%, #d0d0d0 25%, #e0e0e0 50%, #c8c8c8 75%, #e8e8e8 100%);
}

.dice-arena-theme-preview--gothic {
    background: linear-gradient(180deg, #1a1a1a 0%, #2a2020 50%, #1a1515 100%);
    position: relative;
}
.dice-arena-theme-preview--gothic::after {
    content: '';
    position: absolute;
    inset: 0;
    background: repeating-linear-gradient(90deg, transparent 0px, transparent 10px, rgba(80,0,0,0.1) 10px, rgba(80,0,0,0.1) 11px);
}

.dice-arena-theme-preview--steampunk {
    background: linear-gradient(135deg, #2a2015 0%, #3d3020 50%, #2a2015 100%);
    position: relative;
}
.dice-arena-theme-preview--steampunk::after {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at 30% 50%, rgba(184, 134, 11, 0.2) 0%, transparent 30%),
                radial-gradient(circle at 70% 50%, rgba(184, 134, 11, 0.2) 0%, transparent 30%);
}

.dice-arena-theme-preview--neonpink {
    background: #0a0510;
    position: relative;
}
.dice-arena-theme-preview--neonpink::after {
    content: '';
    position: absolute;
    inset: 0;
    background-image: 
        linear-gradient(rgba(255, 0, 128, 0.1) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 0, 128, 0.1) 1px, transparent 1px);
    background-size: 10px 10px;
}

.dice-arena-theme-preview--matrix {
    background: #000800;
    position: relative;
}
.dice-arena-theme-preview--matrix::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(0, 255, 0, 0.1) 0%, transparent 50%, rgba(0, 255, 0, 0.05) 100%);
}

.dice-arena-theme-preview--starfield {
    background: #05050a;
    position: relative;
}
.dice-arena-theme-preview--starfield::after {
    content: '';
    position: absolute;
    inset: 0;
    background-image: 
        radial-gradient(1px 1px at 10% 20%, white, transparent),
        radial-gradient(1px 1px at 30% 60%, white, transparent),
        radial-gradient(1px 1px at 50% 30%, white, transparent),
        radial-gradient(1px 1px at 70% 70%, white, transparent),
        radial-gradient(1px 1px at 90% 40%, white, transparent),
        radial-gradient(2px 2px at 20% 80%, rgba(255,255,255,0.8), transparent),
        radial-gradient(2px 2px at 80% 10%, rgba(255,255,255,0.8), transparent);
}

.dice-arena-theme-preview--sakura {
    background: linear-gradient(180deg, #1a1015 0%, #2a1a20 50%, #1a1015 100%);
    position: relative;
}
.dice-arena-theme-preview--sakura::after {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at 50% 0%, rgba(255, 182, 193, 0.2) 0%, transparent 50%);
}

/* More Theme Previews */
.dice-arena-theme-preview--inferno {
    background: linear-gradient(180deg, #1a0500 0%, #3d0a00 50%, #1a0500 100%);
    position: relative;
}
.dice-arena-theme-preview--inferno::after {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(ellipse at 50% 80%, rgba(255, 100, 0, 0.4) 0%, transparent 50%);
}

.dice-arena-theme-preview--twilight {
    background: linear-gradient(180deg, #1a1030 0%, #2d1845 50%, #0d0820 100%);
    position: relative;
}
.dice-arena-theme-preview--twilight::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(255, 150, 100, 0.15) 0%, transparent 40%);
}

.dice-arena-theme-preview--crystal {
    background: linear-gradient(135deg, #1a2030 0%, #253045 50%, #1a2030 100%);
    position: relative;
}
.dice-arena-theme-preview--crystal::after {
    content: '';
    position: absolute;
    inset: 0;
    background: 
        linear-gradient(60deg, transparent 40%, rgba(150, 200, 255, 0.15) 50%, transparent 60%),
        linear-gradient(-60deg, transparent 40%, rgba(150, 200, 255, 0.1) 50%, transparent 60%);
}

.dice-arena-theme-preview--mossy {
    background: linear-gradient(180deg, #1a1a15 0%, #252520 50%, #1a1a15 100%);
    position: relative;
}
.dice-arena-theme-preview--mossy::after {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at 30% 70%, rgba(80, 120, 60, 0.2) 0%, transparent 40%);
}

.dice-arena-theme-preview--royal {
    background: linear-gradient(135deg, #1a0a20 0%, #2d1040 50%, #1a0a20 100%);
    position: relative;
}
.dice-arena-theme-preview--royal::after {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at 50% 30%, rgba(255, 215, 0, 0.15) 0%, transparent 40%);
}

.dice-arena-theme-preview--eclipse {
    background: radial-gradient(circle at center, #0a0a15 0%, #000005 100%);
    position: relative;
}
.dice-arena-theme-preview--eclipse::after {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at 50% 50%, transparent 15%, rgba(255, 150, 50, 0.3) 20%, transparent 30%);
}

.dice-arena-theme-preview--aurora {
    background: linear-gradient(180deg, #0a0a15 0%, #0d1520 50%, #0a0a15 100%);
    position: relative;
}
.dice-arena-theme-preview--aurora::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, 
        rgba(0, 255, 100, 0.15) 0%, 
        rgba(0, 200, 255, 0.1) 30%, 
        rgba(150, 0, 255, 0.1) 60%, 
        transparent 100%);
}

.dice-arena-theme-preview--storm {
    background: linear-gradient(180deg, #15151a 0%, #1a1a22 50%, #10101a 100%);
    position: relative;
}
.dice-arena-theme-preview--storm::after {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at 70% 30%, rgba(200, 200, 255, 0.15) 0%, transparent 30%);
}

.dice-arena-theme-preview--toxic {
    background: linear-gradient(180deg, #0a0f0a 0%, #0d1a0d 50%, #0a0f0a 100%);
    position: relative;
}
.dice-arena-theme-preview--toxic::after {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(ellipse at 50% 100%, rgba(150, 255, 0, 0.2) 0%, transparent 50%);
}

.dice-arena-theme-preview--copper {
    background: linear-gradient(135deg, #2a1a15 0%, #3d2820 50%, #2a1a15 100%);
    position: relative;
}
.dice-arena-theme-preview--copper::after {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at 30% 30%, rgba(184, 115, 51, 0.2) 0%, transparent 40%);
}

/* ========================================
   ARENA THEMES - Actual Arena Styles
   ======================================== */

/* THE RIFT - New default with custom image */
.dice-arena[data-arena-theme="rift"],
.dice-arena:not([data-arena-theme]) {
    background: url('https://res.cloudinary.com/dza4jgreq/image/upload/v1770181215/rift-assets/cf0ew69drn3yd5max2jr.png') center/cover no-repeat;
    background-color: #1b1b1b;
}
.dice-arena[data-arena-theme="rift"]::after,
.dice-arena:not([data-arena-theme])::after {
    background: none;
}

/* RIFT Negative */
.dice-arena[data-arena-theme="rift-negative"] {
    background: url('https://res.cloudinary.com/dza4jgreq/image/upload/v1770217425/rift-assets/ppyadxq8t37oj5nfytvb.png') center/cover no-repeat #1b1b1b !important;
}
.dice-arena[data-arena-theme="rift-negative"]::after { background: none !important; }

/* RIFT Tag */
.dice-arena[data-arena-theme="rift-tag"] {
    background: url('https://res.cloudinary.com/dza4jgreq/image/upload/v1770217429/rift-assets/cqrjsukgmwlpwyezcbdl.png') center/cover no-repeat #1b1b1b !important;
}
.dice-arena[data-arena-theme="rift-tag"]::after { background: none !important; }

/* RIFT Tag Negative */
.dice-arena[data-arena-theme="rift-tag-negative"] {
    background: url('https://res.cloudinary.com/dza4jgreq/image/upload/v1770217434/rift-assets/ee5vhoakgzxfsez5d5w9.png') center/cover no-repeat #1b1b1b !important;
}
.dice-arena[data-arena-theme="rift-tag-negative"]::after { background: none !important; }

/* RIFT Rest Easy */
.dice-arena[data-arena-theme="rift-rest-easy"] {
    background: url('https://res.cloudinary.com/dza4jgreq/image/upload/v1770217435/rift-assets/mjim6aws4nagnnxrxlae.png') center/cover no-repeat #1b1b1b !important;
}
.dice-arena[data-arena-theme="rift-rest-easy"]::after { background: none !important; }

/* RIFT Rest Easy Negative */
.dice-arena[data-arena-theme="rift-rest-easy-negative"] {
    background: url('https://res.cloudinary.com/dza4jgreq/image/upload/v1770217436/rift-assets/d3nh07m2gyxer7wdtvzv.png') center/cover no-repeat #1b1b1b !important;
}
.dice-arena[data-arena-theme="rift-rest-easy-negative"]::after { background: none !important; }

/* RIFT Punk */
.dice-arena[data-arena-theme="rift-punk"] {
    background: url('https://res.cloudinary.com/dza4jgreq/image/upload/v1770217439/rift-assets/ttxtvwpvcicohknluxi5.png') center/cover no-repeat #1b1b1b !important;
}
.dice-arena[data-arena-theme="rift-punk"]::after { background: none !important; }

/* RIFT Punk Alt */
.dice-arena[data-arena-theme="rift-punk-alt"] {
    background: url('https://res.cloudinary.com/dza4jgreq/image/upload/v1770217441/rift-assets/tgt9azhgs7sqkxbrdh0d.png') center/cover no-repeat #1b1b1b !important;
}
.dice-arena[data-arena-theme="rift-punk-alt"]::after { background: none !important; }

/* RIFT Leather */
.dice-arena[data-arena-theme="rift-leather"] {
    background: url('https://res.cloudinary.com/dza4jgreq/image/upload/v1770217443/rift-assets/mmt55vukt4tbbpek8hlw.png') center/cover no-repeat #1b1b1b !important;
}
.dice-arena[data-arena-theme="rift-leather"]::after { background: none !important; }

/* RIFT Leather Negative */
.dice-arena[data-arena-theme="rift-leather-negative"] {
    background: url('https://res.cloudinary.com/dza4jgreq/image/upload/v1770217445/rift-assets/dlx8hdckjzuw6ijrtrjt.png') center/cover no-repeat #1b1b1b !important;
}
.dice-arena[data-arena-theme="rift-leather-negative"]::after { background: none !important; }

/* RIFT The Dice */
.dice-arena[data-arena-theme="rift-the-dice"] {
    background: url('https://res.cloudinary.com/dza4jgreq/image/upload/v1770221299/rift-assets/njzk9ipytyvsyixmmjka.png') center/cover no-repeat #1b1b1b !important;
}
.dice-arena[data-arena-theme="rift-the-dice"]::after { background: none !important; }

/* RIFT The Dice Alt */
.dice-arena[data-arena-theme="rift-the-dice-alt"] {
    background: url('https://res.cloudinary.com/dza4jgreq/image/upload/v1770221300/rift-assets/vkspd72cmbmydflhd4qk.png') center/cover no-repeat #1b1b1b !important;
}
.dice-arena[data-arena-theme="rift-the-dice-alt"]::after { background: none !important; }

/* Grid (formerly default) - Dark with subtle grid */
.dice-arena[data-arena-theme="grid"] {
    background: #1b1b1b;
}
.dice-arena[data-arena-theme="grid"]::after {
    background-image: 
        linear-gradient(rgba(255,255,255,0.01) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255,255,255,0.01) 1px, transparent 1px);
    background-size: 40px 40px;
}

/* Tavern - Dark wood with grain */
.dice-arena[data-arena-theme="tavern"] {
    background: linear-gradient(135deg, #3d2817 0%, #5c3d2a 30%, #4a3020 60%, #2a1a0f 100%);
}
.dice-arena[data-arena-theme="tavern"]::before {
    background-image: 
        repeating-linear-gradient(90deg, transparent, transparent 80px, rgba(0,0,0,0.2) 80px, rgba(0,0,0,0.2) 82px),
        repeating-linear-gradient(90deg, transparent 0px, rgba(60,40,20,0.1) 20px, transparent 40px),
        repeating-linear-gradient(85deg, transparent, rgba(0,0,0,0.05) 2px, transparent 4px);
    opacity: 0.8;
}
.dice-arena[data-arena-theme="tavern"]::after {
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 100 100' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.8' numOctaves='4'/%3E%3C/filter%3E%3Crect width='100' height='100' filter='url(%23n)' opacity='0.08'/%3E%3C/svg%3E");
    opacity: 0.5;
}

/* Casino - Green felt */
.dice-arena[data-arena-theme="casino"] {
    background: radial-gradient(ellipse at center, #0d6b3f 0%, #0a5530 50%, #073d22 100%);
}
.dice-arena[data-arena-theme="casino"]::before {
    background-image: radial-gradient(circle, rgba(255,255,255,0.02) 1px, transparent 1px);
    background-size: 8px 8px;
}
.dice-arena[data-arena-theme="casino"]::after {
    background: none;
}

/* Dungeon - Stone floor */
.dice-arena[data-arena-theme="dungeon"] {
    background: linear-gradient(180deg, #252525 0%, #1a1a1a 50%, #121212 100%);
}
.dice-arena[data-arena-theme="dungeon"]::before {
    background-image: 
        repeating-linear-gradient(0deg, transparent, transparent 50px, rgba(0,0,0,0.4) 50px, rgba(0,0,0,0.4) 52px),
        repeating-linear-gradient(90deg, transparent, transparent 50px, rgba(0,0,0,0.4) 50px, rgba(0,0,0,0.4) 52px);
    opacity: 0.5;
}
.dice-arena[data-arena-theme="dungeon"]::after {
    background-image: radial-gradient(circle, rgba(0,0,0,0.1) 20%, transparent 20%);
    background-size: 25px 25px;
    opacity: 0.3;
}

/* Arcane - Magic circle with stars */
.dice-arena[data-arena-theme="arcane"] {
    background: radial-gradient(circle at center, #1a0a2e 0%, #12071f 50%, #0d0518 100%);
}
.dice-arena[data-arena-theme="arcane"]::before {
    background: 
        radial-gradient(circle at center, transparent 20%, rgba(138, 43, 226, 0.1) 21%, rgba(138, 43, 226, 0.15) 22%, transparent 23%),
        radial-gradient(circle at center, transparent 35%, rgba(138, 43, 226, 0.08) 36%, rgba(138, 43, 226, 0.12) 37%, transparent 38%),
        radial-gradient(circle at center, transparent 48%, rgba(138, 43, 226, 0.05) 49%, rgba(138, 43, 226, 0.1) 50%, transparent 51%),
        radial-gradient(1px 1px at 20% 30%, white, transparent),
        radial-gradient(1px 1px at 40% 70%, white, transparent),
        radial-gradient(1px 1px at 50% 20%, white, transparent),
        radial-gradient(1px 1px at 60% 50%, white, transparent),
        radial-gradient(1px 1px at 70% 80%, white, transparent),
        radial-gradient(1px 1px at 80% 10%, white, transparent),
        radial-gradient(1px 1px at 90% 60%, white, transparent),
        radial-gradient(1px 1px at 10% 80%, white, transparent),
        radial-gradient(1px 1px at 30% 50%, white, transparent),
        radial-gradient(2px 2px at 15% 15%, rgba(255,255,255,0.8), transparent),
        radial-gradient(2px 2px at 85% 40%, rgba(255,255,255,0.8), transparent),
        radial-gradient(2px 2px at 45% 90%, rgba(255,255,255,0.8), transparent);
    animation: arcane-pulse 4s ease-in-out infinite;
}
.dice-arena[data-arena-theme="arcane"]::after {
    background: 
        radial-gradient(circle at center, rgba(180, 100, 255, 0.05) 0%, transparent 50%);
}
@keyframes arcane-pulse {
    0%, 100% { opacity: 0.6; }
    50% { opacity: 1; }
}

/* Cyber - Neon grid */
.dice-arena[data-arena-theme="cyber"] {
    background: #08080f;
}
.dice-arena[data-arena-theme="cyber"]::before {
    background: 
        linear-gradient(180deg, transparent 0%, rgba(0, 255, 255, 0.03) 50%, transparent 100%);
}
.dice-arena[data-arena-theme="cyber"]::after {
    background-image: 
        linear-gradient(rgba(0, 255, 255, 0.08) 1px, transparent 1px),
        linear-gradient(90deg, rgba(0, 255, 255, 0.08) 1px, transparent 1px);
    background-size: 40px 40px;
    animation: cyber-scan 3s linear infinite;
}
@keyframes cyber-scan {
    0% { background-position: 0 0; }
    100% { background-position: 0 40px; }
}

/* Nebula - Space */
.dice-arena[data-arena-theme="nebula"] {
    background: linear-gradient(135deg, #0d0221 0%, #1a0533 25%, #2d1b4e 50%, #1a0533 75%, #0d0221 100%);
}
.dice-arena[data-arena-theme="nebula"]::before {
    background: 
        radial-gradient(circle at 20% 30%, rgba(255, 100, 200, 0.15) 0%, transparent 30%),
        radial-gradient(circle at 80% 60%, rgba(100, 150, 255, 0.15) 0%, transparent 25%),
        radial-gradient(circle at 50% 80%, rgba(150, 100, 255, 0.1) 0%, transparent 35%);
}
.dice-arena[data-arena-theme="nebula"]::after {
    background-image: radial-gradient(circle, rgba(255,255,255,0.3) 1px, transparent 1px);
    background-size: 50px 50px;
    opacity: 0.3;
}

/* Lava - Volcanic (more red) */
.dice-arena[data-arena-theme="lava"] {
    background: linear-gradient(180deg, #1a0500 0%, #2d0800 30%, #1a0500 60%, #0d0200 100%);
}
.dice-arena[data-arena-theme="lava"]::before {
    background: 
        radial-gradient(ellipse at 30% 90%, rgba(255, 50, 0, 0.35) 0%, transparent 40%),
        radial-gradient(ellipse at 70% 85%, rgba(255, 80, 20, 0.3) 0%, transparent 35%),
        radial-gradient(ellipse at 50% 95%, rgba(255, 30, 0, 0.4) 0%, transparent 50%),
        radial-gradient(ellipse at 20% 80%, rgba(255, 60, 0, 0.25) 0%, transparent 30%),
        radial-gradient(ellipse at 80% 95%, rgba(255, 40, 0, 0.3) 0%, transparent 35%);
    animation: lava-glow 3s ease-in-out infinite;
}
.dice-arena[data-arena-theme="lava"]::after {
    background: none;
}
@keyframes lava-glow {
    0%, 100% { opacity: 0.7; }
    50% { opacity: 1; }
}

/* Frost - Ice */
.dice-arena[data-arena-theme="frost"] {
    background: linear-gradient(180deg, #0a1825 0%, #132840 30%, #1a3555 50%, #132840 70%, #0a1825 100%);
}
.dice-arena[data-arena-theme="frost"]::before {
    background: 
        radial-gradient(circle at 50% 0%, rgba(150, 220, 255, 0.15) 0%, transparent 40%),
        radial-gradient(circle at 20% 20%, rgba(200, 240, 255, 0.1) 0%, transparent 25%),
        radial-gradient(circle at 80% 30%, rgba(180, 230, 255, 0.1) 0%, transparent 20%);
}
.dice-arena[data-arena-theme="frost"]::after {
    background-image: 
        linear-gradient(60deg, transparent 48%, rgba(200, 240, 255, 0.03) 49%, rgba(200, 240, 255, 0.03) 51%, transparent 52%),
        linear-gradient(-60deg, transparent 48%, rgba(200, 240, 255, 0.03) 49%, rgba(200, 240, 255, 0.03) 51%, transparent 52%);
    background-size: 30px 52px;
}

/* Parchment - Old map with grain */
.dice-arena[data-arena-theme="parchment"] {
    background: linear-gradient(135deg, #b8a080 0%, #a89070 25%, #9a8262 50%, #a89070 75%, #b8a080 100%);
}
.dice-arena[data-arena-theme="parchment"]::before {
    background: 
        radial-gradient(circle at 10% 10%, rgba(80, 50, 20, 0.15) 0%, transparent 30%),
        radial-gradient(circle at 90% 90%, rgba(80, 50, 20, 0.2) 0%, transparent 40%),
        radial-gradient(circle at 50% 50%, rgba(80, 50, 20, 0.1) 0%, transparent 50%);
}
.dice-arena[data-arena-theme="parchment"]::after {
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4'/%3E%3C/filter%3E%3Crect width='200' height='200' filter='url(%23n)' opacity='0.15'/%3E%3C/svg%3E");
    opacity: 0.6;
}

/* Ocean - Deep sea */
.dice-arena[data-arena-theme="ocean"] {
    background: linear-gradient(180deg, #0a1628 0%, #0d2847 30%, #0f3060 50%, #0d2847 70%, #0a1628 100%);
}
.dice-arena[data-arena-theme="ocean"]::before {
    background: 
        radial-gradient(ellipse at 50% 100%, rgba(30, 144, 255, 0.15) 0%, transparent 50%),
        radial-gradient(circle at 30% 80%, rgba(0, 191, 255, 0.1) 0%, transparent 30%),
        radial-gradient(circle at 70% 70%, rgba(65, 105, 225, 0.1) 0%, transparent 25%);
}
.dice-arena[data-arena-theme="ocean"]::after {
    background-image: 
        repeating-linear-gradient(0deg, transparent, transparent 60px, rgba(255,255,255,0.02) 60px, rgba(255,255,255,0.02) 61px);
    animation: ocean-waves 4s ease-in-out infinite;
}
@keyframes ocean-waves {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(5px); }
}

/* Forest - Enchanted woods */
.dice-arena[data-arena-theme="forest"] {
    background: linear-gradient(180deg, #0a1a0a 0%, #0d260d 30%, #0f300f 50%, #0d260d 70%, #081408 100%);
}
.dice-arena[data-arena-theme="forest"]::before {
    background: 
        radial-gradient(ellipse at 50% 100%, rgba(34, 139, 34, 0.2) 0%, transparent 50%),
        radial-gradient(circle at 20% 90%, rgba(0, 100, 0, 0.15) 0%, transparent 30%),
        radial-gradient(circle at 80% 85%, rgba(50, 205, 50, 0.1) 0%, transparent 25%);
}
.dice-arena[data-arena-theme="forest"]::after {
    background-image: radial-gradient(circle, rgba(34, 139, 34, 0.03) 1px, transparent 1px);
    background-size: 30px 30px;
}

/* Blood Moon - Dark crimson */
.dice-arena[data-arena-theme="bloodmoon"] {
    background: linear-gradient(180deg, #1a0808 0%, #2d0d0d 30%, #3a1010 50%, #2d0d0d 70%, #1a0505 100%);
}
.dice-arena[data-arena-theme="bloodmoon"]::before {
    background: 
        radial-gradient(circle at 75% 15%, rgba(180, 0, 0, 0.25) 0%, rgba(180, 0, 0, 0.1) 20%, transparent 40%),
        radial-gradient(circle at 20% 80%, rgba(139, 0, 0, 0.1) 0%, transparent 30%);
}
.dice-arena[data-arena-theme="bloodmoon"]::after {
    background: none;
}

/* Desert - Sandy dunes */
.dice-arena[data-arena-theme="desert"] {
    background: linear-gradient(180deg, #3d3020 0%, #5c4a30 30%, #6b5535 50%, #5c4a30 70%, #3d3020 100%);
}
.dice-arena[data-arena-theme="desert"]::before {
    background: 
        radial-gradient(ellipse at 30% 30%, rgba(255, 200, 100, 0.1) 0%, transparent 40%),
        radial-gradient(ellipse at 70% 60%, rgba(255, 180, 80, 0.08) 0%, transparent 35%);
}
.dice-arena[data-arena-theme="desert"]::after {
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 100 100' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.8'/%3E%3C/filter%3E%3Crect width='100' height='100' filter='url(%23n)' opacity='0.05'/%3E%3C/svg%3E");
}

/* Void - Deep darkness with faint stars */
.dice-arena[data-arena-theme="void"] {
    background: #030305;
}
.dice-arena[data-arena-theme="void"]::before {
    background-image: 
        radial-gradient(1px 1px at 15% 25%, rgba(255,255,255,0.3), transparent),
        radial-gradient(1px 1px at 35% 65%, rgba(255,255,255,0.25), transparent),
        radial-gradient(1px 1px at 55% 15%, rgba(255,255,255,0.2), transparent),
        radial-gradient(1px 1px at 75% 45%, rgba(255,255,255,0.3), transparent),
        radial-gradient(1px 1px at 85% 75%, rgba(255,255,255,0.2), transparent),
        radial-gradient(1px 1px at 25% 85%, rgba(255,255,255,0.25), transparent),
        radial-gradient(1px 1px at 45% 35%, rgba(255,255,255,0.15), transparent),
        radial-gradient(1px 1px at 65% 90%, rgba(255,255,255,0.2), transparent),
        radial-gradient(1px 1px at 95% 20%, rgba(255,255,255,0.25), transparent),
        radial-gradient(1px 1px at 5% 55%, rgba(255,255,255,0.2), transparent);
}
.dice-arena[data-arena-theme="void"]::after {
    background: radial-gradient(circle at center, rgba(10, 10, 20, 0.5) 0%, transparent 70%);
}

/* Marble - Elegant stone with veins */
.dice-arena[data-arena-theme="marble"] {
    background: linear-gradient(135deg, #e8e8e8 0%, #d0d0d0 25%, #e0e0e0 50%, #c8c8c8 75%, #e8e8e8 100%);
}
.dice-arena[data-arena-theme="marble"]::before {
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 400 400' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='m'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.015' numOctaves='3' seed='5'/%3E%3CfeDisplacementMap in='SourceGraphic' scale='30'/%3E%3C/filter%3E%3Cfilter id='n'%3E%3CfeTurbulence type='turbulence' baseFrequency='0.01' numOctaves='2'/%3E%3C/filter%3E%3Crect width='400' height='400' fill='%23e0e0e0'/%3E%3Cpath d='M0,200 Q100,180 200,200 T400,190' stroke='%23a0a0a0' stroke-width='3' fill='none' filter='url(%23m)' opacity='0.3'/%3E%3Cpath d='M0,100 Q150,120 300,90 T400,110' stroke='%23909090' stroke-width='2' fill='none' filter='url(%23m)' opacity='0.25'/%3E%3Cpath d='M0,300 Q120,320 250,290 T400,310' stroke='%23a8a8a8' stroke-width='2' fill='none' filter='url(%23m)' opacity='0.2'/%3E%3Crect width='400' height='400' filter='url(%23n)' opacity='0.08'/%3E%3C/svg%3E");
    background-size: cover;
}
.dice-arena[data-arena-theme="marble"]::after {
    background: radial-gradient(ellipse at 30% 30%, rgba(255,255,255,0.3) 0%, transparent 50%);
}

/* Gothic - Dark cathedral */
.dice-arena[data-arena-theme="gothic"] {
    background: linear-gradient(180deg, #1a1a1a 0%, #2a2020 30%, #1a1515 60%, #0f0a0a 100%);
}
.dice-arena[data-arena-theme="gothic"]::before {
    background: 
        repeating-linear-gradient(90deg, transparent 0px, transparent 80px, rgba(60,0,0,0.08) 80px, rgba(60,0,0,0.08) 82px),
        radial-gradient(ellipse at 50% 0%, rgba(100, 0, 0, 0.1) 0%, transparent 50%);
}
.dice-arena[data-arena-theme="gothic"]::after {
    background-image: 
        repeating-linear-gradient(0deg, transparent 0px, transparent 100px, rgba(0,0,0,0.2) 100px, rgba(0,0,0,0.2) 102px);
}

/* Steampunk - Brass and gears */
.dice-arena[data-arena-theme="steampunk"] {
    background: linear-gradient(135deg, #2a2015 0%, #3d3020 30%, #4a3a28 50%, #3d3020 70%, #2a2015 100%);
}
.dice-arena[data-arena-theme="steampunk"]::before {
    background: 
        radial-gradient(circle at 20% 30%, rgba(184, 134, 11, 0.15) 0%, transparent 25%),
        radial-gradient(circle at 80% 70%, rgba(184, 134, 11, 0.15) 0%, transparent 25%),
        radial-gradient(circle at 50% 50%, rgba(139, 90, 43, 0.1) 0%, transparent 40%);
}
.dice-arena[data-arena-theme="steampunk"]::after {
    background-image: 
        radial-gradient(circle, rgba(184, 134, 11, 0.05) 2px, transparent 2px);
    background-size: 40px 40px;
}

/* Neon Pink - Synthwave */
.dice-arena[data-arena-theme="neonpink"] {
    background: linear-gradient(180deg, #0a0510 0%, #150a20 50%, #0a0510 100%);
}
.dice-arena[data-arena-theme="neonpink"]::before {
    background: 
        linear-gradient(180deg, transparent 0%, rgba(255, 0, 128, 0.05) 50%, transparent 100%);
}
.dice-arena[data-arena-theme="neonpink"]::after {
    background-image: 
        linear-gradient(rgba(255, 0, 128, 0.08) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 0, 128, 0.08) 1px, transparent 1px);
    background-size: 40px 40px;
    animation: neon-flicker 0.1s ease-in-out infinite alternate;
}
@keyframes neon-flicker {
    0% { opacity: 0.8; }
    100% { opacity: 1; }
}

/* Matrix - Digital rain (no jarring loop) */
.dice-arena[data-arena-theme="matrix"] {
    background: #000800;
}
.dice-arena[data-arena-theme="matrix"]::before {
    background: 
        linear-gradient(180deg, rgba(0, 255, 0, 0.06) 0%, transparent 30%, rgba(0, 255, 0, 0.03) 100%);
}
.dice-arena[data-arena-theme="matrix"]::after {
    background-image: 
        repeating-linear-gradient(90deg, transparent 0px, transparent 30px, rgba(0, 255, 0, 0.04) 30px, rgba(0, 255, 0, 0.04) 31px),
        repeating-linear-gradient(0deg, transparent 0px, transparent 30px, rgba(0, 255, 0, 0.02) 30px, rgba(0, 255, 0, 0.02) 31px);
    background-size: 31px 31px;
}

/* Starfield - Deep space */
.dice-arena[data-arena-theme="starfield"] {
    background: radial-gradient(ellipse at center, #0a0a15 0%, #050508 100%);
}
.dice-arena[data-arena-theme="starfield"]::before {
    background-image: 
        radial-gradient(1px 1px at 10% 20%, white, transparent),
        radial-gradient(1px 1px at 20% 50%, white, transparent),
        radial-gradient(1px 1px at 30% 30%, white, transparent),
        radial-gradient(1px 1px at 40% 70%, white, transparent),
        radial-gradient(1px 1px at 50% 10%, white, transparent),
        radial-gradient(1px 1px at 60% 60%, white, transparent),
        radial-gradient(1px 1px at 70% 40%, white, transparent),
        radial-gradient(1px 1px at 80% 80%, white, transparent),
        radial-gradient(1px 1px at 90% 25%, white, transparent),
        radial-gradient(1px 1px at 15% 85%, white, transparent),
        radial-gradient(1px 1px at 35% 95%, white, transparent),
        radial-gradient(1px 1px at 55% 45%, white, transparent),
        radial-gradient(1px 1px at 75% 15%, white, transparent),
        radial-gradient(1px 1px at 95% 55%, white, transparent),
        radial-gradient(2px 2px at 25% 35%, rgba(255,255,255,0.8), transparent),
        radial-gradient(2px 2px at 65% 75%, rgba(255,255,255,0.8), transparent),
        radial-gradient(2px 2px at 85% 5%, rgba(255,255,255,0.8), transparent);
    animation: twinkle 3s ease-in-out infinite;
}
.dice-arena[data-arena-theme="starfield"]::after {
    background: radial-gradient(ellipse at 30% 40%, rgba(100, 100, 200, 0.05) 0%, transparent 40%);
}
@keyframes twinkle {
    0%, 100% { opacity: 0.8; }
    50% { opacity: 1; }
}

/* Sakura - Japanese cherry blossom */
.dice-arena[data-arena-theme="sakura"] {
    background: linear-gradient(180deg, #1a1015 0%, #2a1a22 30%, #301e28 50%, #2a1a22 70%, #1a1015 100%);
}
.dice-arena[data-arena-theme="sakura"]::before {
    background: 
        radial-gradient(circle at 50% 0%, rgba(255, 182, 193, 0.15) 0%, transparent 40%),
        radial-gradient(circle at 20% 20%, rgba(255, 192, 203, 0.1) 0%, transparent 25%),
        radial-gradient(circle at 80% 30%, rgba(255, 174, 185, 0.08) 0%, transparent 20%);
}
.dice-arena[data-arena-theme="sakura"]::after {
    background: none;
}

/* Inferno - Fiery depths */
.dice-arena[data-arena-theme="inferno"] {
    background: linear-gradient(180deg, #1a0500 0%, #3d0a00 30%, #4d1000 50%, #3d0a00 70%, #1a0500 100%);
}
.dice-arena[data-arena-theme="inferno"]::before {
    background: 
        radial-gradient(ellipse at 20% 85%, rgba(255, 80, 0, 0.4) 0%, transparent 35%),
        radial-gradient(ellipse at 50% 90%, rgba(255, 50, 0, 0.5) 0%, transparent 40%),
        radial-gradient(ellipse at 80% 80%, rgba(255, 100, 0, 0.35) 0%, transparent 30%),
        radial-gradient(ellipse at 35% 95%, rgba(255, 150, 0, 0.3) 0%, transparent 25%),
        radial-gradient(ellipse at 65% 95%, rgba(255, 60, 0, 0.4) 0%, transparent 30%);
    animation: inferno-flicker 2s ease-in-out infinite alternate;
}
.dice-arena[data-arena-theme="inferno"]::after {
    background: none;
}
@keyframes inferno-flicker {
    0% { opacity: 0.8; }
    50% { opacity: 1; }
    100% { opacity: 0.9; }
}

/* Twilight - Dusk gradient */
.dice-arena[data-arena-theme="twilight"] {
    background: linear-gradient(180deg, #0d0820 0%, #1a1030 20%, #2d1845 50%, #1a1030 80%, #0d0820 100%);
}
.dice-arena[data-arena-theme="twilight"]::before {
    background: 
        linear-gradient(180deg, rgba(255, 150, 100, 0.12) 0%, rgba(255, 100, 150, 0.08) 30%, transparent 60%),
        radial-gradient(circle at 80% 10%, rgba(255, 200, 100, 0.1) 0%, transparent 30%);
}
.dice-arena[data-arena-theme="twilight"]::after {
    background-image: 
        radial-gradient(1px 1px at 20% 40%, rgba(255,255,255,0.4), transparent),
        radial-gradient(1px 1px at 60% 20%, rgba(255,255,255,0.3), transparent),
        radial-gradient(1px 1px at 80% 60%, rgba(255,255,255,0.35), transparent);
}

/* Crystal - Ice cave */
.dice-arena[data-arena-theme="crystal"] {
    background: linear-gradient(135deg, #1a2030 0%, #253045 30%, #2a3550 50%, #253045 70%, #1a2030 100%);
}
.dice-arena[data-arena-theme="crystal"]::before {
    background: 
        linear-gradient(60deg, transparent 30%, rgba(150, 200, 255, 0.1) 45%, rgba(200, 230, 255, 0.15) 50%, rgba(150, 200, 255, 0.1) 55%, transparent 70%),
        linear-gradient(-60deg, transparent 30%, rgba(150, 200, 255, 0.08) 45%, rgba(200, 230, 255, 0.12) 50%, rgba(150, 200, 255, 0.08) 55%, transparent 70%),
        linear-gradient(120deg, transparent 40%, rgba(180, 220, 255, 0.1) 50%, transparent 60%);
}
.dice-arena[data-arena-theme="crystal"]::after {
    background: radial-gradient(circle at 30% 40%, rgba(200, 230, 255, 0.08) 0%, transparent 40%);
}

/* Mossy Stone - Ancient ruins */
.dice-arena[data-arena-theme="mossy"] {
    background: linear-gradient(180deg, #1a1a15 0%, #252520 30%, #2a2a22 50%, #252520 70%, #1a1a15 100%);
}
.dice-arena[data-arena-theme="mossy"]::before {
    background: 
        radial-gradient(ellipse at 20% 80%, rgba(80, 120, 60, 0.2) 0%, transparent 35%),
        radial-gradient(ellipse at 70% 90%, rgba(60, 100, 40, 0.15) 0%, transparent 30%),
        radial-gradient(ellipse at 90% 70%, rgba(70, 110, 50, 0.18) 0%, transparent 25%);
}
.dice-arena[data-arena-theme="mossy"]::after {
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 100 100' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.8'/%3E%3C/filter%3E%3Crect width='100' height='100' filter='url(%23n)' opacity='0.06'/%3E%3C/svg%3E");
}

/* Royal - Purple and gold */
.dice-arena[data-arena-theme="royal"] {
    background: linear-gradient(135deg, #1a0a20 0%, #2d1040 30%, #351248 50%, #2d1040 70%, #1a0a20 100%);
}
.dice-arena[data-arena-theme="royal"]::before {
    background: 
        radial-gradient(circle at 50% 30%, rgba(255, 215, 0, 0.1) 0%, transparent 40%),
        radial-gradient(circle at 30% 70%, rgba(255, 200, 0, 0.06) 0%, transparent 30%),
        radial-gradient(circle at 70% 80%, rgba(255, 210, 0, 0.08) 0%, transparent 25%);
}
.dice-arena[data-arena-theme="royal"]::after {
    background: 
        repeating-linear-gradient(45deg, transparent 0px, transparent 40px, rgba(255, 215, 0, 0.02) 40px, rgba(255, 215, 0, 0.02) 42px);
}

/* Eclipse - Solar corona */
.dice-arena[data-arena-theme="eclipse"] {
    background: radial-gradient(circle at center, #0a0a12 0%, #050508 50%, #000003 100%);
}
.dice-arena[data-arena-theme="eclipse"]::before {
    background: 
        radial-gradient(circle at 50% 50%, #000000 10%, transparent 11%),
        radial-gradient(circle at 50% 50%, transparent 10%, rgba(255, 150, 50, 0.4) 12%, rgba(255, 100, 30, 0.2) 18%, transparent 25%);
    animation: eclipse-pulse 4s ease-in-out infinite;
}
.dice-arena[data-arena-theme="eclipse"]::after {
    background-image: 
        radial-gradient(1px 1px at 20% 30%, rgba(255,255,255,0.3), transparent),
        radial-gradient(1px 1px at 70% 20%, rgba(255,255,255,0.25), transparent),
        radial-gradient(1px 1px at 85% 60%, rgba(255,255,255,0.2), transparent);
}
@keyframes eclipse-pulse {
    0%, 100% { opacity: 0.9; }
    50% { opacity: 1; }
}

/* Aurora - Northern lights */
.dice-arena[data-arena-theme="aurora"] {
    background: linear-gradient(180deg, #0a0a12 0%, #0d1520 30%, #0a1218 50%, #0d1520 70%, #0a0a12 100%);
}
.dice-arena[data-arena-theme="aurora"]::before {
    background: linear-gradient(180deg, 
        rgba(0, 255, 100, 0.12) 0%, 
        rgba(0, 200, 150, 0.1) 20%,
        rgba(50, 150, 255, 0.08) 40%,
        rgba(150, 50, 255, 0.1) 60%,
        rgba(100, 0, 200, 0.08) 80%,
        transparent 100%);
    animation: aurora-wave 8s ease-in-out infinite;
}
.dice-arena[data-arena-theme="aurora"]::after {
    background-image: 
        radial-gradient(1px 1px at 15% 25%, rgba(255,255,255,0.4), transparent),
        radial-gradient(1px 1px at 45% 15%, rgba(255,255,255,0.3), transparent),
        radial-gradient(1px 1px at 75% 35%, rgba(255,255,255,0.35), transparent),
        radial-gradient(1px 1px at 90% 55%, rgba(255,255,255,0.25), transparent);
}
@keyframes aurora-wave {
    0%, 100% { opacity: 0.7; transform: translateX(0); }
    50% { opacity: 1; transform: translateX(10px); }
}

/* Storm - Thunderclouds */
.dice-arena[data-arena-theme="storm"] {
    background: linear-gradient(180deg, #12121a 0%, #1a1a25 30%, #1f1f2a 50%, #1a1a25 70%, #10101a 100%);
}
.dice-arena[data-arena-theme="storm"]::before {
    background: 
        radial-gradient(ellipse at 30% 20%, rgba(150, 150, 180, 0.15) 0%, transparent 40%),
        radial-gradient(ellipse at 70% 40%, rgba(140, 140, 170, 0.12) 0%, transparent 35%),
        radial-gradient(ellipse at 50% 60%, rgba(130, 130, 160, 0.1) 0%, transparent 30%);
}
.dice-arena[data-arena-theme="storm"]::after {
    background: radial-gradient(circle at 65% 25%, rgba(220, 220, 255, 0.08) 0%, transparent 20%);
}

/* Toxic - Radioactive */
.dice-arena[data-arena-theme="toxic"] {
    background: linear-gradient(180deg, #080d08 0%, #0d150d 30%, #101a10 50%, #0d150d 70%, #080d08 100%);
}
.dice-arena[data-arena-theme="toxic"]::before {
    background: 
        radial-gradient(ellipse at 50% 90%, rgba(150, 255, 0, 0.2) 0%, transparent 40%),
        radial-gradient(ellipse at 30% 80%, rgba(100, 255, 50, 0.15) 0%, transparent 30%),
        radial-gradient(ellipse at 70% 85%, rgba(130, 255, 20, 0.18) 0%, transparent 35%);
    animation: toxic-glow 3s ease-in-out infinite;
}
.dice-arena[data-arena-theme="toxic"]::after {
    background: none;
}
@keyframes toxic-glow {
    0%, 100% { opacity: 0.7; }
    50% { opacity: 1; }
}

/* Copper - Aged metal */
.dice-arena[data-arena-theme="copper"] {
    background: linear-gradient(135deg, #2a1a15 0%, #3d2820 30%, #4a3028 50%, #3d2820 70%, #2a1a15 100%);
}
.dice-arena[data-arena-theme="copper"]::before {
    background: 
        radial-gradient(circle at 25% 35%, rgba(184, 115, 51, 0.15) 0%, transparent 35%),
        radial-gradient(circle at 75% 65%, rgba(205, 127, 50, 0.12) 0%, transparent 30%),
        radial-gradient(circle at 50% 80%, rgba(166, 102, 45, 0.1) 0%, transparent 25%);
}
.dice-arena[data-arena-theme="copper"]::after {
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 100 100' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.7'/%3E%3C/filter%3E%3Crect width='100' height='100' filter='url(%23n)' opacity='0.04'/%3E%3C/svg%3E");
}

/* Dragonclaw (Red) - Gold Tier */
.dice-arena[data-arena-theme="dragonclaw-red"] {
    background: url('https://res.cloudinary.com/dza4jgreq/image/upload/v1770235663/rift-assets/mq1vanad7kzp4tg6vwfn.png') center/cover;
}
.dice-arena[data-arena-theme="dragonclaw-red"]::after { background: none !important; }

/* Dragonclaw (Green) - Gold Tier */
.dice-arena[data-arena-theme="dragonclaw-green"] {
    background: url('https://res.cloudinary.com/dza4jgreq/image/upload/v1770235665/rift-assets/rflk7srpbglks52z43s0.png') center/cover;
}
.dice-arena[data-arena-theme="dragonclaw-green"]::after { background: none !important; }

/* Hint text */
.dice-settings-popup__hint {
    font-size: 12px;
    color: rgba(255, 255, 255, 0.5);
    margin: 0 0 16px 0;
    line-height: 1.4;
}

/* Theme Search */
.dice-theme-search {
    width: 100%;
    padding: 10px 14px;
    margin-bottom: 12px;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 8px;
    color: white;
    font-size: 13px;
    outline: none;
    transition: all 0.2s ease;
}

.dice-theme-search:focus {
    background: rgba(255, 255, 255, 0.12);
    border-color: rgba(255, 255, 255, 0.3);
}

.dice-theme-search::placeholder {
    color: rgba(255, 255, 255, 0.1);
}

#themeCount {
    font-weight: normal;
    color: rgba(255, 255, 255, 0.5);
    font-size: 11px;
}

.dice-settings-popup__close svg {
    width: 16px;
    height: 16px;
}

.dice-settings-popup__section {
    margin-bottom: 16px;
    flex-shrink: 0;
}

.dice-settings-popup__section:last-child {
    margin-bottom: 0;
}

/* Stats Grid */
.dice-stats-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
    padding: 16px;
}

.dice-stats-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    padding: 14px 10px;
    background: #252525;
    border-radius: 10px;
}

.dice-stats-card__value {
    font-family: 'Dharma Gothic', sans-serif;
    font-size: 28px;
    font-weight: 700;
    color: var(--text-primary);
}

.dice-stats-card__label {
    font-size: 10px;
    color: rgba(255, 255, 255, 0.5);
    text-transform: uppercase;
    text-align: center;
}

.dice-stats-card--success .dice-stats-card__value {
    color: #4caf50;
}

.dice-stats-card--failure .dice-stats-card__value {
    color: #f44336;
}

/* Hotkeys List */
.dice-hotkeys-popup {
    width: 280px;
    height: auto !important;
    max-height: 500px;
}

/* Stats Popup */
.dice-stats-popup {
    width: 340px;
    height: auto !important;
    max-height: 500px;
}

.dice-stats-hint {
    font-size: 12px;
    color: rgba(255, 255, 255, 0.5);
    margin: 0 0 16px 0;
    padding: 0 16px;
}

.dice-stats-reset {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: calc(100% - 32px);
    margin: 16px;
    padding: 10px 16px;
    background: rgba(255, 70, 85, 0.1);
    border: 1px solid rgba(255, 70, 85, 0.3);
    border-radius: 8px;
    color: #ff4655;
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
}

.dice-stats-reset:hover {
    background: rgba(255, 70, 85, 0.2);
    border-color: rgba(255, 70, 85, 0.5);
}

.dice-stats-reset svg {
    width: 16px;
    height: 16px;
}

.dice-hotkeys-list {
    padding: 12px 16px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.dice-hotkey {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 12px;
}

.dice-hotkey kbd {
    display: inline-block;
    padding: 4px 8px;
    background: #252525;
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 4px;
    font-family: monospace;
    font-size: 11px;
    color: var(--text-primary);
}

.dice-hotkey span {
    color: rgba(255, 255, 255, 0.6);
}

.dice-settings-popup__label {
    display: block;
    font-size: 11px;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.5);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 10px;
}

/* Theme Cards Grid */
.dice-theme-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 8px;
}

.dice-theme-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    padding: 8px 4px;
    background: #252525;
    border: 2px solid transparent;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.dice-theme-card:hover {
    background: #2a2a2a;
    border-color: rgba(255, 255, 255, 0.1);
}

.dice-theme-card.active {
    border-color: var(--dice-accent, var(--accent));
    background: rgba(255, 70, 85, 0.1);
}

/* RIFT Pro Theme Gating (Dice, Zahlen, Arena) */
.dice-theme-card.is-pro,
.dice-label-color-btn.is-pro,
.dice-arena-theme-card.is-pro {
    position: relative;
    filter: grayscale(1) brightness(0.6);
    cursor: default;
    transition: filter 0.2s ease;
}

.dice-theme-card.is-pro:hover,
.dice-label-color-btn.is-pro:hover,
.dice-arena-theme-card.is-pro:hover {
    filter: none;
}

.dice-theme-card.is-pro.active,
.dice-label-color-btn.is-pro.active,
.dice-arena-theme-card.is-pro.active {
    filter: none;
}

/* Pro hover tooltip */
.pro-gate-tooltip {
    position: absolute;
    bottom: calc(100% + 8px);
    left: 50%;
    transform: translateX(-50%) scale(0.95);
    background: #1a1a1a;
    border: 1px solid rgba(188, 162, 76, 0.35);
    border-radius: 8px;
    padding: 8px 14px;
    display: flex;
    align-items: center;
    gap: 10px;
    white-space: nowrap;
    z-index: 100;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.15s ease, transform 0.15s ease;
    box-shadow: 0 4px 16px rgba(0,0,0,0.5);
}

/* Invisible bridge from tooltip to card - keeps hover alive */
.pro-gate-tooltip::before {
    content: '';
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    height: 14px;
}

/* Arrow */
.pro-gate-tooltip::after {
    content: '';
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    border: 5px solid transparent;
    border-top-color: rgba(188, 162, 76, 0.35);
}

.dice-theme-card.is-pro:not(.pro-unlocked):hover .pro-gate-tooltip,
.dice-label-color-btn.is-pro:not(.pro-unlocked):hover .pro-gate-tooltip,
.dice-arena-theme-card.is-pro:not(.pro-unlocked):hover .pro-gate-tooltip {
    opacity: 1;
    pointer-events: auto;
    transform: translateX(-50%) scale(1);
}

.pro-gate-tooltip__badge {
    height: 22px;
    width: auto;
    flex-shrink: 0;
}

.pro-gate-tooltip__divider {
    width: 1px;
    height: 16px;
    background: rgba(255,255,255,0.12);
    flex-shrink: 0;
}

.pro-gate-tooltip__link {
    color: rgba(255,255,255,0.55);
    text-decoration: none;
    font-size: 12px;
    font-weight: 500;
    transition: color 0.15s;
}

.pro-gate-tooltip__link:hover {
    color: #e8d48b;
}

/* Pro user: remove all gating visuals */
.dice-theme-card.is-pro.pro-unlocked,
.dice-label-color-btn.is-pro.pro-unlocked,
.dice-arena-theme-card.is-pro.pro-unlocked {
    filter: none;
    cursor: pointer;
}

.dice-theme-card.is-pro.pro-unlocked .pro-gate-tooltip,
.dice-label-color-btn.is-pro.pro-unlocked .pro-gate-tooltip,
.dice-arena-theme-card.is-pro.pro-unlocked .pro-gate-tooltip {
    display: none;
}

.dice-theme-card__preview {
    width: 36px;
    height: 36px;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

.dice-theme-card__preview--classic {
    background: linear-gradient(135deg, #2a2a2a 0%, #1a1a1a 100%);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.dice-theme-card__preview--blood {
    background: linear-gradient(135deg, #ff4655 0%, #cc2233 50%, #8b0000 100%);
}

.dice-theme-card__preview--ice {
    background: linear-gradient(135deg, #00d4ff 0%, #0099cc 50%, #1565c0 100%);
}

.dice-theme-card__preview--nature {
    background: linear-gradient(135deg, #4caf50 0%, #388e3c 50%, #2e7d32 100%);
}

.dice-theme-card__preview--royal {
    background: linear-gradient(135deg, #9c27b0 0%, #7b1fa2 50%, #6a1b9a 100%);
}

.dice-theme-card__preview--gold {
    background: linear-gradient(135deg, #ffd700 0%, #ffb300 50%, #ff8f00 100%);
}

/* New theme previews */
.dice-theme-card__preview--fire {
    background: linear-gradient(135deg, #ff5722 0%, #ff9800 50%, #e65100 100%);
}

.dice-theme-card__preview--ocean {
    background: linear-gradient(135deg, #00ffff 0%, #0099cc 50%, #006064 100%);
}

.dice-theme-card__preview--toxic {
    background: radial-gradient(circle at 30% 30%, #39ff14 0%, #00ff00 50%, #1b5e20 100%);
    box-shadow: inset 0 0 10px rgba(57, 255, 20, 0.5);
}

.dice-theme-card__preview--nebula {
    background: radial-gradient(circle at 30% 30%, #ff6bcb 0%, #c56cf0 50%, #7b1fa2 100%);
    box-shadow: inset 0 0 10px rgba(197, 108, 240, 0.5);
}

.dice-theme-card__preview--sunset {
    background: linear-gradient(135deg, #ff7e5f 0%, #feb47b 50%, #e65100 100%);
}

.dice-theme-card__preview--cyber {
    background: linear-gradient(135deg, #00ffff 0%, #ff00ff 50%, #7b1fa2 100%);
    animation: cyber-pulse 2s ease-in-out infinite alternate;
}

@keyframes cyber-pulse {
    0% { filter: brightness(1); }
    100% { filter: brightness(1.2); }
}

.dice-theme-card__preview--midnight {
    background: linear-gradient(135deg, #607d8b 0%, #455a64 50%, #37474f 100%);
    position: relative;
    overflow: hidden;
}

.dice-theme-card__preview--midnight::after {
    content: '✦';
    position: absolute;
    top: 8px;
    right: 10px;
    font-size: 8px;
    color: rgba(255, 255, 255, 0.6);
}

.dice-theme-card__preview--copper {
    background: linear-gradient(135deg, #cd7f32 0%, #b87333 50%, #6d4c41 100%);
}

.dice-theme-card__preview--void {
    background: radial-gradient(circle at 30% 30%, #8b5cf6 0%, #6a1b9a 50%, #4a148c 100%);
}

.dice-theme-card__preview--rainbow {
    background: linear-gradient(135deg, 
        #ff6b6b 0%, 
        #feca57 20%, 
        #48dbfb 40%, 
        #ff9ff3 60%, 
        #54a0ff 80%, 
        #5f27cd 100%
    );
    animation: rainbow-shift 3s ease infinite;
    background-size: 200% 200%;
}

@keyframes rainbow-shift {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

/* ═══════════════════════════════════════
   NEW THEME PREVIEWS - ELEMENTAL
   ═══════════════════════════════════════ */
.dice-theme-card__preview--lava {
    background: radial-gradient(circle at 30% 30%, #ffcc00 0%, #ff4500 50%, #bf360c 100%);
}
.dice-theme-card__preview--frost {
    background: linear-gradient(135deg, #ffffff 0%, #b3e5fc 50%, #4fc3f7 100%);
}
.dice-theme-card__preview--storm {
    background: linear-gradient(135deg, #ffd700 0%, #87ceeb 50%, #546e7a 100%);
}
.dice-theme-card__preview--earth {
    background: linear-gradient(135deg, #d2691e 0%, #8b4513 50%, #5d4037 100%);
}
.dice-theme-card__preview--shadow {
    background: radial-gradient(circle at 30% 30%, #4a4a4a 0%, #2d2d2d 50%, #1a1a1a 100%);
}

/* ═══════════════════════════════════════
   NEW THEME PREVIEWS - GEMS
   ═══════════════════════════════════════ */
.dice-theme-card__preview--ruby {
    background: radial-gradient(circle at 30% 30%, #ff4081 0%, #e91e63 50%, #c2185b 100%);
}
.dice-theme-card__preview--sapphire {
    background: radial-gradient(circle at 30% 30%, #82b1ff 0%, #2979ff 50%, #1565c0 100%);
}
.dice-theme-card__preview--emerald {
    background: radial-gradient(circle at 30% 30%, #69f0ae 0%, #00e676 50%, #00897b 100%);
}
.dice-theme-card__preview--amethyst {
    background: radial-gradient(circle at 30% 30%, #ea80fc 0%, #e040fb 50%, #8e24aa 100%);
}
.dice-theme-card__preview--diamond {
    background: linear-gradient(135deg, #ffffff 0%, #e8f4f8 50%, #90caf9 100%);
}
.dice-theme-card__preview--opal {
    background: linear-gradient(135deg, #a8edea 0%, #fed6e3 50%, #f48fb1 100%);
    animation: opal-shift 4s ease infinite;
    background-size: 200% 200%;
}
@keyframes opal-shift {
    0%, 100% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
}

/* ═══════════════════════════════════════
   NEW THEME PREVIEWS - METALS
   ═══════════════════════════════════════ */
.dice-theme-card__preview--silver {
    background: linear-gradient(135deg, #e8e8e8 0%, #c0c0c0 50%, #78909c 100%);
}
.dice-theme-card__preview--bronze {
    background: linear-gradient(135deg, #daa06d 0%, #cd7f32 50%, #8d6e63 100%);
}
.dice-theme-card__preview--platinum {
    background: linear-gradient(135deg, #f5f5f5 0%, #e5e4e2 50%, #90a4ae 100%);
}
.dice-theme-card__preview--obsidian {
    background: linear-gradient(135deg, #37474f 0%, #263238 50%, #1c313a 100%);
}

/* ═══════════════════════════════════════
   NEW THEME PREVIEWS - FANTASY
   ═══════════════════════════════════════ */
.dice-theme-card__preview--dragon {
    background: linear-gradient(135deg, #ffd700 0%, #ff4500 50%, #bf360c 100%);
}
.dice-theme-card__preview--necro {
    background: radial-gradient(circle at 30% 30%, #00ff00 0%, #4caf50 50%, #2e7d32 100%);
}
.dice-theme-card__preview--fey {
    background: linear-gradient(135deg, #ffd1f7 0%, #b8ffc8 50%, #81c784 100%);
}
.dice-theme-card__preview--infernal {
    background: radial-gradient(circle at 30% 30%, #ff4444 0%, #cc0000 50%, #b71c1c 100%);
}
.dice-theme-card__preview--celestial {
    background: radial-gradient(circle at 30% 30%, #fffacd 0%, #ffd700 50%, #ffa000 100%);
}
.dice-theme-card__preview--eldritch {
    background: radial-gradient(circle at 30% 30%, #9370db 0%, #7b68ee 50%, #5e35b1 100%);
}

/* ═══════════════════════════════════════
   NEW THEME PREVIEWS - COSMIC & NATURE
   ═══════════════════════════════════════ */
.dice-theme-card__preview--galaxy {
    background: radial-gradient(circle at 30% 30%, #fff8dc 0%, #dda0dd 50%, #7b1fa2 100%);
}
.dice-theme-card__preview--aurora {
    background: linear-gradient(135deg, #00ff7f 0%, #00ced1 50%, #00838f 100%);
}
.dice-theme-card__preview--bloodmoon {
    background: radial-gradient(circle at 50% 50%, #dc143c 0%, #8b0000 50%, #b71c1c 100%);
}
.dice-theme-card__preview--forest {
    background: linear-gradient(135deg, #90ee90 0%, #228b22 50%, #1b5e20 100%);
}
.dice-theme-card__preview--cherry {
    background: linear-gradient(135deg, #ffc0cb 0%, #ffb7c5 50%, #ec407a 100%);
}
.dice-theme-card__preview--autumn {
    background: linear-gradient(135deg, #ffd700 0%, #ff8c00 50%, #e65100 100%);
}

/* ═══════════════════════════════════════
   NEW THEME PREVIEWS - TECH & RETRO
   ═══════════════════════════════════════ */
.dice-theme-card__preview--matrix {
    background: linear-gradient(135deg, #00ff00 0%, #4caf50 50%, #2e7d32 100%);
}
.dice-theme-card__preview--hologram {
    background: linear-gradient(135deg, #00ffff 0%, #ff00ff 50%, #ffff00 100%);
    animation: hologram-shift 3s ease infinite;
    background-size: 200% 200%;
}
@keyframes hologram-shift {
    0%, 100% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
}
.dice-theme-card__preview--plasma {
    background: radial-gradient(circle at 30% 30%, #ff00ff 0%, #8b008b 50%, #6a1b9a 100%);
}
.dice-theme-card__preview--neon {
    background: linear-gradient(135deg, #ff1493 0%, #00ff00 50%, #00897b 100%);
}
.dice-theme-card__preview--synthwave {
    background: linear-gradient(135deg, #00d9ff 0%, #ff6ec7 50%, #9c27b0 100%);
}
.dice-theme-card__preview--steampunk {
    background: linear-gradient(135deg, #d4af37 0%, #b87333 50%, #795548 100%);
}
.dice-theme-card__preview--vaporwave {
    background: linear-gradient(135deg, #01cdfe 0%, #ff71ce 50%, #9c27b0 100%);
}

/* ═══════════════════════════════════════
   NEW THEME PREVIEWS - FUN & SPECIAL
   ═══════════════════════════════════════ */
.dice-theme-card__preview--candy {
    background: linear-gradient(135deg, #ff69b4 0%, #87ceeb 50%, #f48fb1 100%);
}
.dice-theme-card__preview--prism {
    background: linear-gradient(135deg, #ff0000 0%, #ff8000 17%, #ffff00 33%, #00ff00 50%, #0080ff 67%, #8000ff 100%);
}
.dice-theme-card__preview--bubblegum {
    background: radial-gradient(circle at 30% 30%, #ffaacc 0%, #ff77aa 50%, #ec407a 100%);
}
.dice-theme-card__preview--coral {
    background: linear-gradient(135deg, #ff9a8b 0%, #ff7f50 50%, #e64a19 100%);
}
.dice-theme-card__preview--lavender {
    background: linear-gradient(135deg, #e6e6fa 0%, #d8bfd8 50%, #9575cd 100%);
}
.dice-theme-card__preview--mint {
    background: linear-gradient(135deg, #98ff98 0%, #00fa9a 50%, #00897b 100%);
}
.dice-theme-card__preview--peach {
    background: linear-gradient(135deg, #ffe5b4 0%, #ffcba4 50%, #ff8a65 100%);
}

/* ═══════════════════════════════════════
   TEXTURED PREVIEWS
   ═══════════════════════════════════════ */
.dice-theme-card__preview--marbleWhite {
    background: linear-gradient(135deg, #ffffff 0%, #f5f5f5 50%, #e0e0e0 100%);
    position: relative;
}
.dice-theme-card__preview--marbleWhite::after {
    content: '';
    position: absolute;
    inset: 0;
    background: url("data:image/svg+xml,%3Csvg viewBox='0 0 100 100' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M10,20 Q30,10 50,25 T90,30' stroke='%23ccc' fill='none' stroke-width='0.5'/%3E%3Cpath d='M5,50 Q25,45 45,55 T85,50' stroke='%23ddd' fill='none' stroke-width='0.3'/%3E%3Cpath d='M15,70 Q35,80 55,70 T95,75' stroke='%23ccc' fill='none' stroke-width='0.4'/%3E%3C/svg%3E");
    opacity: 0.5;
}
.dice-theme-card__preview--marbleBlack {
    background: linear-gradient(135deg, #424242 0%, #303030 50%, #1a1a1a 100%);
}
.dice-theme-card__preview--marbleGreen {
    background: linear-gradient(135deg, #81c784 0%, #4caf50 50%, #2e7d32 100%);
}
.dice-theme-card__preview--marbleRose {
    background: linear-gradient(135deg, #f8bbd9 0%, #f48fb1 50%, #ec407a 100%);
}
.dice-theme-card__preview--woodOak {
    background: linear-gradient(135deg, #bcaaa4 0%, #8d6e63 50%, #5d4037 100%);
    background-image: repeating-linear-gradient(90deg, transparent, transparent 2px, rgba(0,0,0,0.05) 2px, rgba(0,0,0,0.05) 4px);
}
.dice-theme-card__preview--woodCherry {
    background: linear-gradient(135deg, #d4a574 0%, #a1887f 50%, #6d4c41 100%);
}
.dice-theme-card__preview--woodEbony {
    background: linear-gradient(135deg, #4a4a4a 0%, #2d2d2d 50%, #1a1a1a 100%);
}
.dice-theme-card__preview--stoneGranite {
    background: linear-gradient(135deg, #bdbdbd 0%, #9e9e9e 50%, #757575 100%);
}
.dice-theme-card__preview--stoneSandstone {
    background: linear-gradient(135deg, #efebe9 0%, #d7ccc8 50%, #a1887f 100%);
}

/* GLITTER */
.dice-theme-card__preview--glitterGold {
    background: linear-gradient(135deg, #ffd700 0%, #ffb300 50%, #ff8f00 100%);
    animation: glitter-sparkle 1.5s ease-in-out infinite;
}
.dice-theme-card__preview--glitterSilver {
    background: linear-gradient(135deg, #eceff1 0%, #cfd8dc 50%, #90a4ae 100%);
    animation: glitter-sparkle 1.5s ease-in-out infinite;
}
.dice-theme-card__preview--glitterRose {
    background: linear-gradient(135deg, #fce4ec 0%, #f8bbd9 50%, #f48fb1 100%);
    animation: glitter-sparkle 1.5s ease-in-out infinite;
}
.dice-theme-card__preview--glitterBlue {
    background: radial-gradient(circle at 30% 30%, #90caf9 0%, #64b5f6 50%, #42a5f5 100%);
    animation: glitter-sparkle 1.5s ease-in-out infinite;
}
.dice-theme-card__preview--glitterPurple {
    background: radial-gradient(circle at 30% 30%, #e1bee7 0%, #ce93d8 50%, #ba68c8 100%);
    animation: glitter-sparkle 1.5s ease-in-out infinite;
}
@keyframes glitter-sparkle {
    0%, 100% { filter: brightness(1); }
    50% { filter: brightness(1.15); }
}

/* PATTERNS */
.dice-theme-card__preview--stripesRed {
    background: repeating-linear-gradient(45deg, #ef5350, #ef5350 3px, #c62828 3px, #c62828 6px);
}
.dice-theme-card__preview--stripesBlue {
    background: repeating-linear-gradient(45deg, #64b5f6, #64b5f6 3px, #1e88e5 3px, #1e88e5 6px);
}
.dice-theme-card__preview--stripesGreen {
    background: repeating-linear-gradient(45deg, #81c784, #81c784 3px, #4caf50 3px, #4caf50 6px);
}
.dice-theme-card__preview--polkaDots {
    background: #f8bbd9;
    background-image: radial-gradient(#ec407a 15%, transparent 16%);
    background-size: 8px 8px;
}
.dice-theme-card__preview--polkaBlack {
    background: #424242;
    background-image: radial-gradient(#757575 15%, transparent 16%);
    background-size: 8px 8px;
}
.dice-theme-card__preview--checkerRed {
    background: repeating-conic-gradient(#f44336 0% 25%, #b71c1c 0% 50%) 50% / 10px 10px;
}
.dice-theme-card__preview--checkerGreen {
    background: repeating-conic-gradient(#66bb6a 0% 25%, #2e7d32 0% 50%) 50% / 10px 10px;
}
.dice-theme-card__preview--camoForest {
    background: linear-gradient(135deg, #8bc34a 0%, #689f38 50%, #558b2f 100%);
}
.dice-theme-card__preview--camoDesert {
    background: linear-gradient(135deg, #d7ccc8 0%, #bcaaa4 50%, #a1887f 100%);
}
.dice-theme-card__preview--camoArctic {
    background: linear-gradient(135deg, #eceff1 0%, #cfd8dc 50%, #b0bec5 100%);
}
.dice-theme-card__preview--waveOcean {
    background: linear-gradient(135deg, #4fc3f7 0%, #29b6f6 50%, #03a9f4 100%);
}
.dice-theme-card__preview--waveAqua {
    background: linear-gradient(135deg, #80deea 0%, #4dd0e1 50%, #26c6da 100%);
}
.dice-theme-card__preview--hexTech {
    background: linear-gradient(135deg, #42a5f5 0%, #2196f3 50%, #1e88e5 100%);
}
.dice-theme-card__preview--hexGold {
    background: linear-gradient(135deg, #ffc107 0%, #ffb300 50%, #ffa000 100%);
}
.dice-theme-card__preview--dragonScales {
    background: linear-gradient(135deg, #66bb6a 0%, #4caf50 50%, #388e3c 100%);
}
.dice-theme-card__preview--fishScales {
    background: linear-gradient(135deg, #4dd0e1 0%, #26c6da 50%, #00bcd4 100%);
}

/* SPECIAL EFFECTS */
.dice-theme-card__preview--starryNight {
    background: radial-gradient(circle at 30% 30%, #3f51b5 0%, #303f9f 50%, #1a237e 100%);
    position: relative;
}
.dice-theme-card__preview--starryNight::after {
    content: '✦ ✧';
    position: absolute;
    top: 4px;
    right: 4px;
    font-size: 6px;
    color: white;
    opacity: 0.8;
}
.dice-theme-card__preview--galaxy2 {
    background: radial-gradient(circle at 30% 30%, #9c27b0 0%, #7b1fa2 50%, #4a148c 100%);
}
.dice-theme-card__preview--thunderstorm {
    background: linear-gradient(135deg, #78909c 0%, #546e7a 50%, #455a64 100%);
}
.dice-theme-card__preview--electricBlue {
    background: linear-gradient(135deg, #29b6f6 0%, #03a9f4 50%, #0288d1 100%);
    animation: electric-flash 2s ease-in-out infinite;
}
@keyframes electric-flash {
    0%, 90%, 100% { filter: brightness(1); }
    92%, 94%, 96% { filter: brightness(1.5); }
}

/* METALLIC */
.dice-theme-card__preview--chrome {
    background: linear-gradient(135deg, #fafafa 0%, #e0e0e0 25%, #9e9e9e 50%, #e0e0e0 75%, #fafafa 100%);
}
.dice-theme-card__preview--titanium {
    background: linear-gradient(135deg, #b0bec5 0%, #78909c 50%, #546e7a 100%);
}
.dice-theme-card__preview--rosegold {
    background: linear-gradient(135deg, #f5d0c5 0%, #e8b4a6 50%, #d4a594 100%);
}
.dice-theme-card__preview--brushedSteel {
    background: linear-gradient(135deg, #e0e0e0 0%, #bdbdbd 50%, #9e9e9e 100%);
}
.dice-theme-card__preview--rust {
    background: linear-gradient(135deg, #e64a19 0%, #d84315 50%, #bf360c 100%);
}
.dice-theme-card__preview--patina {
    background: linear-gradient(135deg, #80cbc4 0%, #4db6ac 50%, #26a69a 100%);
}

/* FOOD */
.dice-theme-card__preview--chocolate {
    background: linear-gradient(135deg, #8d6e63 0%, #6d4c41 50%, #4e342e 100%);
}
.dice-theme-card__preview--caramel {
    background: linear-gradient(135deg, #ffb74d 0%, #ffa726 50%, #ff9800 100%);
}
.dice-theme-card__preview--strawberry {
    background: linear-gradient(135deg, #ef9a9a 0%, #ef5350 50%, #e53935 100%);
}
.dice-theme-card__preview--blueberry {
    background: linear-gradient(135deg, #9fa8da 0%, #7986cb 50%, #5c6bc0 100%);
}
.dice-theme-card__preview--grape {
    background: linear-gradient(135deg, #ce93d8 0%, #ab47bc 50%, #8e24aa 100%);
}
.dice-theme-card__preview--lemon {
    background: linear-gradient(135deg, #fff59d 0%, #ffee58 50%, #ffeb3b 100%);
}
.dice-theme-card__preview--lime {
    background: linear-gradient(135deg, #c5e1a5 0%, #aed581 50%, #9ccc65 100%);
}
.dice-theme-card__preview--orange2 {
    background: linear-gradient(135deg, #ffb74d 0%, #ffa726 50%, #ff9800 100%);
}

/* SEASONAL */
.dice-theme-card__preview--springBlossom {
    background: linear-gradient(135deg, #f8bbd9 0%, #f48fb1 50%, #f06292 100%);
}
.dice-theme-card__preview--summerSun {
    background: radial-gradient(circle at 30% 30%, #ffeb3b 0%, #ffc107 50%, #ff9800 100%);
}
.dice-theme-card__preview--autumnLeaves {
    background: linear-gradient(135deg, #ff8a65 0%, #ff7043 50%, #f4511e 100%);
}
.dice-theme-card__preview--winterFrost {
    background: linear-gradient(135deg, #ffffff 0%, #e1f5fe 50%, #b3e5fc 100%);
}
.dice-theme-card__preview--christmas {
    background: linear-gradient(135deg, #c62828 0%, #2e7d32 50%, #c62828 100%);
}
.dice-theme-card__preview--halloween {
    background: linear-gradient(135deg, #ff9800 0%, #e65100 50%, #1a1a1a 100%);
}
.dice-theme-card__preview--valentine {
    background: radial-gradient(circle at 30% 30%, #f8bbd9 0%, #f48fb1 50%, #ec407a 100%);
}

/* GAMING */
.dice-theme-card__preview--critSuccess {
    background: radial-gradient(circle at 30% 30%, #ffeb3b 0%, #ffc107 50%, #ff9800 100%);
    animation: crit-glow 1s ease-in-out infinite alternate;
}
@keyframes crit-glow {
    from { box-shadow: inset 0 0 5px rgba(255,215,0,0.5); }
    to { box-shadow: inset 0 0 10px rgba(255,215,0,0.8); }
}
.dice-theme-card__preview--critFail {
    background: radial-gradient(circle at 50% 50%, #424242 0%, #212121 70%, #b71c1c 100%);
}
.dice-theme-card__preview--lucky {
    background: radial-gradient(circle at 30% 30%, #a5d6a7 0%, #81c784 50%, #4caf50 100%);
}
.dice-theme-card__preview--cursed {
    background: radial-gradient(circle at 30% 30%, #7b1fa2 0%, #6a1b9a 50%, #4a148c 100%);
}
.dice-theme-card__preview--blessed {
    background: radial-gradient(circle at 30% 30%, #fff9c4 0%, #fff59d 50%, #ffee58 100%);
}
.dice-theme-card__preview--ethereal {
    background: radial-gradient(circle at 30% 30%, #e0f7fa 0%, #b2ebf2 50%, #80deea 100%);
}

/* DARK */
.dice-theme-card__preview--charcoal {
    background: linear-gradient(135deg, #546e7a 0%, #37474f 50%, #263238 100%);
}
.dice-theme-card__preview--slate {
    background: linear-gradient(135deg, #90a4ae 0%, #78909c 50%, #607d8b 100%);
}
.dice-theme-card__preview--graphite {
    background: linear-gradient(135deg, #757575 0%, #616161 50%, #424242 100%);
}
.dice-theme-card__preview--carbon {
    background: linear-gradient(135deg, #424242 0%, #303030 50%, #1a1a1a 100%);
}
.dice-theme-card__preview--onyx {
    background: radial-gradient(circle at 30% 30%, #3a3a3a 0%, #1a1a1a 50%, #0a0a0a 100%);
}

/* PASTEL */
.dice-theme-card__preview--pastelPink {
    background: linear-gradient(135deg, #fce4ec 0%, #f8bbd9 50%, #f48fb1 100%);
}
.dice-theme-card__preview--pastelBlue {
    background: linear-gradient(135deg, #e1f5fe 0%, #b3e5fc 50%, #81d4fa 100%);
}
.dice-theme-card__preview--pastelGreen {
    background: linear-gradient(135deg, #e8f5e9 0%, #c8e6c9 50%, #a5d6a7 100%);
}
.dice-theme-card__preview--pastelYellow {
    background: linear-gradient(135deg, #fffde7 0%, #fff9c4 50%, #fff59d 100%);
}
.dice-theme-card__preview--pastelPurple {
    background: linear-gradient(135deg, #f3e5f5 0%, #e1bee7 50%, #ce93d8 100%);
}
.dice-theme-card__preview--pastelRainbow {
    background: linear-gradient(135deg, #ffcdd2 0%, #fff9c4 25%, #c8e6c9 50%, #b3e5fc 75%, #e1bee7 100%);
}

/* NATURE EXTENDED */
.dice-theme-card__preview--deepSea {
    background: linear-gradient(135deg, #0288d1 0%, #0277bd 50%, #01579b 100%);
}
.dice-theme-card__preview--coralReef {
    background: linear-gradient(135deg, #ffab91 0%, #ff8a65 50%, #ff7043 100%);
}
.dice-theme-card__preview--jungle {
    background: linear-gradient(135deg, #81c784 0%, #66bb6a 50%, #4caf50 100%);
}
.dice-theme-card__preview--desert {
    background: linear-gradient(135deg, #f5deb3 0%, #deb887 50%, #d2b48c 100%);
}
.dice-theme-card__preview--volcanic {
    background: radial-gradient(circle at 30% 30%, #ff9800 0%, #ff5722 50%, #bf360c 100%);
}
.dice-theme-card__preview--arctic {
    background: linear-gradient(135deg, #e1f5fe 0%, #b3e5fc 50%, #81d4fa 100%);
}
.dice-theme-card__preview--tundra {
    background: linear-gradient(135deg, #cfd8dc 0%, #b0bec5 50%, #90a4ae 100%);
}
.dice-theme-card__preview--swamp {
    background: linear-gradient(135deg, #8bc34a 0%, #7cb342 50%, #689f38 100%);
}

.dice-theme-card span {
    font-size: 9px;
    color: rgba(255, 255, 255, 0.7);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 100%;
}

.dice-theme-card.active span {
    color: white;
}

/* Settings Toggles */
.dice-settings-popup__toggles {
    display: flex;
    gap: 8px;
}

.dice-settings-toggle {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 10px;
    background: #252525;
    border: 1px solid transparent;
    border-radius: 8px;
    color: rgba(255, 255, 255, 0.5);
    font-size: 12px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.dice-settings-toggle:hover {
    background: #2a2a2a;
    border-color: rgba(255, 255, 255, 0.1);
    color: white;
}

.dice-settings-toggle.active {
    background: rgba(255, 70, 85, 0.1);
    border-color: var(--text-primary);
    color: var(--text-primary);
}

.dice-settings-toggle svg {
    width: 16px;
    height: 16px;
}

/* ========================================
   PRESETS POPUP
   ======================================== */

.dice-presets-wrapper {
    position: relative;
}

.dice-presets-popup {
    position: absolute;
    top: calc(100% + 8px);
    left: 0;
    width: 280px;
    background: #1a1a1a;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 0;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.2s ease;
    z-index: 1000;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5);
}

.dice-presets-popup.visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.dice-presets-popup__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 16px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.dice-presets-popup__header span {
    font-size: 13px;
    font-weight: 600;
    color: var(--text-primary);
}

.dice-presets-popup__close {
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: transparent;
    border: none;
    color: rgba(255, 255, 255, 0.5);
    cursor: pointer;
    border-radius: 6px;
    transition: all 0.2s ease;
}

.dice-presets-popup__close:hover {
    background: rgba(255, 255, 255, 0.1);
    color: white;
}

.dice-presets-popup__close svg {
    width: 14px;
    height: 14px;
}

.dice-presets-popup__list {
    max-height: 240px;
    overflow-y: auto;
    padding: 8px;
}

.dice-presets-popup__empty {
    padding: 24px 16px;
    text-align: center;
    color: rgba(255, 255, 255, 0.1);
    font-size: 13px;
}

.dice-presets-popup__item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 12px;
    background: #252525;
    border-radius: 8px;
    margin-bottom: 4px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.dice-presets-popup__item:hover {
    background: #2a2a2a;
}

.dice-presets-popup__item:last-child {
    margin-bottom: 0;
}

.dice-presets-popup__item-info {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.dice-presets-popup__item-name {
    font-size: 13px;
    font-weight: 500;
    color: var(--text-primary);
}

.dice-presets-popup__item-notation {
    font-size: 11px;
    color: rgba(255, 255, 255, 0.5);
    font-family: monospace;
}

.dice-presets-popup__item-delete {
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: transparent;
    border: none;
    color: rgba(255, 255, 255, 0.3);
    cursor: pointer;
    border-radius: 6px;
    transition: all 0.2s ease;
}

.dice-presets-popup__item-delete:hover {
    background: rgba(244, 67, 54, 0.2);
    color: #f44336;
}

.dice-presets-popup__item-delete svg {
    width: 14px;
    height: 14px;
}

.dice-presets-popup__hint {
    padding: 10px 16px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    font-size: 11px;
    color: rgba(255, 255, 255, 0.1);
    text-align: center;
}

/* ========================================
   DICE ORBIT ACTION BUTTONS
   ======================================== */

.dice-orbit__dice {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    justify-content: center;
    align-items: stretch;
}

/* Action Buttons (Reset, Stats, Hotkeys, Settings) */
.dice-orbit__action {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 10px;
    color: var(--text-muted);
    cursor: pointer;
    transition: all 0.2s ease;
    flex-shrink: 0;
}

.dice-orbit__action:hover {
    background: #333333;
    border-color: var(--border-hover);
    color: var(--text);
}

.dice-orbit__action.active {
    color: var(--text);
    border-color: var(--border-hover);
}

.dice-orbit__action svg {
    width: 14px;
    height: 14px;
}

/* Reset Button - tall card style */
.dice-orbit__reset {
    width: 80px;
    height: 180px;
    border-radius: 12px;
    flex-direction: column;
    gap: 8px;
    border: none;
}

.dice-orbit__reset svg {
    width: 28px;
    height: 28px;
}

.dice-orbit__reset:hover {
    color: var(--accent);
    border: none;
}

.dice-orbit__reset-label {
    font-family: 'Inter', sans-serif;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.dice-orbit__stats:hover,
.dice-orbit__stats.active {
    color: #a855f7;
    border-color: #a855f7;
}

.dice-orbit__hotkeys:hover,
.dice-orbit__hotkeys.active {
    color: #06b6d4;
    border-color: #06b6d4;
}

.dice-orbit__settings:hover,
.dice-orbit__settings.active {
    color: #f59e0b;
    border-color: #f59e0b;
}

/* Divider */
.dice-orbit__divider {
    width: 1px;
    height: 100px;
    background: var(--border);
    margin: 0 4px;
    align-self: center;
}

/* Settings Wrapper für Popups */
.dice-settings-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

/* Settings Group - 2 Row Layout */
.dice-orbit__settings-group {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.dice-orbit__settings-row {
    display: flex;
    gap: 6px;
}

/* Full width settings button */
.dice-settings-wrapper--full .dice-orbit__action {
    width: 86px; /* Same width as 2 buttons + gap */
}

/* ========================================
   FANCY DICE ICONS
   ======================================== */

.dice-orb {
    width: 54px;
    height: 54px;
    border-radius: 14px;
    flex-direction: column;
    gap: 0;
    padding: 4px;
}

.dice-orb__icon {
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.dice-orb__icon svg {
    width: 100%;
    height: 100%;
}

.dice-orb__label {
    font-size: 8px;
    margin-top: 2px;
}

.dice-orb:hover {
    transform: translateY(-4px) scale(1.08);
}

.dice-orb:hover .dice-orb__icon svg {
    filter: drop-shadow(0 0 8px var(--dice-color));
}

/* ========================================
   IMPROVED MODIFIER BAR
   ======================================== */

.dice-modifier {
    display: flex;
    align-items: center;
    gap: 4px;
    background: #252525;
    border: 1px solid transparent;
    border-radius: 10px;
    padding: 6px 8px;
    transition: border-color 0.2s ease;
}

.dice-modifier:hover {
    border-color: rgba(255, 255, 255, 0.1);
}

.dice-modifier__btn {
    min-width: 36px;
    height: 32px;
    padding: 0 8px;
    background: #1b1b1b;
    border: 1px solid transparent;
    border-radius: 8px;
    color: rgba(255, 255, 255, 0.5);
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.dice-modifier__btn:hover {
    background: #2a2a2a;
    border-color: rgba(255, 255, 255, 0.1);
    color: white;
}

.dice-modifier__btn--md {
    min-width: 40px;
    font-size: 11px;
}

.dice-modifier__btn--lg {
    min-width: 44px;
    font-size: 10px;
}

/* Modifier Display (farbig) */
.dice-modifier__display {
    min-width: 50px;
    height: 32px;
    padding: 0 8px;
    background: #1b1b1b;
    border: 1px solid transparent;
    border-radius: 8px;
    color: rgba(255, 255, 255, 0.5);
    font-family: var(--font-mono);
    font-size: 16px;
    font-weight: 700;
    text-align: center;
    line-height: 30px;
    transition: all 0.2s ease;
}

.dice-modifier__display--positive {
    color: #4caf50;
    border-color: rgba(76, 175, 80, 0.3);
    background: rgba(76, 175, 80, 0.1);
}

.dice-modifier__display--negative {
    color: #f44336;
    border-color: rgba(244, 67, 54, 0.3);
    background: rgba(244, 67, 54, 0.1);
}

/* Hidden input (für Kompatibilität) */
.dice-modifier__value {
    display: none;
}

/* ========================================
   ACTION BUTTONS GROUP (Vorteil/Nachteil)
   ======================================== */

.dice-action-group {
    display: flex;
    align-items: center;
    gap: 6px;
    background: #252525;
    border: 1px solid transparent;
    border-radius: 10px;
    padding: 6px 8px;
    transition: border-color 0.2s ease;
}

.dice-action-group:hover {
    border-color: rgba(255, 255, 255, 0.1);
}

.dice-action-btn {
    width: 38px;
    height: 38px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #1b1b1b;
    border: 1px solid transparent;
    border-radius: 8px;
    color: rgba(255, 255, 255, 0.5);
    cursor: pointer;
    transition: all 0.2s ease;
}

.dice-action-btn:hover {
    background: #2a2a2a;
    border-color: rgba(255, 255, 255, 0.1);
    color: white;
}

.dice-action-btn svg {
    width: 18px;
    height: 18px;
}

.dice-action-btn--adv {
    color: #22c55e;
}

.dice-action-btn--adv:hover {
    background: rgba(34, 197, 94, 0.1);
    border-color: #22c55e;
    color: #22c55e;
}

.dice-action-btn--dis {
    color: #f44336;
}

.dice-action-btn--dis:hover {
    background: rgba(244, 67, 54, 0.1);
    border-color: #f44336;
    color: #f44336;
}

.dice-action-btn--reset:hover {
    color: var(--text-primary);
    border-color: var(--text-primary);
    background: rgba(255, 70, 85, 0.1);
}

.dice-action-divider {
    width: 1px;
    height: 24px;
    background: rgba(255, 255, 255, 0.1);
    margin: 0 4px;
}

/* ========================================
   EPIC RESULT POPUP
   ======================================== */

.dice-result {
    position: absolute;
    bottom: 24px;
    left: 50%;
    transform: translateX(-50%) translateY(20px);
    z-index: 20;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    padding: 24px 48px;
    background: rgba(30, 30, 30, 0.7);
    backdrop-filter: blur(24px);
    -webkit-backdrop-filter: blur(24px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 24px;
    box-shadow: 0 25px 80px rgba(0, 0, 0, 0.5);
    opacity: 0;
    pointer-events: none;
}

.dice-result::before {
    display: none;
}

.dice-result.visible {
    animation: resultPopIn 0.5s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
}

@keyframes resultPopIn {
    0% { 
        opacity: 0; 
        transform: translateX(-50%) translateY(40px) scale(0.8); 
    }
    60% {
        transform: translateX(-50%) translateY(-5px) scale(1.02);
    }
    100% { 
        opacity: 1; 
        transform: translateX(-50%) translateY(0) scale(1); 
    }
}

.dice-result__total {
    font-family: var(--font-display);
    font-size: 64px;
    font-weight: 700;
    color: white;
    line-height: 1;
    letter-spacing: -1px;
}

.dice-result__player {
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    order: -1; /* Show above total */
}

.dice-result__breakdown {
    display: flex;
    align-items: center;
    gap: 8px;
    font-family: var(--font-mono);
    font-size: 13px;
    color: var(--text-muted);
    background: rgba(0, 0, 0, 0.25);
    padding: 6px 14px;
    border-radius: 10px;
}

/* Modifier in Result */
.dice-result__mod {
    font-weight: 700;
    padding: 2px 6px;
    border-radius: 4px;
    margin: 0 2px;
}

.dice-result__mod--positive {
    color: #4caf50;
    background: rgba(76, 175, 80, 0.15);
}

.dice-result__mod--negative {
    color: #f44336;
    background: rgba(244, 67, 54, 0.15);
}

/* Back to Character Sheet Button */
.dice-result__back-btn {
    display: none;
    align-items: center;
    gap: 8px;
    margin-top: 16px;
    padding: 10px 20px;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 8px;
    color: rgba(255, 255, 255, 0.9);
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
}

.dice-result__back-btn svg {
    width: 18px;
    height: 18px;
}

.dice-result__back-btn:hover {
    background: rgba(255, 70, 85, 0.2);
    border-color: rgba(255, 70, 85, 0.4);
    color: #fff;
}

.dice-result__back-btn.visible {
    display: inline-flex;
}

/* Skill Label in Result */
.dice-result__skill-label {
    display: none;
    font-size: 16px;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.7);
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 8px;
}

.dice-result__skill-label.visible {
    display: block;
}

/* Target Value Display */
.dice-result__target {
    display: none;
    font-size: 14px;
    color: rgba(255, 255, 255, 0.5);
    margin-top: 4px;
}

.dice-result__target.visible {
    display: block;
}

/* Outcome Display (Erfolg/Fehlschlag) */
.dice-result__outcome {
    display: none;
    font-size: 24px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-top: 12px;
}

.dice-result__outcome.visible {
    display: block;
}

.dice-result__outcome.success {
    color: #22c55e;
    text-shadow: 0 0 20px rgba(34, 197, 94, 0.5);
}

.dice-result__outcome.failure {
    color: #ef4444;
    text-shadow: 0 0 20px rgba(239, 68, 68, 0.5);
}

/* ========================================
   ROLL ZONE LAYOUT
   ======================================== */

.dice-roll-zone {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    padding: 16px 24px;
    flex-wrap: wrap;
    background: #1b1b1b;
    border: none;
    border-radius: 12px;
}

.dice-roll-zone:hover {
    /* keine Border-Änderung */
}

/* Utility Buttons Group (Reset, Stats, Hotkeys, Settings) */
.dice-utility-group {
    display: flex;
    gap: 8px;
    align-items: center;
}

.dice-utility-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    padding: 0;
    background: #2b2b2b;
    border: none;
    border-radius: 8px;
    color: var(--text-muted);
    cursor: pointer;
    transition: all 0.2s ease;
}

.dice-utility-btn:hover {
    background: #3b3b3b;
    color: var(--text);
}

.dice-utility-btn.active {
    background: var(--accent);
    color: white;
}

.dice-utility-btn svg {
    width: 20px;
    height: 20px;
}

/* ========================================
   COMPACT UNIFIED CONTROL BAR
   Kombiniert Modifier + Roll Button + Actions in einer Zeile
   ======================================== */

/* Desktop: Alles in einer Reihe */
@media (min-width: 769px) {
    .dice-roll-zone {
        display: flex;
        flex-wrap: wrap;
        justify-content: center;
        gap: 16px;
        padding: 16px 32px;
    }
    
    /* Roll Button prominent */
    .dice-roll-btn {
        min-width: 160px;
        height: 48px;
    }
    
    /* Action Buttons zusammen */
    .dice-action-group {
        display: flex;
        gap: 8px;
    }
    
    /* Verstecke mobile-only Elemente */
    .dice-mobile-reset,
    .dice-mobile-settings {
        display: none !important;
    }
}

/* ========================================
   MOBILE RESPONSIVE
   ======================================== */

@media (max-width: 768px) {
    .dice-orbit {
        flex-wrap: wrap;
        justify-content: center;
    }
    
    .dice-orbit__dice {
        order: 0;
        width: 100%;
    }
    
    .dice-orbit__action {
        order: 1;
    }
    
    .dice-modifier {
        flex-wrap: wrap;
        justify-content: center;
    }
    
    .dice-modifier__btn--lg {
        display: none;
    }
    
    .dice-action-group {
        order: 2;
        width: 100%;
        justify-content: center;
    }
    
    .dice-roll-btn {
        order: -1;
        width: 100%;
    }
}

@media (max-width: 480px) {
    .dice-orb {
        width: 46px;
        height: 46px;
    }
    
    .dice-orb__icon {
        width: 26px;
        height: 26px;
    }
    
    .dice-modifier__btn--md {
        display: none;
    }
    
    .dice-result {
        padding: 20px 32px;
    }
    
    .dice-result__total {
        font-size: 56px;
    }
}

/* Small +/- buttons */
.dice-modifier__btn--sm {
    min-width: 32px;
    font-size: 12px;
    font-weight: 600;
}

/* ========================================
   DICE LANDING PULSE EFFECT
   ======================================== */

.dice-pulse {
    position: absolute;
    transform: translate(-50%, 0);
    width: 20px;
    height: 20px;
    border-radius: 50%;
    pointer-events: none;
    z-index: 1;
}

.dice-pulse::before,
.dice-pulse::after {
    content: '';
    position: absolute;
    left: 50%;
    top: 50%;
    width: 20px;
    height: 20px;
    margin-left: -10px;
    margin-top: -10px;
    border-radius: 50%;
    border: 2px solid var(--pulse-color, rgba(255, 255, 255, 0.5));
    animation: pulseRing 1s cubic-bezier(0, 0.4, 0.4, 1) forwards;
}

.dice-pulse::after {
    animation-delay: 0.15s;
}

@keyframes pulseRing {
    0% {
        width: 20px;
        height: 20px;
        margin-left: -10px;
        margin-top: -10px;
        opacity: 0.8;
    }
    100% {
        width: 600px;
        height: 600px;
        margin-left: -300px;
        margin-top: -300px;
        opacity: 0;
    }
}

/* Pulse colors - alle Theme-basiert */
.dice-pulse--d4,
.dice-pulse--d6,
.dice-pulse--d8,
.dice-pulse--d10,
.dice-pulse--d12,
.dice-pulse--d20,
.dice-pulse--d100 { 
    --pulse-color: var(--dice-accent); 
}

/* Critical pulse - more intense */
.dice-pulse--crit::before,
.dice-pulse--crit::after {
    border-width: 2px;
    border-color: var(--dice-accent);
    animation: pulseRingCrit 0.7s cubic-bezier(0, 0.4, 0.4, 1) forwards;
}

.dice-pulse--crit::after {
    animation-delay: 0.08s;
}

@keyframes pulseRingCrit {
    0% {
        width: 20px;
        height: 20px;
        margin-left: -10px;
        margin-top: -10px;
        opacity: 1;
    }
    100% {
        width: 600px;
        height: 600px;
        margin-left: -300px;
        margin-top: -300px;
        opacity: 0;
    }
}

/* ========================================
   ARENA SCAN-LINE / RESOLVE EFFECT - DEAKTIVIERT
   ======================================== */

/* Scanline deaktiviert
.dice-arena.resolving::after {
    content: '';
    position: absolute;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, 
        transparent 0%,
        var(--dice-accent) 20%,
        var(--dice-accent) 50%,
        var(--dice-accent) 80%,
        transparent 100%
    );
    box-shadow: 
        0 0 8px var(--dice-accent),
        0 0 20px color-mix(in srgb, var(--dice-accent) 50%, transparent);
    animation: scanLineUp 1s ease-in-out forwards;
    pointer-events: none;
    z-index: 25;
}

@keyframes scanLineUp {
    0% {
        bottom: 0;
        top: auto;
        opacity: 0;
    }
    10% {
        opacity: 1;
    }
    90% {
        opacity: 0.8;
    }
    100% {
        bottom: 100%;
        top: auto;
        opacity: 0;
    }
}
*/

/* Pulse container - UNDER the 3D canvas */
.dice-pulses {
    position: absolute;
    inset: 0;
    pointer-events: none;
    z-index: 1; /* Below the WebGL canvas which is typically z-index: auto */
    overflow: visible;
}

/* ========================================
   DICE HERO CARD BUTTONS - Portrait Design
   Einheitliches RIFT Design System
   ======================================== */

/* Container für Würfel-Buttons */
.dice-orbit__dice {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    overflow: visible;
    position: relative;
    z-index: 1;
}

/* Portrait Card Button */
.dice-btn {
    position: relative;
    width: 150px;
    height: 180px;
    padding: 0;
    border: none;
    border-radius: 10px;
    cursor: pointer;
    overflow: visible;
    transition: all 0.2s ease;
    background: #2b2b2b;
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
}

.dice-btn:hover {
    transform: translateY(-4px);
    background: #383838;
    z-index: 10;
}

.dice-btn:active {
    transform: translateY(-2px) scale(0.98);
}

/* Aktiv (hat Würfel): Akzentfarbe */
.dice-btn.has-count {
    background: rgba(255, 70, 85, 0.15);
    z-index: 5;
}

/* Icon - Oberer Bereich, zentriert - darf überfließen */
.dice-btn__icon {
    position: relative;
    width: 100%;
    height: 115px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 8px 0;
    transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
    z-index: 2;
}

.dice-btn__icon canvas {
    display: block;
    width: 130px !important;
    height: 130px !important;
}

/* Hover: Würfel schwebt über den Container hinaus */
.dice-btn:hover .dice-btn__icon {
    transform: translateY(-20px) rotate(8deg) scale(1.15);
    filter: drop-shadow(4px 12px 12px rgba(0, 0, 0, 0.5));
}

/* Label */
.dice-btn__label {
    font-family: 'Inter', sans-serif;
    font-size: 22px;
    font-weight: 700;
    color: var(--text);
    text-align: center;
    padding: 2px 0;
    line-height: 1;
}

/* Badge/Count */
.dice-btn__badge {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 4px 10px;
    margin: auto 16px 10px 16px;
    background: var(--bg-elevated);
    border-radius: 4px;
    font-family: 'Inter', sans-serif;
    font-size: 12px;
    font-weight: 600;
    color: var(--text-muted);
    transition: all 0.2s ease;
}

.dice-btn__badge span {
    min-width: 10px;
    text-align: center;
}

.dice-btn__badge::before {
    content: '×';
    margin-right: 2px;
    opacity: 0.5;
    font-size: 10px;
}

.dice-btn.has-count .dice-btn__badge {
    background: var(--accent);
    color: white;
}

.dice-btn.has-count .dice-btn__badge::before {
    opacity: 1;
}

/* Info Button for probability tooltip */
.dice-btn__info {
    position: absolute;
    top: 6px;
    right: 6px;
    width: 18px;
    height: 18px;
    padding: 0;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    color: rgba(255, 255, 255, 0.5);
    font-size: 11px;
    font-weight: 700;
    font-family: 'Inter', sans-serif;
    cursor: help;
    opacity: 0;
    transition: all 0.2s ease;
    z-index: 10;
    display: flex;
    align-items: center;
    justify-content: center;
}

.dice-btn:hover .dice-btn__info {
    opacity: 1;
}

.dice-btn__info:hover {
    background: rgba(255, 255, 255, 0.2);
    border-color: rgba(255, 255, 255, 0.4);
    color: white;
    transform: scale(1.1);
}

/* Glass Bar entfernen - nicht mehr benötigt */
.dice-btn__glass {
    display: none;
}

.dice-btn__icon canvas {
    cursor: grab;
}

.dice-btn__icon canvas:active {
    cursor: grabbing;
}

/* Hover: Icon hoch + rotiert - ÜBER den Container */
.dice-btn:hover .dice-btn__icon {
    transform: translateY(-25px) rotate(10deg) scale(1.2);
    filter: drop-shadow(4px 15px 15px rgba(0, 0, 0, 0.5));
}

/* Selected: Langsames Schweben - HÖHER über Container */
.dice-btn.has-count .dice-btn__icon {
    animation: diceFloat 4s ease-in-out infinite;
}

/* Glow für ausgewählte Würfel */
.dice-btn.has-count::after {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 10px;
    pointer-events: none;
    animation: selectedGlow 3.5s ease-in-out infinite;
}

@keyframes selectedGlow {
    0%, 100% { 
        box-shadow: 0 0 10px var(--dice-bg-light), 0 0 20px var(--dice-shadow);
    }
    50% { 
        box-shadow: 0 0 18px var(--dice-bg-light), 0 0 35px var(--dice-shadow);
    }
}

@keyframes diceFloat {
    0%, 100% { 
        transform: translateY(-15px) rotate(0deg); 
    }
    50% { 
        transform: translateY(-30px) rotate(5deg); 
    }
}

/* ========================================
   PARTIKEL-EFFEKT BEI AUSWAHL
   ======================================== */

.dice-btn__particles {
    position: absolute;
    top: 0;
    right: 8px;
    width: 40px;
    height: 10px;
    pointer-events: none;
    overflow: visible;
    z-index: 20;
}

.dice-btn__particle {
    position: absolute;
    background: var(--dice-bg-light);
    border-radius: 50%;
    opacity: 0;
    pointer-events: none;
}

@keyframes particleFloat {
    0% {
        opacity: 0;
        transform: translateY(0) translateX(0);
    }
    15% {
        opacity: 0.8;
    }
    85% {
        opacity: 0.3;
    }
    100% {
        opacity: 0;
        transform: translateY(-60px) translateX(var(--drift));
    }
}

/* ========================================
   MOBILE ELEMENTS - auf Desktop versteckt
   ======================================== */

.dice-mobile-settings,
.dice-mobile-reset {
    display: none;
}

/* Desktop Settings Overlay - hinter dem Popup aber über allem anderen */
.dice-settings-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.85);
    z-index: 99998; /* Knapp unter dem Popup */
    /* KEIN backdrop-filter - das würde das Popup mit verschwimmen lassen */
}

.dice-settings-overlay.open {
    display: block;
}

/* Mobile overlays verstecken auf Desktop */
.mobile-settings-popup,
.mobile-settings-overlay {
    display: none;
}

/* ========================================
   MOBILE DICE - NUR MOBILE
   Desktop bleibt 100% unberührt
   ======================================== */

@media (max-width: 768px) {
    /* === PAGE === */
    .dice-page {
        display: flex;
        flex-direction: column;
        height: calc(100dvh - 60px);
        padding: 8px;
        gap: 6px;
        overflow: hidden;
    }
    
    /* Alles verstecken was nicht gebraucht wird */
    .dice-page > .page-header,
    .dice-page > .section-divider,
    .page-header,
    .section-divider,
    .dice-toolbar,
    .dice-quick-row,
    .dice-history {
        display: none !important;
    }
    
    /* === ARENA === */
    .dice-arena {
        flex: 1;
        min-height: 100px;
        border-radius: 12px;
    }
    
    /* === CONTROLS === */
    .dice-controls {
        display: flex;
        flex-direction: column;
        flex-shrink: 0;
        gap: 6px;
        padding-bottom: env(safe-area-inset-bottom, 8px);
    }
    
    /* === WÜRFEL ORBIT === */
    .dice-orbit {
        padding: 6px;
        border-radius: 10px;
        background: #1b1b1b;
    }
    
    /* Action Buttons im Orbit verstecken */
    .dice-orbit > .dice-orbit__action,
    .dice-orbit__stats,
    .dice-orbit__hotkeys,
    .dice-orbit__settings {
        display: none !important;
    }
    
    /* Settings Wrapper: display: contents lässt das Popup funktionieren */
    .dice-orbit > .dice-settings-wrapper {
        display: contents;
    }
    
    /* Der Settings Button ist sowieso versteckt via .dice-orbit__settings oben */
    
    /* Würfel Grid - 12 Spalten für flexible Aufteilung */
    .dice-orbit__dice {
        display: grid !important;
        grid-template-columns: repeat(12, 1fr);
        gap: 6px;
    }
    
    /* Erste Reihe: 4 Würfel je 3 Spalten */
    .dice-btn[data-dice="d4"] { grid-column: span 3; }
    .dice-btn[data-dice="d6"] { grid-column: span 3; }
    .dice-btn[data-dice="d8"] { grid-column: span 3; }
    .dice-btn[data-dice="d10"] { grid-column: span 3; }
    
    /* Zweite Reihe: 3 Würfel je 4 Spalten = ALLE GLEICH BREIT */
    .dice-btn[data-dice="d12"] { grid-column: span 4; }
    .dice-btn[data-dice="d20"] { grid-column: span 4; }
    .dice-btn[data-dice="d100"] { grid-column: span 4; }
    
    /* Würfel Buttons - Statische Icons */
    .dice-btn {
        width: 100% !important;
        height: 56px !important;
        border-radius: 10px;
        position: relative;
    }
    
    /* Canvas verstecken */
    .dice-btn__icon {
        display: none !important;
    }
    
    /* Statische SVG Icons via CSS - GROSS und ZENTRIERT */
    .dice-btn::before {
        content: '';
        position: absolute;
        top: 50%;
        left: 50%;
        transform: translate(-50%, -50%);
        width: 42px;
        height: 42px;
        background-size: contain;
        background-repeat: no-repeat;
        background-position: center;
        filter: brightness(0) invert(1);
        opacity: 0.9;
    }
    
    .dice-btn[data-dice="d4"]::before { background-image: url('../icons/dice/d4.svg'); }
    .dice-btn[data-dice="d6"]::before { background-image: url('../icons/dice/d6.svg'); }
    .dice-btn[data-dice="d8"]::before { background-image: url('../icons/dice/d8.svg'); }
    .dice-btn[data-dice="d10"]::before { background-image: url('../icons/dice/d10.svg'); }
    .dice-btn[data-dice="d12"]::before { background-image: url('../icons/dice/d12.svg'); }
    .dice-btn[data-dice="d20"]::before { background-image: url('../icons/dice/d20.svg'); }
    .dice-btn[data-dice="d100"]::before { background-image: url('../icons/dice/d100.svg'); }
    
    /* Label verstecken - nur Icon */
    .dice-btn__glass,
    .dice-btn__label {
        display: none !important;
    }
    
    .dice-btn__badge {
        top: 4px;
        right: 6px;
        font-size: 10px;
        padding: 2px 6px;
    }
    
    /* === ROLL ZONE - CSS GRID für klare Zeilen === */
    .dice-roll-zone {
        display: grid !important;
        grid-template-areas:
            "roll roll roll"
            "adv mod dis"
            "reset settings settings";
        grid-template-columns: 48px 1fr 48px;
        gap: 6px;
        padding: 8px;
        border-radius: 10px;
        background: #1b1b1b;
    }
    
    .dice-notation {
        display: none !important;
    }
    
    /* WÜRFELN */
    .dice-roll-btn {
        grid-area: roll;
        height: 50px;
        font-size: 20px;
        font-weight: 700;
        border-radius: 10px;
    }
    
    /* === MODIFIER ZEILE === */
    .dice-action-group {
        display: contents !important;
    }
    
    .dice-action-btn--adv {
        grid-area: adv;
        height: 36px;
        border-radius: 8px;
        display: flex !important;
        align-items: center;
        justify-content: center;
        background: rgba(74, 222, 128, 0.2);
        color: #4ade80;
        border: none;
    }
    
    .dice-modifier {
        grid-area: mod;
        display: flex !important;
        justify-content: center;
        align-items: center;
        gap: 3px;
        padding: 3px 6px;
        background: rgba(0,0,0,0.3);
        border-radius: 8px;
        height: 36px;
        overflow: hidden;
    }
    
    /* +1/-1 KOMPLETT WEG */
    .dice-modifier .dice-modifier__btn.dice-modifier__btn--sm,
    .dice-modifier button.dice-modifier__btn--sm {
        display: none !important;
        position: absolute !important;
        left: -9999px !important;
    }
    
    .dice-modifier__btn {
        display: flex !important;
        min-width: 28px;
        height: 28px;
        padding: 0 4px;
        font-size: 10px;
        border-radius: 5px;
        align-items: center;
        justify-content: center;
        flex-shrink: 0;
        background: rgba(255,255,255,0.08);
    }
    
    .dice-modifier__display {
        min-width: 32px;
        height: 28px;
        line-height: 28px;
        font-size: 13px;
        font-weight: 700;
        text-align: center;
        flex-shrink: 0;
    }
    
    .dice-modifier__value {
        display: none !important;
    }
    
    .dice-action-btn--dis {
        grid-area: dis;
        height: 36px;
        border-radius: 8px;
        display: flex !important;
        align-items: center;
        justify-content: center;
        background: rgba(248, 113, 113, 0.2);
        color: #f87171;
        border: none;
    }
    
    .dice-action-btn svg {
        width: 18px;
        height: 18px;
    }
    
    /* === BOTTOM ROW: [Reset] [Einstellungen] === */
    .dice-mobile-reset {
        grid-area: reset;
        display: flex !important;
        height: 48px;
        align-items: center;
        justify-content: center;
        background: rgba(255,255,255,0.05);
        border: 1px solid rgba(255,255,255,0.08);
        border-radius: 10px;
        color: var(--text-muted);
        cursor: pointer;
    }
    
    .dice-mobile-reset svg {
        width: 20px;
        height: 20px;
        opacity: 0.7;
    }
    
    .dice-mobile-settings {
        grid-area: settings;
        display: flex !important;
        height: 48px;
        align-items: center;
        justify-content: center;
        gap: 10px;
        background: rgba(255,255,255,0.05);
        border: 1px solid rgba(255,255,255,0.08);
        border-radius: 10px;
        color: var(--text-muted);
        font-size: 14px;
        cursor: pointer;
    }
    
    .dice-mobile-settings svg {
        width: 18px;
        height: 18px;
        opacity: 0.7;
    }
    
    /* === SETTINGS POPUP === */
    .dice-settings-popup {
        display: none;
        position: fixed !important;
        bottom: 0 !important;
        left: 0 !important;
        right: 0 !important;
        top: auto !important;
        transform: none !important;
        width: 100% !important;
        height: auto !important;
        max-height: 75vh;
        border-radius: 20px 20px 0 0;
        padding-bottom: env(safe-area-inset-bottom, 16px);
        z-index: 1001;
        overflow: hidden;
        flex-direction: column;
    }
    
    .dice-settings-popup.open {
        display: flex !important;
    }
    
    .dice-settings-popup__header {
        padding: 16px;
        border-bottom: 1px solid rgba(255,255,255,0.1);
    }
    
    .dice-settings-popup__section--themes {
        padding: 12px;
    }
    
    .dice-theme-grid {
        display: grid;
        grid-template-columns: repeat(4, 1fr);
        gap: 8px;
    }
    
    .dice-theme-card {
        padding: 8px 4px;
    }
    
    .dice-theme-card__preview {
        width: 36px;
        height: 36px;
    }
    
    .dice-theme-card span {
        font-size: 9px;
    }
    
    /* Overlay für Popup */
    .dice-settings-overlay {
        position: fixed;
        inset: 0;
        background: rgba(0,0,0,0.6);
        z-index: 1000;
        display: none;
    }
    
    .dice-settings-overlay.open {
        display: block;
    }
    
    /* Alte Overlays verstecken */
    .dice-settings-overlay {
        display: none !important;
    }
    
    /* === FABs NEBENEINANDER schweben über allem === */
    .rift-fab-container {
        position: fixed !important;
        bottom: 16px !important;
        right: 16px !important;
        flex-direction: row !important;
        gap: 8px !important;
        z-index: 900 !important;
    }
    
    .rift-fab {
        width: 48px !important;
        height: 48px !important;
    }
    
    /* === MOBILE SETTINGS OVERLAY === */
    .mobile-settings-overlay {
        display: none;
        position: fixed;
        inset: 0;
        background: rgba(0,0,0,0.7);
        z-index: 99998;
    }
    
    .mobile-settings-overlay.open {
        display: block;
    }
    
    /* === MOBILE SETTINGS POPUP - Bottom Sheet === */
    .mobile-settings-popup {
        display: none;
        position: fixed;
        bottom: 0;
        left: 0;
        right: 0;
        background: #1a1a1a;
        border-radius: 20px 20px 0 0;
        max-height: 80vh;
        overflow-y: auto;
        z-index: 99999;
        box-shadow: 0 -10px 40px rgba(0,0,0,0.5);
        padding-bottom: env(safe-area-inset-bottom, 16px);
    }
    
    .mobile-settings-popup.open {
        display: block;
    }
    
    .mobile-settings-popup__header {
        display: flex;
        align-items: center;
        justify-content: space-between;
        padding: 16px 20px;
        border-bottom: 1px solid rgba(255,255,255,0.1);
        position: sticky;
        top: 0;
        background: #1a1a1a;
    }
    
    .mobile-settings-popup__header span {
        font-size: 18px;
        font-weight: 600;
        color: #fff;
    }
    
    .mobile-settings-popup__close {
        width: 36px;
        height: 36px;
        border-radius: 50%;
        background: rgba(255,255,255,0.1);
        border: none;
        color: #fff;
        display: flex;
        align-items: center;
        justify-content: center;
        cursor: pointer;
    }
    
    .mobile-settings-popup__close svg {
        width: 20px;
        height: 20px;
    }
    
    .mobile-settings-popup__content {
        padding: 16px;
    }
    
    .mobile-settings-popup__label {
        display: block;
        font-size: 14px;
        color: rgba(255,255,255,0.6);
        margin-bottom: 12px;
    }
    
    .mobile-theme-grid {
        display: grid;
        grid-template-columns: repeat(4, 1fr);
        gap: 10px;
    }
    
    .mobile-theme-grid .dice-theme-card {
        padding: 10px 6px;
        border-radius: 10px;
        background: rgba(255,255,255,0.05);
        border: 2px solid transparent;
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 6px;
        cursor: pointer;
    }
    
    .mobile-theme-grid .dice-theme-card.active {
        border-color: var(--primary, #8b5cf6);
        background: rgba(139, 92, 246, 0.1);
    }
    
    .mobile-theme-grid .dice-theme-card__preview {
        width: 40px;
        height: 40px;
        border-radius: 8px;
    }
    
    .mobile-theme-grid .dice-theme-card span {
        font-size: 10px;
        color: rgba(255,255,255,0.7);
    }
    
    /* Result & Feed */
    .dice-result {
        padding: 16px;
    }
    
    .dice-result__total {
        font-size: 44px;
    }
    
    .dice-feed {
        top: 8px;
        right: 8px;
        max-width: 100px;
    }
}

/* Kleine Screens */
@media (max-width: 380px) {
    .dice-btn {
        height: 50px !important;
    }
    
    .dice-btn::before {
        width: 36px;
        height: 36px;
    }
    
    .dice-roll-zone {
        grid-template-columns: 42px 1fr 42px;
        gap: 4px;
        padding: 6px;
    }
    
    .dice-modifier {
        gap: 2px;
        padding: 2px 4px;
        height: 32px;
    }
    
    .dice-modifier__btn {
        min-width: 24px;
        height: 24px;
        font-size: 9px;
        padding: 0 2px;
    }
    
    /* +1/-1 WEG */
    .dice-modifier .dice-modifier__btn.dice-modifier__btn--sm {
        display: none !important;
        position: absolute !important;
        left: -9999px !important;
    }
    
    .dice-action-btn--adv,
    .dice-action-btn--dis {
        height: 32px;
    }
    
    .dice-action-btn svg {
        width: 16px;
        height: 16px;
    }
    
    .dice-modifier__display {
        min-width: 28px;
        height: 24px;
        line-height: 24px;
        font-size: 11px;
    }
    
    .dice-roll-btn {
        height: 44px;
        font-size: 18px;
    }
    
    .dice-mobile-settings {
        height: 42px;
        font-size: 13px;
    }
    
    .dice-mobile-reset {
        height: 42px;
    }
}


/* Spinning dice removed - using real 3D dice */

/* ========================================
   SPINNING DICE EFFECT
   ======================================== */

.dice-spinning-effect {
    position: relative;
}

.dice-spinning-effect::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 180px;
    height: 180px;
    background: radial-gradient(circle, rgba(255,255,255,0.15) 0%, rgba(255,255,255,0.05) 40%, transparent 70%);
    border-radius: 50%;
    animation: spinGlow 2s ease-in-out infinite;
    pointer-events: none;
    z-index: 1;
}

@keyframes spinGlow {
    0%, 100% {
        opacity: 0.4;
        transform: translate(-50%, -50%) scale(1);
    }
    50% {
        opacity: 0.7;
        transform: translate(-50%, -50%) scale(1.1);
    }
}

