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

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: linear-gradient(180deg, #5C6BC0 0%, #9FA8DA 100%);
    min-height: 100vh;
    color: #333;
    margin: 0;
    padding: 0;
}

.container {
    max-width: 90%;
    width: 100%;
    margin: 0 auto;
    padding: 2rem;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

header {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    padding: 2rem;
    color: white;
    z-index: 10;
}

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

header h1 {
    font-size: 2.5rem;
    margin: 0;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.3);
    font-weight: bold;
}

.auth-buttons {
    display: flex;
    gap: 1rem;
    align-items: center;
}

.btn-login {
    background: #2196F3;
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.user-profile {
    display: flex;
    align-items: center;
    gap: 12px;
    background: rgba(255, 255, 255, 0.1);
    padding: 8px 16px;
    border-radius: 25px;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.user-avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    border: 2px solid rgba(255, 255, 255, 0.3);
    object-fit: cover;
}

.user-name {
    color: white;
    font-weight: 500;
    font-size: 0.9rem;
    text-shadow: 1px 1px 2px rgba(0,0,0,0.3);
}

.btn-logout {
    background: rgba(255, 255, 255, 0.2);
    color: white;
    border: 1px solid rgba(255, 255, 255, 0.3);
    padding: 6px 12px;
    border-radius: 6px;
    font-size: 0.8rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-logout:hover {
    background: rgba(255, 255, 255, 0.3);
    border-color: rgba(255, 255, 255, 0.5);
}

.btn-login:hover {
    background: #1976D2;
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.2);
}

.btn-logout {
    background: #f44336;
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.btn-logout:hover {
    background: #d32f2f;
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.2);
}

header p {
    font-size: 1.1rem;
    opacity: 0.9;
}

.info-box {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 12px;
    padding: 20px;
    margin: 20px 0;
    backdrop-filter: blur(10px);
}

.info-box h3 {
    color: #fff;
    margin-bottom: 15px;
    font-size: 1.2rem;
}

.info-box p {
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: 10px;
    line-height: 1.5;
}

.info-box p:last-child {
    margin-bottom: 0;
}

.loading {
    text-align: center;
    color: white;
    padding: 60px 20px;
}

.spinner {
    width: 50px;
    height: 50px;
    border: 4px solid rgba(255,255,255,0.3);
    border-top: 4px solid white;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 20px;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.questionnaire {
    background: white;
    border-radius: 15px;
    padding: 3rem 2rem;
    box-shadow: 0 8px 32px rgba(0,0,0,0.1);
    max-width: 90%;
    width: 100%;
    max-width: 800px;
    margin: 0 auto;
    text-align: center;
}

.progress-bar {
    display: none; /* Hide the progress bar completely */
}

.progress-fill {
    background: linear-gradient(90deg, #4CAF50, #45a049);
    height: 100%;
    border-radius: 10px;
    transition: width 0.3s ease;
    width: 0%;
}

#progressText {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-weight: bold;
    color: #333;
    font-size: 0.9rem;
}

.joke-container {
    background: transparent;
    border-radius: 15px;
    padding: 30px;
    margin-bottom: 30px;
}

.joke-text {
    font-size: 1.4rem;
    line-height: 1.6;
    margin-bottom: 3rem;
    color: #333;
    font-weight: 400;
    text-align: center;
    padding: 0 1rem;
}

.joke-style {
    font-size: 0.9rem;
    color: #666;
    font-style: italic;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.company-footer {
    text-align: right;
    margin-top: 10px;
}

.company-link {
    font-size: 0.75rem;
    color: #999;
    text-decoration: none;
    font-weight: 500;
    transition: color 0.2s ease;
}

.company-link:hover {
    color: #666;
    text-decoration: underline;
}

.footer-separator {
    color: #ccc;
    margin: 0 5px;
    font-size: 0.7rem;
}

/* Privacy Policy Page Styles */
.privacy-page {
    max-width: 800px;
    margin: 0 auto;
    padding: 2rem;
    background: white;
    border-radius: 15px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    margin-top: 2rem;
    margin-bottom: 2rem;
}

.privacy-page h1 {
    color: #5C6BC0;
    margin-bottom: 0.5rem;
    font-size: 2.5rem;
}

.privacy-page h2 {
    color: #333;
    margin-top: 2rem;
    margin-bottom: 1rem;
    font-size: 1.5rem;
    border-bottom: 2px solid #5C6BC0;
    padding-bottom: 0.5rem;
}

.privacy-page h3 {
    color: #555;
    margin-top: 1.5rem;
    margin-bottom: 0.5rem;
    font-size: 1.2rem;
}

.privacy-page p {
    line-height: 1.6;
    margin-bottom: 1rem;
    color: #333;
}

.privacy-page ul {
    margin-left: 1.5rem;
    margin-bottom: 1rem;
}

.privacy-page li {
    margin-bottom: 0.5rem;
    line-height: 1.5;
}

.privacy-page a {
    color: #5C6BC0;
    text-decoration: none;
}

.privacy-page a:hover {
    text-decoration: underline;
}

.last-updated {
    font-style: italic;
    color: #666;
    font-size: 0.9rem;
    margin-bottom: 2rem;
}

.privacy-section {
    margin-bottom: 2rem;
}

.contact-info {
    background: #f8f9fa;
    padding: 1rem;
    border-radius: 8px;
    margin-top: 1rem;
}

.contact-info p {
    margin-bottom: 0.5rem;
}

.privacy-footer {
    text-align: center;
    margin-top: 3rem;
    padding-top: 2rem;
    border-top: 1px solid #eee;
}

.back-link {
    color: #5C6BC0;
    text-decoration: none;
    font-weight: 500;
    font-size: 1.1rem;
}

.back-link:hover {
    text-decoration: underline;
}

.header-link {
    color: white;
    text-decoration: none;
}

.header-link:hover {
    text-decoration: underline;
}

/* Mobile responsiveness for privacy page */
@media (max-width: 768px) {
    .privacy-page {
        margin: 1rem;
        padding: 1.5rem;
    }
    
    .privacy-page h1 {
        font-size: 2rem;
    }
    
    .privacy-page h2 {
        font-size: 1.3rem;
    }
}

.humor-levels-container {
    margin: 20px auto;
    max-width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    background: transparent;
    border-radius: 15px;
    padding: 20px;
}


/* Mobile responsiveness */
@media (max-width: 768px) {
    .humor-levels-container {
        padding: 10px;
        margin: 10px auto;
    }
    
    
    .brain-layers-active {
        margin-top: 10px;
        font-size: 0.9rem;
    }
}


.brain-layers-active {
    margin-top: 15px;
    text-align: center;
    font-size: 1rem;
    color: #000;
    font-weight: 500;
}

#activeCategoriesList {
    color: #000;
    font-weight: 600;
}

.response-buttons {
    display: flex;
    gap: 20px;
    justify-content: center;
    margin-top: 2rem;
    flex-wrap: wrap;
}

.btn {
    padding: 15px 30px;
    border: none;
    border-radius: 8px;
    font-size: 1.1rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    min-width: 150px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.btn-funny {
    background: #4CAF50;
    color: white;
}

.btn-funny:hover {
    background: #45a049;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(76, 175, 80, 0.3);
}

.btn-not-funny {
    background: #F44336;
    color: white;
}

.btn-not-funny:hover {
    background: #d32f2f;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(244, 67, 54, 0.3);
}

.btn-laughed {
    background: #FFD700;
    color: #333;
    font-weight: 600;
}

.btn-laughed:hover {
    background: #FFC700;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(255, 215, 0, 0.4);
}

.btn-huh {
    background: #9C27B0;
    color: white;
    font-weight: 600;
}

.btn-huh:hover {
    background: #7B1FA2;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(156, 39, 176, 0.4);
}

.btn-primary {
    background: linear-gradient(45deg, #667eea, #764ba2);
    color: white;
}

.btn-secondary {
    background: #6c757d;
    color: white;
}

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

.navigation {
    display: flex;
    gap: 20px;
    justify-content: center;
}

.results {
    background: white;
    border-radius: 20px;
    padding: 40px;
    box-shadow: 0 20px 40px rgba(0,0,0,0.1);
}

.results h2 {
    text-align: center;
    margin-bottom: 30px;
    color: #333;
}

.results-summary {
    text-align: center;
    margin-bottom: 30px;
    color: #666;
    font-size: 1.1rem;
}

.results-grid {
    display: grid;
    gap: 15px;
    margin-bottom: 30px;
}

.result-item {
    background: #f8f9fa;
    border-radius: 10px;
    padding: 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-left: 5px solid #667eea;
    transition: transform 0.2s ease;
}

.result-item:hover {
    transform: translateX(5px);
}

.result-item.high-score {
    border-left-color: #4CAF50;
    background: linear-gradient(90deg, #e8f5e8, #f8f9fa);
}

.result-item.medium-score {
    border-left-color: #ff9800;
    background: linear-gradient(90deg, #fff3e0, #f8f9fa);
}

.result-item.low-score {
    border-left-color: #f44336;
    background: linear-gradient(90deg, #ffebee, #f8f9fa);
}

.result-style {
    font-weight: bold;
    color: #333;
    font-size: 1.1rem;
}

.result-score {
    color: #666;
    font-size: 1rem;
}

.result-percentage {
    font-weight: bold;
    font-size: 1.2rem;
}

.result-description {
    font-size: 0.9rem;
    color: #888;
    font-style: italic;
}

.results-actions {
    display: flex;
    gap: 20px;
    justify-content: center;
}

.hidden {
    display: none;
}

/* Authentication Modal */
.modal {
    display: flex;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.7);
    align-items: center;
    justify-content: center;
}

.modal.hidden {
    display: none;
}

.modal-content {
    background-color: white;
    padding: 40px;
    border-radius: 12px;
    max-width: 500px;
    width: 90%;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
    position: relative;
}

.modal-content h2 {
    margin-top: 0;
    color: #333;
    text-align: center;
    margin-bottom: 15px;
}

.modal-content p {
    color: #666;
    margin-bottom: 30px;
    text-align: center;
}

.auth-buttons {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.auth-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    padding: 15px 20px;
    border: none;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
    color: white;
}

.google-btn {
    background: #4285F4;
}

.google-btn:hover {
    background: #3367D6;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(66, 133, 244, 0.3);
}

.facebook-btn {
    background: #1877F2;
}

.facebook-btn:hover {
    background: #166FE5;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(24, 119, 242, 0.3);
}

.microsoft-btn {
    background: #0078D4;
}

.microsoft-btn:hover {
    background: #106EBE;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 120, 212, 0.3);
}

.close-modal-btn {
    position: absolute;
    top: 15px;
    right: 20px;
    background: none;
    border: none;
    font-size: 24px;
    cursor: pointer;
    color: #666;
    padding: 5px;
    line-height: 1;
}

.close-modal-btn:hover {
    color: #333;
}

/* Abuse Prevention Modal */
#abuseModal .modal-content {
    text-align: center;
}

#abuseModal h2 {
    color: #f44336;
    margin-bottom: 20px;
}

#abuseModal p {
    color: #666;
    margin-bottom: 30px;
    font-size: 1.1rem;
}

#catVideosBtn {
    display: block;
    margin: 0 auto;
    padding: 12px 24px;
    font-size: 1rem;
    font-weight: 500;
}


/* Responsive Design for All Screen Sizes */
@media (max-width: 1200px) {
    .container {
        max-width: 95%;
        padding: 1.5rem;
    }
    
    .questionnaire {
        max-width: 95%;
        padding: 2.5rem 1.5rem;
    }
}

@media (max-width: 768px) {
    .container {
        padding: 1rem;
    }
    
    header {
        padding: 1.5rem;
    }
    
    header h1 {
        font-size: 2rem;
    }
    
    .btn-login {
        padding: 10px 20px;
        font-size: 0.9rem;
    }
    
    .questionnaire {
        padding: 2rem 1.5rem;
        margin: 1rem;
    }
    
    .joke-text {
        font-size: 1.2rem;
        margin-bottom: 2rem;
    }
    
    .response-buttons {
        gap: 15px;
    }
    
    .btn {
        padding: 12px 24px;
        font-size: 1rem;
        min-width: 120px;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0.5rem;
    }
    
    header {
        padding: 1rem;
    }
    
    header h1 {
        font-size: 1.8rem;
    }
    
    .questionnaire {
        padding: 1.5rem 1rem;
        margin: 0.5rem;
    }
    
    .joke-text {
        font-size: 1.1rem;
        margin-bottom: 1.5rem;
        padding: 0 0.5rem;
    }
    
    .response-buttons {
        flex-direction: column;
        gap: 12px;
    }
    
    .btn {
        width: 100%;
        min-width: auto;
        padding: 14px 20px;
    }
    
    .btn-login {
        padding: 8px 16px;
        font-size: 0.85rem;
    }
}

@media (max-width: 320px) {
    header h1 {
        font-size: 1.5rem;
    }
    
    .joke-text {
        font-size: 1rem;
    }
    
    .btn {
        padding: 12px 16px;
        font-size: 0.9rem;
    }
}

/* Loading spinner for session generation */
.loading-spinner {
    width: 40px;
    height: 40px;
    border: 4px solid #f3f3f3;
    border-top: 4px solid #5C6BC0;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}
