/* ===================================
   INTEREST DETECTOR - STYLES
   =================================== */

/* --- Header --- */
.interest-header {
    background: white;
    border-bottom: 2px solid rgba(0, 0, 0, 0.1);
    padding: 16px 20px;
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.header-content {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.back-btn {
    background: none;
    border: 2px solid rgba(0, 0, 0, 0.15);
    padding: 10px 20px;
    border-radius: 12px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    color: var(--color-text, #2D2D2D);
    font-size: 0.95rem;
}

.back-btn:hover {
    border-color: #00D9A3;
    color: #00D9A3;
    transform: translateY(-1px);
}

.header-content .logo {
    font-size: 1.4rem;
    font-weight: 900;
    background: linear-gradient(135deg, #00D9A3, #00B894);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.header-stats {
    font-size: 0.85rem;
    color: rgba(0, 0, 0, 0.5);
    font-weight: 600;
}

/* --- Main Container --- */
.interest-main {
    max-width: 1200px;
    margin: 0 auto;
    padding: 40px 20px;
}

/* --- Hero Section --- */
.interest-hero {
    text-align: center;
    margin-bottom: 60px;
}

.interest-hero h1 {
    font-size: 3rem;
    font-weight: 900;
    margin-bottom: 16px;
    background: linear-gradient(135deg, #00D9A3, #00B894);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.interest-hero .subtitle {
    font-size: 1.2rem;
    color: rgba(0, 0, 0, 0.6);
    max-width: 600px;
    margin: 0 auto;
}

.feature-pills {
    display: flex;
    gap: 16px;
    justify-content: center;
    flex-wrap: wrap;
    margin-top: 32px;
}

.feature-pill {
    background: white;
    padding: 12px 24px;
    border-radius: 30px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: 600;
    font-size: 0.95rem;
}

.pill-icon {
    font-size: 1.3rem;
}

/* --- Upload Section --- */
.upload-section {
    margin-bottom: 60px;
}

.upload-container {
    background: white;
    padding: 40px;
    border-radius: 20px;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.12);
}

.upload-container h2 {
    text-align: center;
    font-size: 1.8rem;
    margin-bottom: 8px;
}

.upload-hint {
    text-align: center;
    color: rgba(0, 0, 0, 0.5);
    margin-bottom: 24px;
}

/* --- Input Toggle --- */
.input-toggle {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin-bottom: 32px;
    background: rgba(0, 217, 163, 0.05);
    /* Theme specific tint */
    padding: 6px;
    border-radius: 30px;
    width: fit-content;
    margin-left: auto;
    margin-right: auto;
}

.toggle-btn {
    background: transparent;
    border: none;
    padding: 10px 24px;
    border-radius: 30px;
    font-weight: 600;
    color: rgba(0, 0, 0, 0.5);
    cursor: pointer;
    transition: all 0.3s ease;
    font-family: var(--font-body);
}

.toggle-btn:hover {
    color: var(--color-text, #2D2D2D);
}

.toggle-btn.active {
    background: white;
    color: #00D9A3;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

/* --- Text Input Zone --- */
.text-zone {
    width: 100%;
}

.text-input {
    width: 100%;
    min-height: 200px;
    padding: 24px;
    border: 2px solid rgba(0, 217, 163, 0.2);
    border-radius: 16px;
    font-family: var(--font-body);
    font-size: 1.05rem;
    line-height: 1.6;
    resize: vertical;
    transition: all 0.3s ease;
    background: rgba(255, 255, 255, 0.8);
    margin-bottom: 24px;
}

.text-input:focus {
    outline: none;
    border-color: #00D9A3;
    box-shadow: 0 0 0 4px rgba(0, 217, 163, 0.1);
    background: white;
}

.drop-zone {
    border: 3px dashed rgba(0, 217, 163, 0.3);
    border-radius: 16px;
    padding: 60px 40px;
    text-align: center;
    transition: all 0.3s ease;
    cursor: pointer;
    background: rgba(0, 217, 163, 0.02);
}

.drop-zone:hover,
.drop-zone.drag-over {
    border-color: #00D9A3;
    background: rgba(0, 217, 163, 0.05);
    transform: scale(1.01);
}

.drop-zone-content .upload-icon {
    font-size: 3rem;
    margin-bottom: 16px;
}

.drop-zone-content h3 {
    font-size: 1.3rem;
    margin-bottom: 8px;
}

.drop-zone-content p {
    color: rgba(0, 0, 0, 0.5);
}

.browse-btn {
    background: linear-gradient(135deg, #00D9A3, #00B894);
    color: white;
    border: none;
    padding: 14px 32px;
    border-radius: 12px;
    font-weight: 700;
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.3s ease;
    margin: 16px 0;
}

.browse-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(0, 217, 163, 0.3);
}

.file-types {
    font-size: 0.85rem;
    color: rgba(0, 0, 0, 0.4);
    margin-top: 8px;
}

/* --- Preview Grid --- */
.preview-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 16px;
    margin: 32px 0;
}

.preview-item {
    position: relative;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    aspect-ratio: 9 / 16;
}

.preview-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.preview-remove {
    position: absolute;
    top: 8px;
    right: 8px;
    background: rgba(255, 0, 0, 0.8);
    color: white;
    border: none;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 1.2rem;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.preview-remove:hover {
    background: rgba(255, 0, 0, 1);
    transform: scale(1.1);
}

/* --- Analyze Actions --- */
.analyze-actions {
    display: flex;
    gap: 16px;
    justify-content: center;
    margin-top: 32px;
    flex-wrap: wrap;
}

.analyze-btn {
    background: linear-gradient(135deg, #00D9A3, #00B894);
    color: white;
    border: none;
    padding: 18px 48px;
    border-radius: 12px;
    font-weight: 700;
    font-size: 1.2rem;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 20px rgba(0, 217, 163, 0.3);
}

.analyze-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 30px rgba(0, 217, 163, 0.4);
}

.analyze-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

.clear-btn {
    background: transparent;
    border: 2px solid rgba(0, 0, 0, 0.2);
    color: #2D2D2D;
    padding: 18px 32px;
    border-radius: 12px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.clear-btn:hover {
    border-color: #FF6B6B;
    color: #FF6B6B;
}

/* --- Loading Section --- */
.loading-section {
    text-align: center;
    padding: 80px 20px;
}

.loading-container {
    max-width: 400px;
    margin: 0 auto;
}

.loading-spinner {
    width: 60px;
    height: 60px;
    border: 4px solid rgba(0, 217, 163, 0.2);
    border-top-color: #00D9A3;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 24px;
}

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

.loading-container h3 {
    font-size: 1.3rem;
    margin-bottom: 12px;
}

.loading-tip {
    color: rgba(0, 0, 0, 0.5);
    transition: opacity 0.3s ease;
}

/* --- Results Section --- */
.results-section {
    animation: slideInUp 0.6s ease-out;
}

@keyframes slideInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* --- Interest Meter --- */
.interest-meter-hero {
    text-align: center;
    margin-bottom: 60px;
}

.interest-meter-hero h2 {
    font-size: 2.5rem;
    font-weight: 900;
    margin-bottom: 48px;
}

.meter-container {
    position: relative;
    width: 280px;
    height: 280px;
    margin: 0 auto 32px;
}

.meter-svg {
    width: 100%;
    height: 100%;
}

#meterCircle {
    transition: stroke-dashoffset 2s cubic-bezier(0.4, 0, 0.2, 1);
}

.meter-content {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
}

.interest-score {
    font-size: 4.5rem;
    font-weight: 900;
    line-height: 1;
    margin-bottom: 4px;
}

.interest-score.high {
    color: #00D9A3;
}

.interest-score.medium {
    color: #FFB84D;
}

.interest-score.low {
    color: #FF6B6B;
}

.interest-percentage {
    font-size: 0.9rem;
    color: rgba(0, 0, 0, 0.6);
    font-weight: 600;
    margin-bottom: 8px;
}

.interest-level {
    font-size: 1.3rem;
    font-weight: 700;
    margin-bottom: 8px;
}

.interest-level.high {
    color: #00D9A3;
}

.interest-level.medium {
    color: #FFB84D;
}

.interest-level.low {
    color: #FF6B6B;
}

.interest-emoji {
    font-size: 2.5rem;
}

/* --- Verdict Card --- */
.verdict-card {
    max-width: 700px;
    margin: 0 auto;
    background: white;
    padding: 32px;
    border-radius: 20px;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.12);
    border-left: 6px solid #00D9A3;
}

.verdict-card.high {
    border-left-color: #00D9A3;
    background: linear-gradient(135deg, rgba(0, 217, 163, 0.05), rgba(0, 184, 148, 0.05));
}

.verdict-card.medium {
    border-left-color: #FFB84D;
    background: linear-gradient(135deg, rgba(255, 184, 77, 0.05), rgba(255, 167, 38, 0.05));
}

.verdict-card.low {
    border-left-color: #FF6B6B;
    background: linear-gradient(135deg, rgba(255, 107, 107, 0.05), rgba(255, 82, 82, 0.05));
}

.verdict-card h3 {
    font-size: 1.5rem;
    margin-bottom: 12px;
}

.verdict-card p {
    font-size: 1.1rem;
    line-height: 1.6;
    color: rgba(0, 0, 0, 0.8);
}

/* --- Signals --- */
.signals-container {
    margin-bottom: 60px;
}

.signals-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 24px;
}

.signals-card {
    background: white;
    padding: 32px;
    border-radius: 20px;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.12);
}

.signals-card.positive-signals {
    border-left: 6px solid #00D9A3;
}

.signals-card.negative-signals {
    border-left: 6px solid #FF6B6B;
}

.signals-card h3 {
    font-size: 1.3rem;
    margin-bottom: 20px;
}

.signal-item {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 12px 0;
    border-bottom: 1px solid rgba(0, 0, 0, 0.08);
}

.signal-item:last-child {
    border-bottom: none;
}

.signal-icon {
    font-size: 1.3rem;
    flex-shrink: 0;
    margin-top: 2px;
}

.signal-text {
    flex: 1;
    font-size: 1rem;
    line-height: 1.5;
}

/* --- Breakdown Section --- */
.breakdown-section {
    background: white;
    padding: 40px;
    border-radius: 20px;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.12);
    margin-bottom: 40px;
}

.breakdown-section h3 {
    font-size: 1.5rem;
    margin-bottom: 32px;
    text-align: center;
}

.breakdown-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 24px;
}

.breakdown-item {
    text-align: center;
}

.breakdown-label {
    font-size: 0.9rem;
    font-weight: 600;
    color: rgba(0, 0, 0, 0.7);
    margin-bottom: 12px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.breakdown-meter {
    width: 100%;
    height: 12px;
    background: rgba(0, 0, 0, 0.1);
    border-radius: 6px;
    overflow: hidden;
    margin-bottom: 8px;
}

.breakdown-fill {
    height: 100%;
    border-radius: 6px;
    transition: width 1.5s cubic-bezier(0.4, 0, 0.2, 1);
    width: 0;
}

.breakdown-fill.high {
    background: linear-gradient(90deg, #00D9A3, #00B894);
}

.breakdown-fill.medium {
    background: linear-gradient(90deg, #FFB84D, #FFA726);
}

.breakdown-fill.low {
    background: linear-gradient(90deg, #FF6B6B, #FF5252);
}

.breakdown-value {
    font-size: 1.5rem;
    font-weight: 900;
}

.breakdown-value.high {
    color: #00D9A3;
}

.breakdown-value.medium {
    color: #FFB84D;
}

.breakdown-value.low {
    color: #FF6B6B;
}

/* --- Recommendation Card --- */
.recommendation-card {
    background: linear-gradient(135deg, rgba(0, 217, 163, 0.1), rgba(0, 184, 148, 0.1));
    padding: 40px;
    border-radius: 20px;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.12);
    text-align: center;
    margin-bottom: 40px;
    border: 2px solid rgba(0, 217, 163, 0.3);
}

.recommendation-icon {
    font-size: 3rem;
    margin-bottom: 16px;
}

.recommendation-card h3 {
    font-size: 1.8rem;
    margin-bottom: 16px;
}

.recommendation-text {
    font-size: 1.1rem;
    line-height: 1.7;
    color: rgba(0, 0, 0, 0.8);
    max-width: 700px;
    margin: 0 auto 24px;
}

.recommendation-actions {
    display: flex;
    gap: 16px;
    justify-content: center;
    flex-wrap: wrap;
    margin-top: 24px;
}

.recommendation-btn {
    padding: 14px 28px;
    border: none;
    border-radius: 12px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 1rem;
}

.recommendation-btn.primary {
    background: linear-gradient(135deg, #00D9A3, #00B894);
    color: white;
}

.recommendation-btn.secondary {
    background: white;
    border: 2px solid #00D9A3;
    color: #00D9A3;
}

.recommendation-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

/* --- Analyze Another --- */
.analyze-another {
    text-align: center;
    margin-bottom: 60px;
}

.analyze-another-btn {
    background: transparent;
    border: 2px solid #00D9A3;
    color: #00D9A3;
    padding: 16px 32px;
    border-radius: 12px;
    font-weight: 700;
    font-size: 1.1rem;
    cursor: pointer;
    transition: all 0.3s ease;
}

.analyze-another-btn:hover {
    background: #00D9A3;
    color: white;
    transform: translateY(-2px);
}

/* --- How It Works --- */
.how-it-works,
.analyze-factors {
    margin-bottom: 60px;
}

.how-it-works h2,
.analyze-factors h2 {
    text-align: center;
    font-size: 2rem;
    margin-bottom: 40px;
}

.steps-grid,
.factors-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 24px;
}

.step-card,
.factor-card {
    background: white;
    padding: 32px 24px;
    border-radius: 20px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    text-align: center;
    position: relative;
}

.step-number {
    position: absolute;
    top: -16px;
    left: 50%;
    transform: translateX(-50%);
    width: 40px;
    height: 40px;
    background: linear-gradient(135deg, #00D9A3, #00B894);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 900;
    font-size: 1.2rem;
}

.step-icon,
.factor-icon {
    font-size: 3rem;
    margin: 24px 0 16px;
}

.step-card h4,
.factor-card h4 {
    font-size: 1.2rem;
    margin-bottom: 8px;
}

.step-card p,
.factor-card p {
    color: rgba(0, 0, 0, 0.7);
    font-size: 0.95rem;
    line-height: 1.5;
}

/* --- FAQ Section --- */
.faq-section {
    margin-bottom: 60px;
}

.faq-section h2 {
    text-align: center;
    font-size: 2rem;
    margin-bottom: 40px;
}

.faq-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 24px;
}

.faq-item {
    background: white;
    padding: 24px;
    border-radius: 16px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.faq-item h4 {
    font-size: 1.1rem;
    margin-bottom: 12px;
    color: #00D9A3;
}

.faq-item p {
    color: rgba(0, 0, 0, 0.7);
    line-height: 1.6;
}

/* --- Footer --- */
.interest-footer {
    text-align: center;
    padding: 40px 20px;
    border-top: 2px solid rgba(0, 0, 0, 0.1);
    color: rgba(0, 0, 0, 0.6);
}

.interest-footer a {
    color: #00D9A3;
    text-decoration: none;
    font-weight: 600;
}

.interest-footer a:hover {
    text-decoration: underline;
}

/* --- Mobile Responsive --- */
@media (max-width: 768px) {
    .interest-hero h1 {
        font-size: 2rem;
    }

    .feature-pills {
        flex-direction: column;
        align-items: center;
    }

    .upload-container {
        padding: 24px;
    }

    .drop-zone {
        padding: 40px 20px;
    }

    .meter-container {
        width: 220px;
        height: 220px;
    }

    .interest-score {
        font-size: 3rem;
    }

    .signals-grid {
        grid-template-columns: 1fr;
    }

    .breakdown-section {
        padding: 24px;
    }

    .recommendation-card {
        padding: 24px;
    }

    .recommendation-actions {
        flex-direction: column;
    }

    .recommendation-btn {
        width: 100%;
    }

    .header-stats {
        display: none;
    }
}