/* Countdown Timer Styles */
.wc-qsm-countdown-timer {
    background: linear-gradient(135deg, #1a73e8 0%, #4285f4 100%);
    color: #fff;
    padding: 30px;
    border-radius: 16px;
    margin: 25px 0;
    text-align: center;
    box-shadow: 0 8px 24px rgba(26, 115, 232, 0.25);
    position: relative;
    overflow: hidden;
}

.wc-qsm-countdown-timer::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255,255,255,0.1) 0%, transparent 70%);
    animation: pulse 15s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% { transform: scale(1); opacity: 0.5; }
    50% { transform: scale(1.1); opacity: 0.8; }
}

.wc-qsm-countdown-label {
    font-size: 20px;
    font-weight: 700;
    margin-bottom: 20px;
    text-transform: uppercase;
    letter-spacing: 2px;
    text-shadow: 0 2px 4px rgba(0,0,0,0.2);
    position: relative;
    z-index: 1;
}

.wc-qsm-countdown-display {
    display: flex;
    justify-content: center;
    gap: 20px;
    flex-wrap: wrap;
    position: relative;
    z-index: 1;
    margin-bottom: 20px;
}

.wc-qsm-countdown-unit {
    display: flex;
    flex-direction: column;
    align-items: center;
    min-width: 85px;
}

.wc-qsm-countdown-value {
    background: rgba(255, 255, 255, 0.95);
    color: #1a73e8;
    padding: 16px 20px;
    border-radius: 12px;
    font-size: 36px;
    font-weight: 800;
    min-width: 85px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    margin-bottom: 8px;
    transition: all 0.3s ease;
    line-height: 1;
}

.wc-qsm-countdown-value:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 20px rgba(0,0,0,0.25);
}

.wc-qsm-countdown-label-small {
    font-size: 13px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    opacity: 0.9;
}

.wc-qsm-countdown-expired {
    font-size: 20px;
    font-weight: bold;
    color: #fff;
    padding: 20px;
    background: rgba(231, 76, 60, 0.9);
    border-radius: 12px;
    box-shadow: 0 4px 12px rgba(231, 76, 60, 0.3);
}

.wc-qsm-participants-info {
    font-size: 15px;
    text-align: center;
    background: rgba(255, 255, 255, 0.15);
    padding: 18px;
    border-radius: 12px;
    margin-top: 20px;
    backdrop-filter: blur(10px);
    position: relative;
    z-index: 1;
}

.wc-qsm-participants-count,
.wc-qsm-remaining-entries {
    margin: 6px 0;
    font-size: 16px;
}

.wc-qsm-participants-countdown {
    position: relative;
    display: grid;
    gap: 24px;
    align-items: center;
    margin: 18px 0;
    padding: 28px;
    background: #ffffff;
    border: 1px solid #e3e6ee;
    border-radius: 30px;
    box-shadow: 0 24px 44px rgba(15, 23, 42, 0.08);
    overflow: hidden;
}

.wc-qsm-participants-countdown > * {
    position: relative;
    z-index: 1;
}

.wc-qsm-participants-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding-bottom: 18px;
    border-bottom: 1px solid #e7eaf0;
}

.wc-qsm-participants-title {
    font-size: 24px;
    font-weight: 700;
    color: #1f2a3a;
    letter-spacing: -0.3px;
}

.wc-qsm-participants-subtitle {
    font-size: 14px;
    color: #7c879a;
    margin-top: 4px;
}

.wc-qsm-participants-pill {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1.2px;
    padding: 6px 12px;
    border-radius: 999px;
    background: #e9f0ff;
    color: #3875f1;
    border: 1px solid #cfd8ee;
    box-shadow: 0 3px 8px rgba(56, 117, 241, 0.16);
}

.wc-qsm-participants-pill::before {
    content: '';
    width: 8px;
    height: 8px;
    border-radius: 999px;
    background: #3875f1;
    box-shadow: 0 0 0 3px rgba(56, 117, 241, 0.2);
}

.wc-qsm-participants-body {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 24px;
    align-items: start;
}

@media (min-width: 860px) {
    .wc-qsm-participants-body {
        grid-template-columns: 230px 1fr;
    }
}

.wc-qsm-countdown-ring {
    position: relative;
    width: 220px;
    margin: 0 auto;
}

.wc-qsm-countdown-ring svg {
    transform: rotate(-90deg);
    width: 220px;
    height: 220px;
}

.wc-qsm-ring-background,
.wc-qsm-ring-progress {
    fill: none;
    stroke-width: 10;
    stroke-linecap: round;
    stroke-dasharray: 339.292;
    stroke-dashoffset: 339.292;
    transition: stroke-dashoffset 1s ease;
}

.wc-qsm-ring-background {
    stroke: #dfe6f2;
    stroke-dasharray: none;
    stroke-dashoffset: 0;
}

.wc-qsm-ring-progress {
    stroke: var(--wc-qsm-accent, #3875f1);
    filter: none;
}

.wc-qsm-ring-center {
    position: absolute;
    inset: 24px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: #1f2a3a;
    background: #ffffff;
    border-radius: 50%;
    box-shadow: none;
    border: none;
}

.wc-qsm-ring-number {
    font-size: 32px;
    font-weight: 800;
    color: #1f2a3a;
    line-height: 1.1;
    letter-spacing: -0.5px;
    white-space: nowrap;
    margin-top: 0;
}

.wc-qsm-ring-caption {
    font-size: 14px;
    color: #7c879a;
    margin-top: 4px;
}

.wc-qsm-ring-subtext {
    font-size: 11px;
    color: #9aa6b2;
    margin-top: 6px;
}

.wc-qsm-countdown-metrics {
    display: grid;
    grid-template-columns: 1fr;
    gap: 18px;
}

.wc-qsm-countdown-card {
    position: relative;
    padding: 18px 20px;
    border-radius: 16px;
    background: #ffffff;
    border: 1px solid #e1e5ee;
    box-shadow: 0 10px 20px rgba(15, 23, 42, 0.06);
    text-align: center;
}

.wc-qsm-card-label {
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 1.4px;
    color: #7c879a;
    margin-bottom: 10px;
    font-weight: 600;
}

.wc-qsm-card-number {
    font-size: 26px;
    font-weight: 800;
    color: #1f2a3a;
    letter-spacing: -0.4px;
}

.wc-qsm-card-remaining {
    border-color: #e1e5ee;
    box-shadow: 0 10px 20px rgba(15, 23, 42, 0.06);
}

.wc-qsm-participants-progress {
    display: grid;
    gap: 10px;
    padding: 18px 20px;
    border-radius: 16px;
    background: #ffffff;
    border: 1px solid #e1e5ee;
    box-shadow: 0 10px 20px rgba(15, 23, 42, 0.06);
}

.wc-qsm-progress-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 1.4px;
    color: #7c879a;
    font-weight: 600;
}

.wc-qsm-progress-value {
    color: #1f2a3a;
    font-weight: 800;
    text-transform: none;
    letter-spacing: 0;
    font-size: 14px;
}

.wc-qsm-progress-bar {
    height: 10px;
    background: #e6ebf4;
    border-radius: 999px;
    overflow: hidden;
}

.wc-qsm-progress-bar span {
    display: block;
    height: 100%;
    background: var(--wc-qsm-accent, #3875f1);
    width: 0;
    transition: width 0.6s ease;
    box-shadow: none;
}

.wc-qsm-progress-meta {
    font-size: 12px;
    color: #7c879a;
    font-weight: 500;
}

.wc-qsm-participants-count strong,
.wc-qsm-remaining-entries strong {
    font-weight: 700;
    margin-right: 8px;
    font-size: 17px;
}

/* Custom Text on Quiz Page */
.wc-qsm-custom-text {
    background: #f8f9fa;
    border-left: 4px solid #3875f1;
    padding: 20px;
    margin: 20px 0;
    border-radius: 4px;
}

.wc-qsm-custom-text h1,
.wc-qsm-custom-text h2,
.wc-qsm-custom-text h3 {
    margin-top: 0;
    color: #3875f1;
}

/* Access Denied Messages */
body.error404,
body.error403 {
    background: #f5f5f5;
}

body.error404 h1,
body.error403 h1 {
    color: #dc3232;
    font-size: 28px;
    margin-bottom: 20px;
}

body.error404 p,
body.error403 p {
    font-size: 16px;
    line-height: 1.6;
    color: #333;
    margin-bottom: 15px;
}

/* Responsive */
@media (max-width: 768px) {
    .wc-qsm-countdown-timer {
        padding: 20px;
    }

    .wc-qsm-countdown-label {
        font-size: 16px;
        margin-bottom: 15px;
    }

    .wc-qsm-countdown-display {
        gap: 12px;
    }

    .wc-qsm-countdown-unit {
        min-width: 70px;
    }

    .wc-qsm-countdown-value {
        font-size: 28px;
        padding: 12px 16px;
        min-width: 70px;
    }

    .wc-qsm-countdown-label-small {
        font-size: 11px;
    }

    .wc-qsm-participants-info {
        font-size: 14px;
        padding: 15px;
    }

    .wc-qsm-modal-content {
        padding: 25px 20px;
        width: 95%;
    }

    .wc-qsm-modal-content h2 {
        font-size: 20px;
    }

    .wc-qsm-modal-buttons {
        flex-direction: column;
        gap: 10px;
    }

    .wc-qsm-modal-buttons button {
        width: 100%;
    }

    .wc-qsm-participants-countdown {
        padding: 22px;
    }

    .wc-qsm-participants-header {
        flex-direction: column;
        align-items: flex-start;
    }

    .wc-qsm-participants-body {
        grid-template-columns: 1fr;
    }

    .wc-qsm-countdown-ring {
        width: 200px;
    }

    .wc-qsm-countdown-ring svg {
        width: 200px;
        height: 200px;
    }

    .wc-qsm-countdown-metrics {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    .wc-qsm-countdown-display {
        gap: 8px;
    }

    .wc-qsm-countdown-unit {
        min-width: 60px;
    }

    .wc-qsm-participants-title {
        font-size: 17px;
    }

    .wc-qsm-countdown-ring {
        width: 180px;
    }

    .wc-qsm-countdown-ring svg {
        width: 180px;
        height: 180px;
    }

    .wc-qsm-countdown-value {
        font-size: 24px;
        padding: 10px 12px;
        min-width: 60px;
    }
}
