/* style.css - Cyber-Security / Command Center Aesthetic */

body {
    font-family: 'Inter', sans-serif;
    background-color: #020617;
    /* slate-950 */
    color: #94a3b8;
    /* slate-400 */
    /* High-tech subtle grid and premium noise texture */
    background-image:
        url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noiseFilter'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.65' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)' opacity='0.03'/%3E%3C/svg%3E"),
        linear-gradient(to right, rgba(30, 41, 59, 0.2) 1px, transparent 1px),
        linear-gradient(to bottom, rgba(30, 41, 59, 0.2) 1px, transparent 1px);
    background-size: auto, 40px 40px, 40px 40px;
    background-position: top left, center top, center top;
}

/* Gradient Text - Sleeker, less aggressive */
.gradient-text {
    background: linear-gradient(90deg, #38bdf8, #818cf8);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.accent-text {
    color: #22d3ee;
    text-shadow: 0 0 12px rgba(34, 211, 238, 0.4);
}

/* Secure Panel Look - ui-designer glassmorphism */
.card-bg {
    background-color: rgba(15, 23, 42, 0.6);
    /* slate-900 */
    backdrop-filter: blur(24px);
    -webkit-backdrop-filter: blur(24px);
    border: 1px solid rgba(255, 255, 255, 0.08);
    /* inner light effect */
    border-top: 1px solid rgba(255, 255, 255, 0.12);
    /* directional light */
    box-shadow: 0 4px 24px -1px rgba(0, 0, 0, 0.4),
        0 0 0 1px rgba(255, 255, 255, 0.05);
    /* subtle glow */
}

/* Primary Action Buttons - Geometric, glowing edge */
.btn-primary {
    background-color: #0891b2;
    /* cyan-600 */
    color: #ffffff;
    border: 1px solid #06b6d4;
    /* cyan-500 */
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.15), 0 0 12px rgba(8, 145, 178, 0.2);
    transition: all 0.2s ease-in-out;
    border-radius: 0.375rem;
    /* rounded-md instead of full */
    text-transform: uppercase;
    letter-spacing: 0.05em;
    font-size: 0.875rem;
}

.btn-primary:hover {
    background-color: #06b6d4;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.2), 0 0 20px rgba(6, 182, 212, 0.4);
    transform: translateY(-1px);
}

/* Secure Input Fields */
.cyber-input {
    background-color: rgba(3, 7, 18, 0.8) !important;
    /* Extremely dark */
    border: 1px solid #334155 !important;
    color: #f8fafc !important;
    border-radius: 0.375rem !important;
    transition: all 0.2s ease;
}

.cyber-input:focus {
    border-color: #22d3ee !important;
    box-shadow: 0 0 0 1px #22d3ee, 0 0 10px rgba(34, 211, 238, 0.1) !important;
    outline: none !important;
}

/* FAQ Styling */
.faq-question {
    transition: background-color 0.2s ease;
    border-left: 2px solid transparent;
}

.faq-question.active {
    border-left-color: #22d3ee;
    background-color: rgba(30, 41, 59, 0.5);
}

.faq-answer {
    transition: max-height 0.4s cubic-bezier(0, 1, 0, 1);
    max-height: 0;
    overflow: hidden;
}

.faq-question.active+.faq-answer {
    max-height: 500px;
    transition: max-height 0.4s ease-in-out;
}

.faq-question .icon-plus {
    transform: rotate(0deg);
    transition: transform 0.3s ease;
}

.faq-question.active .icon-plus {
    transform: rotate(45deg);
    color: #22d3ee;
}

/* Custom scrollbar for chat and containers */
::-webkit-scrollbar {
    width: 6px;
    height: 6px;
}

::-webkit-scrollbar-track {
    background: transparent;
}

::-webkit-scrollbar-thumb {
    background-color: #334155;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background-color: #475569;
}

/* Loading Spinner */
.loader {
    width: 40px;
    aspect-ratio: 1;
    border-radius: 50%;
    border: 4px solid #1e293b;
    border-right-color: #22d3ee;
    position: relative;
    animation: l24 1s infinite linear;
}

@keyframes l24 {
    100% {
        transform: rotate(1turn)
    }
}

/* --- TOAST NOTIFICATION --- */
#toast-container {
    position: fixed;
    top: 24px;
    right: 24px;
    z-index: 9999;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.toast {
    background-color: rgba(15, 23, 42, 0.95);
    backdrop-filter: blur(8px);
    border: 1px solid #334155;
    border-left: 4px solid #0ea5e9;
    color: white;
    padding: 16px 20px;
    border-radius: 6px;
    box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    gap: 12px;
    min-width: 300px;
    font-size: 0.875rem;
    transform: translateX(120%);
    animation: slideIn 0.3s cubic-bezier(0.16, 1, 0.3, 1) forwards, fadeOut 0.4s 4.5s forwards;
}

.toast.error {
    border-left-color: #ef4444;
}

.toast.success {
    border-left-color: #10b981;
}

@keyframes slideIn {
    to {
        transform: translateX(0);
    }
}

@keyframes fadeOut {
    to {
        opacity: 0;
        transform: translateY(-10px);
        pointer-events: none;
    }
}

/* --- SCROLL TO TOP --- */
#scroll-to-top {
    transition: opacity 0.3s, transform 0.3s;
}

/* --- LIGHTBOX (ADMIN) --- */
#image-modal {
    transition: opacity 0.3s ease;
}

#image-modal img {
    max-height: 85vh;
    max-width: 90vw;
    border: 1px solid #334155;
}

/* --- CHAT MARKDOWN STYLES --- */
.chat-bubble {
    line-height: 1.6;
}

.chat-bubble p {
    margin-bottom: 0.75rem;
}

.chat-bubble p:last-child {
    margin-bottom: 0;
}

.chat-bubble strong {
    font-weight: 600;
    color: #38bdf8;
}

.chat-bubble ul {
    list-style-type: square;
    margin-left: 1.25rem;
    margin-bottom: 0.75rem;
    color: #cbd5e1;
}

.chat-bubble ol {
    list-style-type: decimal-leading-zero;
    margin-left: 1.25rem;
    margin-bottom: 0.75rem;
}

.chat-bubble li {
    margin-bottom: 0.25rem;
    font-size: 0.875rem;
}

.chat-bubble a {
    color: #38bdf8;
    text-decoration: underline;
    text-underline-offset: 2px;
}

/* --- ENTRANCE ANIMATIONS --- */
.fade-up {
    opacity: 0;
    transform: translateY(24px);
    transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

.fade-up.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Stagger delays on 8pt system */
.delay-100 {
    transition-delay: 100ms;
}

.delay-200 {
    transition-delay: 200ms;
}

.delay-300 {
    transition-delay: 300ms;
}

.delay-400 {
    transition-delay: 400ms;
}

.delay-500 {
    transition-delay: 500ms;
}