/**
 * Concurrent Curieux Page Styles
 * Template: concurrent-curieux.php
 * Following SafeSanté Theme Design System
 */

/* Screen Reader Only - Visually hidden but accessible to SEO and screen readers */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* ==========================================================================
   0. Header Styles (Same as appointment-partner)
   ========================================================================== */
.ac-page-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    padding: 20px 40px;
    z-index: 1000;
    background: rgba(32, 43, 109, 0.95);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.2);
}

.ac-header-container {
    max-width: 1400px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.ac-logo {
    display: flex;
    align-items: center;
    text-decoration: none;
}

.ac-logo img {
    height: 40px;
    width: auto;
}

.ac-header-buttons {
    display: flex;
    gap: 30px;
}

.ac-btn-link {
    font-family: 'DM Sans', sans-serif;
    font-size: 18px;
    font-weight: 500;
    color: #ffffff;
    text-decoration: none;
    transition: color 0.3s ease;
}

.ac-btn-link:hover {
    color: #A7DBEE;
}

.ac-mobile-toggle {
    display: none;
    background: none;
    border: none;
    color: #ffffff;
    font-size: 24px;
    cursor: pointer;
    padding: 10px;
}

@media (max-width: 768px) {
    .ac-page-header {
        padding: 15px 20px;
    }

    .ac-logo img {
        height: 32px;
    }

    .ac-mobile-toggle {
        display: block;
    }

    .ac-header-buttons {
        display: none;
    }

    .ac-header-buttons.active {
        display: flex;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        flex-direction: column;
        background: rgba(32, 43, 109, 0.98);
        padding: 20px;
        gap: 15px;
        text-align: center;
    }
}

/* ==========================================================================
   1. Hero Section
   ========================================================================== */
.cc-hero-section {
    min-height: 50vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--gradient-blue);
    text-align: center;
    padding: 120px 20px 60px;
    position: relative;
    overflow: hidden;
}

/* Decorative circles like other sections */
.cc-hero-section::before {
    content: '';
    position: absolute;
    top: -100px;
    right: -100px;
    width: 350px;
    height: 350px;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 50%;
}

.cc-hero-section::after {
    content: '';
    position: absolute;
    bottom: -120px;
    left: -120px;
    width: 400px;
    height: 400px;
    background: rgba(255, 255, 255, 0.02);
    border-radius: 50%;
}

.cc-hero-content {
    position: relative;
    z-index: 2;
    max-width: 900px;
    color: var(--white);
}

.cc-hero-title {
    font-size: 3.5rem;
    font-weight: 700;
    margin-bottom: 10px;
    color: var(--white);
    line-height: 1.2;
}

/* Dynamic Text - Typewriter Effect */
.cc-dynamic-text {
    display: inline;
    color: var(--white);
    font-weight: 700;
}

.cc-cursor {
    display: inline;
    color: var(--white);
    font-weight: 400;
    animation: ccBlink 0.8s infinite;
}

@keyframes ccBlink {
    0%, 50% {
        opacity: 1;
    }
    51%, 100% {
        opacity: 0;
    }
}

.cc-hero-tagline {
    font-size: 1.5rem;
    font-weight: 400;
    margin-bottom: 40px;
    color: rgba(255, 255, 255, 0.9);
}

/* ==========================================================================
   2. Tab Navigation - Rounded Pills Style
   ========================================================================== */
.cc-tab-navigation {
    display: inline-flex;
    justify-content: center;
    gap: 0;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50px;
    padding: 5px;
}

.cc-tab-btn {
    padding: 14px 35px;
    font-size: 0.9rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    border: none;
    cursor: pointer;
    transition: all var(--transition-fast);
    font-family: var(--font-primary);
    border-radius: 50px;
    background: transparent;
    color: var(--white);
}

.cc-tab-btn.active {
    background: var(--coral-color);
    color: var(--white);
    box-shadow: 0 5px 20px rgba(255, 107, 91, 0.4);
}

.cc-tab-btn:not(.active):hover {
    background: rgba(255, 255, 255, 0.15);
}

/* ==========================================================================
   3. Tab Content Wrapper
   ========================================================================== */
.cc-tab-content-wrapper {
    background: var(--gradient-blue);
    min-height: 60vh;
}

.cc-tab-panel {
    display: none;
    padding: 60px 0 100px;
}

.cc-tab-panel.active {
    display: block;
    animation: ccFadeIn 0.4s ease;
}

@keyframes ccFadeIn {
    from {
        opacity: 0;
        transform: translateY(15px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ==========================================================================
   4. Game Section (JOUER Tab)
   ========================================================================== */
.cc-game-header {
    text-align: center;
    margin-bottom: 40px;
    color: var(--white);
}

.cc-game-title {
    font-size: 2.2rem;
    font-weight: 700;
    color: var(--white);
    margin-bottom: 20px;
}

.cc-game-subtitle {
    font-size: 1.05rem;
    color: rgba(255, 255, 255, 0.8);
    line-height: 1.8;
    max-width: 650px;
    margin: 0 auto;
}

.cc-rule-badge {
    display: inline-block;
    background: var(--coral-color);
    color: var(--white);
    padding: 5px 14px;
    border-radius: 20px;
    font-weight: 600;
    font-size: 0.9rem;
    margin-right: 5px;
}

/* Game Container Wrapper with Decorations */
.cc-game-wrapper {
    position: relative;
    max-width: 900px;
    margin: 0 auto;
    padding: 20px;
}

/* Decorative floating elements around game */
.cc-game-wrapper::before,
.cc-game-wrapper::after {
    content: '';
    position: absolute;
    border-radius: 50%;
    background: var(--sky-color);
    opacity: 0.15;
    animation: ccFloatDecor 6s ease-in-out infinite;
    pointer-events: none;
}

.cc-game-wrapper::before {
    width: 80px;
    height: 80px;
    top: -20px;
    left: -30px;
    animation-delay: 0s;
}

.cc-game-wrapper::after {
    width: 60px;
    height: 60px;
    bottom: -10px;
    right: -20px;
    animation-delay: 3s;
}

@keyframes ccFloatDecor {
    0%, 100% {
        transform: translateY(0) scale(1);
        opacity: 0.15;
    }
    50% {
        transform: translateY(-15px) scale(1.1);
        opacity: 0.25;
    }
}

/* Game Container - Rounded Card Style */
.cc-game-container {
    position: relative;
    background: var(--indigo-color);
    border: 3px solid rgba(167, 219, 238, 0.3);
    border-radius: 20px;
    overflow: hidden;
    box-shadow:
        0 15px 50px rgba(32, 43, 109, 0.5),
        0 0 0 1px rgba(167, 219, 238, 0.1),
        inset 0 1px 0 rgba(255, 255, 255, 0.05);
    transition: all var(--transition-fast);
}

.cc-game-container:hover {
    border-color: rgba(167, 219, 238, 0.5);
    box-shadow:
        0 20px 60px rgba(32, 43, 109, 0.6),
        0 0 30px rgba(167, 219, 238, 0.15),
        inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.cc-game-score-display {
    position: absolute;
    top: 15px;
    right: 20px;
    color: var(--white);
    font-size: 1.1rem;
    font-weight: 600;
    z-index: 5;
    background: rgba(0, 0, 0, 0.2);
    padding: 8px 16px;
    border-radius: 20px;
    backdrop-filter: blur(5px);
}

#dinoGame {
    display: block;
    width: 100%;
    height: 280px;
}

/* Game Overlay */
.cc-game-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: space-between;
    padding: 40px 20px 50px;
    background: transparent;
    color: var(--white);
    z-index: 10;
    pointer-events: none;
}

.cc-game-overlay > * {
    pointer-events: auto;
}

.cc-game-instruction {
    font-size: 1.1rem;
    color: rgba(255, 255, 255, 0.9);
    text-align: center;
}

/* Game Over State */
.cc-game-overlay.game-over {
    background: rgba(32, 43, 109, 0.9);
    justify-content: center;
    gap: 20px;
    padding: 30px;
}

.cc-game-overlay-bottom {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
}

.cc-game-btn {
    padding: 14px 50px;
    background: linear-gradient(135deg, var(--coral-color) 0%, #ff8578 100%);
    color: var(--white);
    border: none;
    border-radius: 50px;
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    transition: all var(--transition-fast);
    font-family: var(--font-primary);
    position: relative;
    overflow: hidden;
    animation: ccPulseBtn 2s ease-in-out infinite;
}

.cc-game-btn::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: 0.5s;
}

.cc-game-btn:hover::before {
    left: 100%;
}

@keyframes ccPulseBtn {
    0%, 100% {
        box-shadow: 0 5px 20px rgba(255, 107, 91, 0.4);
    }
    50% {
        box-shadow: 0 8px 30px rgba(255, 107, 91, 0.6), 0 0 20px rgba(255, 107, 91, 0.3);
    }
}

.cc-game-btn:hover {
    background: linear-gradient(135deg, #ff8578 0%, var(--coral-color) 50%, #ffd700 100%);
    transform: translateY(-3px) scale(1.02);
    box-shadow: 0 15px 40px rgba(255, 107, 91, 0.5);
    animation: none;
}

.cc-game-message {
    font-size: 0.95rem;
    color: rgba(255, 255, 255, 0.9);
    margin-top: 5px;
}

/* Win Screen */
.cc-game-win {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    display: none;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background: rgba(32, 43, 109, 0.98);
    color: var(--white);
    gap: 12px;
    z-index: 10;
    border-radius: 25px;
}

.cc-game-win h3 {
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--white);
    text-align: center;
    padding: 0 20px;
}

.cc-download-link {
    font-size: 1.3rem;
    font-weight: 600;
    color: var(--coral-color);
    text-decoration: none;
    transition: all 0.3s ease;
    margin: 15px 0;
}

.cc-download-link:hover {
    color: var(--coral-hover);
    text-decoration: underline;
}

.cc-replay-btn {
    margin-top: 20px;
}

/* ==========================================================================
   5. Form Section (REJOINDRE Tab)
   ========================================================================== */
.cc-form-header-section {
    text-align: center;
    margin-bottom: 50px;
    color: var(--white);
}

.cc-form-main-title {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--white);
    margin-bottom: 15px;
    position: relative;
    display: inline-block;
}

.cc-form-main-title::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 3px;
    background: linear-gradient(90deg, var(--coral-color), #fec400);
    border-radius: 2px;
}

.cc-form-main-subtitle {
    font-size: 1.2rem;
    color: rgba(255, 255, 255, 0.75);
    margin-top: 25px;
}

/* Form Container - White Card with Rounded Corners */
.cc-form-container {
    max-width: 700px;
    margin: 0 auto;
    background: var(--white);
    border-radius: 25px;
    padding: 50px;
    box-shadow: var(--shadow-lg);
}

.cc-form-title {
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--primary-color);
    margin-bottom: 30px;
    text-align: center;
}

/* Form Styles */
.cc-form .form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

.cc-form .form-group {
    margin-bottom: 20px;
}

.cc-form .form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: var(--primary-color);
    font-size: 0.9rem;
}

.cc-form .form-group input,
.cc-form .form-group textarea {
    width: 100%;
    padding: 14px 18px;
    border: 2px solid var(--glow-color);
    border-radius: 12px;
    font-family: var(--font-primary);
    font-size: 15px;
    transition: all var(--transition-fast);
    background: var(--white);
    color: var(--primary-color);
}

.cc-form .form-group input:focus,
.cc-form .form-group textarea:focus {
    outline: none;
    border-color: var(--electric-color);
    box-shadow: 0 0 0 4px rgba(47, 74, 205, 0.1);
}

.cc-form .form-group input::placeholder,
.cc-form .form-group textarea::placeholder {
    color: var(--ash-color);
    opacity: 0.6;
}

.cc-form textarea {
    resize: vertical;
    min-height: 100px;
}

/* Radio Buttons */
.cc-reason-group {
    margin-bottom: 25px;
}

.cc-reason-group .group-label {
    display: block;
    margin-bottom: 15px;
    font-weight: 600;
    color: var(--primary-color);
    font-size: 0.9rem;
}

.cc-reason-options {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.cc-reason-option {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 18px;
    background: var(--glow-color);
    border-radius: 12px;
    cursor: pointer;
    transition: all var(--transition-fast);
    border: 2px solid transparent;
}

.cc-reason-option:hover {
    background: rgba(47, 74, 205, 0.05);
    border-color: rgba(47, 74, 205, 0.2);
}

.cc-reason-option input[type="radio"] {
    width: 20px;
    height: 20px;
    accent-color: var(--coral-color);
    cursor: pointer;
    flex-shrink: 0;
}

.cc-reason-option label {
    font-size: 0.95rem;
    color: var(--ash-color);
    cursor: pointer;
    line-height: 1.4;
}

/* Checkbox */
.cc-form .form-checkbox {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    margin-bottom: 25px;
    flex-wrap: wrap;
}

.cc-form .form-checkbox input[type="checkbox"] {
    width: 22px;
    height: 22px;
    accent-color: var(--coral-color);
    cursor: pointer;
    margin-top: 2px;
    flex-shrink: 0;
}

.cc-form .form-checkbox > label {
    font-size: 0.9rem;
    color: var(--ash-color);
    cursor: pointer;
    line-height: 1.5;
}

/* Submit Button - Coral Rounded */
.cc-form .submit-btn {
    width: 100%;
    padding: 16px;
    background: var(--coral-color);
    color: var(--white);
    border: none;
    border-radius: 50px;
    font-size: 1.05rem;
    font-weight: 600;
    cursor: pointer;
    transition: all var(--transition-fast);
    font-family: var(--font-primary);
    margin-top: 10px;
}

.cc-form .submit-btn:hover {
    background: linear-gradient(135deg, var(--coral-color) 0%, #ff8578 50%, #ffd700 100%);
    transform: translateY(-3px);
    box-shadow: 0 12px 30px rgba(255, 107, 91, 0.45);
}

/* Error Styles */
.cc-form .field-error {
    display: none;
    color: #dc3545;
    font-size: 0.8rem;
    font-weight: 500;
    margin-top: 6px;
}

.cc-form .field-error.visible {
    display: block;
}

.cc-form .checkbox-error {
    width: 100%;
    margin-left: 34px;
    display: none;
}

.cc-form .checkbox-error.visible {
    display: block;
}

.cc-form input.input-error,
.cc-form textarea.input-error {
    border-color: #dc3545 !important;
    background: rgba(220, 53, 69, 0.03);
}

/* ==========================================================================
   6. Responsive Styles
   ========================================================================== */
@media (max-width: 992px) {
    .cc-hero-title {
        font-size: 2.8rem;
    }

    .cc-tab-btn {
        padding: 12px 28px;
        font-size: 0.85rem;
    }

    .cc-form-main-title {
        font-size: 2rem;
    }
}

@media (max-width: 768px) {
    .cc-hero-section {
        padding: 100px 20px 50px;
    }

    .cc-hero-title {
        font-size: 2.2rem;
    }

    .cc-hero-tagline {
        font-size: 1.2rem;
        margin-bottom: 30px;
    }

    .cc-tab-navigation {
        flex-direction: column;
        gap: 10px;
        background: transparent;
        padding: 0;
        max-width: 280px;
        margin: 0 auto;
    }

    .cc-tab-btn {
        width: 100%;
    }

    .cc-tab-btn:not(.active) {
        background: rgba(255, 255, 255, 0.1);
    }

    .cc-tab-panel {
        padding: 40px 0 70px;
    }

    .cc-game-title {
        font-size: 1.7rem;
    }

    .cc-form-main-title {
        font-size: 1.7rem;
    }

    .cc-form-container {
        padding: 35px 25px;
        margin: 0 15px;
        border-radius: 20px;
    }

    .cc-form .form-row {
        grid-template-columns: 1fr;
        gap: 0;
    }

    .cc-game-container {
        margin: 0 15px;
        border-radius: 20px;
    }

    .cc-game-overlay,
    .cc-game-win {
        border-radius: 20px;
    }
}

@media (max-width: 576px) {
    .cc-hero-title {
        font-size: 1.8rem;
    }

    .cc-hero-tagline {
        font-size: 1rem;
    }

    .cc-tab-btn {
        padding: 12px 20px;
        font-size: 0.8rem;
    }

    .cc-game-subtitle {
        font-size: 0.9rem;
        padding: 0 10px;
    }

    .cc-rule-badge {
        font-size: 0.8rem;
        padding: 4px 12px;
    }

    .cc-form-title {
        font-size: 1.4rem;
    }

    .cc-form-container {
        padding: 30px 20px;
    }

    .cc-reason-option {
        padding: 12px 15px;
    }

    .cc-reason-option label {
        font-size: 0.85rem;
    }

    .cc-form .form-group input,
    .cc-form .form-group textarea {
        padding: 12px 15px;
        font-size: 14px;
    }
}
