/* Общие стили для всех страниц */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Arial', sans-serif;
}

body {
    background: linear-gradient(135deg, #0f0c29 0%, #302b63 50%, #24243e 100%);
    color: #fff;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 20px;
    overflow-x: hidden;
    position: relative;
    overflow: hidden;
}

body::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background:
            radial-gradient(circle at 20% 80%, rgba(120, 119, 198, 0.3) 0%, transparent 50%),
            radial-gradient(circle at 80% 20%, rgba(255, 119, 198, 0.15) 0%, transparent 50%),
            radial-gradient(circle at 40% 40%, rgba(120, 219, 255, 0.1) 0%, transparent 50%);
    z-index: -1;
}

.container {
    max-width: 1200px;
    width: 100%;
    text-align: center;
    position: relative;
    overflow: hidden;
}

h1 {
    font-size: 4.5rem;
    margin-bottom: 20px;
    text-shadow: 0 0 10px rgba(255, 255, 255, 0.8);
    letter-spacing: 2px;
    color: #ffffff;
    font-weight: 700;
    animation: titleGlow 3s ease-in-out infinite alternate;
}

@keyframes titleGlow {
    0% {
        text-shadow: 0 0 10px rgba(255, 255, 255, 0.8);
    }
    100% {
        text-shadow: 0 0 20px rgba(255, 255, 255, 0.9), 0 0 30px rgba(255, 255, 255, 0.6);
    }
}

.wheel-container {
    position: relative;
    width: 100%;
    max-width: 600px;
    margin: 0 auto 20px;
    overflow: hidden;
}

.wheel {
    width: 100%;
    height: auto;
    transition: transform 5s cubic-bezier(0.17, 0.67, 0.21, 0.99);
    transform-origin: center;
}

.wheel-background {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 80%;
    max-width: 800px;
    height: auto;
    z-index: 5;
    opacity: 1;
    animation: slowSpin 60s linear infinite;
    display: none;
}

@keyframes slowSpin {
    0% {
        transform: translate(-50%, -50%) rotate(0deg);
    }
    100% {
        transform: translate(-50%, -50%) rotate(360deg);
    }
}

.spin-button {
    background: linear-gradient(to bottom, #2ecc71, #27ae60);
    border: none;
    border-radius: 50px;
    color: white;
    font-size: 2rem;
    font-weight: bold;
    padding: 25px 100px;
    cursor: pointer;
    margin-top: 10px;
    transition: all 0.3s ease;
    box-shadow: 0 5px 25px rgba(46, 204, 113, 0.6);
    letter-spacing: 3px;
    text-transform: uppercase;
    position: relative;
    overflow: hidden;
    z-index: 10;
    -webkit-tap-highlight-color: transparent;
    outline: none;
    width: auto;
    min-width: 350px;
}

.spin-button:focus {
    outline: none;
}

.spin-button::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
    transition: left 0.7s;
    z-index: -1;
}

.spin-button:hover {
    transform: scale(1.05);
    box-shadow: 0 7px 30px rgba(46, 204, 113, 0.8);
}

.spin-button:hover::before {
    left: 100%;
}

.spin-button:disabled {
    background: linear-gradient(to bottom, #666, #888);
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

.pointer {
    position: absolute;
    top: -25px;
    left: 50%;
    transform: translateX(-50%);
    width: 50px;
    height: 70px;
    z-index: 10;
}

/* Popup Styles */
.popup-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    padding: 20px;
}

.popup-content {
    background: rgba(255, 255, 255, 0.8); /* 20% transparency */
    backdrop-filter: blur(5px);
    border-radius: 20px;
    padding: 30px;
    max-width: 500px;
    width: 100%;
    color: #333;
    box-shadow: 0 10px 50px rgba(0, 0, 0, 0.3);
    position: relative;
    max-height: 90vh;
    overflow-y: auto;
    z-index: 1001;
}

.popup-header {
    text-align: center;
    margin-bottom: 20px;
}

.popup-title {
    font-size: 1.8rem;
    font-weight: bold;
    color: #2c3e50;
    margin-bottom: 10px;
}

.popup-subtitle {
    font-size: 1.2rem;
    color: #e74c3c;
    font-weight: bold;
}

/* Timer Styles - Desktop Clock Design */
.timer-container {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin: 25px 0;
}

.timer-segment {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.timer-digit-group {
    display: flex;
    gap: 5px;
}

.timer-digit {
    background: linear-gradient(135deg, #3498db, #2980b9);
    color: white;
    font-size: 2.5rem;
    font-weight: bold;
    padding: 15px;
    border-radius: 12px;
    min-width: 60px;
    text-align: center;
    box-shadow: 0 4px 15px rgba(52, 152, 219, 0.3),
    inset 0 1px 0 rgba(255, 255, 255, 0.3),
    inset 0 -4px 8px rgba(0, 0, 0, 0.2);
    position: relative;
    overflow: hidden;
}

.timer-digit::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 50%;
    background: linear-gradient(rgba(255, 255, 255, 0.2), transparent);
    border-radius: 12px 12px 0 0;
}

.timer-label {
    font-size: 0.8rem;
    color: #7f8c8d;
    margin-top: 8px;
    font-weight: bold;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.timer-colon {
    color: #3498db;
    font-size: 2.5rem;
    font-weight: bold;
    align-self: center;
    margin: 0 5px;
}

.phone-form {
    margin: 20px 0;
}

.phone-input-container {
    position: relative;
    width: 100%;
}

.phone-prefix {
    position: absolute;
    left: 15px;
    top: 50%;
    transform: translateY(-50%);
    color: #7f8c8d;
    font-size: 1.1rem;
    font-weight: bold;
    z-index: 2;
}

.phone-input {
    width: 100%;
    padding: 15px 15px 15px 40px;
    border: 2px solid #bdc3c7;
    border-radius: 10px;
    font-size: 1.1rem;
    text-align: left;
    transition: all 0.3s ease;
    background: white;
}

.phone-input:focus {
    outline: none;
    border-color: #3498db;
    box-shadow: 0 0 10px rgba(52, 152, 219, 0.3);
}

.phone-input.valid {
    border-color: #27ae60;
    background-color: #f8fff9;
}

.phone-input.error {
    border-color: #e74c3c;
    background-color: #fff8f8;
}

.phone-hint {
    font-size: 0.8rem;
    color: #7f8c8d;
    margin-top: 5px;
    text-align: left;
}

.terms-text {
    font-size: 0.75rem;
    color: #7f8c8d;
    line-height: 1.4;
    margin: 20px 0;
    text-align: left;
    max-height: 150px;
    overflow-y: auto;
    padding: 10px;
    background: #f8f9fa;
    border-radius: 8px;
    border: 1px solid #e9ecef;
}

/* Checkbox Styles */
.checkbox-group {
    margin: 15px 0;
    text-align: left;
}

.checkbox-item {
    margin: 10px 0;
    display: flex;
    align-items: flex-start;
}

.checkbox-item input[type="checkbox"] {
    margin-right: 10px;
    margin-top: 2px;
    min-width: 18px;
    height: 18px;
    accent-color: #3498db;
}

.checkbox-label {
    font-size: 0.75rem;
    color: #2c3e50;
    line-height: 1.4;
    cursor: pointer;
}

.checkbox-label a {
    color: #3498db;
    text-decoration: none;
}

.checkbox-label a:hover {
    text-decoration: underline;
}

.continue-button {
    background: linear-gradient(to bottom, #3498db, #2980b9);
    border: none;
    border-radius: 50px;
    color: white;
    font-size: 1.2rem;
    font-weight: bold;
    padding: 18px 40px;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 5px 20px rgba(52, 152, 219, 0.4);
    width: 100%;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.continue-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 7px 25px rgba(52, 152, 219, 0.6);
}

.continue-button:active {
    transform: translateY(0);
}

.continue-button:disabled {
    background: linear-gradient(to bottom, #bdc3c7, #95a5a6);
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

/* Insurance Type Popup Styles */
.insurance-type-popup {
    text-align: center;
}

.insurance-buttons {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin: 20px 0;
}

.insurance-button {
    background: linear-gradient(to bottom, #3498db, #2980b9);
    border: none;
    border-radius: 10px;
    color: white;
    font-size: 1.1rem;
    font-weight: bold;
    padding: 16px 20px;
    cursor: pointer;
    transition: all 0.3s ease;
    text-align: center;
    width: 100%;
    box-shadow: 0 4px 15px rgba(52, 152, 219, 0.3);
}

.insurance-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(52, 152, 219, 0.5);
}

/* Question Popup Styles */
.question-popup {
    text-align: center;
}

.question-title {
    font-size: 1.5rem;
    color: #2c3e50;
    margin-bottom: 10px;
    font-weight: bold;
}

.question-subtitle {
    font-size: 0.9rem;
    color: #242929;
    margin-bottom: 30px;
    line-height: 1.4;
    max-width: 90%;
    margin-left: auto;
    margin-right: auto;
}

.question-buttons {
    display: flex;
    gap: 15px;
    justify-content: center;
    margin-bottom: 20px;
}

.question-button {
    flex: 1;
    padding: 15px 25px;
    border: none;
    border-radius: 10px;
    font-size: 1.1rem;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.yes-button {
    background: linear-gradient(to bottom, #2ecc71, #27ae60);
    color: white;
}

.no-button {
    background: linear-gradient(to bottom, #e74c3c, #c0392b);
    color: white;
}

.question-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

.call-now-popup {
    text-align: center;
}

.call-title {
    font-size: 1.4rem;
    color: #2c3e50;
    margin-bottom: 20px;
    font-weight: bold;
}

.call-number {
    font-size: 1.8rem;
    color: #e74c3c;
    font-weight: bold;
    margin: 20px 0;
    background: #f8f9fa;
    padding: 15px;
    border-radius: 10px;
    border: 2px dashed #e74c3c;
}

.call-button {
    background: linear-gradient(to bottom, #2ecc71, #27ae60);
    color: white;
    border: none;
    border-radius: 50px;
    padding: 18px 40px;
    font-size: 1.2rem;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 5px 20px rgba(46, 204, 113, 0.4);
    text-transform: uppercase;
    letter-spacing: 1px;
    width: 100%;
    max-width: 250px;
}

.call-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 7px 25px rgba(46, 204, 113, 0.6);
}

.spin-link {
    display: block;
    margin-top: 15px;
    color: rgba(52, 152, 219, 0.8);
    text-decoration: none;
    font-size: 0.9rem;
    cursor: pointer;
    transition: color 0.3s ease;
}

.spin-link:hover {
    color: rgba(52, 152, 219, 1);
    text-decoration: underline;
}

.hidden {
    display: none;
}

.result-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: none;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, 0.6);
    z-index: 100;
    padding: 20px;
    box-sizing: border-box;
    overflow: auto;
    backdrop-filter: blur(2px);
}

.result-container.show {
    display: flex;
}

.result-content {
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 20px;
    box-sizing: border-box;
}

.prize-image {
    width: 100%;
    height: 100%;
    max-width: 100vw;
    max-height: 100vh;
    object-fit: contain;
    cursor: pointer;
    flex: 1;
}

.try-again-button {
    background: linear-gradient(to bottom, #e74c3c, #c0392b);
    border: none;
    border-radius: 50px;
    color: white;
    font-size: 1.5rem;
    font-weight: bold;
    padding: 20px 60px;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 5px 25px rgba(231, 76, 60, 0.6);
    letter-spacing: 2px;
    text-transform: uppercase;
    width: 100%;
    max-width: 400px;
    -webkit-tap-highlight-color: transparent;
    outline: none;
    margin-top: 20px;
    flex-shrink: 0;
    z-index: 101;
}

.try-again-button:focus {
    outline: none;
}

.try-again-button:hover {
    transform: scale(1.05);
    box-shadow: 0 7px 30px rgba(231, 76, 60, 0.8);
}

.confetti {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 90;
    opacity: 0;
    transition: opacity 0.5s ease;
}

.confetti-piece {
    position: absolute;
    width: 12px;
    height: 20px;
    background: #ffd700;
    top: 0;
    opacity: 0;
}

.confetti-piece:nth-child(odd) {
    background: #ff8c00;
}

.confetti-piece:nth-child(even) {
    width: 15px;
    height: 15px;
    border-radius: 50%;
}

.confetti-piece:nth-child(3n) {
    background: #ff4081;
}

.confetti-piece:nth-child(4n) {
    background: #3f51b5;
}

.confetti-piece:nth-child(5n) {
    background: #4caf50;
}

/* Стили для текста согласия с инлайн-чекбоксами */
.consent-text {
    font-size: 0.7rem;
    color: #7f8c8d;
    line-height: 1.3;
    margin: 20px 0 0 0;
    text-align: left;
    max-height: 200px;
    overflow-y: auto;
    padding: 10px;
    background: #f8f9fa;
    border-radius: 8px;
    border: 1px solid #e9ecef;
}

/* Стили для инлайн-чекбоксов */
.inline-checkbox {
    display: inline-flex;
    align-items: center;
    margin: 0 2px;
    cursor: pointer;
    vertical-align: middle;
}

.inline-checkbox input[type="checkbox"] {
    margin: 0;
    width: 12px;
    height: 12px;
    accent-color: #3498db;
    cursor: pointer;
}

.checkmark {
    display: none;
}

/* Адаптивные стили */
@media (max-width: 768px) {
    h1 {
        font-size: 3.5rem;
    }

    .spin-button {
        font-size: 1.5rem;
        padding: 20px 80px;
        min-width: 300px;
    }

    .popup-content {
        padding: 20px;
        margin: 10px;
    }

    .popup-title {
        font-size: 1.5rem;
    }

    .timer-digit {
        font-size: 2rem;
        padding: 12px;
        min-width: 50px;
    }

    .timer-colon {
        font-size: 2rem;
    }

    .insurance-button {
        font-size: 1rem;
        padding: 14px 15px;
    }

    .question-buttons {
        flex-direction: column;
    }

    .result-container {
        padding: 15px;
    }

    .prize-image {
        max-width: 100vw;
        max-height: calc(100vh - 100px);
    }

    .try-again-button {
        font-size: 1.3rem;
        padding: 18px 50px;
        max-width: 350px;
    }

    .consent-text {
        font-size: 0.65rem;
        max-height: 150px;
    }

    .inline-checkbox input[type="checkbox"] {
        width: 10px;
        height: 10px;
    }
}

@media (max-width: 480px) {
    h1 {
        font-size: 2.5rem;
    }

    .spin-button {
        font-size: 1.3rem;
        padding: 18px 70px;
        min-width: 280px;
    }

    .popup-content {
        padding: 15px;
    }

    .popup-title {
        font-size: 1.3rem;
    }

    .timer-digit {
        font-size: 1.5rem;
        padding: 10px;
        min-width: 40px;
    }

    .timer-colon {
        font-size: 1.5rem;
    }

    .insurance-button {
        font-size: 0.9rem;
        padding: 12px 10px;
    }

    .result-container {
        padding: 10px;
    }

    .prize-image {
        max-height: calc(100vh - 90px);
    }

    .try-again-button {
        font-size: 1.1rem;
        padding: 16px 40px;
        max-width: 300px;
    }
}

@media (max-width: 360px) {
    h1 {
        font-size: 2rem;
    }

    .spin-button {
        font-size: 1.1rem;
        padding: 15px 50px;
        min-width: 250px;
    }

    .timer-digit {
        font-size: 1.2rem;
        padding: 8px;
        min-width: 35px;
    }

    .insurance-button {
        font-size: 0.8rem;
        padding: 10px 8px;
    }

    .result-container {
        padding: 5px;
    }

    .prize-image {
        max-height: calc(100vh - 80px);
    }

    .try-again-button {
        font-size: 1rem;
        padding: 14px 35px;
        max-width: 250px;
    }
}

@media (max-height: 600px) and (orientation: landscape) {
    .result-content {
        flex-direction: row;
        justify-content: space-between;
        padding: 10px;
    }

    .prize-image {
        max-width: 70vw;
        max-height: 90vh;
        flex: 0 1 auto;
    }

    .try-again-button {
        margin-top: 0;
        margin-left: 20px;
        max-width: 200px;
        height: fit-content;
    }
}
/* V3 related */
.call-subtitle {
    font-size: 1.1rem;
    color: #2c3e50;
    margin-bottom: 20px;
    text-align: center;
    line-height: 1.4;
}

.question-popup .continue-button {
    background: linear-gradient(to bottom, #2ecc71, #27ae60);
    color: white;
    border: none;
    border-radius: 50px;
    padding: 18px 40px;
    font-size: 1.2rem;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 5px 20px rgba(46, 204, 113, 0.4);
    text-transform: uppercase;
    letter-spacing: 1px;
    width: 100%;
    max-width: 250px;
    margin: 0 auto;
}

.question-popup .continue-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 7px 25px rgba(46, 204, 113, 0.6);
}

@media (max-width: 768px) {
    .call-subtitle {
        font-size: 1rem;
    }

    .question-popup .continue-button {
        font-size: 1.1rem;
        padding: 16px 30px;
        max-width: 220px;
    }
}

@media (max-width: 480px) {
    .call-subtitle {
        font-size: 0.9rem;
    }

    .question-popup .continue-button {
        font-size: 1rem;
        padding: 14px 25px;
        max-width: 200px;
    }
}



/*v5*/

.result-container.show {
    display: flex !important;
    z-index: 10000 !important;
}

.prize-image {
    cursor: pointer !important;
    pointer-events: auto !important;
}

.result-content {
    pointer-events: auto !important;
}

/* ЕБАНЫЕ СТИЛИ КОТОРЫЕ РАБОТАЮТ */
body.spin-wheel-page .container {
    max-width: 1200px;
    width: 100%;
    text-align: center;
    position: relative;
    overflow: visible;
    padding: 20px 20px 40px;
    min-height: auto;
}

body.spin-wheel-page h1 {
    font-size: 3rem;
    margin-bottom: 20px;
}

body.spin-wheel-page .wheel-container {
    position: relative;
    width: 100%;
    max-width: 500px;
    margin: 0 auto 20px;
}

body.spin-wheel-page .spin-button {
    position: relative;
    margin-top: 20px;
    transform: none !important;
}

@media (max-width: 768px) {
    body.spin-wheel-page .container {
        padding: 15px 15px 30px;
    }

    body.spin-wheel-page h1 {
        font-size: 2.5rem;
        margin-bottom: 15px;
    }

    body.spin-wheel-page .wheel-container {
        max-width: 400px;
        margin-bottom: 15px;
    }
}

@media (max-width: 480px) {
    body.spin-wheel-page .container {
        padding: 10px 10px 25px;
    }

    body.spin-wheel-page h1 {
        font-size: 2rem;
    }

    body.spin-wheel-page .wheel-container {
        max-width: 320px;
    }

    body.spin-wheel-page .spin-button {
        min-width: 280px;
        padding: 18px 60px;
    }
}