/* 65Nation Baby Boomer Trivia Widget - Game Show Energy Design */
/* System fonts only. No Google Fonts. Transparent background. */

/* ============================================
   CSS Custom Properties / Theming
   ============================================ */
:root {
    /* Standard theme: Navy + Gold */
    --primary: #1E3A5F;
    --primary-light: #2A5080;
    --primary-dark: #132840;
    --accent: #D4A843;
    --accent-dark: #B8920A;
    --accent-light: #E8C96A;
    --gradient-primary: linear-gradient(135deg, #1E3A5F 0%, #2A5080 100%);
    --gradient-accent: linear-gradient(135deg, #D4A843 0%, #B8920A 100%);
    --progress-gradient: linear-gradient(90deg, #D4A843, #E8C96A);
    --text-primary: #1a1a1a;
    --text-secondary: #4a5568;
    --text-muted: #718096;
    --border-color: #e2e8f0;
    --border-light: #f0f0f0;
    --surface: #ffffff;
    --surface-alt: #f7f8fa;
    --correct-bg: rgba(5, 150, 105, 0.08);
    --correct-border: #059669;
    --correct-text: #065f46;
    --incorrect-bg: rgba(220, 38, 38, 0.08);
    --incorrect-border: #DC2626;
    --incorrect-text: #991b1b;
    --shadow-sm: 0 1px 3px rgba(0,0,0,0.06);
    --shadow-md: 0 4px 12px rgba(0,0,0,0.08);
    --shadow-lg: 0 8px 30px rgba(0,0,0,0.1);
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 16px;
    --radius-xl: 20px;
}

body.theme-mastermind {
    /* Mastermind theme: Gold primary, deep gold accent */
    --primary: #D4A843;
    --primary-light: #E8C96A;
    --primary-dark: #B8860B;
    --accent: #B8860B;
    --accent-dark: #8B6914;
    --accent-light: #D4A843;
    --gradient-primary: linear-gradient(135deg, #D4A843 0%, #B8860B 100%);
    --gradient-accent: linear-gradient(135deg, #B8860B 0%, #8B6914 100%);
    --progress-gradient: linear-gradient(90deg, #D4A843, #B8860B);
}

/* ============================================
   1. Base & Reset
   ============================================ */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html, body {
    width: 100%;
    height: 100%;
    margin: 0;
    padding: 0;
}

body {
    font-family: system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
    background: transparent;
    color: var(--text-primary);
    margin: 0;
    padding: 16px;
    min-height: 100vh;
    min-height: 100dvh;
    font-size: 16px;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body.fullwidth {
    max-width: 100%;
    padding: 20px;
}

body.fullwidth .trivia-container {
    max-width: 100%;
    width: 100%;
}

body.fullwidth .question-card,
body.fullwidth .results-card {
    max-width: 900px;
    margin: 0 auto;
}

body.embedded {
    background: transparent;
}

.trivia-container {
    max-width: 720px;
    margin: 0 auto;
    width: 100%;
}

#trivia-widget-root {
    width: 100%;
    min-height: 100%;
}

.hidden {
    display: none !important;
}

/* ============================================
   2. Typography
   ============================================ */
h1, h2, h3 {
    font-family: Georgia, 'Times New Roman', serif;
    font-weight: 700;
    line-height: 1.3;
}

/* ============================================
   3. Animations (subtle fade-in only)
   ============================================ */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(8px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

@keyframes modalSlideIn {
    from { opacity: 0; transform: scale(0.95) translateY(12px); }
    to { opacity: 1; transform: scale(1) translateY(0); }
}

/* ============================================
   4. Loading State
   ============================================ */
.trivia-loading {
    text-align: center;
    padding: 60px 24px;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-xl);
    background: var(--surface);
}

.loading-spinner {
    width: 36px;
    height: 36px;
    border: 3px solid var(--border-color);
    border-top-color: var(--primary);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
    margin: 0 auto 20px;
}

.trivia-loading p {
    color: var(--text-muted);
    font-size: 1rem;
}

/* ============================================
   5. Empty / No Trivia State
   ============================================ */
.trivia-empty {
    text-align: center;
    padding: 60px 24px;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-xl);
    background: var(--surface);
}

.empty-icon {
    margin-bottom: 20px;
}

.empty-icon svg {
    display: inline-block;
}

.trivia-empty h2 {
    color: var(--text-primary);
    font-size: 1.5rem;
    margin-bottom: 8px;
}

.trivia-empty p {
    color: var(--text-secondary);
    font-size: 1rem;
}

/* ============================================
   6. Difficulty Picker
   ============================================ */
.difficulty-picker {
    width: 100%;
}

.picker-card {
    background: var(--surface);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-xl);
    padding: 40px 28px;
    text-align: center;
    box-shadow: var(--shadow-sm);
}

.picker-logo {
    display: block;
    height: 40px;
    width: auto;
    margin: 0 auto 16px;
}

.picker-title {
    font-size: 1.75rem;
    color: var(--text-primary);
    margin: 0 0 6px;
}

.picker-subtitle {
    color: var(--text-muted);
    font-size: 0.95rem;
    margin: 0;
}

.picker-prompt {
    text-transform: uppercase;
    letter-spacing: 2.5px;
    font-size: 0.75rem;
    font-weight: 700;
    color: var(--text-muted);
    margin: 28px 0 20px;
}

.difficulty-options {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

.difficulty-card {
    background: var(--surface);
    border: 2px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 28px 20px;
    cursor: pointer;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    color: var(--text-primary);
    font-family: inherit;
}

.difficulty-card.standard:hover {
    border-color: var(--primary);
    box-shadow: 0 4px 20px rgba(30, 58, 95, 0.12);
}

.difficulty-card.mastermind {
    border-color: rgba(212, 168, 67, 0.3);
}

.difficulty-card.mastermind:hover {
    border-color: #D4A843;
    box-shadow: 0 4px 20px rgba(212, 168, 67, 0.15);
}

.diff-badge {
    display: inline-block;
    padding: 4px 14px;
    border-radius: 20px;
    font-weight: 700;
    font-size: 0.65rem;
    letter-spacing: 2px;
    text-transform: uppercase;
}

.standard-badge {
    background: #1E3A5F;
    color: white;
}

.mastermind-badge {
    background: linear-gradient(135deg, #D4A843, #B8860B);
    color: white;
}

.diff-icon {
    display: flex;
    justify-content: center;
}

.diff-icon svg {
    display: block;
}

.diff-title {
    font-family: Georgia, 'Times New Roman', serif;
    font-size: 1.15rem;
    margin: 0;
    color: var(--text-primary);
}

.diff-desc {
    font-size: 0.875rem;
    color: var(--text-secondary);
    line-height: 1.5;
    margin: 0;
}

.diff-details {
    display: flex;
    gap: 12px;
    font-size: 0.75rem;
    color: var(--text-muted);
    justify-content: center;
}

.diff-cta {
    padding: 10px 24px;
    border-radius: var(--radius-md);
    font-weight: 700;
    font-size: 0.875rem;
    margin-top: 4px;
    border: none;
    cursor: pointer;
    color: white;
}

.standard-cta {
    background: #1E3A5F;
}

.mastermind-cta {
    background: linear-gradient(135deg, #D4A843, #B8860B);
}

/* ============================================
   7. Start Screen
   ============================================ */
.start-screen {
    width: 100%;
    animation: fadeIn 0.3s ease;
}

.start-card {
    background: var(--surface);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-xl);
    padding: 48px 32px;
    text-align: center;
    box-shadow: var(--shadow-sm);
}

.start-icon {
    display: flex;
    justify-content: center;
    margin-bottom: 16px;
}

.start-icon svg {
    display: block;
}

.start-title {
    font-size: 2rem;
    color: var(--text-primary);
    margin: 12px 0 8px;
}

.start-subtitle {
    font-family: Georgia, 'Times New Roman', serif;
    font-size: 1.1rem;
    color: var(--text-secondary);
    font-weight: 500;
    margin-bottom: 6px;
}

.start-date {
    color: var(--text-muted);
    font-size: 0.95rem;
    margin-bottom: 24px;
}

.start-info {
    display: flex;
    justify-content: center;
    gap: 28px;
    margin: 28px 0;
    flex-wrap: wrap;
}

.info-item {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.info-icon {
    display: flex;
    align-items: center;
}

.info-text {
    font-size: 0.9rem;
    font-weight: 500;
}

.btn-start {
    padding: 16px 48px;
    background: var(--gradient-primary);
    border: none;
    border-radius: var(--radius-md);
    color: white;
    font-size: 1.1rem;
    font-weight: 700;
    cursor: pointer;
    transition: opacity 0.2s ease, box-shadow 0.2s ease;
    min-height: 52px;
}

.btn-start:hover {
    opacity: 0.9;
    box-shadow: var(--shadow-md);
}

.start-footer {
    color: var(--text-muted);
    font-size: 0.875rem;
    margin-top: 16px;
}

/* ============================================
   8. Game Header
   ============================================ */
.trivia-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
    padding: 14px 20px;
    background: var(--surface);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
}

.trivia-branding {
    display: flex;
    align-items: center;
    gap: 12px;
}

.trivia-icon {
    display: flex;
    align-items: center;
}

.header-logo {
    height: 32px;
    width: auto;
    display: block;
}

.trivia-title {
    font-family: Georgia, 'Times New Roman', serif;
    font-size: 1.15rem;
    color: var(--text-primary);
    margin: 0;
    font-weight: 700;
}

.trivia-subtitle {
    color: var(--text-muted);
    font-size: 0.8rem;
    margin: 0;
}

.trivia-timer {
    background: var(--gradient-primary);
    padding: 8px 16px;
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    gap: 6px;
    color: white;
    font-weight: 700;
    font-size: 1rem;
    font-variant-numeric: tabular-nums;
}

/* ============================================
   9. Progress Bar
   ============================================ */
.progress-bar-container {
    background: var(--border-color);
    border-radius: 6px;
    height: 8px;
    position: relative;
    margin-bottom: 24px;
    margin-top: 4px;
    overflow: hidden;
}

.progress-bar {
    height: 100%;
    background: var(--progress-gradient);
    border-radius: 6px;
    transition: width 0.4s ease;
    width: 0;
}

.progress-text {
    position: absolute;
    right: 0;
    top: -22px;
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--text-muted);
}

/* ============================================
   10. Question Card
   ============================================ */
.question-card {
    background: var(--surface);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-xl);
    padding: 28px;
    box-shadow: var(--shadow-sm);
    animation: fadeIn 0.3s ease;
}

.question-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}

.question-number {
    background: var(--gradient-primary);
    color: white;
    padding: 5px 14px;
    border-radius: var(--radius-sm);
    font-weight: 700;
    font-size: 0.85rem;
    display: inline-block;
}

.category-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 5px 14px;
    border-radius: var(--radius-sm);
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Category badge color schemes — muted, professional */
.category-badge.entertainment {
    background: #fef3c7;
    color: #92400e;
}
.category-badge.culture {
    background: #dbeafe;
    color: #1e40af;
}
.category-badge.people-places {
    background: #d1fae5;
    color: #065f46;
}
.category-badge.events {
    background: #fce7f3;
    color: #9d174d;
}
.category-badge.science-tech {
    background: #e0e7ff;
    color: #3730a3;
}
.category-badge.sports-hobbies {
    background: #fee2e2;
    color: #991b1b;
}

.question-text {
    font-family: Georgia, 'Times New Roman', serif;
    font-size: 1.25rem;
    font-weight: 500;
    color: var(--text-primary);
    line-height: 1.6;
    margin-bottom: 24px;
}

/* ============================================
   11. Option Buttons
   ============================================ */
.options-grid {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.option-btn {
    display: flex;
    align-items: center;
    gap: 14px;
    width: 100%;
    padding: 16px 18px;
    background: var(--surface);
    border: 2px solid var(--border-color);
    border-radius: var(--radius-md);
    color: var(--text-primary);
    font-size: 1rem;
    cursor: pointer;
    transition: border-color 0.2s ease, background-color 0.2s ease;
    text-align: left;
    font-family: inherit;
    min-height: 56px;
    line-height: 1.4;
}

.option-btn:hover:not(.disabled) {
    background: var(--surface-alt);
    border-color: var(--primary);
}

.option-letter {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: var(--gradient-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 0.875rem;
    flex-shrink: 0;
    color: white;
}

.option-text {
    flex: 1;
    font-size: 1rem;
}

/* Correct answer: green border + checkmark icon injected via pseudo-element */
.option-btn.correct {
    background: var(--correct-bg);
    border-color: var(--correct-border);
    color: var(--correct-text);
}

.option-btn.correct .option-letter {
    background: #059669;
}

.option-btn.correct::after {
    content: '';
    width: 28px;
    height: 28px;
    flex-shrink: 0;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23059669' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 13l4 4L19 7'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-size: contain;
}

/* Incorrect answer: red border + X icon */
.option-btn.incorrect {
    background: var(--incorrect-bg);
    border-color: var(--incorrect-border);
    color: var(--incorrect-text);
}

.option-btn.incorrect .option-letter {
    background: #DC2626;
}

.option-btn.incorrect::after {
    content: '';
    width: 28px;
    height: 28px;
    flex-shrink: 0;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23DC2626' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 6l12 12M18 6L6 18'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-size: contain;
}

.option-btn.selected {
    background: rgba(30, 58, 95, 0.06);
    border-color: var(--primary);
}

.option-btn.disabled {
    cursor: default;
    pointer-events: none;
}

/* ============================================
   12. Feedback
   ============================================ */
.feedback-container {
    padding: 18px 20px;
    border-radius: var(--radius-md);
    margin-top: 18px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    animation: fadeIn 0.3s ease;
}

.feedback-container.correct {
    background: var(--correct-bg);
    border: 2px solid var(--correct-border);
}

.feedback-container.incorrect {
    background: var(--incorrect-bg);
    border: 2px solid var(--incorrect-border);
}

.feedback-icon {
    font-size: 1.5rem;
    font-weight: 700;
}

.feedback-container.correct .feedback-icon {
    color: var(--correct-border);
}

.feedback-container.incorrect .feedback-icon {
    color: var(--incorrect-border);
}

.feedback-text {
    font-weight: 700;
    font-size: 1rem;
    color: var(--text-primary);
}

.explanation {
    font-size: 0.9rem;
    color: var(--text-secondary);
    text-align: center;
    line-height: 1.6;
}

/* ============================================
   13. Action Buttons
   ============================================ */
.action-buttons {
    margin-top: 18px;
    text-align: center;
}

.btn-next {
    padding: 14px 36px;
    background: var(--gradient-primary);
    border: none;
    border-radius: var(--radius-md);
    color: white;
    font-size: 1rem;
    font-weight: 700;
    cursor: pointer;
    transition: opacity 0.2s ease, box-shadow 0.2s ease;
    min-height: 50px;
}

.btn-next:hover {
    opacity: 0.9;
    box-shadow: var(--shadow-md);
}

/* ============================================
   14. Results Screen
   ============================================ */
.results-container {
    width: 100%;
    animation: fadeIn 0.3s ease;
}

.results-card {
    background: var(--surface);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-xl);
    padding: 40px 28px;
    text-align: center;
    box-shadow: var(--shadow-sm);
}

.results-header {
    margin-bottom: 24px;
}

.trophy-icon {
    display: flex;
    justify-content: center;
    margin-bottom: 12px;
}

.trophy-icon svg {
    display: block;
}

.results-header h2 {
    font-family: Georgia, 'Times New Roman', serif;
    font-size: 1.75rem;
    color: var(--text-primary);
}

.score-display {
    margin: 24px 0;
}

.score-circle {
    width: 130px;
    height: 130px;
    border-radius: 50%;
    background: var(--gradient-primary);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    margin: 0 auto;
    box-shadow: 0 6px 24px rgba(30, 58, 95, 0.2);
}

body.theme-mastermind .score-circle {
    box-shadow: 0 6px 24px rgba(212, 168, 67, 0.25);
}

.score-number {
    font-size: 3rem;
    font-weight: 700;
    font-family: Georgia, 'Times New Roman', serif;
    color: white;
    line-height: 1;
}

.score-label {
    font-size: 1.1rem;
    opacity: 0.85;
    color: white;
}

.results-stats {
    display: flex;
    justify-content: center;
    gap: 32px;
    margin: 28px 0;
    padding: 20px;
    background: var(--surface-alt);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-lg);
}

.stat-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
}

.stat-icon {
    display: flex;
    align-items: center;
    justify-content: center;
}

.stat-value {
    font-weight: 700;
    font-size: 1.15rem;
    color: var(--text-primary);
}

.stat-label {
    font-size: 0.8rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-weight: 600;
}

/* ============================================
   15. Star Rating
   ============================================ */
.rating-section {
    margin: 24px 0;
    padding: 20px;
    background: var(--surface-alt);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-lg);
    text-align: center;
}

.rating-text {
    font-size: 0.95rem;
    color: var(--text-secondary);
    margin-bottom: 12px;
}

.star-rating {
    display: flex;
    justify-content: center;
    gap: 8px;
}

.star-btn {
    font-size: 2.2rem;
    background: none;
    border: none;
    color: #cbd5e0;
    cursor: pointer;
    transition: color 0.15s ease, transform 0.15s ease;
    padding: 4px;
    min-width: 48px;
    min-height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.star-btn:hover:not(:disabled),
.star-btn.hover-active {
    color: #D4A843;
    transform: scale(1.15);
}

.star-btn.active {
    color: #D4A843;
}

.rating-thanks {
    color: var(--accent);
    font-weight: 600;
    animation: fadeIn 0.3s ease;
    margin-top: 12px;
}

/* ============================================
   16. Share Section
   ============================================ */
.share-section {
    margin-top: 24px;
}

.share-text {
    font-size: 0.9rem;
    color: var(--text-muted);
    margin-bottom: 14px;
}

.share-buttons {
    display: flex;
    gap: 12px;
    justify-content: center;
    flex-wrap: wrap;
}

.share-btn {
    padding: 14px 28px;
    border: none;
    border-radius: var(--radius-md);
    background: var(--gradient-primary);
    color: white;
    font-weight: 700;
    font-size: 0.95rem;
    cursor: pointer;
    transition: opacity 0.2s ease, box-shadow 0.2s ease;
    min-height: 50px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.share-btn.secondary {
    background: var(--surface);
    border: 2px solid var(--border-color);
    color: var(--text-primary);
}

.share-btn:hover {
    opacity: 0.9;
    box-shadow: var(--shadow-md);
}

.share-btn.secondary:hover {
    border-color: var(--primary);
    opacity: 1;
}

/* ============================================
   17. Cross-Difficulty CTA
   ============================================ */
.cross-difficulty-section {
    margin-top: 24px;
    text-align: center;
}

.cross-cta-divider {
    height: 1px;
    background: var(--border-color);
    margin-bottom: 24px;
}

.cross-difficulty-btn {
    width: 100%;
    padding: 18px 24px;
    border: 2px solid var(--border-color);
    border-radius: var(--radius-lg);
    color: var(--text-primary);
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: border-color 0.2s ease, background 0.2s ease;
    background: var(--surface);
    font-family: inherit;
    min-height: 56px;
}

.cross-difficulty-btn.mastermind-cta-btn {
    border-color: rgba(212, 168, 67, 0.4);
    background: rgba(212, 168, 67, 0.05);
}

.cross-difficulty-btn.mastermind-cta-btn:hover {
    background: rgba(212, 168, 67, 0.1);
    border-color: #D4A843;
    box-shadow: 0 4px 16px rgba(212, 168, 67, 0.15);
}

.cross-difficulty-btn.standard-cta-btn {
    border-color: rgba(30, 58, 95, 0.3);
    background: rgba(30, 58, 95, 0.03);
}

.cross-difficulty-btn.standard-cta-btn:hover {
    background: rgba(30, 58, 95, 0.08);
    border-color: #1E3A5F;
    box-shadow: 0 4px 16px rgba(30, 58, 95, 0.12);
}

/* ============================================
   18. Share Modal
   ============================================ */
.share-modal {
    position: fixed;
    inset: 0;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.share-modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(3px);
}

.share-modal-content {
    position: relative;
    background: var(--surface);
    border-radius: var(--radius-xl);
    padding: 28px;
    max-width: 420px;
    width: 100%;
    border: 1px solid var(--border-color);
    box-shadow: var(--shadow-lg);
    animation: modalSlideIn 0.25s ease;
}

.share-modal-close {
    position: absolute;
    top: 12px;
    right: 16px;
    background: none;
    border: none;
    color: var(--text-muted);
    font-size: 1.5rem;
    cursor: pointer;
    transition: color 0.15s;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.share-modal-close:hover {
    color: var(--text-primary);
}

.share-card {
    background: var(--surface-alt);
    border-radius: var(--radius-lg);
    padding: 24px;
    text-align: center;
    border: 1px solid var(--border-light);
    margin-bottom: 20px;
}

.share-card-header {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin-bottom: 12px;
}

.share-logo {
    display: flex;
    align-items: center;
}

.share-logo-img {
    height: 24px;
    width: auto;
}

.share-brand {
    font-weight: 700;
    color: var(--primary);
    font-size: 1rem;
}

.share-card-title {
    font-family: Georgia, 'Times New Roman', serif;
    font-size: 1.15rem;
    color: var(--text-primary);
    margin: 0 0 4px;
}

.share-card-date {
    font-size: 0.85rem;
    color: var(--text-muted);
}

.share-card-emoji {
    margin: 18px 0;
    display: flex;
    justify-content: center;
}

.share-card-emoji svg {
    display: block;
}

.share-card-message {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--text-primary);
}

.share-card-stats {
    display: flex;
    justify-content: center;
    gap: 24px;
    align-items: center;
    margin: 18px 0;
    padding: 14px;
    background: var(--surface);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-md);
}

.share-stat {
    text-align: center;
}

.share-stat-label {
    font-size: 0.7rem;
    color: var(--text-muted);
    display: block;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-weight: 600;
}

.share-stat-value {
    font-size: 1.3rem;
    font-weight: 700;
    color: var(--text-primary);
}

.share-stat-divider {
    width: 1px;
    height: 32px;
    background: var(--border-color);
}

.share-card-cta {
    font-size: 0.85rem;
    color: var(--text-muted);
    margin-top: 12px;
}

.share-card-url {
    color: var(--primary);
    font-weight: 600;
    font-size: 0.85rem;
}

.share-actions {
    margin-top: 20px;
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.share-action-btn {
    padding: 14px 20px;
    border: none;
    border-radius: var(--radius-md);
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s ease;
    width: 100%;
    min-height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.share-action-btn.copy {
    background: var(--surface-alt);
    color: var(--text-primary);
    border: 1px solid var(--border-color);
}

.share-action-btn.copy:hover {
    background: var(--border-color);
}

.share-social-btns {
    display: flex;
    gap: 12px;
    justify-content: center;
}

.share-social-btn {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    border: none;
    color: white;
    font-size: 1.1rem;
    font-weight: 700;
    cursor: pointer;
    transition: opacity 0.15s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.share-social-btn.facebook {
    background: #1877f2;
}

.share-social-btn.twitter {
    background: #000;
}

.share-social-btn.whatsapp {
    background: #25D366;
}

.share-social-btn:hover {
    opacity: 0.85;
}

/* ============================================
   19. Responsive: Mobile (<640px)
   ============================================ */
@media (max-width: 640px) {
    body {
        padding: 10px;
    }

    /* Difficulty Picker stacks */
    .difficulty-options {
        grid-template-columns: 1fr;
    }

    .picker-card {
        padding: 28px 18px;
    }

    .difficulty-card {
        padding: 24px 18px;
    }

    /* Start screen */
    .start-card {
        padding: 32px 18px;
    }

    .start-title {
        font-size: 1.6rem;
    }

    .start-info {
        gap: 16px;
    }

    /* Game header: show branding but compact */
    .trivia-header {
        padding: 12px 14px;
        gap: 8px;
    }

    .header-logo {
        height: 24px;
    }

    .trivia-title {
        font-size: 0.95rem;
    }

    .trivia-subtitle {
        font-size: 0.7rem;
    }

    .trivia-timer {
        padding: 6px 12px;
        font-size: 0.9rem;
    }

    /* Question card */
    .question-card {
        padding: 20px 16px;
        border-radius: var(--radius-lg);
    }

    .question-text {
        font-size: 1.1rem;
    }

    /* Options */
    .option-btn {
        padding: 14px 14px;
        font-size: 0.95rem;
        gap: 12px;
    }

    .option-letter {
        width: 32px;
        height: 32px;
        font-size: 0.8rem;
    }

    /* Results */
    .results-card {
        padding: 28px 18px;
    }

    .results-stats {
        gap: 20px;
        padding: 16px;
    }

    .score-circle {
        width: 110px;
        height: 110px;
    }

    .score-number {
        font-size: 2.5rem;
    }

    /* Star rating touch targets */
    .star-btn {
        font-size: 2rem;
        min-width: 48px;
        min-height: 48px;
    }

    /* Share buttons */
    .share-buttons {
        flex-direction: column;
    }

    .share-btn {
        width: 100%;
    }

    /* Share modal */
    .share-modal-content {
        padding: 20px 16px;
    }

    .share-card {
        padding: 18px 14px;
    }
}

/* Extra small phones (<380px) */
@media (max-width: 380px) {
    body {
        padding: 6px;
    }

    .question-text {
        font-size: 1rem;
    }

    .start-title {
        font-size: 1.4rem;
    }

    .results-stats {
        flex-wrap: wrap;
        gap: 16px;
    }

    .stat-item {
        min-width: 60px;
    }
}
