/*
  quiz.css — "Find Your Plushie" pop-up
  ===================================================================
  One shared stylesheet for the quiz modal used on every page. This
  replaces three separate, overlapping sets of quiz styles that had
  built up in styles.css from earlier redesign passes (a dark neon
  theme, a plain white theme, and a soft-pink theme all stacked on
  top of each other) — they've been removed in favor of this single
  version, kept in the same soft blush/cream/gold language as the
  rest of the site.
*/

.quiz-modal {
    position: fixed;
    inset: 0;
    z-index: 10000;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 1rem;
    background: rgba(42, 34, 40, 0.55);
    backdrop-filter: blur(10px);
    opacity: 0;
    transition: opacity 0.25s ease;
}

.quiz-modal.active {
    display: flex;
    opacity: 1;
}

.quiz-content {
    position: relative;
    width: min(680px, 100%);
    max-height: min(88vh, 900px);
    overflow-y: auto;
    padding: 2.2rem;
    border-radius: 30px;
    background: linear-gradient(180deg, #fffdfb 0%, #fff5f8 100%);
    border: 1px solid rgba(255, 200, 215, 0.65);
    box-shadow: 0 30px 80px rgba(196, 77, 114, 0.24);
    transform: translateY(16px) scale(0.98);
    transition: transform 0.28s ease;
}

.quiz-modal.active .quiz-content {
    transform: translateY(0) scale(1);
}

.quiz-close-btn {
    position: absolute;
    top: 1rem;
    right: 1rem;
    z-index: 2;
    width: 2.75rem;
    height: 2.75rem;
    border: 1px solid rgba(255, 200, 215, 0.65);
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.95);
    color: #c44d72;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 10px 24px rgba(210, 140, 165, 0.16);
    transition: transform 0.2s ease, background 0.2s ease;
}

.quiz-close-btn:hover {
    background: #fff;
    transform: rotate(90deg);
}

.quiz-screen {
    text-align: left;
}

.quiz-header h2,
.quiz-screen h2 {
    font-family: var(--font-display, 'Fredoka', sans-serif);
    font-size: clamp(1.5rem, 3.4vw, 2rem);
    color: #2a2228;
    margin: 0 0 0.6rem;
    line-height: 1.15;
}

.quiz-header p,
.quiz-screen p {
    color: #6b5f68;
    font-size: 0.98rem;
    line-height: 1.65;
    margin: 0 0 1.25rem;
    max-width: 48ch;
}

/* Intro screen */
.quiz-features {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 0.75rem;
    margin: 0 0 1.6rem;
}

.quiz-features .feature {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    justify-content: center;
    gap: 0.45rem;
    min-height: 88px;
    padding: 0.9rem;
    border-radius: 20px;
    background: rgba(255, 255, 255, 0.85);
    border: 1px solid rgba(255, 200, 215, 0.65);
    box-shadow: 0 14px 28px rgba(210, 140, 165, 0.1);
}

.quiz-features .feature i {
    color: #c44d72;
    font-size: 1.1rem;
}

.quiz-features .feature span {
    color: #4a3f47;
    font-size: 0.82rem;
    line-height: 1.4;
}

.start-quiz-btn,
.shop-now-btn {
    background: linear-gradient(135deg, #ff9bb5 0%, #e86b93 100%);
    color: #fff;
    box-shadow: 0 16px 32px rgba(232, 107, 147, 0.28);
}

.start-quiz-btn,
.shop-now-btn,
.retry-btn {
    border: 0;
    border-radius: 999px;
    min-height: 3.1rem;
    padding: 0.85rem 1.4rem;
    font-family: inherit;
    font-weight: 700;
    font-size: 0.95rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.6rem;
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.start-quiz-btn:hover,
.shop-now-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 20px 40px rgba(232, 107, 147, 0.36);
}

.retry-btn {
    background: #fff;
    color: #5a4c5a;
    border: 1px solid rgba(255, 200, 215, 0.65);
}

.retry-btn:hover {
    background: #fff8fb;
}

/* Question screen */
.quiz-header h3 {
    font-family: var(--font-display, 'Fredoka', sans-serif);
    font-size: 1.05rem;
    color: #4a3f47;
    margin: 0 0 0.7rem;
}

.progress-bar {
    height: 10px;
    border-radius: 999px;
    background: rgba(255, 200, 215, 0.4);
    overflow: hidden;
    margin-bottom: 1.5rem;
}

.progress {
    height: 100%;
    width: 0;
    border-radius: 999px;
    background: linear-gradient(135deg, #ff9bb5 0%, #e86b93 100%);
    transition: width 0.35s ease;
}

.question-container {
    opacity: 0;
    transform: translateY(10px);
    transition: opacity 0.3s ease, transform 0.3s ease;
}

.question-container.is-entering {
    opacity: 1;
    transform: translateY(0);
}

.question-container h3 {
    font-family: var(--font-display, 'Fredoka', sans-serif);
    font-size: 1.35rem;
    color: #2a2228;
    margin: 0 0 1.1rem;
    line-height: 1.3;
}

.options {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.option-btn {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 0.95rem 1.1rem;
    border-radius: 18px;
    border: 1px solid rgba(255, 200, 215, 0.65);
    background: rgba(255, 255, 255, 0.92);
    color: #3d313d;
    font-family: inherit;
    font-size: 0.95rem;
    text-align: left;
    cursor: pointer;
    box-shadow: 0 10px 22px rgba(210, 140, 165, 0.08);
    transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease, background 0.2s ease;
}

.option-btn:hover {
    background: #fff8fb;
    border-color: rgba(232, 120, 155, 0.6);
    transform: translateY(-2px);
    box-shadow: 0 14px 28px rgba(210, 140, 165, 0.16);
}

.option-btn i {
    color: #c44d72;
    flex-shrink: 0;
}

/* Result screen */
.result-container {
    animation: quiz-result-in 0.4s ease both;
}

@keyframes quiz-result-in {
    from { opacity: 0; transform: translateY(14px); }
    to { opacity: 1; transform: translateY(0); }
}

.quiz-results-grid {
    display: grid;
    gap: 1rem;
    margin-top: 1.25rem;
}

@media (min-width: 560px) {
    .quiz-results-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

.quiz-result-card {
    position: relative;
    padding: 1.1rem;
    border-radius: 22px;
    background: rgba(255, 255, 255, 0.95);
    border: 1px solid rgba(255, 200, 215, 0.65);
    box-shadow: 0 14px 30px rgba(210, 140, 165, 0.12);
    animation: quiz-card-in 0.45s ease both;
    animation-delay: var(--reveal-delay, 0ms);
}

@keyframes quiz-card-in {
    from { opacity: 0; transform: translateY(16px) scale(0.96); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}

.quiz-result-card.is-featured {
    border-color: rgba(232, 120, 155, 0.75);
    box-shadow: 0 20px 40px rgba(210, 140, 165, 0.2);
}

.quiz-result-badge {
    display: inline-flex;
    margin-bottom: 0.75rem;
    padding: 0.35rem 0.7rem;
    border-radius: 999px;
    background: rgba(255, 239, 245, 0.95);
    color: #bb597c;
    border: 1px solid rgba(255, 200, 215, 0.65);
    font-size: 0.68rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.quiz-result-card .result-image {
    width: 100%;
    height: 180px;
    object-fit: cover;
    border-radius: 16px;
    margin-bottom: 0.85rem;
    display: block;
}

.quiz-result-card .result-name {
    font-family: var(--font-display, 'Fredoka', sans-serif);
    font-size: 1.1rem;
    color: #2a2228;
    margin: 0 0 0.5rem;
}

.quiz-result-card .result-description {
    font-size: 0.82rem;
    line-height: 1.5;
    color: #6b5f68;
    margin: 0 0 0.75rem;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.result-traits {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
    margin: 0 0 0.75rem;
}

.trait {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.3rem 0.6rem;
    border-radius: 999px;
    background: #fff5f8;
    color: #b45177;
    border: 1px solid rgba(255, 200, 215, 0.65);
    font-size: 0.72rem;
}

.trait i {
    font-size: 0.68rem;
}

.result-price {
    margin: 0 0 0.85rem;
    color: #c44d72;
    font-size: 1rem;
}

.quiz-result-card-actions .shop-now-btn {
    width: 100%;
    min-height: 2.75rem;
    font-size: 0.85rem;
}

.result-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    justify-content: center;
    margin-top: 1.5rem;
}

@media (max-width: 560px) {
    .quiz-content {
        padding: 1.5rem;
    }

    .quiz-features {
        grid-template-columns: 1fr;
    }

    .result-actions .shop-now-btn,
    .result-actions .retry-btn {
        width: 100%;
    }
}

@media (prefers-reduced-motion: reduce) {
    .quiz-modal,
    .quiz-content,
    .question-container,
    .result-container,
    .quiz-result-card {
        transition: none;
        animation: none;
    }
}
