/* Assuria 2.0 - Enterprise CNI Design System */
/* Professional, serious, defence/industrial aesthetic */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&display=swap');

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    /* Enterprise Palette - No playful gradients */
    --navy: #0a1628;
    --navy-light: #0f1f35;
    --slate: #1a2d4a;
    --steel: #2a3f5f;
    --teal: #20c19e;
    --teal-dark: #1a9d80;
    --blue: #1e73be;
    --white: #ffffff;
    --gray-50: #f8fafc;
    --gray-100: #f1f5f9;
    --gray-200: #e2e8f0;
    --gray-300: #cbd5e1;
    --gray-400: #94a3b8;
    --gray-500: #64748b;
    --gray-600: #475569;
    --border-light: #e2e8f0;
    --border-dark: #2a3f5f;
    --danger: #dc2626;
    --warning: #f59e0b;
    --success: #16a34a;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    background: var(--gray-50);
    color: var(--navy);
    line-height: 1.6;
    font-size: 16px;
}

/* === CONFIDENTIAL BANNER === */
.confidential-banner {
    background: var(--navy);
    color: var(--gray-400);
    text-align: center;
    padding: 0.5rem 1rem;
    font-size: 0.7rem;
    font-weight: 500;
    letter-spacing: 0.5px;
    text-transform: uppercase;
}

/* === NAVIGATION === */
.nav {
    position: sticky;
    top: 0;
    z-index: 1000;
    background: var(--white);
    border-bottom: 1px solid var(--border-light);
    padding: 0 2rem;
}

.nav-content {
    max-width: 1400px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 64px;
}

.nav-logo {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    text-decoration: none;
    color: var(--navy);
}

.nav-logo-text {
    font-size: 1.25rem;
    font-weight: 700;
    letter-spacing: -0.02em;
}

.nav-logo-text span {
    font-weight: 400;
    color: var(--gray-500);
}

.nav-logo-badge {
    background: var(--teal);
    color: var(--white);
    font-size: 0.6rem;
    font-weight: 700;
    padding: 0.15rem 0.4rem;
    border-radius: 3px;
    margin-left: 0.5rem;
    vertical-align: middle;
}

.nav-links {
    display: flex;
    gap: 0.25rem;
}

.nav-link {
    padding: 0.5rem 1rem;
    color: var(--gray-600);
    text-decoration: none;
    font-size: 0.875rem;
    font-weight: 500;
    border-radius: 6px;
    transition: all 0.15s;
}

.nav-link:hover {
    background: var(--gray-100);
    color: var(--navy);
}

.nav-link.active {
    background: var(--navy);
    color: var(--white);
}

/* Mobile Nav Toggle */
.nav-toggle {
    display: none;
    background: none;
    border: none;
    padding: 0.5rem;
    cursor: pointer;
}

.nav-toggle span {
    display: block;
    width: 24px;
    height: 2px;
    background: var(--navy);
    margin: 5px 0;
    transition: 0.2s;
}

/* === HERO SECTION === */
.hero {
    background: var(--navy);
    color: var(--white);
    padding: 100px 2rem 80px;
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 50%;
    height: 100%;
    background: linear-gradient(135deg, transparent 0%, rgba(32, 193, 158, 0.03) 100%);
    pointer-events: none;
}

.hero-content {
    max-width: 800px;
}

.hero h1 {
    font-size: 3rem;
    font-weight: 800;
    line-height: 1.1;
    letter-spacing: -0.03em;
    margin-bottom: 1.5rem;
}

.hero h1 .accent {
    color: var(--teal);
}

.hero-lead {
    font-size: 1.25rem;
    color: var(--gray-400);
    line-height: 1.6;
    margin-bottom: 2rem;
    max-width: 600px;
}

.hero-cta {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

/* === BUTTONS === */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    font-size: 0.9rem;
    font-weight: 600;
    border-radius: 6px;
    text-decoration: none;
    cursor: pointer;
    border: none;
    transition: all 0.15s;
}

.btn-primary {
    background: var(--teal);
    color: var(--white);
}

.btn-primary:hover {
    background: var(--teal-dark);
}

.btn-secondary {
    background: var(--white);
    color: var(--navy);
    border: 1px solid var(--border-light);
}

.btn-secondary:hover {
    background: var(--gray-100);
}

.btn-outline {
    background: transparent;
    color: var(--white);
    border: 1px solid var(--steel);
}

.btn-outline:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: var(--gray-400);
}

/* === SECTIONS === */
.section {
    padding: 80px 2rem;
}

.section-white {
    background: var(--white);
}

.section-gray {
    background: var(--gray-50);
}

.section-dark {
    background: var(--navy);
    color: var(--white);
}

.container {
    max-width: 1200px;
    margin: 0 auto;
}

/* === TYPOGRAPHY === */
h2 {
    font-size: 2rem;
    font-weight: 700;
    letter-spacing: -0.02em;
    margin-bottom: 1rem;
    color: inherit;
}

h3 {
    font-size: 1.25rem;
    font-weight: 600;
    margin-bottom: 0.75rem;
}

h4 {
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.section-subtitle {
    font-size: 1.125rem;
    color: var(--gray-500);
    max-width: 600px;
    margin-bottom: 3rem;
}

.section-dark .section-subtitle {
    color: var(--gray-400);
}

/* === STATS GRID === */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1.5rem;
    margin: 2rem 0;
}

.stat {
    background: var(--white);
    border: 1px solid var(--border-light);
    border-radius: 8px;
    padding: 1.5rem;
    text-align: center;
}

.section-dark .stat {
    background: var(--slate);
    border-color: var(--border-dark);
}

.stat-value {
    font-size: 2.5rem;
    font-weight: 800;
    color: var(--teal);
    line-height: 1;
}

.stat-label {
    font-size: 0.8rem;
    color: var(--gray-500);
    margin-top: 0.5rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.section-dark .stat-label {
    color: var(--gray-400);
}

/* === CARD GRID === */
.card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.5rem;
}

.card {
    background: var(--white);
    border: 1px solid var(--border-light);
    border-radius: 8px;
    padding: 1.5rem;
}

.card-dark {
    background: var(--slate);
    border-color: var(--border-dark);
}

.card-dark h3,
.card-dark h4 {
    color: var(--white);
}

.card-dark p {
    color: var(--gray-400);
}

.card-icon {
    width: 40px;
    height: 40px;
    background: var(--gray-100);
    color: var(--teal);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 0.9rem;
    margin-bottom: 1rem;
}

.card-dark .card-icon {
    background: var(--navy);
}

/* === CNI SECTOR BADGES === */
.sector-badges {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
    margin: 1rem 0;
}

.sector-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.4rem 0.8rem;
    background: var(--gray-100);
    border: 1px solid var(--border-light);
    border-radius: 4px;
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--gray-600);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.sector-badge.defence {
    border-color: var(--teal);
    color: var(--teal-dark);
}

.sector-badge.marine {
    border-color: var(--blue);
    color: var(--blue);
}

.sector-badge.railway {
    border-color: var(--warning);
    color: #b45309;
}

.sector-badge.energy {
    border-color: var(--success);
    color: var(--success);
}

/* === DASHBOARD MOCKUP === */
.dashboard-window {
    background: var(--navy);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
}

.dashboard-titlebar {
    background: var(--navy-light);
    padding: 0.75rem 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    border-bottom: 1px solid var(--border-dark);
}

.dashboard-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
}

.dashboard-dot.red {
    background: #ff5f57;
}

.dashboard-dot.yellow {
    background: #febc2e;
}

.dashboard-dot.green {
    background: #28c840;
}

.dashboard-title {
    flex: 1;
    text-align: center;
    color: var(--gray-400);
    font-size: 0.8rem;
    font-weight: 500;
}

.dashboard-content {
    padding: 1.5rem;
}

.dashboard-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.dashboard-panel {
    background: var(--slate);
    border: 1px solid var(--border-dark);
    border-radius: 8px;
    padding: 1rem;
}

.panel-label {
    font-size: 0.7rem;
    color: var(--gray-400);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 0.5rem;
}

.panel-value {
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--white);
}

.panel-value.danger {
    color: var(--danger);
}

.panel-value.success {
    color: var(--success);
}

.panel-change {
    font-size: 0.75rem;
    color: var(--gray-400);
    margin-top: 0.25rem;
}

/* === ALERT TABLE === */
.alert-table {
    width: 100%;
    border-collapse: collapse;
}

.alert-table th,
.alert-table td {
    padding: 0.75rem 1rem;
    text-align: left;
    border-bottom: 1px solid var(--border-dark);
    font-size: 0.85rem;
}

.alert-table th {
    background: var(--navy-light);
    color: var(--gray-400);
    font-weight: 600;
    text-transform: uppercase;
    font-size: 0.7rem;
    letter-spacing: 0.5px;
}

.alert-table td {
    color: var(--gray-300);
}

.severity-badge {
    display: inline-block;
    padding: 0.2rem 0.5rem;
    border-radius: 3px;
    font-size: 0.65rem;
    font-weight: 700;
    text-transform: uppercase;
}

.severity-critical {
    background: rgba(220, 38, 38, 0.2);
    color: #fca5a5;
}

.severity-high {
    background: rgba(245, 158, 11, 0.2);
    color: #fcd34d;
}

.severity-medium {
    background: rgba(59, 130, 246, 0.2);
    color: #93c5fd;
}

.severity-low {
    background: rgba(34, 197, 94, 0.2);
    color: #86efac;
}

/* === AI CHAT INTERFACE === */
.ai-chat {
    background: var(--slate);
    border: 1px solid var(--border-dark);
    border-radius: 8px;
    overflow: hidden;
    margin-top: 1.5rem;
}

.ai-chat-header {
    background: var(--navy-light);
    padding: 0.75rem 1rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    border-bottom: 1px solid var(--border-dark);
}

.ai-chat-indicator {
    width: 8px;
    height: 8px;
    background: var(--teal);
    border-radius: 50%;
    animation: pulse 2s infinite;
}

@keyframes pulse {

    0%,
    100% {
        opacity: 1;
    }

    50% {
        opacity: 0.5;
    }
}

.ai-chat-title {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--white);
}

.ai-chat-messages {
    padding: 1rem;
    max-height: 300px;
    overflow-y: auto;
}

.ai-message {
    margin-bottom: 1rem;
    display: flex;
    gap: 0.75rem;
}

.ai-avatar {
    width: 28px;
    height: 28px;
    background: var(--teal);
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.7rem;
    font-weight: 700;
    color: var(--white);
    flex-shrink: 0;
}

.ai-bubble {
    background: var(--navy);
    border: 1px solid var(--border-dark);
    border-radius: 8px;
    padding: 0.75rem 1rem;
    color: var(--gray-300);
    font-size: 0.85rem;
    line-height: 1.5;
    max-width: 80%;
}

.user-message .ai-bubble {
    background: var(--teal);
    color: var(--white);
    border-color: var(--teal);
}

.ai-chat-input {
    display: flex;
    gap: 0.5rem;
    padding: 1rem;
    border-top: 1px solid var(--border-dark);
}

.ai-chat-input input {
    flex: 1;
    background: var(--navy);
    border: 1px solid var(--border-dark);
    border-radius: 6px;
    padding: 0.75rem 1rem;
    color: var(--white);
    font-size: 0.85rem;
}

.ai-chat-input input::placeholder {
    color: var(--gray-500);
}

.ai-chat-input input:focus {
    outline: none;
    border-color: var(--teal);
}

.ai-chat-input button {
    background: var(--teal);
    color: var(--white);
    border: none;
    padding: 0.75rem 1.25rem;
    border-radius: 6px;
    font-weight: 600;
    font-size: 0.85rem;
    cursor: pointer;
    transition: background 0.15s;
}

.ai-chat-input button:hover {
    background: var(--teal-dark);
}

/* === TABLES === */
.data-table {
    width: 100%;
    border-collapse: collapse;
    background: var(--white);
    border: 1px solid var(--border-light);
    border-radius: 8px;
    overflow: hidden;
    margin: 1.5rem 0;
}

.data-table th,
.data-table td {
    padding: 1rem;
    text-align: left;
    border-bottom: 1px solid var(--border-light);
}

.data-table th {
    background: var(--gray-50);
    font-weight: 600;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--gray-500);
}

.data-table td {
    color: var(--gray-600);
    font-size: 0.9rem;
}

.data-table tr:last-child td {
    border-bottom: none;
}

/* === FOOTER === */
.footer {
    background: var(--navy);
    color: var(--gray-400);
    padding: 2rem;
    text-align: center;
    font-size: 0.85rem;
}

/* === PASSWORD OVERLAY === */
.password-overlay {
    position: fixed;
    inset: 0;
    background: linear-gradient(135deg, #0a1628 0%, #0f2847 50%, #0a1628 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    transition: opacity 0.5s, visibility 0.5s;
    overflow: hidden;
}

.password-overlay::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle at 30% 30%, rgba(32, 193, 158, 0.05) 0%, transparent 50%),
        radial-gradient(circle at 70% 70%, rgba(30, 115, 190, 0.05) 0%, transparent 50%);
    animation: passwordGlow 15s ease-in-out infinite;
}

@keyframes passwordGlow {

    0%,
    100% {
        transform: translate(0, 0);
    }

    50% {
        transform: translate(-2%, -2%);
    }
}

.password-overlay.hidden {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

.password-box {
    position: relative;
    background: linear-gradient(145deg, rgba(26, 45, 74, 0.9) 0%, rgba(15, 31, 53, 0.95) 100%);
    border: 1px solid rgba(42, 63, 95, 0.6);
    border-radius: 16px;
    padding: 3rem 2.5rem;
    text-align: center;
    max-width: 420px;
    width: 90%;
    box-shadow: 0 25px 80px rgba(0, 0, 0, 0.5),
        0 0 60px rgba(32, 193, 158, 0.05);
    backdrop-filter: blur(10px);
}

.password-box::before {
    content: '';
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 60%;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--teal), transparent);
}

.password-lock {
    width: 64px;
    height: 64px;
    background: linear-gradient(135deg, var(--teal) 0%, var(--teal-dark) 100%);
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.5rem;
    font-size: 1.5rem;
    color: white;
    box-shadow: 0 8px 24px rgba(32, 193, 158, 0.3);
}

.password-box h1 {
    font-size: 2rem;
    font-weight: 800;
    color: var(--white);
    margin-bottom: 0.25rem;
    letter-spacing: -0.02em;
}

.password-box h1 span {
    color: var(--teal);
}

.password-box .subtitle {
    color: var(--gray-400);
    margin-bottom: 0.5rem;
    font-size: 1rem;
}

.password-box .confidential-note {
    font-size: 0.7rem;
    color: var(--gray-500);
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 2rem;
    padding: 0.5rem;
    border: 1px solid rgba(100, 116, 139, 0.3);
    border-radius: 4px;
    background: rgba(0, 0, 0, 0.2);
}

.password-input {
    width: 100%;
    padding: 1rem 1.25rem;
    background: rgba(10, 22, 40, 0.8);
    border: 1px solid var(--border-dark);
    border-radius: 8px;
    color: var(--white);
    font-size: 1rem;
    text-align: center;
    margin-bottom: 1rem;
    letter-spacing: 0.2em;
    transition: all 0.2s;
}

.password-input::placeholder {
    letter-spacing: normal;
    color: var(--gray-500);
}

.password-input:focus {
    outline: none;
    border-color: var(--teal);
    box-shadow: 0 0 0 3px rgba(32, 193, 158, 0.15);
}

.password-error {
    color: var(--danger);
    font-size: 0.85rem;
    margin-top: 0.5rem;
    display: none;
}

/* === MOBILE RESPONSIVE === */
@media (max-width: 1024px) {
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .dashboard-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .nav-links {
        display: none;
        position: absolute;
        top: 64px;
        left: 0;
        right: 0;
        background: var(--white);
        flex-direction: column;
        padding: 1rem;
        border-bottom: 1px solid var(--border-light);
        box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    }

    .nav-links.open {
        display: flex;
    }

    .nav-toggle {
        display: block;
    }

    .hero {
        padding: 60px 1.5rem 50px;
    }

    .hero h1 {
        font-size: 2rem;
    }

    .hero-lead {
        font-size: 1rem;
    }

    .section {
        padding: 50px 1.5rem;
    }

    .stats-grid {
        grid-template-columns: 1fr 1fr;
        gap: 1rem;
    }

    .stat {
        padding: 1rem;
    }

    .stat-value {
        font-size: 1.75rem;
    }

    .card-grid {
        grid-template-columns: 1fr;
    }

    .dashboard-grid {
        grid-template-columns: 1fr 1fr;
    }

    h2 {
        font-size: 1.5rem;
    }

    .alert-table {
        font-size: 0.75rem;
    }

    .alert-table th,
    .alert-table td {
        padding: 0.5rem;
    }

    .data-table {
        display: block;
        overflow-x: auto;
    }
}

@media (max-width: 480px) {
    .stats-grid {
        grid-template-columns: 1fr;
    }

    .dashboard-grid {
        grid-template-columns: 1fr;
    }

    .hero-cta {
        flex-direction: column;
    }

    .btn {
        width: 100%;
        justify-content: center;
    }
}