/* Achievo AV — Kali Linux × Kaspersky-style UI (flat, no glow) */

#win-antivirus {
    width: 920px;
    height: 620px;
    background: #1a1a1a;
    border: 1px solid #3a3a3a;
    box-shadow: none;
    display: none;
    flex-direction: column;
    font-family: "Segoe UI", "Ubuntu", system-ui, sans-serif;
    color: #d4d4d4;
}

#win-antivirus .w-header {
    background: #222 !important;
    border-bottom: 1px solid #3a3a3a !important;
    color: #ccc !important;
    font-family: "Segoe UI", system-ui, sans-serif !important;
    font-weight: 600 !important;
    letter-spacing: 0 !important;
    text-shadow: none !important;
    padding: 0 12px !important;
    height: 36px;
    min-height: 36px;
}

#win-antivirus .w-header .w-close {
    color: #999 !important;
    text-shadow: none !important;
    font-size: 14px;
}

#win-antivirus .w-header .w-close:hover {
    color: #fff !important;
}

.av-titlebar-brand {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 13px;
}

.av-titlebar-logo {
    width: 22px;
    height: 22px;
    background: #27ae60;
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    color: #fff;
    font-weight: 700;
}

.av-titlebar-ver {
    font-size: 11px;
    color: #666;
    font-weight: 400;
}

#win-antivirus .w-content {
    padding: 0 !important;
    background: #1e1e1e !important;
    flex: 1;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.av-shell {
    display: flex;
    flex: 1;
    min-height: 0;
}

/* ── Sidebar (Kaspersky nav) ── */
.av-sidebar {
    width: 200px;
    background: #252525;
    border-right: 1px solid #333;
    display: flex;
    flex-direction: column;
    flex-shrink: 0;
}

.av-nav {
    flex: 1;
    padding: 8px 0;
}

.av-nav-item {
    display: flex;
    align-items: center;
    gap: 10px;
    width: 100%;
    padding: 10px 16px;
    border: none;
    background: transparent;
    color: #aaa;
    font-size: 13px;
    font-family: inherit;
    text-align: left;
    cursor: pointer;
    border-left: 3px solid transparent;
    transition: background 0.12s, color 0.12s;
}

.av-nav-item:hover {
    background: #2d2d2d;
    color: #ddd;
}

.av-nav-item.active {
    background: #2a2a2a;
    color: #fff;
    border-left-color: #27ae60;
}

.av-nav-icon {
    width: 18px;
    text-align: center;
    font-size: 14px;
    opacity: 0.85;
}

.av-nav-badge {
    margin-left: auto;
    background: #333;
    color: #888;
    font-size: 10px;
    padding: 1px 6px;
    border-radius: 10px;
    min-width: 18px;
    text-align: center;
}

.av-nav-item.active .av-nav-badge {
    background: #27ae60;
    color: #fff;
}

.av-sidebar-footer {
    padding: 12px 16px;
    border-top: 1px solid #333;
}

.av-shield-toggle-label {
    font-size: 11px;
    color: #888;
    margin-bottom: 8px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.av-toggle-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
}

.av-toggle-label {
    font-size: 12px;
    color: #bbb;
}

/* Toggle switch */
.av-toggle {
    position: relative;
    width: 40px;
    height: 22px;
    background: #444;
    border: 1px solid #555;
    border-radius: 11px;
    cursor: pointer;
    padding: 0;
    flex-shrink: 0;
    transition: background 0.15s;
}

.av-toggle::after {
    content: "";
    position: absolute;
    top: 2px;
    left: 2px;
    width: 16px;
    height: 16px;
    background: #ccc;
    border-radius: 50%;
    transition: transform 0.15s, background 0.15s;
}

.av-toggle.active {
    background: #27ae60;
    border-color: #229954;
}

.av-toggle.active::after {
    transform: translateX(18px);
    background: #fff;
}

/* ── Main panel ── */
.av-main {
    flex: 1;
    display: flex;
    flex-direction: column;
    min-width: 0;
    min-height: 0;
}

.av-panel {
    display: none;
    flex: 1;
    flex-direction: column;
    padding: 20px 24px;
    overflow: hidden;
    min-height: 0;
}

.av-panel.active {
    display: flex;
}

.av-panel-title {
    font-size: 18px;
    font-weight: 600;
    color: #eee;
    margin: 0 0 4px;
}

.av-panel-desc {
    font-size: 12px;
    color: #777;
    margin: 0 0 20px;
}

/* ── Home / Protection ── */
.av-home-top {
    display: flex;
    gap: 24px;
    align-items: flex-start;
    margin-bottom: 20px;
}

.av-shield-block {
    flex-shrink: 0;
    width: 120px;
    text-align: center;
}

.av-shield-icon {
    width: 80px;
    height: 80px;
    margin: 0 auto 8px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 36px;
    background: #2a2a2a;
    border: 2px solid #3a3a3a;
    transition: border-color 0.2s, background 0.2s;
}

.av-shield-block.av-state--safe .av-shield-icon {
    border-color: #27ae60;
    background: #1e2e24;
    color: #27ae60;
}

.av-shield-block.av-state--warn .av-shield-icon {
    border-color: #e67e22;
    background: #2e2418;
    color: #e67e22;
}

.av-shield-block.av-state--off .av-shield-icon {
    border-color: #555;
    background: #252525;
    color: #777;
}

.av-status-block {
    flex: 1;
    min-width: 0;
}

#av-status-title {
    font-size: 22px;
    font-weight: 600;
    margin: 0 0 6px;
    color: #27ae60;
}

.av-status-block.av-state--warn #av-status-title {
    color: #e67e22;
}

.av-status-block.av-state--off #av-status-title {
    color: #888;
}

#av-status-subtitle {
    font-size: 13px;
    color: #888;
    margin: 0 0 16px;
    line-height: 1.5;
}

.av-health-track {
    height: 6px;
    background: #333;
    border-radius: 3px;
    overflow: hidden;
}

#av-health-bar {
    height: 100%;
    width: 100%;
    background: #27ae60;
    border-radius: 3px;
    transition: width 0.3s, background 0.3s;
    box-shadow: none;
}

.av-health-track.av-state--warn #av-health-bar {
    background: #e67e22;
}

.av-health-track.av-state--off #av-health-bar {
    background: #666;
}

.av-health-label {
    display: flex;
    justify-content: space-between;
    font-size: 11px;
    color: #666;
    margin-top: 4px;
}

.av-components {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
    margin-bottom: 16px;
}

.av-comp-card {
    background: #252525;
    border: 1px solid #333;
    border-radius: 4px;
    padding: 14px;
}

.av-comp-label {
    font-size: 10px;
    color: #666;
    text-transform: uppercase;
    letter-spacing: 0.4px;
    margin-bottom: 6px;
}

.av-comp-value {
    font-size: 14px;
    font-weight: 600;
    color: #27ae60;
}

.av-comp-card.av-comp--warn .av-comp-value {
    color: #e67e22;
}

.av-comp-card.av-comp--off .av-comp-value {
    color: #777;
}

.av-stats-row {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 12px;
}

.av-stat-box {
    background: #252525;
    border: 1px solid #333;
    border-radius: 4px;
    padding: 10px 12px;
}

.av-stat-label {
    font-size: 10px;
    color: #666;
    margin-bottom: 4px;
}

.av-stat-value {
    font-size: 15px;
    font-weight: 600;
    color: #ddd;
    font-family: "JetBrains Mono", monospace;
}

.av-stat-value.av-ok {
    color: #27ae60;
}

/* ── Scan panel ── */
.av-scan-actions {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 12px;
}

.av-btn-primary {
    background: #27ae60;
    color: #fff;
    border: none;
    border-radius: 4px;
    padding: 8px 20px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    font-family: inherit;
    transition: background 0.12s;
}

.av-btn-primary:hover:not(:disabled) {
    background: #229954;
}

.av-btn-primary:disabled {
    background: #444;
    color: #888;
    cursor: not-allowed;
}

.av-scan-hint {
    font-size: 12px;
    color: #666;
}

.av-terminal-wrap {
    flex: 1;
    display: flex;
    flex-direction: column;
    min-height: 0;
    background: #141414;
    border: 1px solid #333;
    border-radius: 4px;
    overflow: hidden;
}

.av-terminal-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 6px 12px;
    background: #222;
    border-bottom: 1px solid #333;
    font-size: 11px;
    color: #888;
    font-family: "JetBrains Mono", monospace;
}

#av-scan-progress-label {
    color: #27ae60;
    font-weight: 600;
}

#av-typer-screen {
    flex: 1;
    padding: 10px 12px;
    overflow-y: auto;
    overflow-x: hidden;
    font-family: "JetBrains Mono", "Consolas", monospace;
    font-size: 11px;
    line-height: 1.55;
    color: #aaa;
    outline: none;
    white-space: pre-wrap;
    background: #141414;
    scroll-behavior: smooth;
}

.av-scroll,
#av-typer-screen,
#av-event-log,
.av-table-wrap {
    scrollbar-width: thin;
    scrollbar-color: #3a3a3a #1a1a1a;
}

.av-scroll::-webkit-scrollbar,
#av-typer-screen::-webkit-scrollbar,
#av-event-log::-webkit-scrollbar,
.av-table-wrap::-webkit-scrollbar {
    width: 7px;
    height: 7px;
}

.av-scroll::-webkit-scrollbar-track,
#av-typer-screen::-webkit-scrollbar-track,
#av-event-log::-webkit-scrollbar-track,
.av-table-wrap::-webkit-scrollbar-track {
    background: #1a1a1a;
}

#av-typer-screen::-webkit-scrollbar-track {
    border-left: 1px solid #2a2a2a;
}

.av-scroll::-webkit-scrollbar-thumb,
#av-typer-screen::-webkit-scrollbar-thumb,
#av-event-log::-webkit-scrollbar-thumb,
.av-table-wrap::-webkit-scrollbar-thumb {
    background: #3a3a3a;
    border-radius: 3px;
    border: 1px solid #1a1a1a;
}

.av-scroll::-webkit-scrollbar-thumb:hover,
#av-typer-screen::-webkit-scrollbar-thumb:hover,
#av-event-log::-webkit-scrollbar-thumb:hover,
.av-table-wrap::-webkit-scrollbar-thumb:hover {
    background: #27ae60;
}

.av-scroll::-webkit-scrollbar-corner,
#av-typer-screen::-webkit-scrollbar-corner {
    background: #1a1a1a;
}

.av-log-line--info { color: #aaa; }
.av-log-line--ok { color: #27ae60; }
.av-log-line--warn { color: #e67e22; }
.av-log-line--auto { color: #7eb8da; }

.av-progress-track {
    height: 5px;
    background: #2a2a2a;
    overflow: hidden;
}

#av-scan-progress {
    height: 100%;
    width: 0%;
    background: linear-gradient(90deg, #229954, #27ae60);
    transition: width 0.45s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: none;
    will-change: width;
}

/* ── Quarantine table ── */
.av-table-wrap {
    flex: 1;
    overflow-y: auto;
    border: 1px solid #333;
    border-radius: 4px;
    background: #252525;
}

.av-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 12px;
}

.av-table th {
    position: sticky;
    top: 0;
    background: #2a2a2a;
    color: #888;
    font-weight: 600;
    text-align: left;
    padding: 8px 12px;
    border-bottom: 1px solid #333;
    font-size: 10px;
    text-transform: uppercase;
    letter-spacing: 0.4px;
}

.av-table td {
    padding: 8px 12px;
    border-bottom: 1px solid #2e2e2e;
    color: #ccc;
}

.av-table tr:hover td {
    background: #2a2a2a;
}

.av-table .av-sev-high { color: #e74c3c; }
.av-table .av-sev-medium { color: #e67e22; }
.av-table .av-action-blocked { color: #27ae60; font-weight: 600; }
.av-table .av-action-removed { color: #3498db; font-weight: 600; }

.av-empty-msg {
    padding: 32px;
    text-align: center;
    color: #555;
    font-size: 13px;
}

/* ── Event log ── */
#av-event-log {
    flex: 1;
    overflow-y: auto;
    background: #141414;
    border: 1px solid #333;
    border-radius: 4px;
    padding: 8px 12px;
    font-family: "JetBrains Mono", monospace;
    font-size: 11px;
    line-height: 1.7;
    color: #888;
}

.av-log-entry {
    border-bottom: 1px solid #222;
    padding: 2px 0;
}

.av-log-entry .av-log-time { color: #555; }
.av-log-entry.av-log--block .av-log-level { color: #27ae60; }
.av-log-entry.av-log--clean .av-log-level { color: #3498db; }
.av-log-entry.av-log--warn .av-log-level { color: #e67e22; }
.av-log-entry.av-log--scan .av-log-level { color: #7eb8da; }

/* ── Status bar ── */
.av-statusbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 4px 16px;
    background: #222;
    border-top: 1px solid #333;
    font-size: 11px;
    color: #666;
    flex-shrink: 0;
}

.av-statusbar-item {
    display: flex;
    align-items: center;
    gap: 6px;
}

.av-statusbar-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #27ae60;
}

.av-statusbar-dot.off {
    background: #666;
}

/* Linux DE window overrides */
.linux-de #win-antivirus.window {
    border-radius: 0;
}

.linux-de #win-antivirus .w-header {
    border-radius: 0;
}
