/* Stonks Valuation - Ultra Cyberpunk Edition */

:root {
    /* Ultra-dark cyberpunk backgrounds */
    --bg-primary: #000000;
    --bg-secondary: #0a0a14;
    --bg-card: #0d0d1a;
    --bg-elevated: #111122;

    /* High-contrast neon accents */
    --accent-primary: #00ffff;
    --accent-secondary: #ff00ff;
    --accent-tertiary: #7000ff;
    --accent-glow: rgba(0, 255, 255, 0.5);
    --accent-glow-strong: rgba(0, 255, 255, 0.8);
    --magenta-glow: rgba(255, 0, 255, 0.5);

    /* Brighter text for contrast */
    --text-primary: #ffffff;
    --text-secondary: #b8c5db;
    --text-dim: #7a8199;

    /* Vibrant status colors */
    --success: #00ff88;
    --warning: #ffaa00;
    --danger: #ff0055;

    /* Enhanced borders and shadows */
    --border-color: rgba(0, 255, 255, 0.2);
    --border-color-strong: rgba(0, 255, 255, 0.4);
    --shadow-lg: 0 20px 60px rgba(0, 0, 0, 0.9);
    --shadow-neon: 0 0 20px rgba(0, 255, 255, 0.4), 0 0 40px rgba(0, 255, 255, 0.2);
    --shadow-neon-magenta: 0 0 20px rgba(255, 0, 255, 0.4), 0 0 40px rgba(255, 0, 255, 0.2);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Sora', -apple-system, sans-serif;
    background: var(--bg-primary);
    color: var(--text-primary);
    min-height: 100vh;
    padding: 40px 20px;
    position: relative;
    overflow-x: hidden;
}

body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background:
        radial-gradient(circle at 20% 30%, rgba(255, 0, 255, 0.15) 0%, transparent 50%),
        radial-gradient(circle at 80% 70%, rgba(0, 255, 255, 0.12) 0%, transparent 50%),
        radial-gradient(circle at 50% 50%, rgba(0, 255, 255, 0.03) 0%, transparent 80%);
    pointer-events: none;
    z-index: 0;
}

.grain {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0.05;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 400 400' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noiseFilter'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' /%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)' /%3E%3C/svg%3E");
    pointer-events: none;
    z-index: 1;
}

/* Cyberpunk scanline effect */
.grain::after {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: repeating-linear-gradient(
        0deg,
        rgba(0, 255, 255, 0.03) 0px,
        transparent 1px,
        transparent 2px,
        rgba(0, 255, 255, 0.03) 3px
    );
    pointer-events: none;
    z-index: 2;
}

.container {
    max-width: 1400px;
    margin: 0 auto;
    position: relative;
    z-index: 2;
    animation: fadeIn 0.8s ease-out;
}

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

.header {
    text-align: center;
    margin-bottom: 60px;
    animation: slideDown 1s ease-out;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.header h1 {
    font-size: clamp(2.5em, 6vw, 4em);
    font-weight: 800;
    margin-bottom: 16px;
    background: linear-gradient(135deg, var(--accent-primary), var(--accent-secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    letter-spacing: -0.02em;
    line-height: 1.1;
}

.header p {
    font-size: 1.2em;
    color: var(--text-secondary);
    font-weight: 300;
    letter-spacing: 0.02em;
}

.card {
    background: var(--bg-card);
    border-radius: 24px;
    padding: 40px;
    margin-bottom: 30px;
    box-shadow: var(--shadow-lg);
    border: 2px solid var(--border-color);
    backdrop-filter: blur(10px);
    position: relative;
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.card::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(0, 255, 255, 0.1), transparent);
    transition: left 0.6s;
}

.card:hover::before {
    left: 100%;
}

.card:hover {
    transform: translateY(-4px);
    box-shadow: 0 30px 80px rgba(0, 0, 0, 0.9), var(--shadow-neon);
    border-color: var(--border-color-strong);
}

.card h2 {
    font-size: 1.8em;
    margin-bottom: 30px;
    color: var(--text-primary);
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 12px;
}

.card h2::before {
    content: '';
    width: 4px;
    height: 28px;
    background: linear-gradient(180deg, var(--accent-primary), var(--accent-secondary));
    border-radius: 4px;
}

.card h2 i,
.card h3 i {
    color: var(--accent-primary);
    filter: drop-shadow(0 0 15px var(--accent-glow-strong));
    margin-right: 8px;
}

.recommendation i {
    font-size: 1.5em;
    margin-right: 10px;
    filter: drop-shadow(0 0 20px currentColor);
}

.ticker-section {
    display: flex;
    gap: 20px;
    margin-bottom: 30px;
    align-items: flex-end;
}

.ticker-input-group {
    flex: 1;
}

.input-section {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 24px;
    margin-bottom: 30px;
}

.input-group {
    display: flex;
    flex-direction: column;
    position: relative;
}

.input-group label {
    font-weight: 600;
    margin-bottom: 12px;
    color: var(--text-secondary);
    font-size: 0.9em;
    display: flex;
    align-items: center;
    gap: 8px;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.tooltip {
    cursor: help;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 18px;
    height: 18px;
    background: var(--accent-secondary);
    color: white;
    border-radius: 50%;
    font-size: 11px;
    font-weight: bold;
    position: relative;
    transition: all 0.3s;
}

.tooltip:hover {
    background: var(--accent-primary);
    transform: scale(1.1);
}

.tooltip:hover::after {
    content: attr(data-tooltip);
    position: absolute;
    bottom: 130%;
    left: 50%;
    transform: translateX(-50%);
    background: var(--bg-elevated);
    color: var(--text-primary);
    padding: 12px 16px;
    border-radius: 12px;
    font-size: 13px;
    white-space: normal;
    width: 280px;
    z-index: 1000;
    font-weight: normal;
    line-height: 1.5;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.6);
    border: 1px solid var(--border-color);
    font-family: 'Sora', sans-serif;
    letter-spacing: normal;
    text-transform: none;
}

.tooltip:hover::before {
    content: '';
    position: absolute;
    bottom: 123%;
    left: 50%;
    transform: translateX(-50%);
    border: 8px solid transparent;
    border-top-color: var(--bg-elevated);
    z-index: 1000;
}

.input-group input,
.input-group select {
    padding: 14px 18px;
    border: 2px solid var(--border-color);
    border-radius: 12px;
    font-size: 1em;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    background: var(--bg-secondary);
    color: var(--text-primary);
    font-family: 'Space Mono', monospace;
    font-weight: 400;
}

.input-group input:focus,
.input-group select:focus {
    outline: none;
    border-color: var(--accent-primary);
    box-shadow: 0 0 0 4px var(--accent-glow), var(--shadow-neon);
    transform: translateY(-2px);
}

.input-group input::placeholder {
    color: var(--text-dim);
}

.input-group input:disabled {
    background-color: var(--bg-primary);
    cursor: not-allowed;
    opacity: 0.5;
}

.btn {
    background: linear-gradient(135deg, var(--accent-secondary), var(--accent-primary));
    color: #000;
    border: 2px solid var(--accent-primary);
    padding: 16px 40px;
    border-radius: 12px;
    font-size: 1.1em;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    text-transform: uppercase;
    letter-spacing: 0.08em;
    position: relative;
    overflow: hidden;
    font-family: 'Sora', sans-serif;
    box-shadow: 0 0 20px var(--accent-glow);
}

.btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s;
}

.btn:hover::before {
    left: 100%;
}

.btn:hover:not(:disabled) {
    transform: translateY(-3px);
    box-shadow: 0 12px 40px var(--accent-glow-strong), var(--shadow-neon);
}

.btn:active:not(:disabled) {
    transform: translateY(-1px);
}

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

.btn-fetch {
    padding: 14px 32px;
    white-space: nowrap;
}

.btn-analyze {
    width: 100%;
    margin-top: 20px;
}

.loading {
    display: none;
    text-align: center;
    padding: 24px;
    color: var(--accent-primary);
    font-weight: 600;
    font-size: 1.1em;
}

.loading.active {
    display: block;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

.loading::after {
    content: '...';
    animation: dots 1.5s steps(4, end) infinite;
}

@keyframes dots {
    0%, 20% { content: '.'; }
    40% { content: '..'; }
    60%, 100% { content: '...'; }
}

.error-message {
    background: rgba(255, 0, 85, 0.1);
    border-left: 4px solid var(--danger);
    border: 2px solid var(--danger);
    padding: 20px;
    margin: 24px 0;
    border-radius: 12px;
    color: var(--danger);
    display: none;
    animation: shake 0.5s;
    box-shadow: 0 0 20px rgba(255, 0, 85, 0.2);
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    25% { transform: translateX(-10px); }
    75% { transform: translateX(10px); }
}

.error-message.active {
    display: block;
}

.success-message {
    background: rgba(0, 255, 136, 0.1);
    border-left: 4px solid var(--success);
    border: 2px solid var(--success);
    padding: 20px;
    margin: 24px 0;
    border-radius: 12px;
    color: var(--success);
    display: none;
    animation: slideInRight 0.5s;
    box-shadow: 0 0 20px rgba(0, 255, 136, 0.2);
}

@keyframes slideInRight {
    from {
        opacity: 0;
        transform: translateX(-20px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.success-message.active {
    display: block;
}

.results {
    display: none;
}

.results.active {
    display: block;
    animation: fadeIn 0.8s ease-out;
}

.metric-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 24px;
    margin-bottom: 40px;
}

.metric-card {
    background: var(--bg-elevated);
    padding: 28px;
    border-radius: 16px;
    text-align: center;
    position: relative;
    overflow: hidden;
    border: 2px solid var(--border-color);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.metric-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--accent-primary), var(--accent-secondary));
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.metric-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.8), var(--shadow-neon);
    border-color: var(--accent-primary);
}

.metric-card:hover::before {
    transform: scaleX(1);
}

.metric-card h3 {
    font-size: 0.85em;
    color: var(--text-dim);
    margin-bottom: 16px;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    font-weight: 600;
}

.metric-card .value {
    font-size: 2.5em;
    font-weight: 800;
    color: var(--accent-primary);
    margin-bottom: 8px;
    font-family: 'Space Mono', monospace;
    text-shadow: 0 0 30px var(--accent-glow-strong), 0 0 60px var(--accent-glow);
}

.metric-card .subtext {
    font-size: 0.9em;
    color: var(--text-secondary);
    margin-top: 8px;
}

.analysis-section {
    margin-top: 50px;
}

.analysis-section h2 {
    color: var(--text-primary);
    margin-bottom: 30px;
    font-size: 2em;
    font-weight: 700;
    position: relative;
    padding-bottom: 20px;
}

.analysis-section h2::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 80px;
    height: 4px;
    background: linear-gradient(90deg, var(--accent-primary), var(--accent-secondary));
    border-radius: 2px;
}

.valuation-box {
    background: var(--bg-secondary);
    border-left: 4px solid var(--accent-primary);
    padding: 28px;
    margin-bottom: 24px;
    border-radius: 12px;
    border: 2px solid var(--border-color);
    border-left: 4px solid var(--accent-primary);
    transition: all 0.3s;
}

.valuation-box:hover {
    background: var(--bg-elevated);
    transform: translateX(8px);
    box-shadow: 0 0 20px var(--accent-glow);
    border-color: var(--accent-primary);
}

.valuation-box h3 {
    color: var(--accent-primary);
    margin-bottom: 16px;
    font-size: 1.3em;
    font-weight: 700;
}

.valuation-box p {
    line-height: 1.8;
    color: var(--text-secondary);
}

.recommendation {
    padding: 32px;
    border-radius: 16px;
    margin-top: 30px;
    font-size: 1.2em;
    font-weight: 700;
    text-align: center;
    position: relative;
    overflow: hidden;
    animation: scaleIn 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

@keyframes scaleIn {
    from {
        opacity: 0;
        transform: scale(0.9);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

.recommendation::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(45deg, transparent 30%, rgba(255,255,255,0.1) 50%, transparent 70%);
    background-size: 200% 200%;
    animation: shimmer 3s infinite;
}

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

.recommendation.buy {
    background: linear-gradient(135deg, rgba(0, 255, 136, 0.15), rgba(0, 200, 100, 0.2));
    color: var(--success);
    border: 3px solid var(--success);
    box-shadow: 0 0 30px rgba(0, 255, 136, 0.3), 0 0 60px rgba(0, 255, 136, 0.15);
}

.recommendation.hold {
    background: linear-gradient(135deg, rgba(255, 170, 0, 0.15), rgba(255, 200, 0, 0.2));
    color: var(--warning);
    border: 3px solid var(--warning);
    box-shadow: 0 0 30px rgba(255, 170, 0, 0.3), 0 0 60px rgba(255, 170, 0, 0.15);
}

.recommendation.sell {
    background: linear-gradient(135deg, rgba(255, 0, 85, 0.15), rgba(255, 0, 80, 0.2));
    color: var(--danger);
    border: 3px solid var(--danger);
    box-shadow: 0 0 30px rgba(255, 0, 85, 0.3), 0 0 60px rgba(255, 0, 85, 0.15);
}

.details-list {
    list-style: none;
    padding: 0;
}

.details-list li {
    padding: 16px 20px;
    margin-bottom: 12px;
    background: var(--bg-elevated);
    border-radius: 10px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border: 2px solid var(--border-color);
    transition: all 0.3s;
}

.details-list li:hover {
    background: var(--bg-secondary);
    transform: translateX(8px);
    border-color: var(--accent-primary);
    box-shadow: 0 0 15px var(--accent-glow);
}

.details-list li strong {
    color: var(--accent-primary);
    font-weight: 600;
}

.info-box {
    background: rgba(0, 255, 255, 0.05);
    border-left: 4px solid var(--accent-primary);
    padding: 20px 24px;
    margin: 24px 0;
    border-radius: 12px;
    border: 2px solid var(--border-color);
    box-shadow: inset 0 0 20px rgba(0, 255, 255, 0.05);
}

.info-box p {
    color: var(--text-secondary);
    line-height: 1.7;
}

.info-box strong {
    color: var(--accent-primary);
}

.company-info {
    background: var(--bg-secondary);
    padding: 24px;
    border-radius: 16px;
    margin-bottom: 30px;
    border: 2px solid var(--border-color);
    box-shadow: inset 0 0 30px rgba(0, 255, 255, 0.05);
}

.company-info h3 {
    color: var(--accent-primary);
    margin-bottom: 20px;
    font-size: 1.3em;
    font-weight: 700;
}

.company-info-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 16px;
}

.company-info-item {
    display: flex;
    justify-content: space-between;
    padding: 14px 18px;
    background: var(--bg-elevated);
    border-radius: 10px;
    border: 2px solid var(--border-color);
    transition: all 0.3s;
}

.company-info-item:hover {
    background: var(--bg-card);
    border-color: var(--accent-primary);
    box-shadow: 0 0 15px var(--accent-glow);
}

.company-info-item span:first-child {
    color: var(--text-dim);
    font-weight: 600;
    font-size: 0.9em;
}

.company-info-item span:last-child {
    color: var(--text-primary);
    font-family: 'Space Mono', monospace;
}

small {
    color: var(--text-dim);
    font-size: 0.85em;
}

@media (max-width: 768px) {
    .header h1 {
        font-size: 2.2em;
    }

    .ticker-section {
        flex-direction: column;
    }

    .input-section {
        grid-template-columns: 1fr;
    }

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

    .tooltip:hover::after {
        width: 220px;
    }

    .card {
        padding: 24px;
    }
}

/* Cyberpunk glitch effect animation */
@keyframes glitch {
    0%, 100% {
        text-shadow:
            2px 2px 0 var(--accent-primary),
            -2px -2px 0 var(--accent-secondary);
    }
    25% {
        text-shadow:
            -2px 2px 0 var(--accent-primary),
            2px -2px 0 var(--accent-secondary);
    }
    50% {
        text-shadow:
            2px -2px 0 var(--accent-primary),
            -2px 2px 0 var(--accent-secondary);
    }
    75% {
        text-shadow:
            -2px -2px 0 var(--accent-primary),
            2px 2px 0 var(--accent-secondary);
    }
}

/* Subtle pulsing animation for neon elements */
@keyframes neonPulse {
    0%, 100% {
        filter: brightness(1);
        box-shadow: 0 0 20px var(--accent-glow), 0 0 40px var(--accent-glow);
    }
    50% {
        filter: brightness(1.2);
        box-shadow: 0 0 30px var(--accent-glow-strong), 0 0 60px var(--accent-glow);
    }
}

/* Autocomplete Dropdown */
.autocomplete-dropdown {
    position: absolute;
    top: calc(100% + 8px);
    left: 0;
    right: 0;
    background: var(--bg-elevated);
    border: 2px solid var(--border-color-strong);
    border-radius: 16px;
    max-height: 400px;
    overflow-y: auto;
    z-index: 1000;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.8), var(--shadow-neon);
    animation: slideDown 0.3s ease-out;
}

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

.autocomplete-item {
    padding: 16px 20px;
    cursor: pointer;
    transition: all 0.2s ease;
    border-bottom: 1px solid var(--border-color);
}

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

.autocomplete-item:hover,
.autocomplete-item.selected {
    background: var(--bg-secondary);
    border-left: 4px solid var(--accent-primary);
    padding-left: 16px;
    box-shadow: inset 0 0 20px rgba(0, 255, 255, 0.1);
}

.autocomplete-item .ticker-symbol {
    font-weight: 700;
    font-size: 1.1em;
    color: var(--accent-primary);
    font-family: 'Space Mono', monospace;
    display: block;
    margin-bottom: 4px;
    text-shadow: 0 0 10px var(--accent-glow);
}

.autocomplete-item .company-name {
    font-size: 0.9em;
    color: var(--text-secondary);
    display: block;
    margin-bottom: 2px;
}

.autocomplete-item .exchange-type {
    font-size: 0.75em;
    color: var(--text-dim);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.autocomplete-loading {
    padding: 16px 20px;
    text-align: center;
    color: var(--accent-primary);
    font-size: 0.9em;
}

.autocomplete-no-results {
    padding: 16px 20px;
    text-align: center;
    color: var(--text-dim);
    font-size: 0.9em;
}

/* TradingView Chart Styling */
.tradingview-widget-container {
    border-radius: 12px;
    overflow: hidden;
    background: var(--bg-secondary);
    border: 2px solid var(--border-color);
    box-shadow: inset 0 0 30px rgba(0, 255, 255, 0.05);
}

#tradingview_chart {
    border-radius: 12px;
}

/* TradingView widget overrides */
.tradingview-widget-container iframe {
    border-radius: 12px;
}

/* Market Sentiment Card */
.sentiment-card {
    background: linear-gradient(135deg, var(--bg-secondary) 0%, rgba(139, 92, 246, 0.05) 100%);
    border: 2px solid transparent;
    border-radius: 16px;
    padding: 18px 24px;
    width: 100%;
    max-width: 440px;
    margin-bottom: 0;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5), 0 0 0 1px var(--border-color);
    position: relative;
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Animated gradient border */
.sentiment-card::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 24px;
    padding: 2px;
    background: linear-gradient(135deg, rgba(139, 92, 246, 0.6), rgba(0, 255, 255, 0.4), rgba(139, 92, 246, 0.6));
    background-size: 200% 200%;
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    mask-composite: exclude;
    animation: sentimentBorderFlow 6s ease infinite;
    opacity: 0.4;
}

@keyframes sentimentBorderFlow {
    0%, 100% {
        background-position: 0% 50%;
    }
    50% {
        background-position: 100% 50%;
    }
}

.sentiment-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.7), 0 0 40px rgba(139, 92, 246, 0.3);
}

.sentiment-card:hover::before {
    opacity: 0.8;
}

.sentiment-header {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    margin-bottom: 16px;
}

.sentiment-header i {
    font-size: 1.3em;
    color: var(--accent-secondary);
    filter: drop-shadow(0 0 15px rgba(139, 92, 246, 0.6));
}

.sentiment-header h3 {
    font-size: 1.1em;
    margin: 0;
    font-weight: 600;
    letter-spacing: 0.5px;
    background: linear-gradient(135deg, var(--text-primary), var(--accent-secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.sentiment-display {
    text-align: center;
    position: relative;
    z-index: 1;
}

.sentiment-emoji {
    font-size: 2.2em;
    margin-bottom: 8px;
    display: block;
    animation: emojiFloat 3s ease-in-out infinite;
}

@keyframes emojiFloat {
    0%, 100% {
        transform: translateY(0px);
    }
    50% {
        transform: translateY(-10px);
    }
}

.sentiment-rating {
    font-size: 1.6em;
    font-weight: 800;
    margin-bottom: 6px;
    letter-spacing: 0.5px;
    text-shadow: 0 0 30px currentColor;
}

.sentiment-score {
    font-size: 0.9em;
    opacity: 0.9;
    margin-bottom: 6px;
    font-weight: 500;
}

.sentiment-source {
    margin-top: 16px;
    padding-top: 16px;
    border-top: 1px solid var(--border-color);
    font-size: 0.85em;
    opacity: 0.7;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    flex-wrap: wrap;
}

/* Mobile responsive for sentiment card */
@media (max-width: 480px) {
    .sentiment-card {
        padding: 16px 20px;
        max-width: 100%;
    }

    .sentiment-header {
        margin-bottom: 12px;
    }

    .sentiment-header h3 {
        font-size: 1em;
    }

    .sentiment-header i {
        font-size: 1.1em;
    }

    .sentiment-emoji {
        font-size: 1.8em;
        margin-bottom: 6px;
    }

    .sentiment-rating {
        font-size: 1.4em;
        margin-bottom: 4px;
    }

    .sentiment-score {
        font-size: 0.85em;
        margin-bottom: 4px;
    }

    .sentiment-source {
        font-size: 0.75em;
    }

    .sentiment-source {
        flex-direction: column;
        gap: 6px;
        font-size: 0.8em;
    }

    .sentiment-source span:nth-child(2) {
        display: none; /* Hide the separator on mobile */
    }
}

/* Scrollbar styling */
::-webkit-scrollbar {
    width: 10px;
}

::-webkit-scrollbar-track {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
}

::-webkit-scrollbar-thumb {
    background: linear-gradient(180deg, var(--accent-primary), var(--accent-secondary));
    border-radius: 5px;
    box-shadow: 0 0 10px var(--accent-glow);
}

::-webkit-scrollbar-thumb:hover {
    background: var(--accent-primary);
    box-shadow: 0 0 15px var(--accent-glow-strong);
}
