/* Quote Mode Specific Styles */

/* People Counter */
.people-counter {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px 20px;
    background: var(--panel-bg);
    border-radius: 20px;
    border: 1px solid var(--panel-border);
    margin-bottom: 20px;
    font-size: 0.9rem;
    color: var(--text-secondary);
    width: fit-content;
    margin-left: auto;
    margin-right: auto;
}

.people-counter svg {
    color: var(--primary-gold);
}

.people-counter #peopleCount {
    color: #4fd1c5;
    font-weight: 600;
}

/* Quote Panel */
.quote-panel {
    text-align: center;
}

.game-title {
    font-size: 1.3rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 25px;
}

/* Quote Container */
.quote-container {
    position: relative;
    padding: 30px 40px;
    margin-bottom: 25px;
    background: linear-gradient(135deg, rgba(0, 0, 0, 0.5) 0%, rgba(20, 20, 30, 0.5) 100%);
    border-radius: 16px;
    border: 2px solid var(--panel-border);
}

.quote-marks {
    position: absolute;
    font-size: 4rem;
    color: var(--primary-gold);
    opacity: 0.3;
    font-family: Georgia, serif;
    line-height: 1;
}

.quote-open {
    top: 10px;
    left: 15px;
}

.quote-close {
    bottom: 10px;
    right: 15px;
    transform: rotate(180deg);
}

.quote-text {
    font-size: 1.4rem;
    font-style: italic;
    color: var(--text-primary);
    line-height: 1.6;
    margin: 0;
    padding: 0 20px;
}

.quote-text.quote-animate {
    animation: quoteAppear 0.5s ease;
}

@keyframes quoteAppear {
    0% {
        opacity: 0;
        transform: translateY(-10px);
    }
    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Audio Clue Button */
.audio-clue {
    margin-top: 20px;
}

.audio-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: transparent;
    border: 2px solid var(--primary-gold);
    color: var(--primary-gold);
    padding: 10px 20px;
    border-radius: 25px;
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.audio-btn:hover {
    background: rgba(196, 168, 75, 0.1);
    box-shadow: 0 0 15px rgba(196, 168, 75, 0.3);
}

/* Search Container */
.quote-panel .search-container {
    max-width: 400px;
    margin: 0 auto 25px auto;
}

.search-wrapper {
    display: flex;
    align-items: stretch;
    gap: 0;
}

.quote-panel .search-input {
    border-radius: 12px 0 0 12px;
    border-right: none;
}

.search-submit {
    background: linear-gradient(135deg, var(--primary-gold) 0%, var(--primary-gold-dark) 100%);
    border: 2px solid var(--primary-gold);
    border-radius: 0 12px 12px 0;
    padding: 0 20px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.search-submit:hover {
    background: var(--primary-gold);
    box-shadow: 0 0 15px rgba(196, 168, 75, 0.5);
}

.search-submit:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.search-submit svg {
    color: #1a1a1a;
}

.search-container.disabled {
    opacity: 0.5;
    pointer-events: none;
}

/* Guesses List */
.guesses-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-bottom: 20px;
}

.guess-card {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 12px 20px;
    border-radius: 12px;
    animation: slideIn 0.3s ease;
}

@keyframes slideIn {
    0% {
        opacity: 0;
        transform: translateY(-20px);
    }
    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

.guess-card.correct {
    background: linear-gradient(135deg, rgba(76, 175, 80, 0.2) 0%, rgba(56, 142, 60, 0.2) 100%);
    border: 2px solid var(--cell-green);
}

.guess-card.incorrect {
    background: linear-gradient(135deg, rgba(244, 67, 54, 0.2) 0%, rgba(211, 47, 47, 0.2) 100%);
    border: 2px solid var(--cell-red);
}

.guess-icon {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid currentColor;
}

.guess-card.correct .guess-icon {
    border-color: var(--cell-green);
}

.guess-card.incorrect .guess-icon {
    border-color: var(--cell-red);
}

.guess-name {
    flex: 1;
    font-weight: 600;
    font-size: 1.1rem;
    text-align: left;
}

.guess-indicator {
    font-size: 1.5rem;
}

.guess-card.correct .guess-indicator {
    color: var(--cell-green);
}

.guess-card.incorrect .guess-indicator {
    color: var(--cell-red);
}

/* Victory Panel */
.quote-panel .victory-panel {
    display: none;
    background: linear-gradient(135deg, #1a5a3a 0%, #0d3d28 100%);
    border-radius: 15px;
    padding: 30px;
    text-align: center;
    border: 2px solid #2a7a4a;
    margin-top: 20px;
}

.quote-panel .victory-panel.active {
    display: block;
    animation: victoryAppear 0.5s ease;
}

@keyframes victoryAppear {
    from {
        opacity: 0;
        transform: scale(0.95);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

/* Victory Header with Poro Mascots */
.victory-header {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px;
    margin-bottom: 25px;
}

.poro-mascot {
    width: 50px;
    height: 50px;
    object-fit: contain;
}

.poro-left {
    transform: scaleX(-1);
}

.gg-text {
    font-size: 2.5rem;
    color: #f6c944;
    font-weight: 700;
    text-shadow: 0 2px 15px rgba(246, 201, 68, 0.5);
    margin: 0;
}

/* Champion Result */
.champion-result {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px;
    margin-bottom: 20px;
}

.champion-result .champion-icon {
    width: 70px;
    height: 70px;
    border-radius: 10px;
    border: 3px solid #4a9d4a;
    object-fit: cover;
}

.result-text {
    text-align: left;
}

.result-text .label {
    display: block;
    font-size: 0.8rem;
    color: #aaa;
    margin-bottom: 4px;
}

.result-text .champion-name {
    font-size: 1.8rem;
    color: white;
    font-weight: bold;
}

/* Victory Text */
.rank-text {
    color: #ccc;
    font-size: 0.95rem;
    margin-bottom: 8px;
}

.rank-text .rank {
    color: #4fd1c5;
    font-weight: 600;
}

.tries-text {
    color: #ccc;
    font-size: 0.95rem;
    margin-bottom: 20px;
}

.tries-count {
    color: #4fd1c5;
    font-weight: bold;
    font-size: 1.1rem;
}

/* Victory Actions */
.victory-actions {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin-bottom: 25px;
}

.stats-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    background: var(--primary-gold);
    color: #1a1a1a;
    border: none;
    padding: 12px 25px;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.stats-btn:hover {
    background: var(--primary-gold-dark);
    transform: scale(1.05);
}

/* Victory Audio Player */
.victory-audio-player {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 15px;
    background: rgba(0, 0, 0, 0.3);
    border-radius: 10px;
    margin-bottom: 25px;
}

.play-btn {
    width: 45px;
    height: 45px;
    border-radius: 50%;
    background: var(--primary-gold);
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    flex-shrink: 0;
}

.play-btn:hover {
    transform: scale(1.1);
    box-shadow: 0 0 15px rgba(196, 168, 75, 0.5);
}

.play-btn svg {
    color: #1a1a1a;
}

.audio-label {
    font-size: 0.9rem;
    color: #aaa;
    flex-shrink: 0;
}

.audio-progress {
    flex: 1;
    height: 6px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 3px;
    overflow: hidden;
}

.audio-progress-bar {
    height: 100%;
    width: 0%;
    background: var(--primary-gold);
    border-radius: 3px;
    transition: width 0.1s linear;
}

/* Countdown Section */
.next-champion {
    padding-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    margin-bottom: 20px;
}

.next-champion > p {
    color: #888;
    font-size: 0.85rem;
    margin-bottom: 10px;
}

.countdown-display {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 5px;
    margin-bottom: 10px;
}

.countdown-digit-group {
    display: flex;
    gap: 3px;
}

.countdown-digit {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 35px;
    height: 50px;
    background: rgba(0, 0, 0, 0.4);
    border-radius: 6px;
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--primary-gold);
    font-family: 'Courier New', monospace;
}

.countdown-separator {
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--primary-gold);
}

.timezone-info {
    color: #888;
    font-size: 0.75rem;
}

/* Next Mode Suggestion */
.next-mode-suggestion {
    padding-top: 15px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.next-mode-label {
    color: #888;
    font-size: 0.85rem;
    margin-bottom: 12px;
}

.next-mode-link {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    padding: 12px 20px;
    background: rgba(0, 0, 0, 0.3);
    border-radius: 10px;
    text-decoration: none;
    transition: all 0.3s ease;
}

.next-mode-link:hover {
    background: rgba(0, 0, 0, 0.5);
    transform: translateY(-2px);
}

.next-mode-icon {
    width: 40px;
    height: 40px;
    background: var(--primary-gold);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.next-mode-icon svg {
    color: #1a1a1a;
}

.next-mode-info {
    text-align: left;
}

.next-mode-name {
    display: block;
    font-weight: 600;
    color: white;
    font-size: 1rem;
}

.next-mode-desc {
    display: block;
    font-size: 0.8rem;
    color: #888;
}

/* Next Champion Button (Endless Mode) */
.next-btn {
    background: var(--primary-gold);
    color: #1a1a1a;
    border: none;
    padding: 12px 30px;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-top: 15px;
}

.next-btn:hover {
    background: var(--primary-gold-dark);
    transform: scale(1.05);
}

/* Share Card */
.share-card {
    background: rgba(0, 0, 0, 0.5);
    border-radius: 12px;
    padding: 20px;
    margin-top: 20px;
    border: 1px solid var(--panel-border);
}

.share-content {
    margin-bottom: 15px;
}

.share-text {
    font-size: 0.95rem;
    color: var(--text-primary);
    margin-bottom: 5px;
}

.share-url {
    font-size: 0.85rem;
    color: #4fd1c5;
}

.share-actions {
    display: flex;
    justify-content: center;
    gap: 15px;
}

.copy-btn,
.twitter-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    border-radius: 8px;
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    border: none;
}

.copy-btn {
    background: #3b82f6;
    color: white;
}

.copy-btn:hover {
    background: #2563eb;
}

.twitter-btn {
    background: #1da1f2;
    color: white;
}

.twitter-btn:hover {
    background: #0d8cd9;
}

/* Related Games Section */
.related-games {
    text-align: center;
    padding: 30px 20px;
    background: var(--panel-bg);
    border-radius: 15px;
    border: 1px solid var(--panel-border);
    margin-top: 30px;
}

.related-title {
    color: #22c55e;
    font-size: 1.2rem;
    margin-bottom: 5px;
}

.related-subtitle {
    color: var(--text-secondary);
    font-size: 0.9rem;
    margin-bottom: 20px;
}

.related-games-grid {
    display: flex;
    justify-content: center;
    gap: 20px;
    flex-wrap: wrap;
}

.related-game {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    text-decoration: none;
    transition: transform 0.3s ease;
}

.related-game:hover {
    transform: translateY(-3px);
}

.related-game-icon {
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, var(--primary-gold) 0%, var(--primary-gold-dark) 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    font-weight: bold;
    color: #1a1a1a;
}

.related-game-name {
    font-size: 0.85rem;
    color: var(--text-secondary);
}

/* Mode Toggles */
.mode-toggles {
    display: flex;
    flex-direction: column;
    gap: 12px;
    max-width: 400px;
    margin: 0 auto 25px auto;
}

.toggle-card {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 15px 20px;
    background: var(--panel-bg);
    border-radius: 12px;
    border: 1px solid var(--panel-border);
}

.toggle-card-content {
    display: flex;
    align-items: center;
    gap: 12px;
}

.toggle-card-icon {
    width: 40px;
    height: 40px;
    background: rgba(196, 168, 75, 0.1);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary-gold);
}

.toggle-card-text {
    display: flex;
    flex-direction: column;
    text-align: left;
}

.toggle-card-title {
    font-weight: 600;
    font-size: 0.95rem;
    color: var(--text-primary);
}

.toggle-card-desc {
    font-size: 0.8rem;
    color: var(--text-secondary);
}

/* Endless Stats Bar */
.endless-stats-bar {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 25px;
    padding: 15px 20px;
    background: var(--panel-bg);
    border-radius: 12px;
    border: 1px solid var(--panel-border);
    margin-bottom: 20px;
    flex-wrap: wrap;
}

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

.endless-stat-value {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary-gold);
}

.endless-stat-label {
    font-size: 0.75rem;
    color: var(--text-secondary);
}

.endless-reset-btn {
    background: transparent;
    border: 2px solid var(--cell-red);
    color: var(--cell-red);
    padding: 8px 16px;
    border-radius: 8px;
    font-size: 0.85rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.endless-reset-btn:hover {
    background: rgba(244, 67, 54, 0.1);
}

/* Settings List */
.settings-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.setting-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 15px;
    background: var(--input-bg);
    border-radius: 10px;
}

.setting-info {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.setting-label {
    font-weight: 600;
    color: var(--text-primary);
}

.setting-desc {
    font-size: 0.8rem;
    color: var(--text-secondary);
}

/* Stats Modal Additions */
.stats-actions {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin-top: 20px;
}

.share-stats-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    border-radius: 8px;
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    border: none;
    background: #3b82f6;
    color: white;
}

.share-stats-btn:hover {
    background: #2563eb;
}

.share-stats-btn.twitter {
    background: #1da1f2;
}

.share-stats-btn.twitter:hover {
    background: #0d8cd9;
}

.clear-data-btn {
    display: block;
    margin: 20px auto 0;
    background: transparent;
    border: none;
    color: var(--cell-red);
    font-size: 0.85rem;
    font-weight: 600;
    cursor: pointer;
    padding: 10px;
}

.clear-data-btn:hover {
    text-decoration: underline;
}

/* Distribution Chart */
.distribution-row {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 8px;
}

.distribution-guess {
    width: 20px;
    text-align: center;
    font-weight: 600;
    color: var(--text-primary);
}

.distribution-bar {
    min-width: 30px;
    height: 25px;
    background: var(--primary-gold);
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: flex-end;
    padding-right: 8px;
}

.distribution-count {
    font-size: 0.85rem;
    font-weight: 600;
    color: #1a1a1a;
}

.no-data {
    color: var(--text-secondary);
    text-align: center;
    padding: 20px;
}

/* GLHF */
.glhf {
    margin-top: 20px;
    font-weight: 600;
    color: var(--primary-gold);
    font-size: 1.2rem;
}

/* Loading Skeleton */
.quote-skeleton {
    animation: skeleton-pulse 1.5s ease-in-out infinite;
}

.quote-skeleton .quote-text {
    background: linear-gradient(90deg,
        rgba(255, 255, 255, 0.05) 25%,
        rgba(255, 255, 255, 0.1) 50%,
        rgba(255, 255, 255, 0.05) 75%);
    background-size: 200% 100%;
    animation: skeleton-shimmer 1.5s infinite;
    border-radius: 8px;
    color: transparent !important;
    min-height: 1.4em;
}

@keyframes skeleton-pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.7; }
}

@keyframes skeleton-shimmer {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

/* Touch feedback for buttons */
.audio-btn:active,
.play-btn:active,
.stats-btn:active,
.copy-btn:active,
.twitter-btn:active,
.next-btn:active,
.search-submit:active {
    transform: scale(0.95);
}

.next-mode-link:active {
    transform: scale(0.98);
}

/* Better focus states for accessibility */
.search-input:focus-visible,
.audio-btn:focus-visible,
.stats-btn:focus-visible,
.copy-btn:focus-visible,
.twitter-btn:focus-visible {
    outline: 2px solid var(--primary-gold);
    outline-offset: 2px;
}

/* Responsive Styles */
@media (max-width: 768px) {
    .quote-container {
        padding: 25px 30px;
    }

    .quote-marks {
        font-size: 3rem;
    }

    .quote-text {
        font-size: 1.2rem;
    }

    .game-title {
        font-size: 1.1rem;
    }

    .quote-panel .search-container {
        max-width: 100%;
    }

    .guess-card {
        padding: 10px 15px;
    }

    .guess-icon {
        width: 40px;
        height: 40px;
    }

    .guess-name {
        font-size: 1rem;
    }

    .gg-text {
        font-size: 2rem;
    }

    .champion-result .champion-icon {
        width: 60px;
        height: 60px;
    }

    .result-text .champion-name {
        font-size: 1.4rem;
    }

    .countdown-digit {
        width: 32px;
        height: 44px;
        font-size: 1.5rem;
    }

    .countdown-separator {
        font-size: 1.5rem;
    }

    .countdown-digit-group {
        gap: 4px;
    }

    .countdown-display {
        gap: 8px;
    }

    .endless-stats-bar {
        gap: 15px;
    }

    .endless-stat-value {
        font-size: 1.2rem;
    }

    .poro-mascot {
        width: 35px;
        height: 35px;
    }

    .quote-panel .victory-panel {
        padding: 20px 15px;
    }

    .victory-actions {
        margin-bottom: 20px;
    }

    .next-champion {
        margin-bottom: 15px;
    }

    .next-mode-suggestion {
        padding-top: 12px;
    }

    .next-mode-link {
        padding: 10px 16px;
        width: 100%;
        justify-content: center;
    }
}

@media (max-width: 480px) {
    .people-counter {
        font-size: 0.8rem;
        padding: 8px 15px;
    }

    .quote-container {
        padding: 20px 20px;
    }

    .quote-text {
        font-size: 1.05rem;
        padding: 0 10px;
        line-height: 1.5;
    }

    .quote-marks {
        font-size: 2.5rem;
    }

    .quote-open {
        top: 5px;
        left: 10px;
    }

    .quote-close {
        bottom: 5px;
        right: 10px;
    }

    .victory-audio-player {
        flex-wrap: wrap;
        gap: 10px;
        padding: 12px;
    }

    .play-btn {
        width: 40px;
        height: 40px;
    }

    .audio-label {
        font-size: 0.85rem;
    }

    .audio-progress {
        width: 100%;
        order: 3;
    }

    .share-actions {
        flex-direction: column;
        gap: 10px;
    }

    .copy-btn,
    .twitter-btn {
        justify-content: center;
        padding: 12px 20px;
    }

    .countdown-digit {
        width: 28px;
        height: 40px;
        font-size: 1.3rem;
    }

    .countdown-separator {
        font-size: 1.3rem;
    }

    .gg-text {
        font-size: 1.6rem;
    }

    .rank-text,
    .tries-text {
        font-size: 0.9rem;
    }

    .result-text .champion-name {
        font-size: 1.2rem;
    }

    .champion-result .champion-icon {
        width: 50px;
        height: 50px;
    }

    .stats-btn {
        padding: 10px 20px;
        font-size: 0.9rem;
    }

    .next-mode-icon {
        width: 36px;
        height: 36px;
    }

    .next-mode-name {
        font-size: 0.9rem;
    }

    .next-mode-desc {
        font-size: 0.75rem;
    }
}
