/* 12-Volt Troubleshooting App Custom Styles */

/* Base font adjustments */
body {
    font-family: 'Inter', sans-serif;
}

code, pre, .font-mono {
    font-family: 'JetBrains Mono', monospace;
}

/* Custom scrollbar to match theme */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}
::-webkit-scrollbar-track {
    background: #0f172a; /* bg-gray-950 */
}
::-webkit-scrollbar-thumb {
    background: #334155; /* bg-gray-700 */
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: #475569; /* bg-gray-600 */
}

/* Tab button states managed in JS */
.tab-btn {
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.scenario-tag {
    display: inline-flex;
    align-items: center;
    padding: 0.125rem 0.5rem;
    border-width: 1px;
    border-radius: 0.25rem;
    font-size: 0.625rem;
    line-height: 1rem;
    font-weight: 700;
    letter-spacing: 0.05em;
}

.scenario-card {
    transition: border-color 0.2s ease, transform 0.2s ease;
}

.scenario-card:hover {
    border-color: #60a5fa;
    transform: translateY(-2px);
}

.removal-card {
    transition: border-color 0.2s ease, transform 0.2s ease;
}

.removal-card:hover {
    border-color: #fb923c;
    transform: translateY(-2px);
}

.removal-step {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2rem;
    height: 2rem;
    flex: 0 0 2rem;
    border-radius: 9999px;
    background: rgba(251, 146, 60, 0.15);
    border: 1px solid rgba(251, 146, 60, 0.35);
    color: #fdba74;
    font-weight: 800;
    font-family: 'JetBrains Mono', monospace;
}

.panasonic-step {
    background: rgba(248, 113, 113, 0.15);
    border-color: rgba(248, 113, 113, 0.35);
    color: #fca5a5;
}

.radar-card {
    transition: border-color 0.2s ease, transform 0.2s ease;
}

.radar-card:hover {
    border-color: #818cf8;
    transform: translateY(-2px);
}

.radar-step {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2rem;
    height: 2rem;
    flex: 0 0 2rem;
    border-radius: 9999px;
    background: rgba(129, 140, 248, 0.15);
    border: 1px solid rgba(129, 140, 248, 0.35);
    color: #a5b4fc;
    font-weight: 800;
    font-family: 'JetBrains Mono', monospace;
}

.diagram-card {
    background: rgba(15, 23, 42, 0.35);
    border: 1px solid #374151;
    border-radius: 0.75rem;
    padding: 1rem;
}

.resource-link {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    padding: 0.875rem;
    border: 1px solid #374151;
    border-radius: 0.75rem;
    background: rgba(15, 23, 42, 0.55);
    color: #dbeafe;
    transition: border-color 0.2s ease, background-color 0.2s ease, transform 0.2s ease;
}

.resource-link:hover {
    border-color: #22d3ee;
    background: rgba(8, 47, 73, 0.55);
    transform: translateY(-1px);
}

.resource-link span {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.resource-link small {
    color: #9ca3af;
    line-height: 1.35;
}

.upfitter-card {
    transition: border-color 0.2s ease, transform 0.2s ease;
}

.upfitter-card:hover {
    border-color: #34d399;
    transform: translateY(-2px);
}

.vehicle-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2.5rem;
    height: 2.5rem;
    border-radius: 0.75rem;
    font-size: 1.25rem;
}

.wiring-diagram {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 1rem;
    border: 1px solid #374151;
    border-radius: 0.75rem;
    background: rgba(15, 23, 42, 0.55);
}

.wire-box {
    width: 100%;
    padding: 0.65rem 0.5rem;
    border-radius: 0.5rem;
    text-align: center;
    font-size: 0.7rem;
    font-weight: 700;
}

.wire-source {
    color: #bbf7d0;
    background: rgba(6, 78, 59, 0.6);
    border: 1px solid #34d399;
}

.wire-load {
    color: #fde68a;
    background: rgba(120, 53, 15, 0.6);
    border: 1px solid #f59e0b;
}

.wire-end {
    color: #bfdbfe;
    background: rgba(30, 64, 175, 0.6);
    border: 1px solid #60a5fa;
}

.wire-line {
    width: 3px;
    height: 1.25rem;
    background: #60a5fa;
}

.diagram-card svg {
    display: block;
}

/* Hot node pulse and color animations */
@keyframes wire-glow {
    0% {
        box-shadow: 0 0 5px rgba(239, 68, 68, 0.4);
    }
    50% {
        box-shadow: 0 0 15px rgba(239, 68, 68, 0.8);
    }
    100% {
        box-shadow: 0 0 5px rgba(239, 68, 68, 0.4);
    }
}

.hot-joint-mild {
    animation: wire-glow 2s infinite;
    background-color: #f59e0b !important; /* amber-500 */
}

.hot-joint-severe {
    animation: wire-glow 0.8s infinite;
    background-color: #ef4444 !important; /* red-500 */
}

/* Filament bulb animations */
@keyframes filament-pulse {
    0%, 100% { opacity: 0.9; }
    50% { opacity: 1; }
}

.bulb-glowing {
    animation: filament-pulse 1s infinite alternate;
}

/* Custom switch / range slider stylings */
input[type="range"]::-webkit-slider-thumb {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: #f59e0b; /* amber-500 */
    cursor: pointer;
    border: 2px solid #0f172a;
    transition: transform 0.1s;
}

input[type="range"]::-webkit-slider-thumb:hover {
    transform: scale(1.15);
}

input[type="range"]::-moz-range-thumb {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: #f59e0b;
    cursor: pointer;
    border: 2px solid #0f172a;
    transition: transform 0.1s;
}

input[type="range"]::-moz-range-thumb:hover {
    transform: scale(1.15);
}

/* Fuse pulled visual representation */
.fuse-pulled {
    opacity: 0.3 !important;
    text-decoration: line-through;
    border-style: dashed !important;
    background-color: rgba(31, 41, 55, 0.5) !important; /* gray-800 */
}

.fuse-active {
    transition: all 0.2s ease-in-out;
}

/* Smooth content transitions */
.tab-content {
    animation: fadeIn 0.3s ease-in-out forwards;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(4px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes spin {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}

