/* AI Tool Finder - Quiz Styles */

.aitf-container {
    max-width: 800px;
    margin: 0 auto;
    padding: 1.5rem 1rem;
    font-family: Raleway, Arial, Helvetica, sans-serif;
}

/* Progress Bar */
.aitf-progress {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 2rem;
}

.aitf-progress-bar {
    flex: 1;
    height: 6px;
    background: #e2e8f0;
    border-radius: 3px;
    overflow: hidden;
}

.aitf-progress-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--primary-color, #6B46C1), var(--accent-color, #00D9FF));
    border-radius: 3px;
    transition: width 0.4s ease;
}

.aitf-progress-text {
    font-size: 0.85rem;
    color: #718096;
    white-space: nowrap;
    font-weight: 600;
}

/* Welcome Screen */
.aitf-welcome {
    text-align: center;
    padding: 2rem 0;
}

.aitf-welcome h2 {
    font-family: Quicksand, Tahoma, Arial, sans-serif;
    font-size: 1.8rem;
    color: #2d3748;
    margin-bottom: 0.75rem;
}

.aitf-welcome p {
    font-size: 1.05rem;
    color: #718096;
    margin-bottom: 2rem;
    line-height: 1.6;
}

.aitf-welcome-features {
    display: flex;
    justify-content: center;
    gap: 2rem;
    margin-bottom: 2rem;
    flex-wrap: wrap;
}

.aitf-welcome-feature {
    text-align: center;
    flex: 0 1 140px;
}

.aitf-welcome-feature .aitf-feature-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    border-radius: 12px;
    margin: 0 auto 0.5rem;
    font-size: 1.1rem;
    font-weight: 800;
    font-family: Quicksand, Tahoma, Arial, sans-serif;
    color: #fff;
}

.aitf-welcome-feature span {
    display: block;
    font-size: 0.85rem;
    color: #4a5568;
}

/* Step */
.aitf-step {
    animation: aitf-fadeIn 0.3s ease;
}

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

.aitf-step h2 {
    font-family: Quicksand, Tahoma, Arial, sans-serif;
    font-size: 1.4rem;
    color: #2d3748;
    margin-bottom: 1.5rem;
    text-align: center;
}

/* Option Cards */
.aitf-options {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 1rem;
    margin-bottom: 2rem;
}

.aitf-option {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 1rem 1.25rem;
    border: 2px solid #e2e8f0;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.2s ease;
    background: #fff;
    min-height: 60px;
}

.aitf-option:hover {
    border-color: var(--primary-color, #6B46C1);
    box-shadow: 0 2px 8px rgba(107, 70, 193, 0.15);
}

.aitf-option.selected {
    border-color: var(--primary-color, #6B46C1);
    background: linear-gradient(135deg, rgba(107, 70, 193, 0.06), rgba(0, 217, 255, 0.06));
    box-shadow: 0 2px 12px rgba(107, 70, 193, 0.2);
}

.aitf-option-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    width: 36px;
    height: 36px;
    border-radius: 8px;
    font-size: 0.95rem;
    font-weight: 800;
    font-family: Quicksand, Tahoma, Arial, sans-serif;
    color: #fff;
}

.aitf-option-label {
    font-size: 0.95rem;
    font-weight: 600;
    color: #2d3748;
    line-height: 1.3;
}

/* Navigation */
.aitf-nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 1.5rem;
}

.aitf-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1.75rem;
    border: none;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    font-family: Quicksand, Tahoma, Arial, sans-serif;
}

.aitf-btn:disabled {
    opacity: 0.4;
    cursor: not-allowed;
}

.aitf-btn-back {
    background: #edf2f7;
    color: #4a5568;
}

.aitf-btn-back:hover:not(:disabled) {
    background: #e2e8f0;
}

.aitf-btn-next {
    background: var(--primary-color, #6B46C1);
    color: #fff;
}

.aitf-btn-next:hover:not(:disabled) {
    filter: brightness(1.1);
    box-shadow: 0 4px 12px rgba(107, 70, 193, 0.3);
}

.aitf-btn-start {
    background: linear-gradient(135deg, var(--primary-color, #6B46C1), var(--accent-color, #00D9FF));
    color: #fff;
    padding: 1rem 2.5rem;
    font-size: 1.1rem;
    border-radius: 12px;
}

.aitf-btn-start:hover {
    filter: brightness(1.05);
    box-shadow: 0 6px 20px rgba(107, 70, 193, 0.35);
    transform: translateY(-1px);
}

/* Results */
.aitf-results {
    animation: aitf-fadeIn 0.4s ease;
}

.aitf-results h2 {
    font-family: Quicksand, Tahoma, Arial, sans-serif;
    font-size: 1.6rem;
    color: #2d3748;
    text-align: center;
    margin-bottom: 0.5rem;
}

.aitf-results-subtitle {
    text-align: center;
    color: #718096;
    margin-bottom: 2rem;
    font-size: 0.95rem;
}

/* Result Card */
.aitf-result-card {
    border: 2px solid #e2e8f0;
    border-radius: 16px;
    padding: 1.5rem;
    margin-bottom: 1.25rem;
    background: #fff;
    transition: all 0.2s ease;
}

.aitf-result-card:hover {
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08);
}

.aitf-result-card.aitf-top-pick {
    border-color: var(--primary-color, #6B46C1);
    background: linear-gradient(135deg, rgba(107, 70, 193, 0.03), rgba(0, 217, 255, 0.03));
    box-shadow: 0 4px 20px rgba(107, 70, 193, 0.12);
}

.aitf-result-header {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1rem;
}

.aitf-result-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    width: 44px;
    height: 44px;
    border-radius: 10px;
    font-size: 1.1rem;
    font-weight: 800;
    font-family: Quicksand, Tahoma, Arial, sans-serif;
    color: #fff;
}

.aitf-result-info {
    flex: 1;
}

.aitf-result-name {
    font-family: Quicksand, Tahoma, Arial, sans-serif;
    font-size: 1.2rem;
    font-weight: 700;
    color: #2d3748;
    margin: 0;
}

.aitf-result-badge {
    display: inline-block;
    padding: 0.2rem 0.6rem;
    border-radius: 20px;
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-left: 0.5rem;
    vertical-align: middle;
}

.aitf-badge-top {
    background: linear-gradient(135deg, var(--primary-color, #6B46C1), var(--accent-color, #00D9FF));
    color: #fff;
}

.aitf-badge-runner {
    background: #edf2f7;
    color: #4a5568;
}

.aitf-result-category {
    font-size: 0.8rem;
    color: #718096;
    margin-top: 0.15rem;
}

.aitf-result-score {
    flex-shrink: 0;
    text-align: center;
}

.aitf-score-value {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary-color, #6B46C1);
}

.aitf-score-label {
    font-size: 0.7rem;
    color: #a0aec0;
    text-transform: uppercase;
}

.aitf-result-desc {
    color: #4a5568;
    font-size: 0.95rem;
    line-height: 1.6;
    margin-bottom: 1rem;
}

.aitf-result-features {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.aitf-feature-tag {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    background: #f7fafc;
    border: 1px solid #e2e8f0;
    border-radius: 20px;
    font-size: 0.8rem;
    color: #4a5568;
}

.aitf-result-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 0.75rem;
}

.aitf-result-pricing {
    font-size: 0.9rem;
    color: #718096;
    font-weight: 600;
}

.aitf-result-link,
.aitf-result-link:visited {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.5rem 1.25rem;
    background: var(--primary-color, #6B46C1);
    color: #fff !important;
    text-decoration: none !important;
    border-radius: 8px;
    font-size: 0.9rem;
    font-weight: 600;
    transition: all 0.2s ease;
}

.aitf-result-link:hover,
.aitf-result-link:focus {
    filter: brightness(1.1);
    box-shadow: 0 3px 10px rgba(107, 70, 193, 0.25);
    color: #fff !important;
    text-decoration: none !important;
}

/* Results footer */
.aitf-results-footer {
    text-align: center;
    margin-top: 2rem;
    padding-top: 1.5rem;
    border-top: 1px solid #e2e8f0;
}

.aitf-btn-restart {
    background: #edf2f7;
    color: #4a5568;
    padding: 0.75rem 2rem;
}

.aitf-btn-restart:hover {
    background: #e2e8f0;
}

/* ── Static Catalog (server-rendered for SEO) ──────────────── */

.aitf-static-catalog {
    max-width: 800px;
    margin: 2rem auto 0;
    padding: 0 1rem;
    font-family: Raleway, Arial, Helvetica, sans-serif;
}

.aitf-static-catalog h2 {
    font-family: Quicksand, Tahoma, Arial, sans-serif;
    font-size: 1.6rem;
    color: #2d3748;
    text-align: center;
    margin-bottom: 0.5rem;
}

.aitf-static-catalog > p {
    text-align: center;
    color: #718096;
    margin-bottom: 2rem;
    font-size: 0.95rem;
}

.aitf-static-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
    gap: 1.25rem;
}

.aitf-static-tool {
    border: 2px solid #e2e8f0;
    border-radius: 16px;
    padding: 1.25rem;
    background: #fff;
    transition: box-shadow 0.2s ease;
}

.aitf-static-tool:hover {
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08);
}

.aitf-static-tool-header {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 0.75rem;
}

.aitf-static-tool-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    width: 40px;
    height: 40px;
    border-radius: 10px;
    font-size: 1rem;
    font-weight: 800;
    font-family: Quicksand, Tahoma, Arial, sans-serif;
    color: #fff;
}

.aitf-static-tool-name {
    font-family: Quicksand, Tahoma, Arial, sans-serif;
    font-size: 1.1rem;
    font-weight: 700;
    color: #2d3748;
    margin: 0;
}

.aitf-static-tool-cat {
    font-size: 0.75rem;
    color: #718096;
}

.aitf-static-tool-desc {
    color: #4a5568;
    font-size: 0.9rem;
    line-height: 1.5;
    margin-bottom: 0.75rem;
}

.aitf-static-tool-features {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
    margin-bottom: 0.75rem;
}

.aitf-static-tool-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.aitf-static-tool-price {
    font-size: 0.85rem;
    color: #718096;
    font-weight: 600;
}

/* Mobile responsive */
@media (max-width: 600px) {
    .aitf-container {
        padding: 1rem 0.75rem;
    }

    .aitf-options {
        grid-template-columns: 1fr;
    }

    .aitf-welcome h2 {
        font-size: 1.4rem;
    }

    .aitf-welcome-features {
        gap: 1rem;
    }

    .aitf-result-header {
        flex-wrap: wrap;
    }

    .aitf-result-score {
        margin-left: auto;
    }

    .aitf-result-meta {
        flex-direction: column;
        align-items: flex-start;
    }

    .aitf-result-link {
        width: 100%;
        justify-content: center;
    }

    .aitf-static-grid {
        grid-template-columns: 1fr;
    }

    .aitf-static-tool-meta {
        flex-direction: column;
        align-items: flex-start;
    }
}
