/* ===================================
   عجلة الأسماء - Qatar Seen Jeem
   =================================== */

:root {
    --primary-maroon: #a29a8a;
    --secondary-white: #F9F9F9;
    --accent-gold: #ffffff;
    --text-white: #FFFFFF;
    --dark-maroon: #5A1520;
    --light-maroon: #9A2E37;
    --shadow: rgba(122, 30, 39, 0.2);
    --success: #2ECC71;
    --danger: #E74C3C;
}

.wheel-page {
    background: linear-gradient(135deg, #af1540 0%, #7d193d 100%);
    min-height: 100vh;
    padding-bottom: 2rem;
}

.wheel-container {
    padding: 2rem 0;
}

.wheel-layout {
    display: grid;
    grid-template-columns: 1fr 1.5fr 1fr;
    gap: 2rem;
    margin-bottom: 2rem;
}

/* ===================================
   Panel Cards
   =================================== */

.panel-card {
    background: linear-gradient(135deg, white 0%, #faf7f2 100%);
    border-radius: 20px;
    padding: 2.5rem;
    box-shadow: 
        0 15px 40px rgba(0, 0, 0, 0.15),
        0 0 1px rgba(255, 255, 255, 0.5) inset;
    backdrop-filter: blur(5px);
    border: 1px solid rgba(255, 255, 255, 0.6);
    transition: all 0.3s ease;
}

.panel-card:hover {
    box-shadow: 
        0 20px 50px rgba(0, 0, 0, 0.2),
        0 0 1px rgba(255, 255, 255, 0.6) inset;
    transform: translateY(-3px);
}

.panel-card h2 {
    color: var(--primary-maroon);
    margin-bottom: 1.5rem;
    font-size: 1.6rem;
    text-align: center;
    border-bottom: 3px solid gold;
    padding-bottom: 0.75rem;
    font-weight: 800;
    letter-spacing: 0.5px;
}

.panel-card h3 {
    color: var(--primary-maroon);
    margin-bottom: 1rem;
    font-size: 1.2rem;
}

/* ===================================
   Names Panel
   =================================== */

.add-name-form {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 2rem;
}

.name-input {
    flex: 1;
    padding: 12px 16px;
    border: 2px solid #e0e0e0;
    border-radius: 12px;
    font-family: 'Cairo', sans-serif;
    font-size: 1rem;
    transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
    background: linear-gradient(135deg, #fafafa 0%, #ffffff 100%);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.name-input:focus {
    outline: none;
    border-color:gold
    box-shadow: 
        0 0 0 3px rgba(255, 255, 255, 0.3),
        0 4px 16px rgba(212, 175, 55, 0.2);
    transform: translateY(-2px);
    background: white;
}

.quick-add {
    background: #f9f9f9;
    padding: 1.5rem;
    border-radius: 10px;
    margin-bottom: 2rem;
}

.quick-add p {
    margin-bottom: 0.75rem;
    color: #666;
    font-size: 0.9rem;
}

.bulk-input {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid #e0e0e0;
    border-radius: 12px;
    font-family: 'Cairo', sans-serif;
    font-size: 1rem;
    resize: vertical;
    margin-bottom: 0.75rem;
    transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
    background: linear-gradient(135deg, #fafafa 0%, #ffffff 100%);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.bulk-input:focus {
    outline: none;
    border-color:gold
    box-shadow: 
        0 0 0 3px rgba(255, 255, 255, 0.3),
        0 4px 16px rgba(212, 175, 55, 0.2);
    transform: translateY(-2px);
    background: white;
}

.names-list {
    margin-top: 2rem;
}

.names-container {
    max-height: 300px;
    overflow-y: auto;
    margin-bottom: 1rem;
    padding: 0.5rem;
}

.name-tag {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: linear-gradient(135deg, #af1540 0%, #7d193d 100%);
    color: white;
    padding: 12px 16px;
    border-radius: 10px;
    margin-bottom: 0.75rem;
    animation: slideIn 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
    border: 1px solid rgba(255, 255, 255, 0.1);
    transition: all 0.3s ease;
}

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

.name-tag:hover {
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.3);
    transform: translateX(5px);
    background: linear-gradient(135deg, var(--dark-maroon) 0%, var(--light-maroon) 100%);
}

.name-tag span {
    font-weight: 700;
    letter-spacing: 0.3px;
}

.name-tag button {
    background: rgba(255, 255, 255, 0.2);
    border: none;
    color: white;
    padding: 6px 12px;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
    font-family: 'Cairo', sans-serif;
    font-weight: 700;
}

.name-tag button:hover {
    background: rgba(255, 255, 255, 0.35);
    transform: scale(1.08);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.empty-state {
    text-align: center;
    color: #999;
    padding: 2rem;
    font-style: italic;
}

/* ===================================
   Wheel Panel
   =================================== */

.wheel-wrapper {
    position: relative;
    display: flex;
    justify-content: center;
    align-items: center;
    margin: 2rem 0;
}

#wheelCanvas {
    max-width: 100%;
    height: auto;
    filter: drop-shadow(0 10px 20px rgba(0, 0, 0, 0.3));
}

.wheel-pointer {
    position: absolute;
    top: -20px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 3rem;
    color:gold
    filter: drop-shadow(0 5px 10px rgba(0, 0, 0, 0.3));
    animation: bounce 2s infinite;
}

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

.wheel-controls {
    text-align: center;
}

.btn-large {
    font-size: 1.3rem;
    padding: 1rem 2rem;
    min-width: 250px;
}

.selected-name {
    margin-top: 2rem;
    text-align: center;
    animation: fadeIn 0.5s ease;
}

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

.name-display {
    background: linear-gradient(135deg, var(--accent-gold) 0%, #f0f0f0 100%);
    color: var(--primary-maroon);
    padding: 2rem;
    border-radius: 16px;
    font-size: 2.2rem;
    font-weight: 900;
    margin-top: 1rem;
    box-shadow: 
        0 8px 25px rgba(0, 0, 0, 0.2),
        0 0 1px rgba(255, 255, 255, 0.5) inset;
    backdrop-filter: blur(5px);
    border: 2px solid rgba(255, 255, 255, 0.3);
    animation: popIn 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
}

@keyframes popIn {
    0% {
        opacity: 0;
        transform: scale(0.8) rotateZ(-5deg);
    }
    50% {
        transform: scale(1.05);
    }
    100% {
        opacity: 1;
        transform: scale(1) rotateZ(0deg);
    }
}

/* ===================================
   Teams Panel
   =================================== */

.team-settings {
    margin-bottom: 1.5rem;
    padding: 1rem;
    background: #f9f9f9;
    border-radius: 8px;
}

.team-settings label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 600;
    color: var(--primary-maroon);
}

.team-settings select {
    width: 100%;
    padding: 0.75rem;
    border: 2px solid #ddd;
    border-radius: 8px;
    font-family: 'Cairo', sans-serif;
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.3s ease;
}

.team-settings select:focus {
    outline: none;
    border-color:gold
}

.auto-distribute {
    margin-bottom: 1.5rem;
}

.auto-distribute button {
    width: 100%;
}

.teams-container {
    margin-bottom: 1.5rem;
    max-height: 400px;
    overflow-y: auto;
}

.team-box {
    background: linear-gradient(135deg, #af1540 0%, #7d193d 100%);
    border-radius: 16px;
    padding: 2rem;
    margin-bottom: 1.5rem;
    animation: slideIn 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
    box-shadow: 
        0 8px 20px rgba(0, 0, 0, 0.3),
        0 0 1px rgba(255, 255, 255, 0.1) inset;
    border: 1px solid rgba(255, 255, 255, 0.1);
    transition: all 0.3s ease;
}

.team-box:hover {
    box-shadow: 
        0 12px 30px rgba(0, 0, 0, 0.4),
        0 0 1px rgba(255, 255, 255, 0.15) inset;
    transform: translateY(-2px);
}

.team-header {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid gold;
}

.team-name-input {
    flex: 1;
    background: rgba(255, 255, 255, 0.1);
    border: 2px solid transparent;
    color: #ffffff;
    padding: 0.5rem 0.75rem;
    border-radius: 8px;
    font-family: 'Cairo', sans-serif;
    font-size: 1.2rem;
    font-weight: 600;
    transition: all 0.3s ease;
}