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

body {
    font-family: 'Arial', sans-serif;
    background: url('background.png') no-repeat center center fixed;
    background-size: cover;
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20px;
}

.container {
    background: transparent;
    border-radius: 20px;
    padding: 20px;
    max-width: 1400px;
    width: 100%;
}

h1 {
    text-align: center;
    margin-bottom: 50px;
    font-size: 3rem;
    font-family: "華文行楷", "STXingkai", cursive;
    letter-spacing: 3px;
    position: relative;
}

h1::before {
    content: "亡命之輪";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(45deg, #ffdd44, #ff6b35, #ff8c00);
    background-size: 300% 300%;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: gradient-shift 6s ease-in-out infinite;
    opacity: 0.8;
    z-index: 2;
}

h1::after {
    content: "亡命之輪";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    color: rgba(255, 255, 255, 0.6);
    text-shadow: 
        1px 1px 2px rgba(0, 0, 0, 0.7),
        0 0 25px rgba(255, 165, 0, 0.6),
        0 0 40px rgba(255, 140, 0, 0.4);
    z-index: 1;
}

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

.game-container {
    display: grid;
    grid-template-columns: 1.2fr 0.64fr;
    gap: 40px;
    align-items: start;
}

.wheel-section {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.wheel-container {
    position: relative;
    width: 630px;
    height: 630px;
}

#wheel {
    border-radius: 50%;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}

.pointer {
    display: none;
}

.controls {
    margin-top: 30px;
}

.spin-btn {
    background: linear-gradient(135deg, #8B0000, #DC143C, #B22222);
    color: #f4f4f4;
    border: 3px solid #654321;
    padding: 18px 45px;
    font-size: 1.4rem;
    font-family: "Noto Serif TC", "Microsoft JhengHei", "微軟正黑體", "華文黑體", "STHeiti", serif;
    font-weight: bold;
    border-radius: 0;
    cursor: pointer;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.8);
    box-shadow: 
        inset 0 2px 0 rgba(255, 255, 255, 0.2),
        0 4px 8px rgba(0, 0, 0, 0.4),
        0 0 15px rgba(220, 20, 60, 0.6);
    transition: all 0.3s;
    letter-spacing: 2px;
    position: relative;
    overflow: hidden;
}

.spin-btn:hover {
    transform: translateY(-3px);
    box-shadow: 
        inset 0 2px 0 rgba(255, 255, 255, 0.3),
        0 6px 12px rgba(0, 0, 0, 0.5),
        0 0 25px rgba(220, 20, 60, 0.8);
    background: linear-gradient(135deg, #A0522D, #FF6347, #CD5C5C);
}

.spin-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
    box-shadow: 
        inset 0 1px 0 rgba(255, 255, 255, 0.1),
        0 2px 4px rgba(0, 0, 0, 0.3);
}

.list-section {
    background: url('fugitive_list.png') no-repeat center center;
    background-size: cover;
    padding: 30px;
    border-radius: 15px;
}

.list-section h2 {
    font-family: "Ma Shan Zheng", "Noto Serif TC", "華文行楷", "STXingkai", cursive;
    font-size: 2rem;
    font-weight: 900;
    margin-bottom: 20px;
    text-align: center;
    position: relative;
    color: #8B0000;
    text-shadow: 
        2px 2px 0px #000,
        -1px -1px 0px #000,
        1px -1px 0px #000,
        -1px 1px 0px #000,
        0 0 8px rgba(139, 0, 0, 0.8),
        0 0 15px rgba(220, 20, 60, 0.6);
    letter-spacing: 2px;
    animation: dangerous-glow 2s ease-in-out infinite alternate;
}

@keyframes dangerous-glow {
    0% { 
        text-shadow: 
            2px 2px 0px #000,
            -1px -1px 0px #000,
            1px -1px 0px #000,
            -1px 1px 0px #000,
            0 0 8px rgba(139, 0, 0, 0.8),
            0 0 15px rgba(220, 20, 60, 0.6);
    }
    100% { 
        text-shadow: 
            2px 2px 0px #000,
            -1px -1px 0px #000,
            1px -1px 0px #000,
            -1px 1px 0px #000,
            0 0 12px rgba(139, 0, 0, 1),
            0 0 25px rgba(220, 20, 60, 0.8),
            0 0 35px rgba(255, 0, 0, 0.4);
    }
}

.list-controls {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-bottom: 25px;
    position: relative;
}

.btn {
    background: rgba(139, 69, 19, 0.8);
    color: #f4f4f4;
    border: 2px solid #654321;
    padding: 8px 16px;
    border-radius: 0;
    cursor: pointer;
    font-family: "華文行楷", "STXingkai", cursive;
    font-size: 0.9rem;
    font-weight: bold;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.8);
    box-shadow: 
        inset 0 1px 0 rgba(255, 255, 255, 0.2),
        0 2px 4px rgba(0, 0, 0, 0.3);
    transition: all 0.3s;
    letter-spacing: 1px;
}

.btn:hover {
    background: rgba(160, 82, 45, 0.9);
    border-color: #8b4513;
    transform: translateY(-1px);
    box-shadow: 
        inset 0 1px 0 rgba(255, 255, 255, 0.3),
        0 4px 8px rgba(0, 0, 0, 0.4);
}

.list-hint {
    color: #666;
    margin-bottom: 10px;
    font-size: 0.9rem;
}

.items-textarea {
    width: 100%;
    min-height: 420px;
    padding: 15px;
    border: none;
    border-radius: 8px;
    font-size: 1.5rem;
    font-family: "Ma Shan Zheng", "Noto Serif TC", "華文行楷", "STXingkai", cursive;
    font-weight: 600;
    color: #4a2c1a;
    resize: vertical;
    background: transparent;
    transition: border-color 0.3s;
    line-height: 1.2;
    letter-spacing: 1px;
    text-shadow: 0.5px 0.5px 1px rgba(0, 0, 0, 0.3);
    scrollbar-color: #8b4513 transparent;
    scrollbar-width: thin;
    resize: none;
}

.items-textarea:focus {
    outline: none;
}

.items-textarea::placeholder {
    color: rgba(139, 69, 19, 0.6);
    font-style: italic;
    font-weight: 400;
}

.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 1000;
    justify-content: center;
    align-items: center;
}

.modal.show {
    display: flex;
}

.modal-content {
    background: white;
    padding: 40px;
    border-radius: 20px;
    text-align: center;
    animation: slideIn 0.3s ease;
}

.modal-content h2 {
    color: #667eea;
    margin-bottom: 20px;
    font-size: 2rem;
}

.modal-content p {
    font-size: 1.5rem;
    color: #333;
    margin-bottom: 30px;
}

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

@media (max-width: 768px) {
    .game-container {
        grid-template-columns: 1fr;
    }
    
    .wheel-container {
        width: 300px;
        height: 300px;
    }
    
    #wheel {
        width: 300px;
        height: 300px;
    }
}