/*
========================================================================
GLOBAL CHALLENGE WHEELS STYLESHEET (Gielinor Gatherings Theme)
========================================================================
*/

:root {
    --bg: #071018;
    --card: #102131;
    --gold: #d9b15f;
    --gold-bright: #f2d28c;
    --blue: #2f8cff;
    --text: #f2f2f2;
    --muted: #b7c0cb;
    --border: rgba(255, 255, 255, 0.08);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
    background: 
        radial-gradient(circle at top, rgba(47,140,255,0.12), transparent 45%),
        linear-gradient(to bottom, #04070c, var(--bg));
    color: var(--text);
    padding: 40px 20px;
    min-height: 100vh;
    overflow-x: hidden;
}

/* Custom Scrollbars */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: #04070c;
}
::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: var(--gold);
}

h1 {
    font-size: clamp(2rem, 4vw, 3rem);
    color: var(--gold-bright);
    text-shadow: 0 0 20px rgba(217, 177, 95, 0.35);
    margin-bottom: 40px;
    font-weight: 700;
    text-align: center;
}

/* Wheel Canvas Grid Display */
.container {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 50px;
    margin-top: 20px;
    align-items: flex-start;
}

.wheel-wrapper {
    position: relative;
    background: rgba(16, 33, 49, 0.4);
    border: 1px solid var(--border);
    padding: 30px;
    border-radius: 24px;
    backdrop-filter: blur(10px);
    box-shadow: 0 12px 40px rgba(0,0,0,0.4);
    transition: transform 0.3s ease;
    text-align: center;
}

.wheel-wrapper:hover {
    transform: translateY(-5px);
    border-color: rgba(217, 177, 95, 0.25);
}

.wheel-wrapper p {
    margin-top: 20px;
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--gold-bright);
    letter-spacing: 0.5px;
}

canvas {
    background: #111e29;
    border-radius: 50%;
    box-shadow: 
        0 0 0 6px rgba(16, 33, 49, 0.8),
        0 0 0 8px rgba(217, 177, 95, 0.4),
        0 15px 40px rgba(0,0,0,0.6);
    display: block;
    margin: 0 auto;
}

/* Reimagined Arrow Selector */
.arrow {
    width: 0;
    height: 0;
    border-left: 16px solid transparent;
    border-right: 16px solid transparent;
    border-top: 26px solid var(--gold-bright);
    filter: drop-shadow(0 4px 8px rgba(0,0,0,0.5));
    margin: 0 auto 15px;
    position: relative;
    z-index: 5;
}

/* Centered Button Dashboard Layout */
.controls {
    margin: 40px 0;
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 16px;
}

/* Premium Buttons matching index.html actions */
button {
    padding: 14px 28px;
    font-size: 15px;
    font-weight: 700;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.25s ease;
    border: 1px solid transparent;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.03);
    border-color: rgba(255, 255, 255, 0.14);
    color: var(--text);
    backdrop-filter: blur(12px);
}

button:hover {
    transform: translateY(-3px);
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(255, 255, 255, 0.25);
}

/* Highlight primary multi-spin action */
button[onclick*="spinBoth"] {
    background: linear-gradient(135deg, var(--gold), #9b6b25);
    color: #1a1206;
    border-color: transparent;
    box-shadow: 0 8px 24px rgba(217, 177, 95, 0.25);
}

button[onclick*="spinBoth"]:hover {
    box-shadow: 0 12px 32px rgba(217, 177, 95, 0.4);
}
/* Highlight primary multi-spin action */
button[onclick*="spinSequentially"] {
    background: linear-gradient(135deg, var(--gold), #9b6b25);
    color: #1a1206;
    border-color: transparent;
    box-shadow: 0 8px 24px rgba(217, 177, 95, 0.25);
}

button[onclick*="spinSequentially"]:hover {
    box-shadow: 0 12px 32px rgba(217, 177, 95, 0.4);
}

/* Modern Glowing Live Results Panel */
.results {
    margin: 30px auto;
    max-width: 650px;
    background: linear-gradient(145deg, rgba(217,177,95,0.08), rgba(47,140,255,0.05));
    border: 1px solid rgba(217, 177, 95, 0.15);
    border-radius: 20px;
    padding: 24px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.3);
}

.results div {
    font-size: 1.15rem;
    line-height: 1.8;
    color: var(--muted);
    font-weight: 500;
}

.results div:not(:last-child) {
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    padding-bottom: 12px;
    margin-bottom: 12px;
}

/* Menu Custom Labels Customization Panel */
.menus {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 40px;
    margin-top: 45px;
    max-width: 1000px;
    margin-left: auto;
    margin-right: auto;
}

.menu {
    flex: 1;
    min-width: 280px;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--border);
    border-radius: 20px;
    padding: 24px;
}

.menu h3 {
    font-size: 1.2rem;
    color: var(--gold-bright);
    margin-bottom: 16px;
    border-bottom: 1px solid rgba(217, 177, 95, 0.2);
    padding-bottom: 8px;
    font-weight: 600;
}

.menu div {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.menu input {
    width: 100%;
    padding: 11px 16px;
    background: rgba(0, 0, 0, 0.4);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    color: var(--text);
    font-size: 14px;
    font-family: inherit;
    transition: all 0.25s ease;
}

.menu input:focus {
    outline: none;
    border-color: var(--blue);
    background: rgba(16, 33, 49, 0.6);
    box-shadow: 0 0 10px rgba(47, 140, 255, 0.25);
}

@media (max-width: 600px) {
    body {
        padding: 20px 10px;
    }
    .wheel-wrapper {
        padding: 16px;
        width: 100%;
    }
    canvas {
        width: 100% !important;
        height: auto !important;
    }
    button {
        width: 100%;
    }
    
    
    
    
}

.page-wrapper{
    transform-origin: top center;


}

/* Floating Settings Trigger & Dropdown */
.settings-menu-container {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 2000;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

.cog-btn {
    background: rgba(16, 33, 49, 0.85);
    border: 1px solid var(--gold);
    color: var(--gold-bright);
    font-size: 20px;
    width: 42px;
    height: 42px;
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.2s ease-in-out;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
    display: flex;
    align-items: center;
    justify-content: center;
    backdrop-filter: blur(4px);
}

.cog-btn:hover {
    transform: rotate(45deg);
    background: var(--card);
    box-shadow: 0 4px 16px rgba(217, 177, 95, 0.2);
}

.settings-dropdown {
    position: absolute;
    top: 52px;
    right: 0;
    background: #102131;
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 16px;
    box-sizing: border-box;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.6);
    display: none; /* Handled dynamically via JS */
    min-width: 180px;
}

.settings-dropdown.show {
    display: block;
    animation: fadeInDropdown 0.15s ease-out;
}

.zoom-controls-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    margin-top: 6px;
}

@keyframes fadeInDropdown {
    from { opacity: 0; transform: translateY(-5px); }
    to { opacity: 1; transform: translateY(0); }
}