/* =============================================================================
   Find My Saint — discovery wizard
   ============================================================================= */

/* ── Hero ──────────────────────────────────────────────────────────────────── */

.fms-hero {
    position: relative;
    padding: 5rem 0 4rem;
    text-align: center;
    overflow: hidden;
    background: var(--accent-secondary, #2A3F3F);
}

.fms-hero-content {
    position: relative;
    z-index: 2;
}

.fms-hero-inner {
    max-width: 640px;
    margin: 0 auto;
}

.fms-hero-title {
    font-family: var(--font-primary);
    font-size: clamp(2rem, 5vw, 3.2rem);
    color: var(--text-light, #FFFFF0);
    letter-spacing: 0.04em;
    text-transform: uppercase;
    margin: 0 0 1rem;
    line-height: 1.15;
}

.fms-hero-description {
    font-family: var(--font-body);
    font-size: 1.1rem;
    color: rgba(255, 255, 240, 0.8);
    line-height: 1.7;
    margin: 0;
}

/* ── Wizard section ─────────────────────────────────────────────────────────── */

.fms-wizard-section {
    padding: 3rem 0 5rem;
    background: var(--primary-dark, #1F2E2E);
    min-height: 60vh;
}

/* ── Progress indicator ─────────────────────────────────────────────────────── */

.fms-progress {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0;
    margin-bottom: 3rem;
}

.fms-progress-step {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.4rem;
}

.fms-progress-dot {
    width: 14px;
    height: 14px;
    border-radius: 50%;
    border: 2px solid rgba(255, 255, 240, 0.3);
    background: transparent;
    transition: background 0.3s, border-color 0.3s;
    display: block;
}

.fms-progress-step.active .fms-progress-dot {
    background: var(--tertiary-color, #C9A053);
    border-color: var(--tertiary-color, #C9A053);
    box-shadow: 0 0 8px rgba(201, 160, 83, 0.5);
}

.fms-progress-step.completed .fms-progress-dot {
    background: rgba(201, 160, 83, 0.5);
    border-color: rgba(201, 160, 83, 0.5);
}

.fms-progress-label {
    font-family: var(--font-body);
    font-size: 0.72rem;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: rgba(255, 255, 240, 0.45);
    transition: color 0.3s;
    white-space: nowrap;
}

.fms-progress-step.active .fms-progress-label {
    color: var(--tertiary-color, #C9A053);
}

.fms-progress-step.completed .fms-progress-label {
    color: rgba(201, 160, 83, 0.6);
}

.fms-progress-line {
    width: 48px;
    height: 2px;
    background: rgba(255, 255, 240, 0.15);
    margin: 0 0.5rem;
    margin-bottom: 1.2rem;
    flex-shrink: 0;
}

/* ── Step ───────────────────────────────────────────────────────────────────── */

.fms-step {
    max-width: 860px;
    margin: 0 auto;
    animation: fms-fadein 0.35s ease;
}

.fms-step--hidden {
    display: none !important;
}

@keyframes fms-fadein {
    from { opacity: 0; transform: translateY(10px); }
    to   { opacity: 1; transform: translateY(0); }
}

.fms-step-header {
    text-align: center;
    margin-bottom: 2.5rem;
}

.fms-step-title {
    font-family: var(--font-primary);
    font-size: clamp(1.4rem, 3vw, 2rem);
    color: var(--text-light, #FFFFF0);
    margin: 0 0 0.6rem;
    letter-spacing: 0.02em;
}

.fms-step-hint {
    font-family: var(--font-body);
    font-size: 0.95rem;
    color: rgba(255, 255, 240, 0.55);
    margin: 0;
}

/* ── Choice grids ───────────────────────────────────────────────────────────── */

.fms-choices {
    display: grid;
    gap: 0.75rem;
    margin-bottom: 2.5rem;
}

.fms-choices--multi {
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
}

.fms-choices--single {
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
}

/* ── Choice button ──────────────────────────────────────────────────────────── */

.fms-choice {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 1.1rem 0.75rem;
    background: rgba(255, 255, 240, 0.04);
    border: 1.5px solid rgba(255, 255, 240, 0.12);
    border-radius: var(--radius-md, 8px);
    cursor: pointer;
    text-align: center;
    transition: background 0.25s, border-color 0.25s, transform 0.2s;
    color: var(--text-light, #FFFFF0);
    font-family: var(--font-body);
}

.fms-choice:hover,
.fms-choice:focus-visible {
    background: rgba(201, 160, 83, 0.08);
    border-color: rgba(201, 160, 83, 0.4);
    outline: none;
    transform: translateY(-2px);
}

.fms-choice--selected {
    background: rgba(201, 160, 83, 0.14) !important;
    border-color: var(--tertiary-color, #C9A053) !important;
    color: var(--tertiary-color, #C9A053);
}

.fms-choice--selected .fms-choice-icon {
    color: var(--tertiary-color, #C9A053);
}

.fms-choice-icon {
    font-size: 1.4rem;
    color: rgba(255, 255, 240, 0.5);
    transition: color 0.25s;
    line-height: 1;
}

.fms-choice-label {
    font-size: 0.9rem;
    font-weight: 600;
    letter-spacing: 0.01em;
    line-height: 1.3;
}

/* Choices with description text (types / regions) */
.fms-choice--described {
    align-items: flex-start;
    text-align: left;
    gap: 0.3rem;
    padding: 1rem 1rem;
}

.fms-choice-desc {
    font-size: 0.8rem;
    color: rgba(255, 255, 240, 0.45);
    line-height: 1.4;
    font-weight: 400;
}

.fms-choice--selected .fms-choice-desc {
    color: rgba(201, 160, 83, 0.7);
}

/* ── Children mode toggle ───────────────────────────────────────────────────── */

.fms-child-mode-toggle {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    cursor: pointer;
    padding: 1rem 1.25rem;
    background: rgba(255, 255, 240, 0.03);
    border: 1.5px solid rgba(255, 255, 240, 0.1);
    border-radius: var(--radius-md, 8px);
    margin-bottom: 2rem;
    transition: background 0.25s, border-color 0.25s;
    max-width: 420px;
}

.fms-child-mode-toggle:hover {
    background: rgba(255, 255, 240, 0.06);
    border-color: rgba(255, 255, 240, 0.2);
}

.fms-child-mode-toggle input[type="checkbox"] {
    width: 18px;
    height: 18px;
    accent-color: var(--tertiary-color, #C9A053);
    cursor: pointer;
    flex-shrink: 0;
}

.fms-child-mode-icon {
    font-size: 1.1rem;
    color: rgba(255, 255, 240, 0.5);
}

.fms-child-mode-toggle span:last-child {
    font-family: var(--font-body);
    font-size: 0.9rem;
    color: rgba(255, 255, 240, 0.7);
    line-height: 1.4;
}

/* ── Step footer ────────────────────────────────────────────────────────────── */

.fms-step-footer {
    display: flex;
    align-items: center;
    gap: 1rem;
    justify-content: flex-end;
    padding-top: 0.5rem;
}

.fms-next-btn,
.fms-submit-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1.75rem;
    background: var(--tertiary-color, #C9A053);
    color: #1F2E2E;
    font-family: var(--font-body);
    font-size: 0.95rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    border: none;
    border-radius: 50px;
    cursor: pointer;
    transition: background 0.25s, transform 0.2s, opacity 0.25s;
}

.fms-next-btn:hover,
.fms-submit-btn:hover {
    background: #d4aa60;
    transform: translateY(-1px);
}

.fms-next-btn:disabled {
    opacity: 0.35;
    cursor: not-allowed;
    transform: none;
}

.fms-back-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.75rem 1.25rem;
    background: transparent;
    color: rgba(255, 255, 240, 0.5);
    font-family: var(--font-body);
    font-size: 0.9rem;
    border: 1px solid rgba(255, 255, 240, 0.15);
    border-radius: 50px;
    cursor: pointer;
    transition: color 0.2s, border-color 0.2s;
}

.fms-back-btn:hover {
    color: rgba(255, 255, 240, 0.85);
    border-color: rgba(255, 255, 240, 0.35);
}

/* ── Loading ────────────────────────────────────────────────────────────────── */

.fms-loading {
    max-width: 860px;
    margin: 0 auto;
    text-align: center;
    padding: 4rem 1rem;
}

.fms-loading-inner p {
    font-family: var(--font-body);
    font-size: 1rem;
    color: rgba(255, 255, 240, 0.6);
    margin: 1rem 0 0;
}

.fms-loading-cross {
    font-size: 2.5rem;
    color: var(--tertiary-color, #C9A053);
    animation: fms-pulse 1.6s ease-in-out infinite;
    display: block;
}

@keyframes fms-pulse {
    0%, 100% { opacity: 0.4; transform: scale(0.95); }
    50%       { opacity: 1;   transform: scale(1.05); }
}

/* ── Results header ─────────────────────────────────────────────────────────── */

.fms-results {
    max-width: 960px;
    margin: 0 auto;
    animation: fms-fadein 0.4s ease;
}

.fms-results-header {
    text-align: center;
    margin-bottom: 2.5rem;
}

.fms-results-title {
    font-family: var(--font-primary);
    font-size: clamp(1.5rem, 3.5vw, 2.4rem);
    color: var(--text-light, #FFFFF0);
    margin: 0 0 0.5rem;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.fms-results-sub {
    font-family: var(--font-body);
    font-size: 1rem;
    color: rgba(255, 255, 240, 0.55);
    margin: 0;
}

/* ── Primary result ─────────────────────────────────────────────────────────── */

.fms-result-primary {
    display: grid;
    grid-template-columns: 280px 1fr;
    gap: 2.5rem;
    background: rgba(255, 255, 240, 0.04);
    border: 1px solid rgba(201, 160, 83, 0.25);
    border-radius: var(--radius-lg, 12px);
    overflow: hidden;
    margin-bottom: 3rem;
}

.fms-result-image-wrap {
    position: relative;
    min-height: 320px;
}

.fms-result-image-wrap img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.fms-result-feast-badge {
    position: absolute;
    bottom: 0.75rem;
    left: 0.75rem;
    background: rgba(31, 46, 46, 0.85);
    color: var(--tertiary-color, #C9A053);
    font-family: var(--font-body);
    font-size: 0.72rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    padding: 0.3rem 0.65rem;
    border-radius: 4px;
    backdrop-filter: blur(4px);
}

.fms-result-body {
    padding: 2rem 2rem 2rem 0;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
}

.fms-result-eyebrow {
    font-family: var(--font-body);
    font-size: 0.72rem;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--tertiary-color, #C9A053);
    display: block;
    margin-bottom: 0.4rem;
}

.fms-result-eyebrow--sm {
    font-size: 0.65rem;
}

.fms-result-name {
    font-family: var(--font-primary);
    font-size: clamp(1.4rem, 3vw, 2rem);
    color: var(--text-light, #FFFFF0);
    margin: 0 0 0.5rem;
    line-height: 1.2;
}

.fms-result-location {
    font-family: var(--font-body);
    font-size: 0.85rem;
    color: rgba(255, 255, 240, 0.5);
    margin: 0 0 1rem;
    display: flex;
    align-items: center;
    gap: 0.35rem;
}

.fms-result-desc {
    font-family: var(--font-body);
    font-size: 0.95rem;
    line-height: 1.7;
    color: rgba(255, 255, 240, 0.8);
    margin: 0 0 1rem;
}

.fms-result-why {
    font-family: var(--font-body);
    font-size: 0.9rem;
    line-height: 1.6;
    color: rgba(201, 160, 83, 0.85);
    margin: 0 0 1.25rem;
    padding-left: 0.75rem;
    border-left: 2px solid rgba(201, 160, 83, 0.35);
}

.fms-result-why em {
    font-style: normal;
}

.fms-result-places {
    margin-bottom: 1.5rem;
}

.fms-result-places h4 {
    font-family: var(--font-body);
    font-size: 0.72rem;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: rgba(255, 255, 240, 0.4);
    margin: 0 0 0.5rem;
}

.fms-result-places ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.fms-result-places li {
    font-family: var(--font-body);
    font-size: 0.85rem;
    color: rgba(255, 255, 240, 0.65);
    padding: 0.2rem 0;
    padding-left: 1rem;
    position: relative;
}

.fms-result-places li::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0.55em;
    width: 5px;
    height: 5px;
    border-radius: 50%;
    background: rgba(201, 160, 83, 0.5);
}

/* ── Action buttons ─────────────────────────────────────────────────────────── */

.fms-result-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-top: auto;
    padding-top: 0.5rem;
}

.fms-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.65rem 1.25rem;
    border-radius: 50px;
    font-family: var(--font-body);
    font-size: 0.88rem;
    font-weight: 600;
    cursor: pointer;
    text-decoration: none;
    border: none;
    transition: background 0.25s, transform 0.2s, color 0.25s;
}

.fms-btn--primary {
    background: var(--accent-primary, #895348);
    color: var(--text-light, #FFFFF0);
}

.fms-btn--primary:hover {
    background: #9e6259;
    transform: translateY(-1px);
    color: var(--text-light, #FFFFF0);
}

.fms-btn--secondary {
    background: rgba(255, 255, 240, 0.08);
    color: var(--text-light, #FFFFF0);
    border: 1px solid rgba(255, 255, 240, 0.2);
}

.fms-btn--secondary:hover {
    background: rgba(255, 255, 240, 0.12);
    transform: translateY(-1px);
}

.fms-btn--ghost {
    background: transparent;
    color: rgba(255, 255, 240, 0.55);
    border: 1px solid rgba(255, 255, 240, 0.15);
}

.fms-btn--ghost:hover {
    color: rgba(255, 255, 240, 0.85);
    border-color: rgba(255, 255, 240, 0.35);
}

.fms-btn--sm {
    padding: 0.5rem 1rem;
    font-size: 0.8rem;
}

/* ── Secondary results grid ─────────────────────────────────────────────────── */

.fms-secondary {
    margin-bottom: 3rem;
}

.fms-secondary-title {
    font-family: var(--font-primary);
    font-size: 1.1rem;
    color: rgba(255, 255, 240, 0.6);
    letter-spacing: 0.06em;
    text-transform: uppercase;
    margin-bottom: 1.25rem;
}

.fms-secondary-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 1.25rem;
}

.fms-result-card {
    background: rgba(255, 255, 240, 0.04);
    border: 1px solid rgba(255, 255, 240, 0.1);
    border-radius: var(--radius-md, 8px);
    overflow: hidden;
    transition: border-color 0.25s, transform 0.2s;
}

.fms-result-card:hover {
    border-color: rgba(201, 160, 83, 0.3);
    transform: translateY(-2px);
}

.fms-result-card-img {
    height: 180px;
    overflow: hidden;
}

.fms-result-card-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.fms-result-card-body {
    padding: 1.1rem;
}

.fms-result-card-name {
    font-family: var(--font-primary);
    font-size: 1rem;
    color: var(--text-light, #FFFFF0);
    margin: 0.25rem 0 0.3rem;
    line-height: 1.25;
}

.fms-result-card-location {
    font-family: var(--font-body);
    font-size: 0.75rem;
    color: rgba(255, 255, 240, 0.4);
    margin: 0 0 0.5rem;
    display: flex;
    align-items: center;
    gap: 0.3rem;
}

.fms-result-card-why {
    font-family: var(--font-body);
    font-size: 0.8rem;
    color: rgba(255, 255, 240, 0.6);
    margin: 0 0 0.85rem;
    line-height: 1.5;
}

.fms-result-card-actions {
    display: flex;
    gap: 0.5rem;
    align-items: center;
}

/* ── Restart / empty ─────────────────────────────────────────────────────────── */

.fms-restart-row {
    text-align: center;
    padding-top: 1rem;
}

.fms-restart-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    background: transparent;
    color: rgba(255, 255, 240, 0.45);
    border: 1px solid rgba(255, 255, 240, 0.15);
    border-radius: 50px;
    padding: 0.6rem 1.25rem;
    font-family: var(--font-body);
    font-size: 0.85rem;
    cursor: pointer;
    transition: color 0.2s, border-color 0.2s;
}

.fms-restart-btn:hover {
    color: rgba(255, 255, 240, 0.8);
    border-color: rgba(255, 255, 240, 0.3);
}

.fms-empty {
    text-align: center;
    padding: 3rem 1rem;
}

.fms-empty p {
    font-family: var(--font-body);
    color: rgba(255, 255, 240, 0.55);
    margin-bottom: 1.5rem;
}

/* ── Saints page CTA block ──────────────────────────────────────────────────── */

.fms-cta-section {
    padding: 3.5rem 0;
    background: var(--accent-secondary, #2A3F3F);
    position: relative;
    overflow: hidden;
}

.fms-cta-section::before {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(ellipse at 50% 50%, rgba(201, 160, 83, 0.07) 0%, transparent 70%);
    pointer-events: none;
}

.fms-cta-inner {
    position: relative;
    z-index: 1;
    max-width: 680px;
    margin: 0 auto;
    text-align: center;
    padding: 0 1.5rem;
}

.fms-cta-eyebrow {
    display: block;
    font-family: var(--font-body);
    font-size: 0.7rem;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: var(--tertiary-color, #C9A053);
    margin-bottom: 0.75rem;
}

.fms-cta-title {
    font-family: var(--font-primary);
    font-size: clamp(1.5rem, 3.5vw, 2.2rem);
    color: var(--text-light, #FFFFF0);
    margin: 0 0 0.9rem;
    letter-spacing: 0.03em;
}

.fms-cta-desc {
    font-family: var(--font-body);
    font-size: 1rem;
    color: rgba(255, 255, 240, 0.65);
    line-height: 1.7;
    margin: 0 0 1.75rem;
}

.fms-cta-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.85rem 2rem;
    background: var(--tertiary-color, #C9A053);
    color: #1F2E2E;
    font-family: var(--font-body);
    font-size: 0.95rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    border-radius: 50px;
    text-decoration: none;
    transition: background 0.25s, transform 0.2s;
}

.fms-cta-btn:hover {
    background: #d4aa60;
    transform: translateY(-2px);
    color: #1F2E2E;
}

/* ── Responsive ─────────────────────────────────────────────────────────────── */

@media (max-width: 768px) {
    .fms-result-primary {
        grid-template-columns: 1fr;
    }

    .fms-result-image-wrap {
        min-height: 240px;
        max-height: 300px;
    }

    .fms-result-body {
        padding: 1.5rem;
    }

    .fms-choices--multi {
        grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
    }

    .fms-choices--single {
        grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    }

    .fms-progress-line {
        width: 28px;
    }

    .fms-secondary-grid {
        grid-template-columns: 1fr 1fr;
    }
}

@media (max-width: 480px) {
    .fms-choices--multi {
        grid-template-columns: repeat(2, 1fr);
    }

    .fms-choices--single {
        grid-template-columns: 1fr 1fr;
    }

    .fms-secondary-grid {
        grid-template-columns: 1fr;
    }

    .fms-result-actions {
        flex-direction: column;
    }

    .fms-btn {
        justify-content: center;
    }
}

/* ── Reduced motion ─────────────────────────────────────────────────────────── */

@media (prefers-reduced-motion: reduce) {
    .fms-choice,
    .fms-next-btn,
    .fms-submit-btn,
    .fms-back-btn,
    .fms-btn,
    .fms-result-card,
    .fms-cta-btn {
        transition: none;
        transform: none !important;
    }

    @keyframes fms-fadein  { from { opacity: 1; } }
    @keyframes fms-pulse   { from { opacity: 1; } }
}
