:root {
    --ricter-blue: #070E27;
    --bg-dark: #0a0e14;
    --card-bg: #161c24;
    --text-main: #e2e8f0;
    --text-muted: #94a3b8;
    --accent-blue: #38bdf8;
    --shadow: 0px 7px 5px rgba(0, 0, 0, 0.3);
}

body { 
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif; 
    background-color: var(--bg-dark); 
    margin: 0; padding: 0; color: var(--text-main);
}
body.modal-open { overflow: hidden; }
body.dashboard-page {
    position: relative;
    min-height: 100vh;
}
body.dashboard-page header,
body.dashboard-page .container,
body.dashboard-page .site-footer,
body.dashboard-page .pwa-banner {
    position: relative;
    z-index: 1;
}

/* —— Ambient achtergrond (login + dashboard) —— */
.ambient-bg {
    position: fixed;
    inset: 0;
    pointer-events: none;
    z-index: 0;
}
.ambient-grid {
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(rgba(56, 189, 248, 0.04) 1px, transparent 1px),
        linear-gradient(90deg, rgba(56, 189, 248, 0.04) 1px, transparent 1px);
    background-size: 48px 48px;
    mask-image: radial-gradient(ellipse 80% 70% at 50% 35%, black 15%, transparent 78%);
}
.ambient-orb {
    position: absolute;
    border-radius: 50%;
    filter: blur(80px);
    opacity: 0.38;
    animation: ambient-float 14s ease-in-out infinite;
}
.ambient-orb-a {
    width: 420px;
    height: 420px;
    background: #0284c7;
    top: -120px;
    left: -80px;
}
.ambient-orb-b {
    width: 360px;
    height: 360px;
    background: #1d4ed8;
    bottom: -100px;
    right: -60px;
    animation-delay: -6s;
}
@keyframes ambient-float {
    0%, 100% { transform: translate(0, 0) scale(1); }
    50% { transform: translate(24px, 18px) scale(1.05); }
}
.header-stats {
    font-size: 0.82rem;
    margin: 0.45rem 0 0;
    color: rgba(255, 255, 255, 0.82);
    font-variant-numeric: tabular-nums;
    letter-spacing: 0.02em;
}
.header-stats .stat-online { color: #86efac; font-weight: 700; }
.header-stats .stat-offline { color: #fca5a5; font-weight: 700; }
.header-stats .stat-muted { color: rgba(255, 255, 255, 0.55); }
.header-stats .stat-pending { color: #94a3b8; font-style: italic; }

.keyboard-hint {
    display: block;
    margin-top: 0.35rem;
    font-size: 0.68rem;
    color: rgba(148, 163, 184, 0.85);
    letter-spacing: 0.03em;
}

.pwa-banner {
    position: fixed;
    bottom: 1rem;
    left: 50%;
    transform: translateX(-50%);
    z-index: 900;
    width: min(520px, calc(100% - 2rem));
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.85rem 1rem;
    background: linear-gradient(145deg, #161c24, #111827);
    border: 1px solid rgba(56, 189, 248, 0.35);
    border-radius: 1rem;
    box-shadow: 0 16px 40px rgba(0, 0, 0, 0.45);
}
.pwa-banner[hidden] { display: none; }
.pwa-banner-icon {
    font-size: 1.35rem;
    color: var(--accent-blue);
    flex-shrink: 0;
}
.pwa-banner-text {
    flex: 1;
    font-size: 0.8rem;
    line-height: 1.35;
    color: var(--text-main);
}
.pwa-banner-actions {
    display: flex;
    gap: 0.4rem;
    flex-shrink: 0;
}
.pwa-banner-actions button {
    border-radius: 999px;
    border: 1px solid rgba(56, 189, 248, 0.35);
    background: rgba(56, 189, 248, 0.12);
    color: var(--accent-blue);
    font-size: 0.72rem;
    font-weight: 700;
    padding: 0.35rem 0.7rem;
    cursor: pointer;
}
.pwa-banner-actions button:hover {
    background: rgba(56, 189, 248, 0.22);
}
.pwa-banner-actions .pwa-dismiss {
    background: transparent;
    border-color: rgba(148, 163, 184, 0.35);
    color: var(--text-muted);
}

:focus { outline: none; }
:focus-visible {
    outline: 2px solid var(--accent-blue);
    outline-offset: 3px;
}

header { 
    background-color: var(--ricter-blue); 
    color: white; padding: 40px 20px 60px; 
    box-shadow: var(--shadow);
    display: flex; justify-content: center;
}

.header-content-wrapper {
    width: 100%; max-width: 1400px;
    display: grid;
    grid-template-columns: 1fr 1.5fr 1fr;
    align-items: center;
}

.header-left { display: flex; align-items: center; }
.header-center { display: flex; flex-direction: column; align-items: center; text-align: center; }
.header-right { display: flex; flex-direction: column; align-items: flex-end; gap: 10px; }

#main-logo { width: 400px; height: auto; filter: drop-shadow(0px 4px 6px rgba(0, 0, 0, 0.3)); }
#main-logo.logo-konami-flash {
    animation: logo-konami 0.65s ease-out;
}
@keyframes logo-konami {
    0% { transform: scale(1); filter: drop-shadow(0 0 0 transparent); }
    40% { transform: scale(1.04); filter: drop-shadow(0 0 18px rgba(252, 211, 77, 0.55)); }
    100% { transform: scale(1); filter: drop-shadow(0px 4px 6px rgba(0, 0, 0, 0.3)); }
}
.personal-greeting.easter-greeting {
    color: #fde68a;
    text-shadow: 0 0 20px rgba(252, 211, 77, 0.25);
    animation: easter-greeting-pop 0.55s cubic-bezier(0.22, 1, 0.36, 1);
}
@keyframes easter-greeting-pop {
    from { opacity: 0; transform: translateY(6px) scale(0.97); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}
#clock { font-size: 4rem; font-weight: 200; margin: 0; }
#date { font-size: 1.1rem; opacity: 0.8; margin: 0.25rem 0 0; }
.personal-greeting {
    font-size: 0.95rem;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.92);
    margin: 0.65rem 0 0;
    max-width: 28rem;
    line-height: 1.35;
    font-style: italic;
    text-wrap: balance;
}
html[lang="nl"] .personal-greeting {
    font-style: normal;
}

.network-info { font-size: 0.8rem; background: rgba(255,255,255,0.1); padding: 6px 15px; border-radius: 20px; }
.header-actions {
    display: flex;
    align-items: center;
    gap: 8px;
}
#lang-toggle, .header-icon-btn {
    background: rgba(255,255,255,0.15);
    border: 1px solid rgba(255,255,255,0.3);
    color: white;
    padding: 5px 12px;
    border-radius: 6px;
    cursor: pointer;
    font-weight: bold;
    line-height: 1;
}
.header-icon-btn {
    padding: 6px 10px;
    font-size: 0.95rem;
}
.header-icon-btn:hover, #lang-toggle:hover { background: rgba(255,255,255,0.25); }
a.header-icon-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    box-sizing: border-box;
}
.header-logout-btn:hover {
    background: rgba(239, 68, 68, 0.28);
    border-color: rgba(239, 68, 68, 0.45);
}

.search-container { 
    grid-column: 1 / span 3;
    max-width: 900px; margin: 40px auto 0; 
    display: flex; gap: 20px; width: 100%;
}

.search-wrapper { position: relative; flex: 1; }
.search-input, #dashboard-filter { 
    width: 100%; background-color: #1e293b; border-radius: 2rem; border: 1px solid rgba(255,255,255,0.1); 
    height: 3.5rem; padding: 0 3.5rem; font-size: 1.1rem; color: white; box-sizing: border-box; 
}
.search-icon { position: absolute; left: 1.3rem; top: 50%; transform: translateY(-50%); color: var(--accent-blue); }
#clear-filter { position: absolute; right: 1rem; top: 50%; transform: translateY(-50%); background: none; border: none; color: white; font-size: 1.5rem; cursor: pointer; display: none; }

.container { width: 95%; max-width: 1400px; margin: -30px auto 50px; }
.tabs-nav { display: flex; justify-content: center; gap: 15px; margin-bottom: 40px; }
.tab-btn { background-color: #1e293b; border: 1px solid rgba(255,255,255,0.1); border-radius: 2rem; padding: 12px 28px; font-weight: 700; color: var(--text-muted); cursor: pointer; }
.tab-btn.active { background-color: var(--ricter-blue); color: white; border-color: var(--accent-blue); }

.tab-content { display: none; opacity: 0; }
.tab-content.active {
    display: block;
    animation: tabFadeIn 0.45s cubic-bezier(0.22, 1, 0.36, 1) both;
}
@keyframes tabFadeIn {
    from {
        opacity: 0;
        transform: translateY(14px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

body.is-filtering .tab-content {
    display: block;
}
body.is-filtering .tab-content:not(.active) {
    margin-top: 2.5rem;
    padding-top: 2rem;
    border-top: 1px solid rgba(148, 163, 184, 0.2);
}
.section-title { margin: 40px 0 15px 10px; font-size: 0.9rem; text-transform: uppercase; color: var(--accent-blue); font-weight: 800; }

.dashboard-section { margin-bottom: 0.25rem; }
.section-toggle {
    width: calc(100% - 20px);
    margin: 40px 10px 15px;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    text-align: left;
    background: none;
    border: none;
    cursor: pointer;
    font: inherit;
    font-size: 0.9rem;
    text-transform: uppercase;
    color: var(--accent-blue);
    font-weight: 800;
    letter-spacing: inherit;
}
.section-toggle:hover { color: #7dd3fc; }
.section-toggle:focus-visible {
    outline: 2px solid var(--accent-blue);
    outline-offset: 4px;
    border-radius: 4px;
}
.section-toggle-text { flex: 1; text-align: left; }
.section-count {
    font-size: 0.72rem;
    font-weight: 700;
    color: var(--text-muted);
    font-variant-numeric: tabular-nums;
    flex-shrink: 0;
}
.section-chevron {
    font-size: 0.72rem;
    opacity: 0.75;
    transition: transform 0.25s ease;
    flex-shrink: 0;
}
.dashboard-section.is-collapsed .section-chevron {
    transform: rotate(-90deg);
}
.dashboard-section.is-collapsed .section-body {
    display: none;
}
.dashboard-section.is-collapsed .section-toggle {
    margin-bottom: 8px;
}

.site-footer {
    width: 95%;
    max-width: 1400px;
    margin: 0 auto 2.5rem;
    padding: 1.25rem 10px 0;
    border-top: 1px solid rgba(148, 163, 184, 0.18);
    text-align: center;
}
.footer-row {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 0.35rem 0.5rem;
    font-size: 0.78rem;
    color: var(--text-muted);
}
a.footer-brand {
    color: var(--text-main);
    font-weight: 700;
    text-decoration: none;
}
a.footer-brand:hover {
    color: var(--accent-blue);
    text-decoration: underline;
}
.footer-tagline {
    margin: 0.5rem 0 0;
    font-size: 0.72rem;
    color: rgba(148, 163, 184, 0.95);
}
.footer-coffee {
    color: rgba(253, 224, 71, 0.85);
}
.footer-version {
    color: var(--accent-blue);
    font-weight: 700;
    font-variant-numeric: tabular-nums;
}
.footer-dot { opacity: 0.45; user-select: none; }
.footer-session,
.footer-tab-status,
.footer-deploy {
    margin: 0.3rem 0 0;
    font-size: 0.7rem;
    color: rgba(148, 163, 184, 0.9);
}
.footer-deploy {
    color: rgba(56, 189, 248, 0.75);
    font-variant-numeric: tabular-nums;
}
.footer-tips-wrap {
    margin: 0.65rem auto 0;
    max-width: 34rem;
}
.footer-tips-wrap[hidden] {
    display: none;
}
.footer-random-tip {
    margin: 0;
    font-size: 0.68rem;
    line-height: 1.45;
    color: rgba(148, 163, 184, 0.92);
    text-align: center;
    padding: 0.5rem 0.75rem;
    background: rgba(56, 189, 248, 0.06);
    border: 1px solid rgba(56, 189, 248, 0.15);
    border-radius: 0.65rem;
}
.footer-random-tip::before {
    content: "› ";
    color: var(--accent-blue);
    font-weight: 700;
}
.footer-action-muted {
    border-color: rgba(148, 163, 184, 0.3);
    color: var(--text-muted);
    background: rgba(148, 163, 184, 0.08);
}
.footer-action-muted:hover {
    color: var(--text-main);
    background: rgba(148, 163, 184, 0.15);
}
.footer-beunhaas-btn {
    opacity: 0.28;
    border-color: rgba(251, 191, 36, 0.25);
    color: rgba(251, 191, 36, 0.65);
    background: transparent;
    font-size: 0.62rem;
    padding: 0.35rem 0.55rem;
    letter-spacing: 0.02em;
}
.footer-beunhaas-btn:hover,
.footer-beunhaas-btn.is-active {
    opacity: 1;
    border-color: rgba(251, 191, 36, 0.55);
    color: #fde68a;
    background: rgba(251, 191, 36, 0.12);
}
.footer-beunhaas-btn.is-active {
    box-shadow: 0 0 12px rgba(251, 191, 36, 0.2);
}

/* —— Beunhaas modus —— */
html:has(body.beunhaas-mode) {
    overflow-x: hidden;
}
body.beunhaas-mode.dashboard-page {
    transform: rotate(-1.35deg) skewX(-0.55deg);
    transform-origin: 50% 0;
}
body.beunhaas-mode .tab-btn {
    border-radius: 0 !important;
    border: 2px solid #000 !important;
    background: #fff !important;
    color: #000 !important;
    box-shadow: 3px 3px 0 #000 !important;
}
body.beunhaas-mode header {
    box-shadow: 4px 4px 0 #000 !important;
    border-bottom: 3px solid #ff0 !important;
}
body.beunhaas-mode .card,
body.beunhaas-mode .card:hover,
body.beunhaas-mode .card:focus-visible {
    all: unset;
    display: flex !important;
    align-items: center !important;
    gap: 6px !important;
    position: relative !important;
    padding: 6px 8px !important;
    margin: 0 !important;
    border-radius: 0 !important;
    background: #ffff99 !important;
    border: 2px solid #000 !important;
    box-shadow: 3px 3px 0 #000 !important;
    transform: none !important;
    text-decoration: none !important;
    color: #000 !important;
    font-family: 'Comic Sans MS', 'Arial', sans-serif !important;
    font-size: 0.85rem !important;
    transition: none !important;
}
body.beunhaas-mode .card:hover {
    background: #ff9999 !important;
}
body.beunhaas-mode .card i {
    font-size: 0.9rem !important;
    padding: 2px 4px !important;
    margin: 0 !important;
    border-radius: 0 !important;
    background: #fff !important;
    border: 1px solid #000 !important;
    color: #000 !important;
    min-width: auto !important;
}
body.beunhaas-mode .card-info > span {
    font-size: 0.85rem !important;
    font-weight: 700 !important;
}
body.beunhaas-mode .card-info > small {
    font-size: 0.7rem !important;
    color: #333 !important;
}
body.beunhaas-mode .card-meta,
body.beunhaas-mode .status-dot,
body.beunhaas-mode .click-count {
    display: none !important;
}
body.beunhaas-mode .grid {
    gap: 6px !important;
}
body.beunhaas-mode .section-toggle {
    font-family: 'Comic Sans MS', 'Arial', sans-serif !important;
    color: #000 !important;
    text-transform: none !important;
}
body.beunhaas-mode .search-input,
body.beunhaas-mode #dashboard-filter {
    border-radius: 0 !important;
    border: 2px solid #000 !important;
}
.beunhaas-overlay {
    position: fixed;
    inset: -5%;
    pointer-events: none;
    z-index: 12000;
    overflow: visible;
}
.beunhaas-overlay[hidden] {
    display: none;
}
.duct-tape {
    position: absolute;
    filter: drop-shadow(1px 3px 5px rgba(0, 0, 0, 0.35));
}
.duct-tape-1 {
    top: 6%;
    left: -4%;
    width: min(42vw, 320px);
    transform: rotate(-28deg);
}
.duct-tape-2 {
    top: 38%;
    right: -6%;
    width: min(36vw, 280px);
    transform: rotate(22deg);
}
.duct-tape-3 {
    bottom: 18%;
    left: 8%;
    width: min(30vw, 220px);
    transform: rotate(-12deg);
}
.duct-tape-4 {
    top: 14%;
    right: 18%;
    width: min(22vw, 180px);
    transform: rotate(48deg);
}

@media (prefers-reduced-motion: reduce) {
    body.beunhaas-mode.dashboard-page {
        transform: none;
    }
}
.footer-actions {
    margin-top: 0.85rem;
    display: flex;
    justify-content: center;
    gap: 0.5rem;
}
.footer-action-btn {
    background: rgba(56, 189, 248, 0.12);
    border: 1px solid rgba(56, 189, 248, 0.35);
    color: var(--accent-blue);
    padding: 0.4rem 0.9rem;
    border-radius: 999px;
    cursor: pointer;
    font-size: 0.74rem;
    font-weight: 700;
}
.footer-action-btn:hover {
    background: rgba(56, 189, 248, 0.22);
}
.section-note {
    margin: 0 10px 2rem;
    font-size: 0.82rem;
    line-height: 1.45;
    color: var(--text-muted);
}
.grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 20px;
}

.card { 
    position: relative;
    background-color: var(--card-bg); padding: 20px; border-radius: 1.5rem; text-decoration: none; 
    color: var(--text-main); display: flex; align-items: center; gap: 15px; border: 1px solid rgba(255,255,255,0.03); transition: 0.2s;
}
body.beunhaas-mode.has-daily-mood .card {
    border-color: color-mix(in srgb, var(--mood-accent) 35%, #000);
    box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--mood-accent) 20%, transparent);
}
body.beunhaas-mode.has-daily-mood .card i {
    color: var(--mood-accent);
    background: var(--mood-tint);
}
.card:hover { transform: translateY(-5px); border-color: var(--accent-blue); background-color: #1f2937; }
.card:focus-visible {
    transform: translateY(-5px);
    border-color: var(--accent-blue);
    background-color: #1f2937;
}
.card i { font-size: 1.5rem; color: var(--accent-blue); background: rgba(56, 189, 248, 0.1); padding: 15px; border-radius: 1.2rem; }
body.beunhaas-mode .card--decoy {
    cursor: pointer;
    border-style: dashed !important;
    background: #ffcccc !important;
}
body.beunhaas-mode .card--decoy:hover {
    background: #ff6666 !important;
}
body.beunhaas-mode .card--shy {
    transition: opacity 0.12s ease, visibility 0.12s, transform 0.12s;
}
body.beunhaas-mode .card--shy.card--shy-hide {
    opacity: 0.04;
    visibility: hidden;
    pointer-events: none;
    transform: scale(0.92);
}
.card-info > span { display: block; font-weight: 700; font-size: 1.1rem; }
.card-info > small { color: var(--text-muted); }
.card-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.25rem 0.45rem;
    margin-top: 0.35rem;
}
.card-meta .security-hint,
.card-meta .reach-label {
    font-size: 0.72rem;
    line-height: 1.25;
    color: var(--text-muted);
}
.card-meta .security-badge {
    font-size: 0.58rem;
    font-weight: 700;
    padding: 0.08rem 0.32rem;
    vertical-align: middle;
}
.card.hidden { display: none; }

.click-count {
    position: absolute;
    bottom: 10px;
    left: 12px;
    font-size: 0.62rem;
    font-weight: 800;
    color: var(--text-muted);
    background: rgba(15, 23, 42, 0.85);
    border: 1px solid rgba(148, 163, 184, 0.25);
    border-radius: 999px;
    padding: 0.12rem 0.4rem;
    font-variant-numeric: tabular-nums;
    display: inline-flex;
    align-items: center;
    gap: 0.2rem;
    z-index: 2;
}
.click-count[hidden] { display: none; }
.click-count--king {
    border-color: rgba(251, 191, 36, 0.45);
    color: #fde68a;
    background: rgba(251, 191, 36, 0.12);
}
.click-king-icon {
    width: 14px;
    height: 14px;
    object-fit: contain;
    vertical-align: middle;
}

/* —— Interacties —— */
.dash-toast {
    position: fixed;
    bottom: 1.5rem;
    left: 50%;
    transform: translateX(-50%) translateY(120%);
    z-index: 13000;
    padding: 0.75rem 1.25rem;
    background: linear-gradient(145deg, #1e293b, #0f172a);
    border: 1px solid rgba(251, 191, 36, 0.45);
    border-radius: 999px;
    color: #fde68a;
    font-weight: 700;
    font-size: 0.9rem;
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.45);
    opacity: 0;
    transition: transform 0.35s cubic-bezier(0.22, 1, 0.36, 1), opacity 0.3s;
    pointer-events: none;
}
.dash-toast--show {
    transform: translateX(-50%) translateY(0);
    opacity: 1;
}
.terminal-toast {
    position: fixed;
    bottom: 1.5rem;
    right: 1.25rem;
    z-index: 13001;
    max-width: min(420px, calc(100vw - 2rem));
    padding: 0.85rem 1rem;
    background: #0c0c0c;
    border: 1px solid #22c55e;
    border-radius: 0.5rem;
    font-family: Consolas, 'Courier New', monospace;
    font-size: 0.78rem;
    line-height: 1.45;
    color: #86efac;
    box-shadow: 0 0 24px rgba(34, 197, 94, 0.2);
    opacity: 0;
    transform: translateY(12px);
    transition: opacity 0.25s, transform 0.25s;
    pointer-events: none;
}
.terminal-toast--show {
    opacity: 1;
    transform: translateY(0);
}
.terminal-prompt { color: #94a3b8; }
.terminal-out { color: #f87171; }
.hover-still-tip {
    position: fixed;
    z-index: 12500;
    padding: 0.35rem 0.65rem;
    background: #334155;
    color: #f8fafc;
    font-size: 0.72rem;
    font-weight: 600;
    border-radius: 0.4rem;
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.35);
    pointer-events: none;
}
.hover-still-tip[hidden] { display: none; }
.link-preview {
    position: fixed;
    z-index: 11000;
    pointer-events: none;
}
.link-preview[hidden] { display: none; }
.link-preview-frame {
    width: 292px;
    background: #111827;
    border: 1px solid rgba(56, 189, 248, 0.35);
    border-radius: 0.65rem;
    overflow: hidden;
    box-shadow: 0 16px 40px rgba(0, 0, 0, 0.5);
}
.link-preview-img {
    display: block;
    width: 100%;
    height: 158px;
    object-fit: cover;
    background: #1e293b;
}
.link-preview-img--favicon {
    object-fit: contain;
    padding: 2rem;
    height: 120px;
}
.link-preview-host {
    display: block;
    padding: 0.4rem 0.65rem;
    font-size: 0.68rem;
    color: var(--text-muted);
    border-top: 1px solid rgba(148, 163, 184, 0.15);
}
.link-confirm-panel { width: min(400px, 100%); }
.link-confirm-service {
    margin: 0 0 0.35rem;
    font-weight: 700;
    color: var(--text-main);
}
.link-confirm-url {
    margin: 0 0 0.75rem;
    font-size: 0.72rem;
    word-break: break-all;
    color: var(--accent-blue);
}
.link-confirm-wait {
    margin: 0 0 0.65rem;
    font-size: 0.75rem;
    color: #fcd34d;
    font-style: italic;
}
.link-confirm-actions {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}
.link-confirm-go {
    flex: 1;
    min-width: 8rem;
    padding: 0.55rem 1rem;
    border: none;
    border-radius: 0.65rem;
    background: linear-gradient(135deg, #0284c7, #1d4ed8);
    color: white;
    font-weight: 700;
    cursor: pointer;
}
.link-confirm-go:disabled {
    opacity: 0.45;
    cursor: not-allowed;
}
.link-confirm-go.is-waiting:not(:disabled) {
    opacity: 0.7;
}
.link-confirm-cancel {
    padding: 0.55rem 1rem;
    border-radius: 0.65rem;
    border: 1px solid rgba(148, 163, 184, 0.35);
    background: transparent;
    color: var(--text-muted);
    cursor: pointer;
    font-weight: 600;
}
.link-confirm-cancel:hover { color: var(--text-main); }

/* —— Status modal —— */
.status-modal[hidden] { display: none; }
.status-modal {
    position: fixed;
    inset: 0;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
}
.status-modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(2, 6, 23, 0.72);
    backdrop-filter: blur(2px);
}
.status-modal-panel {
    position: relative;
    width: min(520px, 100%);
    max-height: min(85vh, 640px);
    overflow-y: auto;
    background: #111827;
    border: 1px solid rgba(148, 163, 184, 0.2);
    border-radius: 1rem;
    padding: 1rem 1.1rem 1.15rem;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.45);
}
.status-modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    margin-bottom: 0.75rem;
}
.status-modal-header h2 {
    margin: 0;
    font-size: 1rem;
    font-weight: 700;
    color: var(--text-main);
}
.status-modal-close {
    background: none;
    border: none;
    color: var(--text-muted);
    font-size: 1.5rem;
    line-height: 1;
    cursor: pointer;
    padding: 0 0.25rem;
}
.status-modal-close:hover { color: white; }
.modal-note {
    margin: 0.75rem 0 0;
    font-size: 0.72rem;
    line-height: 1.45;
    color: var(--text-muted);
}

/* —— Status & security —— */
.status-legend {
    display: flex;
    flex-direction: column;
    gap: 0.85rem;
    font-size: 0.72rem;
    color: var(--text-muted);
}
.legend-group {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.45rem 0.85rem;
}
.legend-heading {
    font-weight: 800;
    color: var(--accent-blue);
    text-transform: uppercase;
    letter-spacing: 0.04em;
    width: 100%;
    margin-bottom: 0.1rem;
}
.legend-item {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
}
.legend-summary {
    flex: 1 1 100%;
    font-size: 0.8rem;
    color: var(--text-main);
    min-height: 1.1rem;
}
.refresh-checks {
    align-self: flex-start;
    background: rgba(56, 189, 248, 0.12);
    border: 1px solid rgba(56, 189, 248, 0.35);
    color: var(--accent-blue);
    padding: 0.3rem 0.75rem;
    border-radius: 999px;
    cursor: pointer;
    font-size: 0.72rem;
    font-weight: 700;
}
.refresh-checks:hover { background: rgba(56, 189, 248, 0.22); }

.status-dot {
    position: absolute;
    top: 12px;
    right: 12px;
    width: 11px;
    height: 11px;
    border-radius: 50%;
    border: 2px solid var(--card-bg);
    box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.35);
    flex-shrink: 0;
}
.status-dot.dot-pending { background: #64748b; animation: pulse-dot 1.2s ease-in-out infinite; }
.status-dot.dot-online { background: #22c55e; }
.status-dot.dot-offline { background: #ef4444; }
.status-dot.dot-skip { background: #475569; opacity: 0.85; }

.security-badge {
    display: inline-block;
    font-size: 0.52rem;
    font-weight: 700;
    letter-spacing: 0.02em;
    text-transform: uppercase;
    padding: 0.1rem 0.35rem;
    border-radius: 999px;
    border: 1px solid transparent;
    line-height: 1.25;
}
.status-legend .security-badge {
    font-size: 0.58rem;
}
.security-badge.sec-good {
    color: #86efac;
    background: rgba(34, 197, 94, 0.12);
    border-color: rgba(34, 197, 94, 0.35);
}
.security-badge.sec-warn {
    color: #fcd34d;
    background: rgba(245, 158, 11, 0.12);
    border-color: rgba(245, 158, 11, 0.35);
}
.security-badge.sec-neutral {
    color: #93c5fd;
    background: rgba(59, 130, 246, 0.12);
    border-color: rgba(59, 130, 246, 0.35);
}
.security-badge.sec-lan {
    color: #c4b5fd;
    background: rgba(139, 92, 246, 0.12);
    border-color: rgba(139, 92, 246, 0.35);
}
.security-badge.sec-portal {
    color: #94a3b8;
    background: rgba(148, 163, 184, 0.12);
    border-color: rgba(148, 163, 184, 0.35);
}

@keyframes pulse-dot {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.45; }
}

#my-ip { cursor: pointer; }

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

@media (max-width: 850px) {
    .header-content-wrapper { display: flex; flex-direction: column; text-align: center; }
    .header-right {
        align-items: center;
        width: 100%;
    }
    #main-logo { width: 250px; }
    .search-container { flex-direction: column; }
}

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

.shortcut-list {
    display: flex;
    flex-direction: column;
    gap: 0.55rem;
    margin: 0;
    padding: 0;
}
.shortcut-row {
    display: flex;
    align-items: center;
    gap: 0.85rem;
    font-size: 0.84rem;
    color: var(--text-main);
}
.shortcut-row kbd {
    display: inline-block;
    min-width: 1.85rem;
    text-align: center;
    padding: 0.22rem 0.55rem;
    border-radius: 0.45rem;
    background: rgba(56, 189, 248, 0.1);
    border: 1px solid rgba(56, 189, 248, 0.32);
    font-family: inherit;
    font-size: 0.78rem;
    font-weight: 700;
    color: var(--accent-blue);
    flex-shrink: 0;
}
.shortcut-row span {
    color: var(--text-muted);
    line-height: 1.35;
}

@media (prefers-reduced-motion: reduce) {
    .dash-toast,
    .terminal-toast { transition: none; }
    .ambient-orb { animation: none; }
    .tab-content.active { animation: none; opacity: 1; transform: none; }
    body.is-filtering .tab-content:not(.active) {
        margin-top: 1.5rem;
        padding-top: 1.25rem;
    }
    .card { transition: none; }
    .card:hover,
    .card:focus-visible { transform: none; }
    .status-dot.dot-pending { animation: none; }
}
