/* Janus — custom style overrides */

/* Smooth transitions for HTMX content swaps */
.htmx-settling {
    opacity: 0.8;
}

.htmx-swapping {
    opacity: 0;
    transition: opacity 150ms ease-out;
}

/* Light mode overrides */
html:not(.dark) body {
    background-color: #f8fafc;
    color: #1e293b;
}

html:not(.dark) aside {
    background-color: #ffffff;
    border-color: #e2e8f0;
}

html:not(.dark) .bg-slate-800 {
    background-color: #ffffff;
}

html:not(.dark) .bg-slate-900 {
    background-color: #f1f5f9;
}

html:not(.dark) .bg-slate-700 {
    background-color: #f1f5f9;
}

html:not(.dark) .bg-slate-700\/50 {
    background-color: rgba(241, 245, 249, 0.5);
}

html:not(.dark) .hover\:bg-slate-700:hover {
    background-color: #e2e8f0;
}

html:not(.dark) .hover\:bg-slate-600:hover {
    background-color: #cbd5e1;
}

html:not(.dark) .border-slate-700 {
    border-color: #e2e8f0;
}

html:not(.dark) .border-slate-700\/50 {
    border-color: rgba(226, 232, 240, 0.5);
}

html:not(.dark) .border-slate-700\/30 {
    border-color: rgba(226, 232, 240, 0.3);
}

html:not(.dark) .border-slate-600 {
    border-color: #cbd5e1;
}

html:not(.dark) .text-slate-100 {
    color: #1e293b;
}

html:not(.dark) .text-slate-200 {
    color: #334155;
}

html:not(.dark) .text-slate-300 {
    color: #475569;
}

html:not(.dark) .text-slate-400 {
    color: #64748b;
}

html:not(.dark) .text-slate-500 {
    color: #94a3b8;
}

html:not(.dark) .text-white {
    color: #1e293b;
}

/* Form elements in light mode */
html:not(.dark) input[type="text"],
html:not(.dark) input[type="number"],
html:not(.dark) input[type="file"],
html:not(.dark) select,
html:not(.dark) textarea {
    background-color: #ffffff;
    border-color: #cbd5e1;
    color: #1e293b;
}

html:not(.dark) input[type="text"]::placeholder,
html:not(.dark) textarea::placeholder {
    color: #94a3b8;
}

html:not(.dark) input[type="text"]:focus,
html:not(.dark) input[type="number"]:focus,
html:not(.dark) select:focus,
html:not(.dark) textarea:focus {
    border-color: #d69e2e;
}

/* Modals in light mode */
html:not(.dark) #override-modal > div:nth-child(2) > div,
html:not(.dark) #export-modal > div:nth-child(2) > div,
html:not(.dark) #help-modal > div:nth-child(2) > div > div {
    background-color: #ffffff;
    border-color: #e2e8f0;
}

/* Door panels / cards in light mode */
html:not(.dark) details {
    background-color: #ffffff;
    border-color: #e2e8f0;
}

html:not(.dark) details summary:hover {
    background-color: #f8fafc;
}

/* Drag-drop zone light mode */
html:not(.dark) #drop-zone {
    border-color: #cbd5e1;
    background-color: #ffffff;
}

html:not(.dark) #drop-zone:hover {
    border-color: #d69e2e;
}

/* Details/summary triangle hide (use custom icons) */
details > summary {
    list-style: none;
}

details > summary::-webkit-details-marker {
    display: none;
}

/* Progress bar animation */
@keyframes progress-shine {
    from { transform: translateX(-100%); }
    to { transform: translateX(200%); }
}

.progress-bar-animated::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 50%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
    animation: progress-shine 1.5s infinite;
}
