/* admin-overview.css */

/* Custom grid and flex layouts for the Admin-Übersicht */
.ao-grid {
    display: grid;
    grid-template-columns: 2fr 1.2fr;
    gap: 24px;
    margin-top: 24px;
    position: relative;
    z-index: 2;
}

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

/* Background Blobs inside page */
.ao-blob-container {
    position: absolute;
    inset: 0;
    pointer-events: none;
    z-index: 1;
    overflow: hidden;
}

.ao-bg-blob {
    position: absolute;
    border-radius: 50%;
    filter: blur(100px);
    opacity: 0.22;
    animation: ao-float 12s infinite alternate ease-in-out;
}

.ao-bg-blob.purple {
    top: 5%;
    left: -150px;
    width: 450px;
    height: 450px;
    background: radial-gradient(circle, var(--accent-purple) 0%, transparent 70%);
}

.ao-bg-blob.cyan {
    bottom: 5%;
    right: -150px;
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, var(--accent-cyan) 0%, transparent 70%);
    animation-delay: -6s;
}

@keyframes ao-float {
    0% {
        transform: translate(0, 0) scale(1) rotate(0deg);
        opacity: 0.18;
    }

    100% {
        transform: translate(60px, 40px) scale(1.2) rotate(45deg);
        opacity: 0.26;
    }
}

/* Card Stripe Element - Positioned exactly on the outer border edge to replace the gray card border */
.ao-stripe {
    position: absolute !important;
    top: 0 !important;
    left: 0 !important;
    right: 0 !important;
    height: 4px;
    z-index: 10 !important;
}

/* Extremely bright neon gradients for high visibility on dark background */
.ao-stripe.purple {
    background: linear-gradient(90deg, #e9d5ff, #c084fc, #9b6dff);
    box-shadow: 0 2px 12px rgba(155, 109, 255, 0.65);
    transition: box-shadow 0.3s ease;
}

.ao-stripe.cyan {
    background: linear-gradient(90deg, #cffafe, #22d3ee, #06b6d4);
    box-shadow: 0 2px 12px rgba(34, 211, 238, 0.65);
    transition: box-shadow 0.3s ease;
}

.ao-stripe.amber {
    background: linear-gradient(90deg, #fef3c7, #fbbf24, #f59e0b);
    box-shadow: 0 2px 12px rgba(245, 158, 11, 0.65);
    transition: box-shadow 0.3s ease;
}

.ao-stripe.emerald {
    background: linear-gradient(90deg, #d1fae5, #34d399, #10b981);
    box-shadow: 0 2px 12px rgba(16, 185, 129, 0.65);
    transition: box-shadow 0.3s ease;
}

.ao-stripe.rose {
    background: linear-gradient(90deg, #ffe4e6, #fb7185, #f43f5e);
    box-shadow: 0 2px 12px rgba(244, 63, 94, 0.65);
    transition: box-shadow 0.3s ease;
}

/* Intense hover glows */
.glow-card:hover .ao-stripe.purple,
.ao-stat-card:hover .ao-stripe.purple {
    box-shadow: 0 4px 20px rgba(155, 109, 255, 0.9), 0 0 35px rgba(155, 109, 255, 0.7) !important;
}

.glow-card:hover .ao-stripe.cyan,
.ao-stat-card:hover .ao-stripe.cyan {
    box-shadow: 0 4px 20px rgba(34, 211, 238, 0.9), 0 0 35px rgba(34, 211, 238, 0.7) !important;
}

.glow-card:hover .ao-stripe.amber,
.ao-stat-card:hover .ao-stripe.amber {
    box-shadow: 0 4px 20px rgba(245, 158, 11, 0.9), 0 0 35px rgba(245, 158, 11, 0.7) !important;
}

.glow-card:hover .ao-stripe.emerald,
.ao-stat-card:hover .ao-stripe.emerald {
    box-shadow: 0 4px 20px rgba(16, 185, 129, 0.9), 0 0 35px rgba(16, 185, 129, 0.7) !important;
}

.glow-card:hover .ao-stripe.rose,
.ao-stat-card:hover .ao-stripe.rose {
    box-shadow: 0 4px 20px rgba(244, 63, 94, 0.9), 0 0 35px rgba(244, 63, 94, 0.7) !important;
}

/* Stats Row */
.ao-stats-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 20px;
    margin-bottom: 24px;
    position: relative;
    z-index: 2;
}

.ao-stat-card {
    background: rgba(16, 18, 24, 0.45);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.03);
    border-radius: 20px;
    padding: 20px;
    display: flex;
    align-items: center;
    gap: 16px;
    position: relative;
    overflow: hidden;
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}

/* Rounded top corners to prevent clipping at the outer border edge */
.ao-stat-card .ao-stripe {
    border-radius: 20px 20px 0 0;
}

/* Hover Glow on Stat Cards */
.ao-stat-card:hover {
    transform: translateY(-4px);
}

.ao-stat-card.purple:hover {
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.5), 0 0 25px rgba(155, 109, 255, 0.55) !important;
    border-color: rgba(155, 109, 255, 0.55) !important;
}

.ao-stat-card.cyan:hover {
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.5), 0 0 25px rgba(34, 211, 238, 0.55) !important;
    border-color: rgba(34, 211, 238, 0.55) !important;
}

.ao-stat-card.amber:hover {
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.5), 0 0 25px rgba(245, 158, 11, 0.55) !important;
    border-color: rgba(245, 158, 11, 0.55) !important;
}

.ao-stat-card.emerald:hover {
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.5), 0 0 25px rgba(16, 185, 129, 0.55) !important;
    border-color: rgba(16, 185, 129, 0.55) !important;
}

.ao-stat-card i {
    font-size: 24px;
    width: 48px;
    height: 48px;
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.ao-stat-card.purple i {
    color: var(--accent-purple);
    background: rgba(139, 92, 246, 0.1);
    border-color: rgba(139, 92, 246, 0.2);
}

.ao-stat-card.cyan i {
    color: var(--accent-cyan);
    background: rgba(34, 211, 238, 0.1);
    border-color: rgba(34, 211, 238, 0.2);
}

.ao-stat-card.amber i {
    color: var(--accent-amber);
    background: rgba(245, 158, 11, 0.1);
    border-color: rgba(245, 158, 11, 0.2);
}

.ao-stat-card.emerald i {
    color: var(--accent-emerald);
    background: rgba(16, 185, 129, 0.1);
    border-color: rgba(16, 185, 129, 0.2);
}

.ao-stat-info {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.ao-stat-info h3 {
    font-size: 11px;
    font-weight: 700;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.ao-stat-info span {
    font-size: 24px;
    font-weight: 800;
    color: #fff;
    font-family: var(--font-display);
}

.ao-stat-sub {
    font-size: 11px;
    font-weight: 600;
}

.ao-stat-sub.purple {
    color: #c4b5fd;
}

.ao-stat-sub.cyan {
    color: #67e8f9;
}

.ao-stat-sub.amber {
    color: #fcd34d;
}

.ao-stat-sub.emerald {
    color: #6ee7b7;
}

/* Glow Cards & Hovers with custom borders */
.glow-card {
    background: rgba(16, 18, 24, 0.6) !important;
    border-radius: 24px;
    padding: 24px;
    position: relative;
    overflow: hidden;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5);
    border: 1px solid rgba(255, 255, 255, 0.05);
    transition: transform 0.3s cubic-bezier(0.25, 0.8, 0.25, 1), box-shadow 0.3s ease, border-color 0.3s ease;
}

/* Rounded corners for stripe inside glow card */
.glow-card .ao-stripe {
    border-radius: 24px 24px 0 0;
}

.glow-card:hover {
    transform: translateY(-4px) !important;
}

/* Custom Theme Glows for glow-cards */
.glow-card.purple-theme:hover {
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.5), 0 0 25px rgba(155, 109, 255, 0.55) !important;
    border-color: rgba(155, 109, 255, 0.55) !important;
}

.glow-card.cyan-theme:hover {
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.5), 0 0 25px rgba(34, 211, 238, 0.55) !important;
    border-color: rgba(34, 211, 238, 0.55) !important;
}

.glow-card.amber-theme:hover {
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.5), 0 0 25px rgba(245, 158, 11, 0.55) !important;
    border-color: rgba(245, 158, 11, 0.55) !important;
}

.glow-card.emerald-theme:hover {
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.5), 0 0 25px rgba(16, 185, 129, 0.55) !important;
    border-color: rgba(16, 185, 129, 0.55) !important;
}

.glow-card.rose-theme:hover {
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.5), 0 0 25px rgba(244, 63, 94, 0.55) !important;
    border-color: rgba(244, 63, 94, 0.55) !important;
}

/* Disable the background rotating borders from default styles */
.glow-card::before,
.glow-card::after {
    display: none !important;
}

/* Status Board Nodes */
.node-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.node-item {
    background: rgba(255, 255, 255, 0.01);
    border: 1px solid rgba(255, 255, 255, 0.03);
    border-radius: 16px;
    padding: 14px 18px;
    display: flex;
    flex-direction: column;
    gap: 0;
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    cursor: pointer;
    overflow: hidden;
}

.node-item:hover {
    background: rgba(255, 255, 255, 0.03);
    border-color: rgba(139, 92, 246, 0.2);
    box-shadow: inset 0 0 12px rgba(139, 92, 246, 0.05);
}

.node-main-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
}

.node-info-block {
    display: flex;
    align-items: center;
    gap: 14px;
}

.node-icon-wrap {
    width: 38px;
    height: 38px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.05);
    font-size: 14px;
    color: var(--text-muted);
}

.node-item.online .node-icon-wrap {
    color: var(--accent-emerald);
    background: rgba(16, 185, 129, 0.08);
    border-color: rgba(16, 185, 129, 0.2);
    box-shadow: 0 0 12px rgba(16, 185, 129, 0.2);
}

.node-item.syncing .node-icon-wrap {
    color: var(--accent-amber);
    background: rgba(245, 158, 11, 0.08);
    border-color: rgba(245, 158, 11, 0.2);
    box-shadow: 0 0 12px rgba(245, 158, 11, 0.2);
}

.node-details h4 {
    font-size: 14px;
    font-weight: 700;
    color: #fff;
    margin-bottom: 2px;
}

.node-details span {
    font-size: 11px;
    color: var(--text-muted);
}

.node-metrics {
    display: flex;
    align-items: center;
    gap: 20px;
}

.metric-pill {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 2px;
}

.metric-pill .label {
    font-size: 9px;
    font-weight: 700;
    color: var(--text-muted);
    text-transform: uppercase;
}

.metric-pill .value {
    font-size: 12px;
    font-weight: 800;
    color: #fff;
}

.metric-pill .value.green {
    color: var(--accent-emerald);
}

.metric-pill .value.amber {
    color: var(--accent-amber);
}

.node-chevron {
    color: var(--text-muted);
    font-size: 12px;
    transition: transform 0.3s ease;
    margin-left: 10px;
}

.node-item.expanded .node-chevron {
    transform: rotate(180deg);
    color: var(--accent-purple);
}

/* Node Details Panel (expanded state) */
.node-details-panel {
    max-height: 0;
    opacity: 0;
    overflow: hidden;
    transition: max-height 0.4s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.3s ease, margin-top 0.3s ease;
}

.node-item.expanded .node-details-panel {
    max-height: 200px;
    opacity: 1;
    margin-top: 16px;
    border-top: 1px dashed rgba(255, 255, 255, 0.06);
    padding-top: 14px;
}

.node-telemetry-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
}

.telemetry-cell {
    background: rgba(0, 0, 0, 0.15);
    border: 1px solid rgba(255, 255, 255, 0.02);
    border-radius: 10px;
    padding: 10px;
}

.telemetry-cell label {
    display: block;
    font-size: 9px;
    font-weight: 700;
    color: var(--text-muted);
    text-transform: uppercase;
    margin-bottom: 4px;
}

.telemetry-cell span {
    font-size: 12.5px;
    font-weight: 800;
    color: #fff;
}

/* Server List Styles */
.server-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
    max-height: 380px;
    overflow-y: auto;
    padding-right: 6px;
}

.server-item {
    background: rgba(255, 255, 255, 0.01);
    border: 1px solid rgba(255, 255, 255, 0.03);
    border-radius: 16px;
    padding: 14px 18px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    transition: all 0.3s ease;
}

.server-item:hover {
    background: rgba(255, 255, 255, 0.03);
    border-color: rgba(139, 92, 246, 0.2);
    box-shadow: inset 0 0 12px rgba(139, 92, 246, 0.05);
}

.server-info-block {
    display: flex;
    align-items: center;
    gap: 14px;
}

.server-avatar-circle {
    width: 42px;
    height: 42px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
    font-size: 14px;
    color: #fff;
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.server-details h4 {
    font-size: 14.5px;
    font-weight: 800;
    color: #fff;
    margin-bottom: 2px;
}

.server-details span {
    font-size: 11px;
    color: var(--text-muted);
}

.server-metrics {
    display: flex;
    align-items: center;
    gap: 20px;
}

.server-online-badge {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 11px;
    font-weight: 700;
    color: var(--accent-emerald);
    background: rgba(16, 185, 129, 0.08);
    border: 1px solid rgba(16, 185, 129, 0.2);
    padding: 4px 10px;
    border-radius: 20px;
    box-shadow: 0 0 10px rgba(16, 185, 129, 0.1);
}

/* Glow Search Input */
.ao-search-wrap {
    position: relative;
    margin-bottom: 16px;
}

.ao-search-input {
    width: 100%;
    background: rgba(0, 0, 0, 0.2);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 14px;
    padding: 12px 16px 12px 42px;
    color: #fff;
    font-size: 14px;
    outline: none;
    transition: all 0.3s ease;
}

.ao-search-input:focus {
    border-color: var(--accent-purple);
    background: rgba(0, 0, 0, 0.3);
    box-shadow: 0 0 15px rgba(139, 92, 246, 0.2);
}

.ao-search-wrap i {
    position: absolute;
    left: 16px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
    font-size: 14px;
    transition: color 0.3s;
}

.ao-search-input:focus+i {
    color: var(--accent-purple);
}

/* System Alerts Card */
.alert-card-item {
    background: rgba(244, 63, 94, 0.03);
    border: 1px solid rgba(244, 63, 94, 0.15);
    border-radius: 16px;
    padding: 12px 16px;
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 12px;
    box-shadow: 0 0 15px rgba(244, 63, 94, 0.05);
}

.alert-card-item.warning {
    background: rgba(245, 158, 11, 0.03);
    border-color: rgba(245, 158, 11, 0.15);
    box-shadow: 0 0 15px rgba(245, 158, 11, 0.05);
}

.alert-card-item i {
    font-size: 16px;
    flex-shrink: 0;
}

.alert-card-item.danger i {
    color: var(--accent-rose);
}

.alert-card-item.warning i {
    color: var(--accent-amber);
}

.alert-card-content {
    flex: 1;
    font-size: 12px;
    color: rgba(255, 255, 255, 0.85);
    line-height: 1.4;
}

/* Timeline/Audit Logs widget */
.timeline-list {
    display: flex;
    flex-direction: column;
    gap: 16px;
    max-height: 320px;
    overflow-y: auto;
    padding-right: 6px;
}

.timeline-item {
    display: flex;
    gap: 14px;
    position: relative;
}

.timeline-item::before {
    content: '';
    position: absolute;
    left: 7px;
    top: 20px;
    bottom: -24px;
    width: 2px;
    background: rgba(255, 255, 255, 0.05);
}

.timeline-item:last-child::before {
    display: none;
}

.timeline-dot {
    width: 16px;
    height: 16px;
    border-radius: 50%;
    border: 3px solid #06070a;
    background: var(--text-muted);
    flex-shrink: 0;
    margin-top: 2px;
    z-index: 2;
}

.timeline-dot.info {
    background: var(--accent-cyan);
    box-shadow: 0 0 10px rgba(34, 211, 238, 0.5);
}

.timeline-dot.warning {
    background: var(--accent-amber);
    box-shadow: 0 0 10px rgba(245, 158, 11, 0.5);
}

.timeline-dot.danger {
    background: var(--accent-rose);
    box-shadow: 0 0 10px rgba(244, 63, 94, 0.5);
}

.timeline-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.timeline-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.timeline-user {
    font-size: 12px;
    font-weight: 800;
    color: #fff;
}

.timeline-time {
    font-size: 10px;
    color: var(--text-muted);
}

.timeline-desc {
    font-size: 12px;
    color: rgba(255, 255, 255, 0.75);
    line-height: 1.4;
}

.timeline-category {
    align-self: flex-start;
    font-size: 9px;
    font-weight: 800;
    padding: 2px 6px;
    border-radius: 4px;
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-muted);
    text-transform: uppercase;
}

/* Pulse breathing effect */
.pulse-green {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--accent-emerald);
    box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.7);
    animation: pulse-breathing 2s infinite;
}

@keyframes pulse-breathing {
    0% {
        transform: scale(0.95);
        box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.7);
    }

    70% {
        transform: scale(1);
        box-shadow: 0 0 0 8px rgba(16, 185, 129, 0);
    }

    100% {
        transform: scale(0.95);
        box-shadow: 0 0 0 0 rgba(16, 185, 129, 0);
    }
}