/**
 * Age Verification Modal CSS
 * Path: public_html/css/age-verification.css
 * Version: 1.1.1
 *
 * Changelog v1.1.1:
 * - Fixed: Modal box also needs to be visible by default (not just overlay)
 *
 * Changelog v1.1.0:
 * - Modal now visible by default, hidden via .verified class
 * - Prevents content flash before age verification
 *
 * Styles for NSFW content age verification modal
 * Includes light mode, dark mode, and responsive styles
 */

/* ============================================
   AGE VERIFICATION OVERLAY & BLUR
   ============================================ */

/* Body class when modal is active - prevents scrolling */
body.age-verification-active {
    overflow: hidden;
}

/* Blur the page content when verification needed */
body.age-verification-active .main,
body.age-verification-active .breadcrumbs,
body.age-verification-active .section-nav,
body.age-verification-active .ai-tools-full-width,
body.age-verification-active .new-tools-widget-container {
    filter: blur(8px);
    pointer-events: none;
    user-select: none;
    transition: filter 0.3s ease;
}

/* ============================================
   MODAL OVERLAY
   ============================================ */

.age-verification-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(26, 54, 93, 0.85);
    backdrop-filter: blur(4px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10000;
    padding: 20px;
    box-sizing: border-box;
    /* Visible by default - hidden via .age-verified class on body */
    opacity: 1;
    visibility: visible;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

/* Hide modal when user is already verified */
body.age-verified .age-verification-overlay {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

/* Legacy: .show class still works for backwards compatibility */
.age-verification-overlay.show {
    opacity: 1;
    visibility: visible;
}

/* ============================================
   MODAL CONTAINER
   ============================================ */

.age-verification-modal {
    background: #ffffff;
    border-radius: 16px;
    max-width: 400px;
    width: 100%;
    overflow: hidden;
    box-shadow: 0 25px 80px rgba(0, 0, 0, 0.4);
    /* Visible by default */
    transform: scale(1);
    opacity: 1;
    transition: transform 0.3s ease, opacity 0.3s ease;
}

/* Legacy: .show class still works */
.age-verification-overlay.show .age-verification-modal {
    transform: scale(1);
    opacity: 1;
}

/* ============================================
   MODAL HEADER
   ============================================ */

.age-verification-header {
    background: linear-gradient(135deg, #1a365d 0%, #2d4a6f 100%);
    padding: 30px 30px 40px;
    text-align: center;
}

.age-verification-icon {
    width: 80px;
    height: 80px;
    background: #fff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.2);
}

.age-verification-icon svg {
    width: 44px;
    height: 44px;
}

.age-verification-header h2 {
    margin: 20px 0 0;
    font-size: 22px;
    font-weight: 600;
    color: #ffffff;
}

/* ============================================
   MODAL BODY
   ============================================ */

.age-verification-body {
    padding: 28px 30px 30px;
}

.age-verification-body p {
    margin: 0 0 24px;
    font-size: 15px;
    color: #555;
    line-height: 1.7;
    text-align: center;
}

.age-verification-body p strong {
    color: #1a365d;
}

/* ============================================
   REMEMBER CHECKBOX
   ============================================ */

.age-verification-remember {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 14px 16px;
    background: #f8fafc;
    border-radius: 8px;
    margin-bottom: 20px;
    cursor: pointer;
    border: 1px solid #e2e8f0;
    font-size: 13px;
    color: #666;
    line-height: 1.5;
    transition: border-color 0.2s ease, background-color 0.2s ease;
}

.age-verification-remember:hover {
    border-color: #cbd5e1;
    background: #f1f5f9;
}

.age-verification-remember input[type="checkbox"] {
    width: 18px;
    height: 18px;
    margin-top: 2px;
    accent-color: #007cba;
    cursor: pointer;
    flex-shrink: 0;
}

.age-verification-remember span {
    flex: 1;
}

/* ============================================
   BUTTONS
   ============================================ */

.age-verification-buttons {
    display: flex;
    gap: 12px;
}

.age-verification-btn {
    flex: 1;
    padding: 14px 20px;
    font-size: 15px;
    font-weight: 500;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s ease;
    text-align: center;
    text-decoration: none;
    display: inline-block;
    box-sizing: border-box;
}

.age-verification-btn-exit {
    color: #666;
    background: #fff;
    border: 2px solid #e2e8f0;
}

.age-verification-btn-exit:hover {
    border-color: #cbd5e1;
    background: #f8fafc;
    color: #333;
}

.age-verification-btn-confirm {
    color: #fff;
    background: #007cba;
    border: 2px solid #007cba;
    font-weight: 600;
}

.age-verification-btn-confirm:hover {
    background: #005a87;
    border-color: #005a87;
}

/* ============================================
   FOOTER TEXT
   ============================================ */

.age-verification-footer {
    margin: 20px 0 0;
    font-size: 11px;
    color: #999;
    text-align: center;
    line-height: 1.5;
}

.age-verification-footer a {
    color: #007cba;
    text-decoration: none;
}

.age-verification-footer a:hover {
    text-decoration: underline;
}

/* ============================================
   RESPONSIVE - MOBILE
   ============================================ */

@media screen and (max-width: 480px) {
    .age-verification-overlay {
        padding: 15px;
    }

    .age-verification-modal {
        max-width: 100%;
        border-radius: 12px;
    }

    .age-verification-header {
        padding: 25px 20px 35px;
    }

    .age-verification-icon {
        width: 70px;
        height: 70px;
    }

    .age-verification-icon svg {
        width: 38px;
        height: 38px;
    }

    .age-verification-header h2 {
        font-size: 20px;
    }

    .age-verification-body {
        padding: 24px 20px;
    }

    .age-verification-body p {
        font-size: 14px;
    }

    .age-verification-buttons {
        flex-direction: column;
    }

    .age-verification-btn {
        padding: 16px 20px;
    }
}

/* ============================================
   DARK MODE SUPPORT
   ============================================ */

[data-theme="dark"] .age-verification-overlay {
    background: rgba(0, 0, 0, 0.85);
}

[data-theme="dark"] .age-verification-modal {
    background: #1e1e1e;
}

[data-theme="dark"] .age-verification-header {
    background: linear-gradient(135deg, #252525 0%, #333333 100%);
}

[data-theme="dark"] .age-verification-icon {
    background: #2d2d2d;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.4);
}

[data-theme="dark"] .age-verification-icon svg path {
    stroke: #6db3f2;
}

[data-theme="dark"] .age-verification-icon svg text {
    fill: #6db3f2;
}

[data-theme="dark"] .age-verification-body p {
    color: #b0b0b0;
}

[data-theme="dark"] .age-verification-body p strong {
    color: #6db3f2;
}

[data-theme="dark"] .age-verification-remember {
    background: #252525;
    border-color: #3d3d3d;
    color: #b0b0b0;
}

[data-theme="dark"] .age-verification-remember:hover {
    background: #2d2d2d;
    border-color: #555;
}

[data-theme="dark"] .age-verification-remember input[type="checkbox"] {
    accent-color: #6db3f2;
}

[data-theme="dark"] .age-verification-btn-exit {
    background: #252525;
    border-color: #3d3d3d;
    color: #b0b0b0;
}

[data-theme="dark"] .age-verification-btn-exit:hover {
    background: #2d2d2d;
    border-color: #555;
    color: #e4e4e4;
}

[data-theme="dark"] .age-verification-btn-confirm {
    background: #007cba;
    border-color: #007cba;
}

[data-theme="dark"] .age-verification-btn-confirm:hover {
    background: #0095e0;
    border-color: #0095e0;
}

[data-theme="dark"] .age-verification-footer {
    color: #888;
}

[data-theme="dark"] .age-verification-footer a {
    color: #6db3f2;
}