/* soc-simulation.css - Styles for SOC Analyst Simulation */

:root {
    --primary-color: #212529;
    --secondary-color: #495057;
    --accent-color: #6c757d;
    --text-color: #333333;
    --light-bg: #f8f9fa;
    --dark-bg: #212529;
    --border-radius: 4px;
    --box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
    --alert-low: #ffc107;
    --alert-medium: #fd7e14;
    --alert-high: #dc3545;
    --alert-critical: #7a1212;
    --success: #28a745;
    --info: #0d6efd;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: "Times New Roman", Times, serif;
    font-style: italic;
    line-height: 1.6;
    color: var(--text-color);
    background-color: var(--light-bg);
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 15px;
}

/* ============= HEADER ============= */
header {
    background-color: var(--primary-color);
    color: white;
    padding: 15px 0;
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

header:after {
    content: "";
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 100%;
    height: 5px;
    background: linear-gradient(to right, transparent, rgba(255, 255, 255, 0.1), transparent);
}

nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-size: 24px;
    font-weight: bold;
    display: flex;
    align-items: center;
    text-decoration: none;
    color: white;
}

.logo i {
    margin-right: 10px;
    color: #adb5bd;
}

.nav-links {
    display: flex;
    list-style: none;
}

.nav-links li {
    margin-left: 30px;
}

.nav-links a {
    color: white;
    font-weight: 500;
    position: relative;
    text-decoration: none;
    transition: color 0.3s;
}

.nav-links a:after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 1px;
    background-color: white;
    transition: width 0.3s;
}

.nav-links a:hover:after {
    width: 100%;
}

.mobile-menu-btn {
    display: none;
    cursor: pointer;
    font-size: 24px;
    color: white;
}

/* ============= NOTIFICATION ============= */
.notification {
    position: fixed;
    top: 80px;
    right: 20px;
    background-color: white;
    padding: 15px 20px;
    border-radius: var(--border-radius);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    display: none;
    z-index: 2000;
    min-width: 300px;
    max-width: 400px;
    animation: slideIn 0.3s ease-out;
}

@keyframes slideIn {
    from {
        transform: translateX(400px);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

.notification.show {
    display: block;
}

.notification.success {
    border-left: 4px solid var(--success);
}

.notification.error {
    border-left: 4px solid var(--alert-high);
}

.notification.info {
    border-left: 4px solid var(--info);
}

.notification strong {
    display: block;
    margin-bottom: 5px;
    color: var(--primary-color);
}

.notification p {
    margin: 0;
    font-size: 14px;
    color: var(--secondary-color);
}

/* ============= SIMULATION SECTION ============= */
.simulation-section {
    padding: 80px 0;
    position: relative;
}

.section-title {
    font-size: 36px;
    margin-bottom: 35px;
    color: var(--primary-color);
    position: relative;
    display: inline-block;
    z-index: 1;
}

.section-subtitle {
    font-size: 18px;
    color: var(--secondary-color);
    max-width: 800px;
    margin-bottom: 40px;
}

.cyber-accent::before {
    content: "";
    position: absolute;
    height: 2px;
    width: 60px;
    background-color: var(--secondary-color);
    bottom: -12px;
    left: 0;
}

.cyber-accent::after {
    content: "";
    position: absolute;
    height: 2px;
    width: 30px;
    background-color: #adb5bd;
    bottom: -12px;
    left: 70px;
}

/* ============= DASHBOARD ============= */
.soc-dashboard {
    display: grid;
    grid-template-columns: 1fr 3fr;
    gap: 20px;
    margin-top: 30px;
}

.dashboard-sidebar {
    background-color: var(--primary-color);
    color: white;
    padding: 20px;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
    height: fit-content;
    position: sticky;
    top: 100px;
}

.sidebar-header {
    font-size: 18px;
    font-weight: bold;
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
    display: flex;
    align-items: center;
}

.sidebar-header i {
    margin-right: 10px;
}

.filter-heading {
    font-size: 14px;
    margin: 20px 0 10px;
    opacity: 0.8;
    font-weight: 600;
}

.filter-option {
    display: flex;
    align-items: center;
    margin-bottom: 8px;
    cursor: pointer;
    user-select: none;
}

.filter-option input {
    margin-right: 10px;
    cursor: pointer;
}

.filter-option label {
    cursor: pointer;
    flex: 1;
}

.filter-stats {
    background-color: rgba(255, 255, 255, 0.1);
    padding: 15px;
    border-radius: var(--border-radius);
    margin-top: 20px;
}

.stat-item {
    display: flex;
    justify-content: space-between;
    margin-bottom: 10px;
    font-size: 14px;
}

.stat-value {
    font-weight: bold;
    color: #fff;
}

/* ============= DASHBOARD MAIN ============= */
.dashboard-main {
    background-color: white;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
    overflow: hidden;
}

.tabs {
    display: flex;
    background-color: #e9ecef;
    border-bottom: 1px solid #dee2e6;
    overflow-x: auto;
}

.tab {
    padding: 15px 25px;
    cursor: pointer;
    border-bottom: 3px solid transparent;
    font-weight: 500;
    transition: all 0.3s;
    white-space: nowrap;
    flex-shrink: 0;
}

.tab.active {
    background-color: white;
    border-bottom-color: var(--secondary-color);
}

.tab:hover:not(.active) {
    background-color: #f1f3f5;
}

.tab i {
    margin-right: 8px;
}

.tab-content {
    display: none;
}

.tab-content.active {
    display: block;
}

/* ============= ALERTS ============= */
.alert-list {
    list-style: none;
}

.alert-item {
    padding: 15px;
    border-left: 4px solid transparent;
    border-bottom: 1px solid #f1f3f5;
    cursor: pointer;
    transition: all 0.3s;
    position: relative;
}

.alert-item:hover {
    background-color: #f8f9fa;
    transform: translateX(2px);
}

.alert-item.low {
    border-left-color: var(--alert-low);
}

.alert-item.medium {
    border-left-color: var(--alert-medium);
}

.alert-item.high {
    border-left-color: var(--alert-high);
}

.alert-item.critical {
    border-left-color: var(--alert-critical);
}

.alert-item.resolved {
    opacity: 0.5;
    background-color: #f8f9fa;
}

.alert-item.resolved .alert-title {
    text-decoration: line-through;
}

.alert-header {
    display: flex;
    justify-content: space-between;
    margin-bottom: 8px;
    align-items: center;
    gap: 10px;
}

.alert-title {
    font-weight: bold;
    font-size: 16px;
    color: var(--primary-color);
    flex: 1;
}

.alert-severity {
    font-size: 13px;
    padding: 3px 10px;
    border-radius: 20px;
    color: white;
    white-space: nowrap;
}

.alert-severity.low {
    background-color: var(--alert-low);
}

.alert-severity.medium {
    background-color: var(--alert-medium);
}

.alert-severity.high {
    background-color: var(--alert-high);
}

.alert-severity.critical {
    background-color: var(--alert-critical);
}

.alert-details {
    display: flex;
    font-size: 14px;
    color: var(--secondary-color);
    flex-wrap: wrap;
    gap: 15px;
}

.alert-source,
.alert-time {
    display: flex;
    align-items: center;
}

.alert-source i,
.alert-time i {
    margin-right: 5px;
    font-size: 12px;
}

.alert-actions {
    position: absolute;
    right: 15px;
    bottom: 15px;
    display: none;
    gap: 10px;
}

.alert-item:hover .alert-actions {
    display: flex;
}

.action-btn {
    background: none;
    border: 1px solid var(--secondary-color);
    color: var(--secondary-color);
    padding: 5px 10px;
    cursor: pointer;
    font-size: 13px;
    display: flex;
    align-items: center;
    border-radius: 3px;
    transition: all 0.3s;
    font-style: italic;
}

.action-btn:hover {
    background-color: var(--secondary-color);
    color: white;
}

.action-btn i {
    margin-right: 5px;
}

/* ============= ALERT DETAIL VIEW ============= */
.alert-detail-view {
    padding: 30px;
    max-height: 800px;
    overflow-y: auto;
}

.detail-header {
    border-bottom: 1px solid #dee2e6;
    padding-bottom: 20px;
    margin-bottom: 20px;
}

.detail-title {
    font-size: 24px;
    margin-bottom: 10px;
    color: var(--primary-color);
    font-weight: bold;
}

.detail-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    font-size: 14px;
    color: var(--secondary-color);
}

.detail-meta-item {
    display: flex;
    align-items: center;
}

.detail-meta-item i {
    margin-right: 8px;
    color: var(--accent-color);
}

.detail-section {
    margin-bottom: 30px;
}

.detail-section-title {
    font-size: 18px;
    margin-bottom: 15px;
    color: var(--primary-color);
    font-weight: bold;
}

.detail-description {
    background-color: #f8f9fa;
    padding: 15px;
    border-radius: var(--border-radius);
    margin-bottom: 20px;
    font-style: normal;
}

.detail-table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 20px;
}

.detail-table th,
.detail-table td {
    padding: 12px 15px;
    text-align: left;
    border-bottom: 1px solid #dee2e6;
    font-style: normal;
}

.detail-table th {
    background-color: #f1f3f5;
    font-weight: 600;
}

.detail-table tr:hover {
    background-color: #f8f9fa;
}

.code-block {
    background-color: #f1f3f5;
    padding: 15px;
    border-radius: var(--border-radius);
    font-family: monospace;
    white-space: pre-wrap;
    overflow-x: auto;
    border: 1px solid #dee2e6;
    font-style: normal;
    font-size: 12px;
    line-height: 1.4;
}

.response-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    margin-top: 30px;
    padding-top: 20px;
    border-top: 1px solid #dee2e6;
}

.action-btn-large {
    padding: 10px 20px;
    background-color: var(--secondary-color);
    color: white;
    border: none;
    border-radius: var(--border-radius);
    cursor: pointer;
    font-weight: 500;
    display: flex;
    align-items: center;
    transition: all 0.3s;
    font-style: italic;
}

.action-btn-large i {
    margin-right: 8px;
}

.action-btn-large.primary {
    background-color: var(--primary-color);
}

.action-btn-large.danger {
    background-color: var(--alert-high);
}

.action-btn-large.success {
    background-color: var(--success);
}

.action-btn-large:hover:not(:disabled) {
    opacity: 0.9;
    transform: translateY(-2px);
}

.action-btn-large:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

/* ============= METRICS & DASHBOARD ============= */
.metrics-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    margin-bottom: 30px;
    padding: 20px;
}

.metric-card {
    background-color: white;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
    padding: 20px;
    text-align: center;
    transition: all 0.3s;
}

.metric-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.metric-icon {
    font-size: 30px;
    margin-bottom: 15px;
    color: var(--secondary-color);
}

.metric-value {
    font-size: 36px;
    font-weight: bold;
    margin-bottom: 5px;
    color: var(--primary-color);
}

.metric-title {
    font-size: 16px;
    color: var(--secondary-color);
}

.chart-container {
    background-color: white;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
    padding: 20px;
    margin: 0 20px 30px;
}

.chart-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    flex-wrap: wrap;
    gap: 15px;
}

.chart-title {
    font-size: 18px;
    font-weight: bold;
    color: var(--primary-color);
}

.time-selector {
    display: flex;
    gap: 10px;
}

.time-option {
    padding: 5px 10px;
    background-color: #f1f3f5;
    border-radius: 3px;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.3s;
}

.time-option.active {
    background-color: var(--secondary-color);
    color: white;
}

.time-option:hover:not(.active) {
    background-color: #dee2e6;
}

.chart {
    width: 100%;
    height: 300px;
    background-color: #f8f9fa;
    display: flex;
    justify-content: center;
    align-items: center;
    color: var(--secondary-color);
    border-radius: var(--border-radius);
    font-size: 14px;
}

/* ============= TABLES ============= */
.list-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 1px solid #dee2e6;
    flex-wrap: wrap;
    gap: 15px;
}

.list-title {
    font-size: 18px;
    font-weight: bold;
    color: var(--primary-color);
}

.search-bar {
    display: flex;
    gap: 10px;
}

.search-input {
    padding: 8px 15px;
    border: 1px solid #dee2e6;
    border-radius: var(--border-radius);
    width: 250px;
    font-style: italic;
    font-family: "Times New Roman", Times, serif;
}

.search-input:focus {
    outline: none;
    border-color: var(--secondary-color);
}

.search-btn {
    background-color: var(--secondary-color);
    color: white;
    border: none;
    border-radius: var(--border-radius);
    padding: 8px 15px;
    cursor: pointer;
    transition: all 0.3s;
}

.search-btn:hover {
    background-color: var(--primary-color);
}

.list-table {
    width: 100%;
    border-collapse: collapse;
}

.list-table th,
.list-table td {
    padding: 12px 15px;
    text-align: left;
    border-bottom: 1px solid #dee2e6;
    font-style: normal;
}

.list-table th {
    background-color: #f1f3f5;
    font-weight: 600;
    color: var(--primary-color);
}

.list-table tbody tr {
    transition: background-color 0.2s;
}

.list-table tbody tr:hover {
    background-color: #f8f9fa;
    cursor: pointer;
}

.status-badge {
    display: inline-block;
    padding: 4px 8px;
    border-radius: 3px;
    font-size: 12px;
    color: white;
    font-weight: 500;
}

.status-badge.active {
    background-color: #20c997;
}

.status-badge.inactive {
    background-color: var(--accent-color);
}

.status-badge.in-progress {
    background-color: #0d6efd;
}

.status-badge.pending {
    background-color: var(--alert-low);
    color: #333;
}

.status-badge.closed {
    background-color: #6c757d;
}

/* ============= PAGINATION ============= */
.pagination {
    display: flex;
    justify-content: center;
    margin-top: 20px;
    gap: 5px;
}

.page-btn {
    width: 35px;
    height: 35px;
    display: flex;
    justify-content: center;
    align-items: center;
    border: 1px solid #dee2e6;
    border-radius: var(--border-radius);
    cursor: pointer;
    transition: all 0.3s;
    background-color: white;
    color: var(--text-color);
}

.page-btn:hover {
    background-color: #f1f3f5;
}

.page-btn.active {
    background-color: var(--secondary-color);
    color: white;
    border-color: var(--secondary-color);
}

/* ============= RESPONSIVE DESIGN ============= */
@media (max-width: 992px) {
    .soc-dashboard {
        grid-template-columns: 1fr;
    }

    .dashboard-sidebar {
        position: static;
    }

    .metrics-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .metrics-grid {
        grid-template-columns: 1fr;
    }

    .mobile-menu-btn {
        display: block;
    }

    .nav-links {
        position: fixed;
        top: 70px;
        left: 0;
        width: 100%;
        flex-direction: column;
        background-color: var(--primary-color);
        padding: 20px;
        transform: translateY(-150%);
        transition: transform 0.3s;
        z-index: 1000;
    }

    .nav-links.active {
        transform: translateY(0);
    }

    .nav-links li {
        margin: 15px 0;
    }

    .tabs {
        overflow-x: auto;
    }

    .response-actions {
        flex-direction: column;
    }

    .action-btn-large {
        width: 100%;
        justify-content: center;
    }

    .chart-header {
        flex-direction: column;
        align-items: flex-start;
    }

    .list-header {
        flex-direction: column;
        align-items: flex-start;
    }

    .search-bar {
        width: 100%;
    }

    .search-input {
        flex: 1;
        width: auto;
    }
}

@media (max-width: 576px) {
    .detail-meta {
        flex-direction: column;
        gap: 10px;
    }

    .alert-detail-view {
        padding: 15px;
    }

    .section-title {
        font-size: 28px;
    }

    .section-subtitle {
        font-size: 16px;
    }

    .notification {
        right: 10px;
        left: 10px;
        min-width: auto;
    }

    .alert-actions {
        position: static;
        display: flex;
        margin-top: 10px;
    }

    .alert-item:hover .alert-actions {
        display: flex;
    }

    .list-table {
        font-size: 14px;
    }

    .list-table th,
    .list-table td {
        padding: 8px 10px;
    }
}

/* ============= LOADING STATES ============= */
.loading {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    border-top-color: white;
    animation: spin 1s ease-in-out infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* ============= UTILITIES ============= */
.text-center {
    text-align: center;
}

.mb-20 {
    margin-bottom: 20px;
}

.mt-20 {
    margin-top: 20px;
}

.p-20 {
    padding: 20px;
}

/* ============= SCROLLBAR STYLING ============= */
.alert-detail-view::-webkit-scrollbar,
.tab-content::-webkit-scrollbar {
    width: 8px;
}

.alert-detail-view::-webkit-scrollbar-track,
.tab-content::-webkit-scrollbar-track {
    background: #f1f1f1;
}

.alert-detail-view::-webkit-scrollbar-thumb,
.tab-content::-webkit-scrollbar-thumb {
    background: #888;
    border-radius: 4px;
}

.alert-detail-view::-webkit-scrollbar-thumb:hover,
.tab-content::-webkit-scrollbar-thumb:hover {
    background: #555;
}

/* ============= PRINT STYLES ============= */
@media print {
    .dashboard-sidebar,
    .tabs,
    .response-actions,
    header,
    .notification {
        display: none;
    }

    .dashboard-main {
        box-shadow: none;
    }

    .alert-detail-view {
        max-height: none;
    }
}
