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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    background-color: #0f0f0f;
    color: #f3f4f6;
    line-height: 1.6;
}

.container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 1.5rem;
}

/* Header */
.header {
    background-color: #1a1a1a;
    padding: 1.5rem 1.5rem 1rem;
}

.logo {
    font-family: 'Courier New', 'Consolas', monospace;
    font-size: 2rem;
    font-weight: 700;
    color: #60a5fa;
    text-align: center;
    letter-spacing: 0.1em;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.logo::before {
    content: '';
    display: inline-block;
    width: 8px;
    height: 8px;
    background: #60a5fa;
    border-radius: 2px;
    box-shadow:
        0 0 10px rgba(96, 165, 250, 0.5),
        0 0 20px rgba(96, 165, 250, 0.3);
    animation: pulse-glow 2s ease-in-out infinite;
}

@keyframes pulse-glow {
    0%, 100% {
        opacity: 1;
        transform: scale(1);
    }
    50% {
        opacity: 0.7;
        transform: scale(1.1);
    }
}

/* Subtitle Section */
.subtitle-section {
    background-color: #1a1a1a;
    border-bottom: 1px solid #2a2a2a;
    padding: 0.5rem 1.5rem 1.5rem;
}

.subtitle-content {
    text-align: center;
    margin-bottom: 1.5rem;
}

.subtitle {
    color: #9ca3af;
    font-size: 1rem;
}

/* Search */
.search-container {
    display: flex;
    gap: 0.75rem;
    max-width: 768px;
    margin: 0 auto;
}

.search-wrapper {
    position: relative;
    flex: 1;
}

.search-icon {
    position: absolute;
    left: 1rem;
    top: 50%;
    transform: translateY(-50%);
    width: 1.25rem;
    height: 1.25rem;
    color: #6b7280;
}

.search-input {
    width: 100%;
    background-color: #252525;
    border: 1px solid #3a3a3a;
    border-radius: 0.5rem;
    padding: 0.75rem 1rem 0.75rem 3rem;
    color: #f3f4f6;
    font-size: 0.875rem;
}

.search-input:focus {
    outline: none;
    border-color: #60a5fa;
}

.btn-primary {
    background-color: #60a5fa;
    color: white;
    padding: 0.75rem 1.5rem;
    border-radius: 0.5rem;
    font-weight: 500;
    border: none;
    cursor: pointer;
    font-size: 0.875rem;
    transition: background-color 0.2s;
}

.btn-primary:hover {
    background-color: #ff5252;
}

/* Filters & Navigation */
.filters-section {
    background-color: #1a1a1a;
    border-bottom: 1px solid #2a2a2a;
    padding: 1rem 1.5rem;
}

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

.quick-filters {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.filter-label {
    font-size: 0.875rem;
    font-weight: 600;
    color: #9ca3af;
    text-transform: uppercase;
}

.filter-buttons {
    display: flex;
    gap: 0.5rem;
}

.filter-btn {
    padding: 0.5rem 1rem;
    border-radius: 0.375rem;
    font-weight: 500;
    font-size: 0.875rem;
    border: none;
    cursor: pointer;
    background-color: #252525;
    color: #9ca3af;
    transition: all 0.2s;
}

.filter-btn:hover {
    background-color: #2f2f2f;
}

.filter-btn.active {
    background-color: #60a5fa;
    color: white;
}

/* Navigation Menu */
.nav-menu {
    display: flex;
    gap: 2rem;
}

.nav-link {
    color: #9ca3af;
    font-size: 0.875rem;
    font-weight: 500;
    text-decoration: none;
    padding: 0.5rem 0;
    border-bottom: 2px solid transparent;
    transition: color 0.2s;
}

.nav-link:hover {
    color: #e5e7eb;
}

.nav-link.active {
    color: #60a5fa;
    font-weight: 600;
    border-bottom-color: #60a5fa;
}

/* Stats Section */
.stats-section {
    background-color: #1a1a1a;
    border-bottom: 1px solid #2a2a2a;
    padding: 1rem 1.5rem;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 0.25rem;
}

.stat-card {
    background-color: #252525;
    border: 1px solid #3a3a3a;
    border-radius: 0.25rem;
    padding: 0.25rem 0.5rem;
    text-align: center;
}

.stat-value {
    font-size: 0.875rem;
    font-weight: bold;
    color: #60a5fa;
}

.stat-value-orange {
    color: #ffa94d;
}

.stat-label {
    font-size: 0.5rem;
    color: #9ca3af;
    text-transform: uppercase;
    margin-top: 0.125rem;
}

/* Honeypot Card */
.honeypot-card {
    background-color: #1e293b;
    border: 2px solid #10b981;
    box-shadow: 0 0 20px rgba(16, 185, 129, 0.15);
}

.honeypot-header {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0.5rem;
    justify-content: center;
}

.honeypot-icon {
    width: 1.25rem;
    height: 1.25rem;
    color: #10b981;
}

.honeypot-label {
    font-size: 0.75rem;
    color: #9ca3af;
    text-transform: uppercase;
    font-weight: 600;
}

.honeypot-detail {
    font-size: 0.75rem;
    color: #64748b;
    margin-bottom: 0.5rem;
}

.honeypot-events {
    font-size: 0.875rem;
    color: #e2e8f0;
    font-weight: 600;
}

.events-count {
    color: #60a5fa;
}

/* Cards Section */
.cards-section {
    padding: 2rem 1.5rem;
}

.cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 1.5rem;
}

.detection-card {
    background-color: #1a1a1a;
    border: 1px solid #2a2a2a;
    border-radius: 0.5rem;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    transition: border-color 0.3s;
    cursor: pointer;
}

.detection-card:hover {
    border-color: #60a5fa;
}

.card-badges {
    padding: 1rem 1rem 0.75rem;
    display: flex;
    gap: 0.5rem;
}

.badge {
    font-size: 0.75rem;
    font-weight: 600;
    padding: 0.25rem 0.75rem;
    border-radius: 0.375rem;
}

.badge-protocol-abuse { background-color: rgba(168, 85, 247, 0.15); color: #d8b4fe; }
.badge-network { background-color: rgba(6, 182, 212, 0.15); color: #a5f3fc; }
.badge-fraud { background-color: rgba(236, 72, 153, 0.15); color: #f9a8d4; }
.badge-auth { background-color: rgba(251, 191, 36, 0.15); color: #fde68a; }

.badge-critical { background-color: rgba(244, 63, 94, 0.15); color: #fda4af; }
.badge-high { background-color: rgba(251, 146, 60, 0.15); color: #fdba74; }
.badge-medium { background-color: rgba(250, 204, 21, 0.15); color: #fde047; }
.badge-low { background-color: rgba(59, 130, 246, 0.15); color: #93c5fd; }

.card-title {
    padding: 0 1rem 0.75rem;
    color: white;
    font-weight: 600;
    font-size: 1.125rem;
    line-height: 1.4;
}

.card-identifier {
    padding: 0 1rem 0.75rem;
}

.card-identifier code {
    font-size: 0.75rem;
    color: #9ca3af;
    background-color: #252525;
    padding: 0.25rem 0.5rem;
    border-radius: 0.25rem;
    font-family: 'Courier New', monospace;
}

.card-description {
    padding: 0 1rem 1rem;
    flex: 1;
    font-size: 0.875rem;
    color: #9ca3af;
    line-height: 1.6;
}

.card-tags {
    padding: 0 1rem 1rem;
    display: flex;
    flex-wrap: wrap;
    gap: 0.25rem;
}

.tag {
    font-size: 0.75rem;
    background-color: #252525;
    color: #9ca3af;
    padding: 0.25rem 0.5rem;
    border-radius: 0.25rem;
}

.card-mapping {
    padding: 0 1rem 1rem;
    display: flex;
    flex-wrap: wrap;
    gap: 0.25rem;
}

.mapping-badge {
    font-size: 0.75rem;
    padding: 0.25rem 0.5rem;
    border-radius: 0.25rem;
}

.mapping-mitre {
    background-color: rgba(96, 165, 250, 0.15);
    color: #93c5fd;
}

.mapping-iec {
    background-color: rgba(192, 132, 252, 0.15);
    color: #c084fc;
}

.card-footer {
    padding: 0.75rem 1rem;
    border-top: 1px solid #2a2a2a;
    background-color: rgba(37, 37, 37, 0.5);
}

.card-link {
    font-size: 0.875rem;
    color: #60a5fa;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 500;
    text-decoration: none;
}

/* Modal - CENTERED */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.9);
    overflow-y: auto;
    padding: 1rem;
}

.modal.active {
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-content {
    background-color: #1a1a1a;
    border: 1px solid #2a2a2a;
    border-radius: 0.75rem;
    max-width: 1600px;
    width: 98%;
    max-height: 95vh;
    display: flex;
    flex-direction: column;
}

.modal-header {
    background-color: #1a1a1a;
    border-bottom: 1px solid #2a2a2a;
    padding: 1.5rem;
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
}

.modal-title {
    font-size: 1.5rem;
    font-weight: bold;
    color: #f3f4f6;
    margin-bottom: 0.5rem;
}

.modal-badges {
    display: flex;
    gap: 0.5rem;
    margin-top: 0.5rem;
}

.modal-close {
    background: none;
    border: none;
    color: #9ca3af;
    font-size: 2rem;
    cursor: pointer;
    line-height: 1;
    padding: 0;
    width: 2rem;
    height: 2rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: color 0.2s;
}

.modal-close:hover {
    color: white;
}

/* NEW LAYOUT - 2 columns */
.modal-body {
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    overflow-y: auto;
    flex: 1;
}

.modal-body-top {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
}

/* Left Column */
.left-column {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

/* Right Column */
.right-column {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.modal-section {
    margin-bottom: 0;
}

.section-title {
    font-size: 0.7rem;
    font-weight: 600;
    color: #9ca3af;
    margin-bottom: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.modal-text {
    color: #e5e7eb;
    line-height: 1.6;
    font-size: 0.813rem;
}

/* Mappings Row */
.mappings-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
    height: 700px;
}

.mapping-column {
    display: flex;
    flex-direction: column;
    background-color: #252525;
    border: 1px solid #3a3a3a;
    border-radius: 0.5rem;
    padding: 1rem;
    overflow-y: auto;
}

.badge-list {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    margin-bottom: 0.75rem;
}

.mapping-badge {
    font-size: 0.75rem;
    padding: 0.5rem 0.75rem;
    border-radius: 0.375rem;
    border: 1px solid;
    text-align: center;
    background-color: transparent;
}

.mapping-mitre {
    color: #93c5fd;
    border-color: rgba(96, 165, 250, 0.5);
}

.mapping-iec {
    color: #c084fc;
    border-color: rgba(192, 132, 252, 0.5);
}

.mapping-description {
    padding: 0.75rem;
    background-color: #1a1a1a;
    border-radius: 0.375rem;
    font-size: 0.75rem;
    color: #9ca3af;
    line-height: 1.5;
}

.mapping-description strong {
    color: #e5e7eb;
    display: block;
    margin-bottom: 0.4rem;
    font-size: 0.813rem;
}

.tag-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

/* Lab Testing - Right Column */
.lab-testing-section {
    
    border: 1px solid rgba(59, 130, 246, 0.2);
    border-radius: 0.5rem;
    padding: 1.25rem;
    margin-top: 1rem;
}

.lab-header {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0.75rem;
}

.lab-header svg {
    color: #60a5fa;
    width: 16px;
    height: 16px;
}

.lab-header .section-title {
    margin: 0;
    font-size: 0.7rem;
}

.lab-description {
    color: #9ca3af;
    font-size: 0.813rem;
    line-height: 1.5;
    margin-bottom: 0;
}

.lab-description strong {
    color: #e5e7eb;
    font-size: 0.875rem;
}

.btn-trigger {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%);
    color: white;
    padding: 0.875rem 1.25rem;
    border-radius: 0.5rem;
    font-weight: 600;
    border: none;
    cursor: pointer;
    font-size: 0.875rem;
    transition: all 0.2s;
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.3);
    width: 100%;
    margin-top: 1rem;
}

.btn-trigger:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(59, 130, 246, 0.4);
    background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%);
}

.btn-trigger:active {
    transform: translateY(0);
}

.btn-trigger svg {
    width: 1rem;
    height: 1rem;
}

.lab-status {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1rem;
    background-color: rgba(96, 165, 250, 0.1);
    border: 1px solid rgba(96, 165, 250, 0.3);
    border-radius: 0.375rem;
    color: #93c5fd;
    font-size: 0.875rem;
    margin-top: 1rem;
}

.status-icon {
    font-size: 1.25rem;
    animation: pulse 1.5s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

.lab-results {
    padding: 1rem;
    border: 0px solid #10b981;
    border-radius: 0.375rem;
    animation: slideIn 0.3s ease-out;
    margin-top: 1rem;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.lab-results h4 {
    color: #10b981;
    font-size: 0.938rem;
    font-weight: 600;
    margin-bottom: 0.75rem;
}

.lab-results ul {
    list-style: none;
    padding: 0;
}

.lab-results li {
    padding: 0.5rem 0;
    border-bottom: 0px solid rgba(16, 185, 129, 0.1);
    color: #9ca3af;
    font-size: 0.813rem;
}

.lab-results li:last-child {
    border-bottom: none;
}

.lab-results li::before {
    content: "✓ ";
    color: #10b981;
    font-weight: bold;
    margin-right: 0.5rem;
}

.lab-results a {
    color: #60a5fa;
    text-decoration: underline;
}

/* Resource Frames */
.resource-frame {
    background-color: #0f0f0f;
    border: 1px solid #2a2a2a;
    border-radius: 0.5rem;
    overflow: hidden;
    margin-bottom: 1rem;
}

.resource-frame:last-child {
    margin-bottom: 0;
}

.resource-frame-header {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1rem;
    background-color: #1a1a1a;
    border-bottom: 1px solid #2a2a2a;
}

.resource-frame-header svg {
    color: #60a5fa;
    flex-shrink: 0;
    width: 16px;
    height:16px;
    
}

.resource-frame-header span {
    flex: 1;
    font-size: 0.875rem;
    font-weight: 500;
    color: #e5e7eb;
}

.open-external {
    color: #9ca3af;
    transition: color 0.2s;
}

.open-external:hover {
    color: #60a5fa;
}

.iframe-container {
    position: relative;
    width: 100%;
    padding-bottom: 50%;
    height: 0;
    overflow: hidden;
    background-color: #0a0a0a;
}

.iframe-container.kibana {
    padding-bottom: 55%;
}

.iframe-container iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: none;
}

.iframe-placeholder {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    color: #6b7280;
}

.iframe-container iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: none;
    z-index: 2;
}

.iframe-placeholder {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    color: #6b7280;
    z-index: 1;
}

/* Hide placeholder when iframe has content */
.iframe-container iframe[src]:not([src=""]) ~ .iframe-placeholder {
    display: none;
}

.iframe-placeholder svg {
    width: 3rem;
    height: 3rem;
    color: #4b5563;
}

.iframe-placeholder p {
    font-weight: 500;
    font-size: 0.938rem;
    margin: 0;
}

.iframe-placeholder small {
    font-size: 0.75rem;
    color: #6b7280;
}

.modal-footer {
    border-top: 1px solid #2a2a2a;
    padding: 0.75rem 1.5rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 0.75rem;
    color: #6b7280;
}

.modal-date {
    color: #6b7280;
}

.modal-source {
    color: #6b7280;
}

/* No Results */
.no-results {
    text-align: center;
    padding: 4rem 0;
}

.no-results p {
    color: #6b7280;
    font-size: 1.125rem;
}

/* Footer */
.footer {
    background-color: #1a1a1a;
    border-top: 1px solid #2a2a2a;
    padding: 1.5rem;
    margin-top: 3rem;
}

.footer p {
    text-align: center;
    color: #6b7280;
    font-size: 0.875rem;
}

/* Responsive */
@media (max-width: 1024px) {
    .stats-grid {
        grid-template-columns: repeat(3, 1fr);
    }

    .honeypot-card {
        grid-column: span 3;
    }

    .filters-nav-wrapper {
        flex-direction: column;
        gap: 1rem;
        align-items: flex-start;
    }

    .nav-menu {
        width: 100%;
        justify-content: flex-start;
    }

    .modal-body-top {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .cards-grid {
        grid-template-columns: 1fr;
    }

    .mappings-row {
        grid-template-columns: 1fr;
    }

    .search-container {
        flex-direction: column;
    }
}
