﻿/* Professional government-style title bar */
.title-bar {
    width: 100%;
    background: #003a94;
    /* dark blue */
    text-align: center;
    padding: 30px 15px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    /* subtle shadow for depth */
}

.hero {
    /* Restored dark blue gradient overlay to maintain text visibility */
    background: linear-gradient(#003a94, rgba(26, 35, 126, 0.9)), url(https://images.unsplash.com/photo-1550751827-4bd374c3f58b?ixlib=rb-4.0.3&auto=format&fit=crop&w=1200&q=80);
    background-size: cover;
    background-position: center;
    color: white; /* Set text color to white for contrast */
    padding: 1rem 46px;
    text-align: center;
    border-radius: 5px;
    margin: 50px;
}

    .hero h1 {
        color: white; /* Ensure heading is white */
    }

/* Mobile responsiveness */
@@media (max-width: 768px) {
    .hero {
        padding: 1.5rem 20px;
        border-radius: 8px;
    }

        .hero h1 {
            font-size: 1.8rem;
            /* adjust heading size */
        }

        .hero p {
            font-size: 1rem;
            /* adjust paragraph size */
        }
}

@@media (max-width: 480px) {
    .hero {
        padding: 1rem 15px;
        border-radius: 6px;
    }

        .hero h1 {
            font-size: 1.5rem;
        }

        .hero p {
            font-size: 0.95rem;
        }
}

.title-bar h1 {
    margin: 0;
    color: #fff;
    /* white text */
    font-size: 2.2rem;
    font-weight: 600;
    font-family: 'Segoe UI', 'Arial', sans-serif;
    /* clean, professional font */
    letter-spacing: 0.5px;
    /* subtle spacing for readability */
}

/* Container for slider */
.container {
    position: relative;
    /* anchor for absolute arrows */
    max-width: 1200px;
    margin: 0 auto;
}

/* Slider wrapper */
.slider {
    overflow: hidden;
    position: relative;
}

/* Slider track with smooth scroll */
.slider-track {
    display: flex;
    scroll-behavior: smooth;
    /* smooth scrolling */
    scroll-snap-type: x mandatory;
    /* snap cards */
    will-change: transform;
    /* GPU acceleration */
    backface-visibility: hidden;
    /* improve performance */
}

/* ----- CARD STYLES (COMPACTED & COLOR FIXED) ----- */
.card {
    min-width: 300px;
    margin: 8px; /* Reduced margin */
    background: #ffffff;
    border-radius: 12px;
    overflow: hidden;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    scroll-snap-align: start;
}

    .card:hover {
        transform: none;
        box-shadow: none;
    }

.card-header {
    color: white;
    padding: 15px; /* Reduced padding */
    position: relative;
}

    .card-header::after {
        content: '';
        position: absolute;
        bottom: 0;
        left: 0;
        width: 100%;
        height: 4px;
        background: linear-gradient(to right, #ff9800, #ff5722);
    }

.advisory-badge {
    display: inline-block;
    background: rgba(255, 255, 255, 0.2);
    padding: 4px 10px; /* Reduced padding */
    border-radius: 20px;
    font-size: 0.75rem; /* Slightly smaller font */
    margin-bottom: 8px; /* Reduced margin */
}

.advisory-title {
    font-size: 0.9rem;
    font-weight: 700;
    margin-bottom: 3px; /* Reduced margin */
}

.advisory-date {
    font-size: 0.85rem; /* Slightly smaller date font */
    opacity: 0.9;
}

.card-content {
    padding: 15px 20px; /* Reduced vertical padding */
}

.cve-id {
    display: inline-block;
    background: #f5f5f5;
    color: #d32f2f;
    padding: 6px 12px; /* Reduced padding */
    border-radius: 6px;
    font-weight: 700;
    font-size: 1rem; /* Slightly smaller font */
    margin-bottom: 15px; /* Reduced margin */
    border-left: 4px solid #d32f2f;
}

.severity-indicator {
    display: flex;
    align-items: center;
    margin-bottom: 15px; /* Reduced margin */
}

.severity-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: #d32f2f; /* **FIXED: Critical color set** */
    margin-right: 10px;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0% {
        opacity: 1;
    }

    50% {
        opacity: 0.5;
    }

    100% {
        opacity: 1;
    }
}

.severity-text {
    font-weight: 600;
    color: #d32f2f; /* **FIXED: Critical color set** */
}

/* Ensure custom styles in HTML override defaults for HIGH severity, e.g.,
                   <div class="severity-dot" style="background: darkorange;"></div>
                   <div class="severity-text" style="color: darkorange;">HIGH SEVERITY</div>
                   These inline styles are present in the HTML above and will work correctly.
                */

.advisory-description {
    line-height: 1.5; /* Slightly tighter line height */
    color: #444;
    margin-bottom: 15px; /* Reduced margin */
    font-size: 0.95rem; /* Slightly smaller text */
}

.read-more {
    color: #1b46c0;
    background: white;
    text-decoration: none;
    font-weight: bold;
    display: inline-block;
    padding-top: 5px;
    padding-bottom: 5px;
    font-size: 0.95rem;
}



/* Slider arrows */
.slider-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background-color: rgba(0, 0, 0, 0.5);
    color: white;
    border: none;
    padding: 12px;
    cursor: pointer;
    z-index: 100;
    border-radius: 50%;
    transition: background 0.3s;
}

    .slider-btn:hover {
        background-color: rgba(0, 0, 0, 0.7);
    }

.slider-btn-left {
    left: -60px;
    /* outside container */
}

.slider-btn-right {
    right: -60px;
    /* outside container */
}

/* Dots below slider */
.slider-dots {
    width: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    margin-top: 15px;
}

    .slider-dots span {
        display: inline-block;
        width: 12px;
        height: 12px;
        margin: 0 6px;
        background: #ccc;
        border-radius: 50%;
        cursor: pointer;
        transition: background 0.3s;
    }

    .slider-dots .active {
        background: #1b46c0;
    }

/* Show more button */
.show-more-container {
    text-align: center;
    margin-top: 20px;
}

.show-more-btn {
    padding: 10px 20px;
    background: #1b46c0;
    color: #fff;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    transition: background 0.3s;
}

    .show-more-btn:hover {
        background: #0f2e8a;
    }

/* Section background */
.content-section {
    background: url('img/pacific-bg2.png') no-repeat center center;
    background-size: cover;
    background-attachment: fixed;
    /* smoother scroll */
}

/* Responsive: hide arrows and dots on mobile */
@media (max-width: 768px) {
    .slider-btn,
    .slider-dots {
        display: none !important;
    }
    /* Adjust card width for smaller screens in slider */
    .card {
        min-width: 90%;
        /* Allow cards to take up more width */
        margin: 10px auto;
        /* Center cards on smaller screens */
    }
}

:root {
    --primary: #157fac;
    --secondary: #157fac;
    --accent: #3949ab;
    --light: #e8eaf6;
    --danger: #157fac;
    --warning: #157fac;
    --success: #157fac;
    --dark: #0d1b2a;
    --gray: #f5f7fa;
}

h1 {
    font-size: 2.5rem;
    margin-bottom: 0.5rem;
}

.subtitle {
    font-size: 1.2rem;
    opacity: 0.9;
    max-width: 800px;
    margin: 0 auto;
}

.intro {
    background-color: white;
    color: #444444;
    padding: 2rem;
    border-radius: 10px;
    box-shadow: 0 2px 15px rgba(0, 0, 0, 0.08);
    margin-bottom: 2rem;
    border-left: 5px solid var(--accent);
}

.container3 {
    padding: 25px;
}

/* Card Grid Style for exactly 3 columns */
.threats-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
    margin-top: 2rem;
    /* IMPORTANT FIX */
    align-items: start; /* prevents row stretching */
}

.threat-card {
    background-color: white;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}


.threat-header {
    padding: 1.2rem;
    color: white;
    display: flex;
    align-items: center;
}

.threat-icon {
    font-size: 1.8rem;
    margin-right: 0.8rem;
}

.threat-title {
    font-weight: 600;
}

.threat-content {
    color: #444444;
    padding: 1.5rem;
}

.threat-description {
    margin-bottom: 1rem;
}

.threat-example {
    background-color: var(--light);
    padding: 1rem;
    border-radius: 6px;
    font-style: italic;
    border-left: 4px solid var(--accent);
}


.threat-prevention {
    margin-top: 1rem;
    font-size: 0.9rem;
}

    .threat-prevention ul {
        padding-left: 1.2rem;
    }

    .threat-prevention li {
        margin-bottom: 0.3rem;
    }

@media (max-width: 1024px) {
    .threats-grid {
        grid-template-columns: repeat(2, 1fr); /* 2 columns on medium screens */
    }
}

@media (max-width: 768px) {
    .threats-grid {
        grid-template-columns: 1fr; /* 1 column on small screens */
    }
}


.malware {
    background-color: var(--danger);
}

.phishing {
    background-color: var(--warning);
}

.dos {
    background-color: #6a1b9a;
}

.mitm {
    background-color: #00838f;
}

.sql-injection {
    background-color: #ad1457;
}

.zero-day {
    background-color: #5d4037;
}

.social-engineering {
    background-color: #ef6c00;
}

.ransomware {
    background-color: #c2185b;
}

/* Accordion behavior */
.accordion-header {
    cursor: pointer;
    justify-content: space-between;
}

    .accordion-header .threat-title {
        flex: 1;
    }

.accordion-arrow {
    transition: transform 0.3s ease;
}

.threat-card.active .accordion-arrow {
    transform: rotate(180deg);
}

/* Hidden by default */
.accordion-content {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s ease, padding 0.3s ease;
    padding-top: 0;
    padding-bottom: 0;
}

/* Expanded state */
.threat-card.active .accordion-content {
    max-height: 500px;
    padding: 1.5rem;
}
