:root {
    --bg-color: #1a1a2e;
    --text-color: #ffffff;
    --accent-color: #e94560;
    --secondary-color: #16213e;
    --wheel-border: #ffffff;
    --modal-bg: #ffffff;
    --modal-text: #333333;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    -webkit-tap-highlight-color: transparent;
}

body {
    font-family: 'Outfit', sans-serif;
    background-color: var(--bg-color);
    color: var(--text-color);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    overflow-x: hidden;
}

.app-container {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 2rem 1rem;
    max-width: 600px;
    margin: 0 auto;
    width: 100%;
}

header {
    text-align: center;
    margin-bottom: 2rem;
}

.header-logo {
    width: 100%;
    max-width: 400px;
    height: auto;
    margin-bottom: 1rem;
}

header h1 {
    font-size: 2.5rem;
    font-weight: 900;
    margin-bottom: 0.5rem;
    background: linear-gradient(45deg, #FF6B6B, #4ECDC4);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    text-transform: uppercase;
    letter-spacing: 1px;
}

header p {
    opacity: 0.8;
    font-size: 1rem;
}

.wheel-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
    gap: 2rem;
}

.wheel-wrapper {
    position: relative;
    width: 90%;
    max-width: 400px;
    aspect-ratio: 1;
    filter: drop-shadow(0 10px 20px rgba(0, 0, 0, 0.5));
}

#wheelCanvas {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    border: 4px solid var(--wheel-border);
    transition: transform 4s cubic-bezier(0.17, 0.67, 0.12, 0.99);
    /* Default spin transition */
}

.wheel-pointer {
    position: absolute;
    top: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 0;
    border-left: 15px solid transparent;
    border-right: 15px solid transparent;
    border-top: 30px solid var(--accent-color);
    z-index: 10;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.3));
}

.wheel-center {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 40px;
    height: 40px;
    background: var(--wheel-border);
    border-radius: 50%;
    z-index: 5;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.2);
}

.spin-button {
    background: linear-gradient(45deg, var(--accent-color), #ff2e63);
    color: white;
    border: none;
    padding: 1rem 3rem;
    font-size: 1.5rem;
    font-weight: 900;
    border-radius: 50px;
    cursor: pointer;
    box-shadow: 0 4px 15px rgba(233, 69, 96, 0.4);
    transition: transform 0.2s, box-shadow 0.2s;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.spin-button:active {
    transform: scale(0.95);
}

.spin-button:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
}

/* Modal Styles */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 100;
    opacity: 1;
    transition: opacity 0.3s;
    padding: 1rem;
}

.modal.hidden {
    opacity: 0;
    pointer-events: none;
}

.modal-content {
    background: var(--modal-bg);
    color: var(--modal-text);
    padding: 2rem;
    border-radius: 20px;
    width: 100%;
    max-width: 400px;
    text-align: center;
    position: relative;
    transform: translateY(0);
    transition: transform 0.3s;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.modal.hidden .modal-content {
    transform: translateY(20px);
}

.prize-display {
    font-size: 2rem;
    font-weight: 900;
    color: var(--accent-color);
    margin: 1rem 0 2rem;
    padding: 1rem;
    background: #f5f5f5;
    border-radius: 10px;
    border: 2px dashed var(--accent-color);
}

.form-group {
    margin-bottom: 1.5rem;
    text-align: left;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 700;
    font-size: 0.9rem;
    color: #666;
}

.form-group input {
    width: 100%;
    padding: 1rem;
    border: 2px solid #ddd;
    border-radius: 10px;
    font-size: 1rem;
    font-family: inherit;
    transition: border-color 0.3s;
}

.form-group input:focus {
    border-color: var(--accent-color);
    outline: none;
}

footer {
    margin-top: 2rem;
    text-align: center;
}

footer a {
    font-size: 0.85rem;
    color: rgba(255, 255, 255, 0.6);
    text-decoration: none;
}

footer a:hover {
    text-decoration: underline;
}

.claim-button {
    width: 100%;
    background: var(--secondary-color);
    color: white;
    border: none;
    padding: 1rem;
    font-size: 1.1rem;
    font-weight: 700;
    border-radius: 10px;
    cursor: pointer;
    transition: background 0.3s;
}

.success-icon {
    font-size: 4rem;
    margin-top: 20px;
    animation: bounce 1s infinite;
}

@keyframes bounce {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-10px);
    }
}

.claim-button:hover {
    background: #2a3b55;
}

/* Confetti placeholder */
.confetti-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    overflow: hidden;
    border-radius: 20px;
}

.code-display {
    font-size: 2rem;
    font-weight: 900;
    color: var(--accent-color);
    margin: 0.5rem 0 1rem;
    padding: 1rem;
    background: #f5f5f5;
    border-radius: 10px;
    border: 2px dashed var(--accent-color);
    letter-spacing: 2px;
}

.instagram-link {
    display: inline-block;
    margin-top: 1rem;
    padding: 0.75rem 1.5rem;
    background: linear-gradient(45deg, #f09433, #e6683c, #dc2743, #cc2366, #bc1888);
    color: white;
    text-decoration: none;
    font-weight: 700;
    border-radius: 10px;
    transition: transform 0.2s, box-shadow 0.2s;
}

.instagram-link:hover {
    transform: scale(1.05);
    box-shadow: 0 4px 15px rgba(188, 24, 136, 0.4);
}

.instagram-handle {
    font-weight: 700;
    color: #c13584;
    margin-top: 0.25rem;
}