/* PremiumSignals AI - Global Styles */

:root {
    --primary: #f0b90b;
    --primary-dark: #d4a008;
    --bg-900: #0a0a12;
    --bg-800: #0f0f1a;
    --bg-700: #151525;
    --bg-600: #1c1c2e;
    --bg-500: #252540;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Scrollbar */
::-webkit-scrollbar { width: 5px; height: 5px; }
::-webkit-scrollbar-track { background: var(--bg-800); }
::-webkit-scrollbar-thumb { background: #2a2a3e; border-radius: 10px; }
::-webkit-scrollbar-thumb:hover { background: var(--primary); }

/* Glassmorphism */
.glass {
    background: rgba(255, 255, 255, 0.03);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.06);
}

/* Gradient text */
.gradient-text {
    background: linear-gradient(135deg, var(--primary), #ff9800);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Glow effects */
.glow-primary { box-shadow: 0 0 20px rgba(240, 185, 11, 0.15); }
.glow-green { box-shadow: 0 0 20px rgba(16, 185, 129, 0.15); }
.glow-red { box-shadow: 0 0 20px rgba(239, 68, 68, 0.15); }

/* Shimmer animation */
@keyframes shimmer {
    0% { background-position: -200% 0; }
    100% { background-position: 200% 0; }
}
.animate-shimmer {
    background: linear-gradient(90deg, #1c1c2e 25%, #252540 50%, #1c1c2e 75%);
    background-size: 200% 100%;
    animation: shimmer 1.5s infinite;
}

/* Fade animations */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(8px); }
    to { opacity: 1; transform: translateY(0); }
}
@keyframes slideUp {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}
@keyframes slideInRight {
    from { opacity: 0; transform: translateX(20px); }
    to { opacity: 1; transform: translateX(0); }
}
.animate-fade-in { animation: fadeIn 0.3s ease-out; }
.animate-slide-up { animation: slideUp 0.3s ease-out; }
.animate-slide-right { animation: slideInRight 0.3s ease-out; }

/* Pulse dot (live indicator) */
@keyframes pulse-dot {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.5; transform: scale(0.8); }
}
.pulse-dot { animation: pulse-dot 2s infinite; }

/* Custom select */
select { cursor: pointer; }
select option { background: #1c1c2e; color: #fff; }

/* Table hover rows */
tr { transition: background-color 0.1s; }

/* Safe area for mobile */
.safe-area-inset-bottom { padding-bottom: env(safe-area-inset-bottom, 0); }

/* Price ticker animation */
@keyframes priceUp {
    0% { background: rgba(16, 185, 129, 0.2); }
    100% { background: transparent; }
}
@keyframes priceDown {
    0% { background: rgba(239, 68, 68, 0.2); }
    100% { background: transparent; }
}
.price-up { animation: priceUp 0.8s ease-out; }
.price-down { animation: priceDown 0.8s ease-out; }

/* Signal strength bars */
.strength-bar {
    display: flex;
    gap: 2px;
    align-items: flex-end;
    height: 16px;
}
.strength-bar span {
    width: 3px;
    border-radius: 2px;
    background: #2a2a3e;
}
.strength-bar.weak span:nth-child(1) { height: 4px; background: #ef4444; }
.strength-bar.medium span:nth-child(-n+2) { height: 8px; background: #f59e0b; }
.strength-bar.strong span:nth-child(-n+3) { height: 12px; background: #3b82f6; }
.strength-bar.very_strong span { height: 16px; background: #10b981; }

/* Candlestick colors override for charts */
.tv-chart-container { border-radius: 0; }

/* Mobile responsive adjustments */
@media (max-width: 768px) {
    .hide-mobile { display: none !important; }
    main { padding-bottom: 5rem; }
}

/* Input focus styles */
input:focus, select:focus, textarea:focus {
    outline: none;
}

/* Loading overlay */
.loading-overlay {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(10, 10, 18, 0.7);
    backdrop-filter: blur(4px);
    border-radius: inherit;
    z-index: 10;
}

/* Toggle switch */
.toggle-switch {
    position: relative;
    width: 44px;
    height: 24px;
    border-radius: 12px;
    cursor: pointer;
    transition: background 0.2s;
}
.toggle-switch::after {
    content: '';
    position: absolute;
    top: 2px;
    left: 2px;
    width: 20px;
    height: 20px;
    background: #fff;
    border-radius: 50%;
    transition: transform 0.2s;
    box-shadow: 0 1px 3px rgba(0,0,0,0.4);
}
.toggle-switch.on { background: var(--primary); }
.toggle-switch.on::after { transform: translateX(20px); }
.toggle-switch.off { background: #374151; }

/* Tooltip */
[data-tooltip] {
    position: relative;
}
[data-tooltip]:hover::before {
    content: attr(data-tooltip);
    position: absolute;
    bottom: calc(100% + 8px);
    left: 50%;
    transform: translateX(-50%);
    background: #1c1c2e;
    color: #e5e7eb;
    font-size: 11px;
    padding: 4px 8px;
    border-radius: 6px;
    white-space: nowrap;
    border: 1px solid #374151;
    z-index: 50;
    pointer-events: none;
}

/* Prose for AI content */
.prose-dark { color: #d1d5db; line-height: 1.7; }
.prose-dark strong { color: #f9fafb; }
.prose-dark code { background: #1c1c2e; padding: 2px 6px; border-radius: 4px; font-size: 0.85em; }

/* Card hover lift */
.card-hover { transition: transform 0.2s, box-shadow 0.2s; }
.card-hover:hover { transform: translateY(-2px); box-shadow: 0 8px 32px rgba(0,0,0,0.3); }

/* Light theme overrides */
html:not(.dark) {
    --bg-900: #f3f4f6;
    --bg-800: #ffffff;
    --bg-700: #f9fafb;
    --bg-600: #f3f4f6;
}
