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

body {
    margin: 0;
    padding: 0;
    overflow: hidden;
    font-family: 'Roboto', sans-serif;
    background-color: #ffffff;
    /* background-color: #f5f5f5; */
    color: #333;
    line-height: 1.6;
    display: flex;
}

.container {
    max-width: 100%;
    margin: 0 auto;
    padding-left: 16px;
    padding-right: 16px;
    padding-top: 20px;
}

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

header h1 {
    font-size: 2.5rem;
    color: #2c3e50;
    margin-bottom: 0.5rem;
}

header p {
    color: #7f8c8d;
    font-size: 1.1rem;
}

main {
    display: flex;
    flex-direction: row;
    align-items: flex-start;
    gap: 2rem;
    justify-content: center;
    padding-top: 55px;
}

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

#wheelCanvas {
    width: 100%;
    height: 100%;
    position: absolute;
    top: 0;
    left: 0;
}

.wheel-pointer {
    position: absolute;
    top: 50%;
    left: 93%;
    transform: translateY(-50%);
    width: 0;
    height: 0;
    border-top: 20px solid transparent;
    border-bottom: 20px solid transparent;
    border-right: 39px solid #beb9b9;
    z-index: 2;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.2));
    animation: pointerGlow 2s infinite;
}

.wheel-pointer::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 100px;
    height: 100px;
    background: radial-gradient(circle, rgba(231,76,60,0.2) 0%, rgba(231,76,60,0) 70%);
    border-radius: 50%;
    animation: magicPulse 2s infinite;
    z-index: -1;
}

.wheel-pointer::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 150px;
    height: 150px;
    background: radial-gradient(circle, rgba(231,76,60,0.1) 0%, rgba(231,76,60,0) 70%);
    border-radius: 50%;
    animation: magicPulse 2s infinite 0.5s;
    z-index: -2;
}

@keyframes pointerGlow {
    0%, 100% {
        filter: drop-shadow(0 0 5px rgba(231,76,60,0.5));
    }
    50% {
        filter: drop-shadow(0 0 20px rgba(231,76,60,0.8));
    }
}

@keyframes magicPulse {
    0% {
        transform: translate(-50%, -50%) scale(0.8);
        opacity: 0.5;
    }
    50% {
        transform: translate(-50%, -50%) scale(1.2);
        opacity: 0.2;
    }
    100% {
        transform: translate(-50%, -50%) scale(0.8);
        opacity: 0.5;
    }
}

.wheel-center {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 1;
}

#spinButton {
    background-color: #ffffff;
    color: #5e20ac;
    border: none;
    padding: 1rem 2rem;
    font-size: 18px;
    border-radius: 50%;
    cursor: pointer;
    transition: transform 0.2s, background-color 0.2s;
    width: 130px;
    height: 130px;
    align-items: center;
    justify-content: center;
}

#spinButton:hover {
    background-color: #e9dcdb;
    transform: scale(1.05);
}

.controls {
    /* width: 50%;
    max-width: 340px; */
    background: #eae2e2;
    padding: 2rem;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.input-section {
    margin-bottom: 2rem;
    width: 335px;
}

#nameInput {
    width: 100%;
    height: 380px;
    padding: 1rem;
    border: 2px solid #ddd;
    border-radius: 5px;
    margin-bottom: 1rem;
    resize: vertical;
    font-family: inherit;
    font-size: 17px;
    line-height: 23px;
}

.button-group {
    display: flex;
    gap: 1rem;
}

button {
    padding: 0.8rem 1.5rem;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 1rem;
    transition: background-color 0.2s;
}

#addButton {
    background-color: #2ecc71;
    color: white;
}

#addButton:hover {
    background-color: #27ae60;
}

#clearButton {
    background-color: #95a5a6;
    color: white;
}

#clearButton:hover {
    background-color: #7f8c8d;
}

.settings {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
}

.setting-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.setting-group label {
    font-weight: 500;
    color: #2c3e50;
}

.setting-group input {
    padding: 0.5rem;
    border: 1px solid #ddd;
    border-radius: 5px;
}

/* footer {
    text-align: center;
    margin-top: 2rem;
    color: #7f8c8d;
} */

@media (max-width: 1200px) {
    main {
        flex-direction: column;
        align-items: center;
    }

    .wheel-container {
        width: 600px;
        height: 600px;
    }

    .controls {
        max-width: 600px;
    }
}

@media (max-width: 768px) {
    .wheel-container {
        width: 380px;
        height: 380px;
    }

    .container {
        padding: 1rem;
    }

    .controls {
        padding: 1rem;
        min-width: 328px;
    }

    .settings {
        grid-template-columns: 1fr;
    }

    .wheel-pointer {
        position: absolute;
        top: 50%;
        left: 91%;
        transform: translateY(-50%);
        width: 0;
        height: 0;
        border-top: 14px solid transparent;
        border-bottom: 14px solid transparent;
        border-right: 26px solid #bdb7b7;
        z-index: 2;
        filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.2));
        animation: pointerGlow 2s infinite;
    }
    
    .wheel-pointer::before {
        content: '';
        position: absolute;
        top: 50%;
        left: 50%;
        transform: translate(-50%, -50%);
        width: 100px;
        height: 100px;
        background: radial-gradient(circle, rgba(231,76,60,0.2) 0%, rgba(231,76,60,0) 70%);
        border-radius: 50%;
        animation: magicPulse 2s infinite;
        z-index: -1;
    }
    
    .wheel-pointer::after {
        content: '';
        position: absolute;
        top: 50%;
        left: 50%;
        transform: translate(-50%, -50%);
        width: 150px;
        height: 150px;
        background: radial-gradient(circle, rgba(231,76,60,0.1) 0%, rgba(231,76,60,0) 70%);
        border-radius: 50%;
        animation: magicPulse 2s infinite 0.5s;
        z-index: -2;
    }

    #spinButton {
        background-color: #ffffff;
        color: #5e20ac;
        border: none;
        padding: 1rem 2rem;
        font-size: 18px;
        border-radius: 50%;
        cursor: pointer;
        transition: transform 0.2s, background-color 0.2s;
        width: 100px;
        height: 100px;
        align-items: center;
        justify-content: center;
    }
}

.winner-announcement {
    position: fixed;
    top: 40%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: #fffffff0;
    padding: 1rem;
    border-radius: 16px;
    box-shadow: 5px 7px 17px 3px rgb(70 229 193 / 76%);
    text-align: center;
    z-index: 1000;
    width: 350px;
    height: 300px;
    display: none;
}

.winner-announcement h2 {
    color: #2c3e50;
    margin-bottom: 1rem;
}

.winner-announcement p {
    font-size: 1.5rem;
    color: #e74c3c;
    margin-bottom: 1.5rem;
}

.winner-announcement button {
    background-color: #e74c3c;
    color: white;
    padding: 0.8rem 1.5rem;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 1rem;
    transition: background-color 0.2s;
    margin: 7px;
}

.winner-announcement button:hover {
    background-color: #c0392b;
}

.overlay1 {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 999;
    display: none;
}

/* .confetti {
    position: absolute;
    width: 10px;
    height: 10px;
    background: #FFD700;
    border-radius: 50%;
    animation: confetti-fall 10s linear infinite;
} */

/* @keyframes confetti-fall {
    0% {
        transform: translateY(-100vh) rotate(0deg);
        opacity: 0;
    }
    10% {
        transform: translateY(0) rotate(45deg);
        opacity: 1;
    }
    90% {
        transform: translateY(100vh) rotate(90deg);
        opacity: 1;
    }
    100% {
        transform: translateY(100vh) rotate(180deg);
        opacity: 0;
    }
} */

.celebration-overlay1 {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.4);
    z-index: 998;
    display: none;
    justify-content: center;
    align-items: center;
    flex-direction: column;
    overflow: hidden;
    padding-top: 150px;
    padding-left: 20px;
    padding-right: 20px;
}

.celebration-content {
    text-align: center;
    color: white;
    z-index: 1000;
    background: rgba(0, 0, 0, 0.3);
    padding: 2rem;
    border-radius: 20px;
    width: 90%;
    max-width: 600px;
    box-sizing: border-box;
}

.celebration-content h1 {
    font-size: clamp(2rem, 5vw, 4rem);
    margin-bottom: 1.5rem;
    color: #FFD700;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
    line-height: 1.2;
}

.celebration-content p {
    font-size: clamp(1.5rem, 4vw, 2.5rem);
    color: #FFD700;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
    font-weight: bold;
    line-height: 1.3;
    word-wrap: break-word;
}

@media (max-width: 768px) {
    .celebration-content {
        padding: 1.5rem;
    }
    
    .celebration-content h1 {
        margin-bottom: 1rem;
    }
    
    .celebration-content p {
        margin-bottom: 0.5rem;
    }
}

@media (max-width: 480px) {
    .celebration-content {
        padding: 1rem;
    }
    
    .celebration-content h1 {
        font-size: 2rem;
    }
    
    .celebration-content p {
        font-size: 1.5rem;
    }
}

.color-picker {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-top: -30px;
}

.color-box {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    cursor: pointer;
    border: 2px solid transparent;
    transition: all 0.3s ease;
}

.color-box:hover {
    transform: scale(1.1);
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.2);
}

.color-box.active {
    border-color: #333;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.3);
} 


/* Updated Popup Styles */
.popup-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(5px);
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    z-index: 1000;
}

.popup-overlay.active {
    opacity: 1;
    visibility: visible;
}

.popup-content {
    background: white;
    padding: 30px;
    border-radius: 16px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
    width: 90%;
    max-width: 500px;
    transform: translateY(20px);
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.popup-overlay.active .popup-content {
    transform: translateY(0);
}

.popup-title {
    margin: 0 0 20px 0;
    font-size: 22px;
    font-weight: 600;
    color: #2c3e50;
}

.popup-message {
    margin-bottom: 25px;
    color: #7f8c8d;
    line-height: 1.5;
}

/* Modern Settings Group Styling */
.settings {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.setting-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.setting-group label {
    font-size: 14px;
    font-weight: 500;
    color: #34495e;
}

/* Sophisticated Select Dropdown */
.setting-group select {
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    width: 100%;
    padding: 12px 15px;
    font-size: 14px;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    background-color: #f9f9f9;
    background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%237f8c8d' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6 9 12 15 18 9'%3e%3c/polyline%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right 12px center;
    background-size: 16px;
    transition: all 0.3s ease;
    cursor: pointer;
    color: #2c3e50;
}

.setting-group select:focus {
    outline: none;
    border-color: #3498db;
    box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.2);
    background-color: white;
}

/* Modern Number Input */
.setting-group input[type="number"] {
    width: 100%;
    padding: 12px 15px;
    font-size: 14px;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    background-color: #f9f9f9;
    transition: all 0.3s ease;
    color: #2c3e50;
}

.setting-group input[type="number"]:focus {
    outline: none;
    border-color: #3498db;
    box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.2);
    background-color: white;
}

/* Button Styles */
.popup-buttons {
    display: flex;
    justify-content: flex-end;
    gap: 12px;
    margin-top: 25px;
}

.popup-btn {
    padding: 10px 20px;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
}

.popup-btn.cancel {
    background-color: #f5f7fa;
    color: #7f8c8d;
}

.popup-btn.cancel:hover {
    background-color: #eaeef2;
}

.popup-btn.ok {
    background-color: #3498db;
    color: white;
}

.popup-btn.ok:hover {
    background-color: #2980b9;
}

.margin-section {
    height: 55px;
}

.container-single-page {
    max-width: 95%;
    margin: 0 auto;
    /* padding-left: 16px;
    padding-right: 16px; */
    padding-top: 20px;
    text-align: justify;
}

.post-excerpts p {
    color: #333;
    font-size: 17px;
    line-height: 1.5;
    margin-bottom: 18px;
}

/* footer {
    background-color: #f8f9fa;
    padding: 1rem;
    border-top: 1px solid #e9ecef;
    font-size: 0.9rem;
}

.footer-content {
    flex-direction: column;
    text-align: center;
}

.footer-links {
    flex-wrap: wrap;
    justify-content: center;
}

.footer-links a {
    color: #495057;
    text-decoration: none;
    transition: color 0.2s;
    white-space: nowrap;
}

.footer-links a:hover {
    color: #007bff;
}

.copyright {
    color: #6c757d;
    white-space: nowrap;
}

@media (max-width: 768px) {
    .footer-content {
        flex-direction: column;
        text-align: center;
    }
    
    .footer-links {
        flex-wrap: wrap;
        justify-content: center;
    }
} */

/* FOOTER STYLES */
footer {
    background: #e4e4e454;
    color: #ecf0f1;
    padding: 1.2rem 0;
    margin-top: auto;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
}

.footer-links {
    display: flex;
    list-style: none;
    gap: 1.8rem;
    flex-wrap: wrap;
}

.footer-links a {
    color: #050505;
    text-decoration: none;
    transition: color 0.3s;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.footer-links a:hover {
    color: #3498db;
}

.footer-links a i {
    font-size: 0.9rem;
}

.copyright {
    color: #bdc3c7;
    font-size: 0.95rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.copyright i {
    color: #e74c3c;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    /* .header-content {
        flex-direction: column;
        gap: 1rem;
    } */
    
    .footer-content {
        flex-direction: column;
        text-align: center;
    }
    
    .footer-links {
        justify-content: center;
    }
}

@media (max-width: 480px) {
    .footer-links {
        /* flex-direction: column; */
        gap: 0.8rem;
    }
    
    /* .hero h1 {
        font-size: 2.2rem;
    } */
}