:root {
    /* Background Colors */
    --background-color: #0a0e1b;
    --card-background: rgba(255, 255, 255, 0.02);
    --btn-text-dark: #1a1a2e;

    /* Text Colors */
    --text-color: #e6f0ff;
    --text-muted: #8099cc;
    --heading-color: #ffffff;
    --link-color: #b3d9ff;
    --placeholder-color: #5a6a8a;

    /* Primary Colors */
    --primary-color: #7eb8da;
    --primary-hover: #a3d0eb;
    --primary-light: rgba(126, 184, 218, 0.15);
    --primary-light-hover: rgba(126, 184, 218, 0.25);
    --primary-border: rgba(126, 184, 218, 0.3);
    --primary-border-hover: rgba(126, 184, 218, 0.5);

    /* Status Colors */
    --danger-color: #ef6b6b;
    --danger-hover: #e04545;
    --danger-light: rgba(232, 160, 160, 0.15);
    --danger-light-hover: rgba(232, 160, 160, 0.25);
    --danger-border: rgba(232, 160, 160, 0.3);
    --danger-border-hover: rgba(232, 160, 160, 0.5);
    --danger-text: #e8a0a0;

    --success-color: #4eca7a;
    --success-hover: #3db868;
    --success-light: rgba(142, 205, 168, 0.15);
    --success-light-hover: rgba(142, 205, 168, 0.25);
    --success-border: rgba(142, 205, 168, 0.3);
    --success-border-hover: rgba(142, 205, 168, 0.5);
    --success-text: #8ecda8;

    --warning-color: #f0a020;
    --warning-hover: #d89010;
    --warning-light: rgba(232, 200, 140, 0.15);
    --warning-light-hover: rgba(232, 200, 140, 0.25);
    --warning-border: rgba(232, 200, 140, 0.3);
    --warning-border-hover: rgba(232, 200, 140, 0.5);
    --warning-text: #e8c88c;

    /* Border & Glass Effects */
    --border-color: rgba(255, 255, 255, 0.08);
    --glass-bg: rgba(255, 255, 255, 0.02);
    --glass-border: rgba(255, 255, 255, 0.08);
    --glass-blur: blur(12px);

    /* Gradients */
    --gradient-primary: linear-gradient(135deg, #7eb8da, #a3d0eb);
    --gradient-primary-hover: linear-gradient(135deg, #a3d0eb, #7eb8da);
    --gradient-danger: linear-gradient(135deg, #ef6b6b, #e04545);
    --gradient-success: linear-gradient(135deg, #4eca7a, #3db868);
    --gradient-warning: linear-gradient(135deg, #f0a020, #d89010);

    /* Shadows */
    --shadow-glow: 0 8px 20px rgba(126, 184, 218, 0.25);
    --shadow-card: 0 8px 32px rgba(0, 0, 0, 0.3);
    --shadow-button: 0 4px 15px rgba(126, 184, 218, 0.25);

    /* Border Radius */
    --radius-sm: 4px;
    --radius-md: 6px;
    --radius-lg: 8px;
    --radius-xl: 12px;
    --radius-2xl: 16px;
    --radius-pill: 20px;

    /* Spacing */
    --space-1: 4px;
    --space-2: 8px;
    --space-3: 12px;
    --space-4: 16px;
    --space-5: 20px;
    --space-6: 24px;
    --space-8: 32px;

    /* Typography */
    --font-size-xs: 0.65rem;
    --font-size-sm: 0.75rem;
    --font-size-base: 0.85rem;
    --font-size-md: 0.9rem;
    --font-size-lg: 1rem;
    --font-size-xl: 1.25rem;
    --font-size-2xl: 1.5rem;

    /* Transitions */
    --transition-fast: 0.2s ease;
    --transition-base: 0.3s ease;
}

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

body {
    font-family: 'Segoe UI', -apple-system, BlinkMacSystemFont, Roboto, 'Helvetica Neue', Arial, sans-serif;
    background-color: var(--background-color);
    color: var(--text-color);
    line-height: 1.6;
    min-height: 100vh;
    overflow-x: hidden;
    position: relative;
}

body::before {
    content: '';
    position: fixed;
    inset: 0;
    background:
        radial-gradient(ellipse at top left, rgba(26, 47, 99, 0.4) 0%, transparent 50%),
        radial-gradient(ellipse at bottom right, rgba(15, 31, 66, 0.4) 0%, transparent 50%),
        radial-gradient(ellipse at center, rgba(20, 35, 70, 0.2) 0%, transparent 70%);
    pointer-events: none;
    z-index: 0;
}

body::after {
    content: '';
    position: fixed;
    inset: 0;
    background-image:
        linear-gradient(rgba(255,255,255,.01) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255,255,255,.01) 1px, transparent 1px);
    background-size: 50px 50px;
    pointer-events: none;
    z-index: 0;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
    position: relative;
    z-index: 1;
}

.header {
    background: rgba(1, 9, 21, 0.9);
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
    color: white;
    padding: 20px 0;
    position: sticky;
    top: 0;
    z-index: 1000;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    margin-bottom: 30px;
}

.header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.header h1 {
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--heading-color);
}

.header-nav {
    display: flex;
    gap: 20px;
    align-items: center;
}

.header-nav a {
    color: var(--link-color);
    text-decoration: none;
    padding: 8px 16px;
    border-radius: 6px;
    transition: all 0.3s ease;
    font-weight: 500;
}

.header-nav a:hover {
    color: var(--heading-color);
    background-color: rgba(126, 184, 218, 0.15);
}

.header-nav form {
    display: inline;
}

.header-nav button {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(126, 184, 218, 0.3);
    color: var(--link-color);
    padding: 8px 16px;
    border-radius: 6px;
    font-size: inherit;
    font-family: inherit;
    cursor: pointer;
    transition: all 0.3s ease;
    font-weight: 500;
}

.header-nav button:hover {
    background: rgba(126, 184, 218, 0.15);
    border-color: #7eb8da;
    color: var(--heading-color);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(126, 184, 218, 0.25);
}

.header-nav span {
    color: var(--text-muted);
}

.nav-dropdown {
    position: relative;
    display: inline-block;
}

.nav-dropdown-toggle {
    background: transparent;
    border: none;
    color: var(--link-color);
    padding: 8px 16px;
    border-radius: 6px;
    cursor: pointer;
    font-weight: 500;
    font-size: inherit;
    font-family: inherit;
    transition: all 0.3s ease;
}

.nav-dropdown-toggle:hover,
.nav-dropdown-toggle.active {
    color: var(--heading-color);
    background-color: rgba(126, 184, 218, 0.15);
}

.nav-dropdown-menu {
    display: none;
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    min-width: 160px;
    background: rgba(15, 20, 35, 0.95);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--glass-border);
    border-radius: 8px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4);
    z-index: 1001;
    overflow: hidden;
    margin-top: 4px;
}

.nav-dropdown-menu.show {
    display: block;
}

.nav-dropdown-menu a {
    display: block;
    padding: 12px 16px;
    color: var(--text-color);
    text-decoration: none;
    font-size: 0.9rem;
    transition: background 0.2s ease;
}

.nav-dropdown-menu a:hover {
    background: rgba(126, 184, 218, 0.15);
    color: #7eb8da;
}

.card {
    background: var(--glass-bg);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    border-radius: 16px;
    border: 1px solid var(--glass-border);
    box-shadow: var(--shadow-card);
    padding: 25px;
    margin-bottom: 20px;
    position: relative;
    z-index: 1;
    transition: all 0.3s ease;
    animation: fadeInUp 0.5s ease-out;
}

.card:hover {
    border-color: rgba(126, 184, 218, 0.2);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.4);
}

.card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 1px solid var(--glass-border);
}

.card-header h2 {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--heading-color);
}

.btn {
    display: inline-block;
    padding: 10px 20px;
    border: none;
    border-radius: 6px;
    font-family: inherit;
    font-size: 0.9rem;
    font-weight: 600;
    line-height: 1.2;
    text-decoration: none;
    cursor: pointer;
    box-sizing: border-box;
    vertical-align: middle;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.btn:hover {
    transform: translateY(-2px);
}

.btn-danger {
    background: var(--gradient-danger);
    color: #1a1a2e;
    box-shadow: 0 4px 15px rgba(212, 136, 136, 0.3);
}

.btn-danger::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.3), transparent);
    transition: left 0.5s ease;
}

.btn-danger:hover::before {
    left: 100%;
}

.btn-danger:hover {
    background: linear-gradient(135deg, #d48888, #e8a0a0);
    box-shadow: 0 8px 20px rgba(212, 136, 136, 0.4);
}

.btn-primary {
    background: var(--gradient-primary);
    color: #1a1a2e;
    box-shadow: 0 4px 15px rgba(126, 184, 218, 0.3);
}

.btn-primary::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.3), transparent);
    transition: left 0.5s ease;
}

.btn-primary:hover::before {
    left: 100%;
}

.btn-primary:hover {
    background: var(--gradient-primary-hover);
    box-shadow: 0 8px 20px rgba(126, 184, 218, 0.4);
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.05);
    color: var(--link-color);
    border: 1px solid rgba(126, 184, 218, 0.3);
}

.btn-secondary:hover {
    background: rgba(126, 184, 218, 0.15);
    border-color: #7eb8da;
    color: var(--heading-color);
    box-shadow: 0 8px 20px rgba(126, 184, 218, 0.25);
}

.btn-sm {
    padding: 5px 12px;
    font-size: 0.75rem;
}

.table-responsive {
    width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    border-radius: 8px;
}

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

.table th,
.table td {
    padding: 12px 15px;
    text-align: left;
    border-bottom: 1px solid var(--glass-border);
    vertical-align: middle;
}

.table th {
    background-color: rgba(255, 255, 255, 0.03);
    font-weight: 600;
    color: var(--link-color);
    text-transform: uppercase;
    font-size: 0.75rem;
    letter-spacing: 0.5px;
    text-align: center;
}

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

.table-actions {
    display: flex;
    gap: 8px;
}

.order-buttons {
    display: flex;
    flex-direction: column;
    gap: 2px;
    align-items: center;
}

.btn-order {
    padding: 4px 8px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--glass-border);
    color: var(--text-color);
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
}

.btn-order:hover {
    background: rgba(126, 184, 218, 0.15);
    border-color: var(--primary-color);
    color: var(--primary-color);
}

.btn-order.btn-disabled {
    cursor: default;
    opacity: 0.3;
    pointer-events: none;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 6px;
    font-weight: 500;
    color: var(--link-color);
}

.form-control {
    width: 100%;
    padding: 12px 14px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--glass-border);
    border-radius: 8px;
    font-size: 1rem;
    color: var(--text-color);
    transition: border-color 0.3s ease, box-shadow 0.3s ease, background 0.3s ease;
}

.form-control:focus {
    outline: none;
    border-color: #7eb8da;
    background: rgba(126, 184, 218, 0.05);
    box-shadow: 0 0 0 3px rgba(126, 184, 218, 0.15);
}

.form-control::placeholder {
    color: #5a6a8a;
}

select.form-control {
    appearance: none;
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3e%3cpath fill='none' stroke='%23b3d9ff' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='m2 5 6 6 6-6'/%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right 12px center;
    background-size: 16px 12px;
    padding-right: 40px;
    /* Override transition to exclude background (prevents arrow animation on step change) */
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.form-check {
    display: flex;
    align-items: center;
    gap: 8px;
}

.form-check input[type="checkbox"] {
    width: 16px;
    height: 16px;
    accent-color: var(--primary-color);
}

.form-actions {
    display: flex;
    gap: 10px;
    margin-top: 20px;
}

.alert {
    padding: 15px 20px;
    border-radius: 8px;
    margin-bottom: 20px;
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
}

.alert-success {
    background-color: rgba(142, 205, 168, 0.1);
    color: #8ecda8;
    border: 1px solid rgba(142, 205, 168, 0.4);
    box-shadow: 0 0 20px rgba(142, 205, 168, 0.15);
}

.alert-danger {
    background-color: rgba(232, 160, 160, 0.1);
    color: #e8a0a0;
    border: 1px solid rgba(232, 160, 160, 0.4);
    box-shadow: 0 0 20px rgba(232, 160, 160, 0.15);
}

.login-container {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    position: relative;
    z-index: 1;
}

.login-card {
    background: var(--glass-bg);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    border-radius: 16px;
    border: 1px solid var(--glass-border);
    box-shadow: var(--shadow-card);
    padding: 50px 60px;
    width: 100%;
    max-width: 480px;
    animation: fadeInUp 0.6s ease-out;
}

.login-card h1 {
    text-align: center;
    margin-bottom: 40px;
    background: linear-gradient(135deg, #ffffff, #b3d9ff);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    font-size: 2rem;
    font-weight: 300;
}

.login-card .form-group {
    margin-bottom: 24px;
}

.login-card .btn {
    width: 100%;
    padding: 14px;
    margin-top: 10px;
}

.badge {
    display: inline-block;
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.badge-success {
    background: rgba(142, 205, 168, 0.15);
    color: #8ecda8;
    border: 1px solid rgba(142, 205, 168, 0.3);
}

.badge-danger {
    background: rgba(232, 160, 160, 0.15);
    color: #e8a0a0;
    border: 1px solid rgba(232, 160, 160, 0.3);
}

.badge-info {
    background: rgba(126, 184, 218, 0.15);
    color: #7eb8da;
    border: 1px solid rgba(126, 184, 218, 0.3);
}

.badge-warning {
    background: rgba(232, 200, 140, 0.15);
    color: #e8c88c;
    border: 1px solid rgba(232, 200, 140, 0.3);
}

.machine-list {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.machine-tag {
    background: rgba(126, 184, 218, 0.1);
    color: var(--link-color);
    padding: 6px 12px;
    border-radius: 6px;
    font-size: 0.85rem;
    border: 1px solid rgba(126, 184, 218, 0.2);
    transition: all 0.2s ease;
}

.machine-tag:hover {
    background: rgba(126, 184, 218, 0.2);
    border-color: rgba(126, 184, 218, 0.4);
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
        opacity: 1;
    }
    50% {
        transform: scale(1.05);
        opacity: 0.8;
    }
}

@keyframes shine {
    0% {
        left: -100%;
    }
    100% {
        left: 100%;
    }
}

@keyframes float {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-10px);
    }
}

@media (max-width: 768px) {
    .header .container {
        flex-direction: row;
        flex-wrap: wrap;
        justify-content: space-between;
        padding: 15px;
    }

    .header h1 {
        font-size: 1.25rem;
    }

    .header-nav {
        gap: 10px;
    }

    .header-nav span {
        font-size: 0.9rem;
    }

    .header-nav button {
        padding: 6px 12px;
        font-size: 0.85rem;
    }

    .container {
        padding: 15px;
    }

    .card {
        padding: 15px;
        margin-bottom: 15px;
        border-radius: 12px;
    }

    .card-header {
        flex-direction: column;
        gap: 15px;
        align-items: stretch;
    }

    .card-header h2 {
        text-align: center;
    }

    .card-header .btn {
        width: 100%;
        text-align: center;
    }

    .table-responsive {
        width: 100%;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        margin-bottom: 15px;
        border: 1px solid var(--glass-border);
        border-radius: 8px;
        position: relative;
    }

    .table-responsive::after {
        content: '';
        position: absolute;
        top: 0;
        right: 0;
        bottom: 0;
        width: 20px;
        background: linear-gradient(to left, rgba(10, 14, 27, 0.8), transparent);
        pointer-events: none;
    }

    .table {
        min-width: 650px;
    }

    .table th,
    .table td {
        padding: 10px 12px;
        white-space: nowrap;
    }

    .table-actions {
        flex-wrap: nowrap;
        gap: 6px;
    }

    .form-actions {
        display: flex;
        flex-direction: column;
        gap: 10px;
    }

    .form-actions .btn {
        width: 100%;
        text-align: center;
    }

    .login-card {
        padding: 40px 45px;
        margin: 15px;
    }
}

@media (max-width: 480px) {
    .header .container {
        flex-direction: column;
        gap: 10px;
        padding: 12px 15px;
    }

    .header h1 {
        font-size: 1.1rem;
    }

    .header-nav {
        flex-direction: row;
        gap: 15px;
        width: 100%;
        justify-content: center;
    }

    .header-nav span {
        font-size: 0.85rem;
    }

    .header-nav button {
        padding: 5px 10px;
        font-size: 0.8rem;
    }

    .container {
        padding: 10px;
    }

    .card {
        padding: 12px;
        border-radius: 10px;
    }

    .card-header {
        gap: 12px;
    }

    .card-header h2 {
        font-size: 1rem;
    }

    .table-responsive {
        margin: 0 -12px;
        width: calc(100% + 24px);
        border-radius: 0;
        border-left: none;
        border-right: none;
    }

    .table {
        min-width: 580px;
    }

    .table th,
    .table td {
        padding: 8px 10px;
        font-size: 0.8rem;
    }

    .table-actions {
        gap: 4px;
    }

    .table-actions .btn-sm {
        padding: 5px 8px;
        font-size: 0.7rem;
    }

    .badge {
        padding: 3px 8px;
        font-size: 0.65rem;
    }

    .machine-tag {
        padding: 3px 6px;
        font-size: 0.7rem;
    }

    .login-card {
        padding: 35px 25px;
        margin: 10px;
        max-width: none;
        width: calc(100% - 20px);
    }

    .login-card h1 {
        font-size: 1.5rem;
        margin-bottom: 30px;
    }

    .form-control {
        padding: 14px;
        font-size: 16px;
    }

    .btn {
        padding: 12px 16px;
    }

    .alert {
        padding: 12px 15px;
        font-size: 0.9rem;
    }

    .card-header .btn {
        padding: 10px 16px;
        font-size: 0.9rem;
    }
}

.btn:disabled,
.btn[disabled] {
    opacity: 0.5;
    cursor: not-allowed;
    pointer-events: none;
}

.btn:disabled:hover,
.btn[disabled]:hover {
    transform: none;
}

.gradient-text {
    background: linear-gradient(135deg, #ffffff, #b3d9ff);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.highlight-box {
    background: rgba(126, 184, 218, 0.08);
    border-left: 3px solid #7eb8da;
    padding: 20px;
    margin: 25px 0;
    border-radius: 8px;
}

.highlight-box p {
    color: var(--link-color);
    margin-bottom: 0;
}

.hidden {
    display: none !important;
}

.form-inline {
    display: inline;
}

.text-center {
    text-align: center;
}

.text-muted {
    color: var(--text-muted);
}

/* Utility classes */
.mt-15 {
    margin-top: 15px;
}

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

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

.m-0 {
    margin: 0;
}

.form-inline {
    margin: 0;
}

.hr-section {
    margin: 1.5rem 0;
    border-color: var(--border-color);
}

.full-grid-width {
    grid-column: 1 / -1;
    text-align: center;
    padding: 2rem;
}

.empty-state {
    text-align: center;
    color: var(--text-muted);
    padding: 20px;
}

.empty-state-lg {
    text-align: center;
    color: var(--text-muted);
    padding: 40px;
}

.machine-input-container {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 15px;
}

.machine-input-row {
    display: flex;
    gap: 10px;
    align-items: center;
}

.machine-input-row input {
    width: 150px;
}

.current-machines {
    margin-bottom: 20px;
    padding: 15px;
    background-color: rgba(255, 255, 255, 0.02);
    border-radius: 8px;
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.current-machines h4 {
    margin-bottom: 10px;
    color: #b3d9ff;
}

.help-text {
    color: #8099cc;
    font-size: 0.875rem;
    margin-top: 5px;
}

.help-text code {
    background: rgba(126, 184, 218, 0.1);
    padding: 2px 6px;
    border-radius: 4px;
    color: #7eb8da;
}

.available-servers {
    margin-top: 5px;
    margin-left: 20px;
    color: var(--text-muted);
}

.machine-assignment-form {
    display: flex;
    flex-direction: column;
    height: calc(100vh - 400px);
    min-height: 300px;
}

.vm-selection-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 8px;
    flex: 1;
    overflow-y: auto;
    padding: 10px;
    background: rgba(0, 0, 0, 0.15);
    border-radius: 10px;
    margin-bottom: 20px;
    border: 1px solid var(--glass-border);
    align-items: start;
    align-content: start;
}

.vm-checkbox-item {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: 4px;
    padding: 6px 12px;
    transition: all 0.2s ease;
}

.vm-checkbox-item:hover {
    border-color: rgba(126, 184, 218, 0.4);
    background: rgba(126, 184, 218, 0.05);
}

.vm-checkbox-item.selected {
    border: 1px solid rgba(255, 255, 255, 0.8);
    background: rgba(126, 184, 218, 0.05);
}

.vm-checkbox-label {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    cursor: pointer;
}

.vm-checkbox-label input[type="checkbox"] {
    appearance: none;
    -webkit-appearance: none;
    width: 14px;
    height: 14px;
    border: 1px solid rgba(126, 184, 218, 0.4);
    border-radius: 3px;
    background: rgba(126, 184, 218, 0.1);
    cursor: pointer;
    position: relative;
    transition: all 0.2s ease;
    flex-shrink: 0;
    margin-top: 3px;
}

.vm-checkbox-label input[type="checkbox"]:hover {
    border-color: rgba(126, 184, 218, 0.6);
    background: rgba(126, 184, 218, 0.15);
}

.vm-checkbox-label input[type="checkbox"]:checked {
    background: rgba(126, 184, 218, 0.25);
    border-color: rgba(126, 184, 218, 0.6);
}

.vm-checkbox-label input[type="checkbox"]:checked::after {
    content: '✓';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: #7eb8da;
    font-size: 9px;
    font-weight: bold;
}

.vm-info {
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
    flex: 1;
}

.vm-name {
    font-weight: 500;
    color: var(--heading-color);
    font-size: 0.8rem;
}

.vm-meta {
    display: flex;
    align-items: center;
    gap: 6px;
}

.vm-server {
    font-size: 0.75rem;
    color: var(--text-muted);
}

.status-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    flex-shrink: 0;
}

.status-dot.running {
    background: #8ecda8;
    box-shadow: 0 0 6px rgba(142, 205, 168, 0.5);
}

.status-dot.stopped {
    background: #e8a0a0;
    box-shadow: 0 0 6px rgba(232, 160, 160, 0.5);
}

.status-dot.other {
    background: #e8c88c;
    box-shadow: 0 0 6px rgba(232, 200, 140, 0.5);
}

.assign-checkbox.hidden {
    display: none !important;
}

.vm-checkbox-item {
    cursor: pointer;
    display: flex;
    flex-direction: column;
    gap: 4px;
}


.vm-meta-row {
    display: flex;
    align-items: center;
    gap: 8px;
}

.owned-checkbox-label {
    display: flex;
    align-items: center;
    gap: 4px;
    cursor: pointer;
    opacity: 0.4;
    transition: opacity 0.2s;
}

.vm-checkbox-item.selected .owned-checkbox-label {
    opacity: 1;
}

.owned-checkbox {
    appearance: none;
    -webkit-appearance: none;
    width: 14px;
    height: 14px;
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 3px;
    background: rgba(255, 255, 255, 0.05);
    cursor: pointer;
    position: relative;
    transition: all 0.2s ease;
    flex-shrink: 0;
}

.owned-checkbox:disabled {
    opacity: 0.3;
    cursor: not-allowed;
}

.owned-checkbox:not(:disabled):hover {
    border-color: rgba(255, 255, 255, 0.5);
    background: rgba(255, 255, 255, 0.1);
}

.owned-checkbox:checked {
    background: rgba(255, 255, 255, 0.15);
    border-color: rgba(255, 255, 255, 0.5);
}

.owned-checkbox:checked::after {
    content: '✓';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: rgba(255, 255, 255, 0.9);
    font-size: 9px;
    font-weight: bold;
}

.owned-label {
    font-size: 0.75rem;
    color: var(--text-muted);
    user-select: none;
}


.vm-meta-row .vm-server {
    margin-left: auto;
}

.bulk-selection {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
    margin-bottom: 15px;
    padding: 12px 15px;
    background: rgba(255, 255, 255, 0.02);
    border-radius: 8px;
    border: 1px solid var(--glass-border);
}

.selection-count {
    color: var(--heading-color);
    font-size: 0.9rem;
    margin-left: auto;
}

.header-actions {
    display: flex;
    gap: 10px;
    align-items: center;
}

@media (max-width: 768px) {
    .vm-selection-grid {
        grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
        padding: 8px;
        gap: 6px;
    }

    .vm-checkbox-item {
        padding: 5px 10px;
    }

    .bulk-selection {
        flex-direction: column;
        align-items: stretch;
        gap: 8px;
    }

    .bulk-selection .btn {
        width: 100%;
        text-align: center;
    }

    .selection-count {
        margin-left: 0;
        text-align: center;
    }

    .header-actions {
        flex-direction: column;
        width: 100%;
    }

    .header-actions .btn,
    .header-actions form {
        width: 100%;
    }

    .header-actions form .btn {
        width: 100%;
    }
}

@media (max-width: 480px) {
    .vm-selection-grid {
        grid-template-columns: 1fr;
        padding: 6px;
        gap: 4px;
    }

    .vm-checkbox-label {
        gap: 6px;
    }

    .vm-name {
        font-size: 0.75rem;
    }

    .vm-server {
        display: none;
    }
}

.announcements-list {
    display: flex;
    flex-direction: column;
    gap: 20px;
    padding: 20px;
}

.announcement-item {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--glass-border);
    border-radius: 12px;
    padding: 20px;
    transition: all 0.3s ease;
}

.announcement-item:hover {
    border-color: rgba(126, 184, 218, 0.2);
    background: rgba(126, 184, 218, 0.03);
}

.announcement-title {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--heading-color);
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 1px solid var(--glass-border);
}

.announcement-content {
    color: var(--text-color);
    line-height: 1.7;
}

.markdown-body h1,
.markdown-body h2,
.markdown-body h3,
.markdown-body h4,
.markdown-body h5,
.markdown-body h6 {
    color: var(--heading-color);
    margin-top: 1.5em;
    margin-bottom: 0.5em;
    font-weight: 600;
}

.markdown-body h1:first-child,
.markdown-body h2:first-child,
.markdown-body h3:first-child,
.markdown-body h4:first-child {
    margin-top: 0;
}

.markdown-body h1 { font-size: 1.5rem; }
.markdown-body h2 { font-size: 1.3rem; }
.markdown-body h3 { font-size: 1.15rem; }
.markdown-body h4 { font-size: 1rem; }

.markdown-body p {
    margin-bottom: 1em;
}

.markdown-body ul,
.markdown-body ol {
    margin-bottom: 1em;
    padding-left: 2em;
}

.markdown-body li {
    margin-bottom: 0.5em;
}

.markdown-body a {
    color: var(--link-color);
    text-decoration: underline;
}

.markdown-body a:hover {
    color: var(--heading-color);
}

.markdown-body code {
    background: rgba(126, 184, 218, 0.1);
    padding: 2px 6px;
    border-radius: 4px;
    color: var(--primary-color);
    font-family: 'Consolas', 'Monaco', 'Courier New', monospace;
    font-size: 0.9em;
}

.markdown-body pre {
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid var(--glass-border);
    border-radius: 8px;
    padding: 15px;
    overflow-x: auto;
    margin-bottom: 1em;
}

.markdown-body pre code {
    background: transparent;
    padding: 0;
    color: var(--text-color);
}

.markdown-body blockquote {
    border-left: 3px solid var(--primary-color);
    padding-left: 15px;
    margin: 1em 0;
    color: var(--text-muted);
    font-style: italic;
}

.markdown-body hr {
    border: none;
    border-top: 1px solid var(--glass-border);
    margin: 2em 0;
}

.markdown-body strong {
    color: var(--heading-color);
}

.markdown-body table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 1em;
}

.markdown-body th,
.markdown-body td {
    border: 1px solid var(--glass-border);
    padding: 8px 12px;
    text-align: left;
}

.markdown-body th {
    background: rgba(126, 184, 218, 0.1);
    color: var(--heading-color);
}

.markdown-body img {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
}

textarea.markdown-editor {
    font-family: 'Consolas', 'Monaco', 'Courier New', monospace;
    font-size: 0.9rem;
    line-height: 1.5;
    resize: vertical;
    min-height: 300px;
}

.help-text {
    color: var(--text-muted);
    font-size: 0.85rem;
    margin-top: 5px;
}

.empty-state-lg {
    text-align: center;
    padding: 60px 20px;
    color: var(--text-muted);
}

.empty-state-lg p {
    font-size: 1.1rem;
}

@media (max-width: 768px) {
    .announcements-list {
        padding: 15px;
        gap: 15px;
    }

    .announcement-item {
        padding: 15px;
    }

    .announcement-title {
        font-size: 1.1rem;
    }
}

@media (max-width: 480px) {
    .announcements-list {
        padding: 10px;
        gap: 12px;
    }

    .announcement-item {
        padding: 12px;
    }

    .announcement-title {
        font-size: 1rem;
    }

    .markdown-body pre {
        padding: 10px;
        font-size: 0.85rem;
    }
}

.lang-switch {
    display: flex;
    gap: 8px;
    align-items: center;
}

.lang-switch a {
    padding: 4px 10px;
    font-size: 0.8rem;
    font-weight: 500;
    color: var(--text-muted);
    text-decoration: none;
    border: 1px solid var(--glass-border);
    border-radius: 4px;
    transition: all 0.2s ease;
}

.lang-switch a:hover {
    color: var(--text-color);
    border-color: rgba(126, 184, 218, 0.4);
    background: rgba(126, 184, 218, 0.1);
}

.lang-switch a.active {
    color: #7eb8da;
    border-color: rgba(126, 184, 218, 0.5);
    background: rgba(126, 184, 218, 0.15);
}

.login-lang-switch {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin-top: 20px;
}

.login-lang-switch a {
    padding: 6px 14px;
    font-size: 0.85rem;
    font-weight: 500;
    color: var(--text-muted);
    text-decoration: none;
    border: 1px solid var(--glass-border);
    border-radius: 6px;
    transition: all 0.2s ease;
}

.login-lang-switch a:hover {
    color: var(--text-color);
    border-color: rgba(126, 184, 218, 0.4);
    background: rgba(126, 184, 218, 0.1);
}

.login-lang-switch a.active {
    color: #7eb8da;
    border-color: rgba(126, 184, 218, 0.5);
    background: rgba(126, 184, 218, 0.15);
}

.language-tabs {
    display: flex;
    gap: 0;
    margin-bottom: 1.5rem;
    border-bottom: 2px solid var(--glass-border);
}

.tab-btn {
    padding: 0.75rem 1.5rem;
    border: none;
    background: transparent;
    color: var(--text-muted);
    cursor: pointer;
    font-size: 1rem;
    font-family: inherit;
    border-bottom: 2px solid transparent;
    margin-bottom: -2px;
    transition: all 0.2s ease;
}

.tab-btn:hover {
    color: var(--text-color);
    background: rgba(126, 184, 218, 0.05);
}

.tab-btn.active {
    color: #7eb8da;
    border-bottom-color: #7eb8da;
    font-weight: 500;
}

.tab-content {
    display: none;
}

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

.badge-primary {
    background: rgba(126, 184, 218, 0.2);
    color: #7eb8da;
    border: 1px solid rgba(126, 184, 218, 0.4);
}

.badge-secondary {
    background: rgba(126, 184, 218, 0.2);
    color: #7eb8da;
    border: 1px solid rgba(126, 184, 218, 0.4);
}

@media (max-width: 480px) {
    .language-tabs {
        margin-bottom: 1rem;
    }

    .tab-btn {
        padding: 0.5rem 1rem;
        font-size: 0.9rem;
    }
}


.dashboard-container {
    max-width: 1600px;
}

.table td {
    font-size: 0.85rem;
    color: rgba(230, 240, 255, 0.95);
}

.table th:nth-child(n+2),
.table td:nth-child(n+2) {
    text-align: center;
}

.table td:nth-child(n+2) .resource-bar {
    justify-content: center;
}

.table td:nth-child(5) .table-actions {
    justify-content: center;
}

/* Dashboard table-specific button styles - subtle pill buttons */
.table .btn-success,
.bulk-actions-bar .btn-success {
    background: var(--success-light);
    color: var(--success-text);
    border: 1px solid var(--success-border);
    border-radius: var(--radius-pill);
    box-shadow: none;
}

.table .btn-success:hover:not(:disabled),
.bulk-actions-bar .btn-success:hover:not(:disabled) {
    background: var(--success-light-hover);
    border-color: var(--success-border-hover);
    transform: none;
    box-shadow: none;
}

.table .btn-danger,
.bulk-actions-bar .btn-danger {
    background: var(--danger-light);
    color: var(--danger-text);
    border: 1px solid var(--danger-border);
    border-radius: var(--radius-pill);
    box-shadow: none;
}

.table .btn-danger:hover:not(:disabled),
.bulk-actions-bar .btn-danger:hover:not(:disabled) {
    background: var(--danger-light-hover);
    border-color: var(--danger-border-hover);
    transform: none;
    box-shadow: none;
}

.table .btn-danger::before,
.bulk-actions-bar .btn-danger::before {
    display: none;
}

.table .btn-warning,
.bulk-actions-bar .btn-warning {
    background: var(--warning-light);
    color: var(--warning-text);
    border: 1px solid var(--warning-border);
    border-radius: var(--radius-pill);
    box-shadow: none;
}

.table .btn-warning:hover:not(:disabled),
.bulk-actions-bar .btn-warning:hover:not(:disabled) {
    background: var(--warning-light-hover);
    border-color: var(--warning-border-hover);
    transform: none;
    box-shadow: none;
}

.table .btn-secondary,
.table .btn-primary,
.bulk-actions-bar .btn-secondary,
.bulk-actions-bar .btn-primary {
    background: var(--primary-light);
    color: var(--primary-color);
    border: 1px solid var(--primary-border);
    border-radius: var(--radius-pill);
    box-shadow: none;
}

.table .btn-secondary:hover:not(:disabled),
.table .btn-primary:hover:not(:disabled),
.bulk-actions-bar .btn-secondary:hover:not(:disabled),
.bulk-actions-bar .btn-primary:hover:not(:disabled) {
    background: var(--primary-light-hover);
    border-color: var(--primary-border-hover);
    box-shadow: none;
    transform: none;
}

.table .btn-primary::before,
.bulk-actions-bar .btn-primary::before {
    display: none;
}

.table .btn-sm {
    font-size: 0.75rem;
    padding: 5px 12px;
}

.table .badge {
    font-size: 0.7rem;
    padding: 3px 8px;
    text-transform: none;
    letter-spacing: normal;
}

.status-badge {
    font-size: 0.65rem;
    padding: 3px 6px;
    text-transform: none;
    letter-spacing: normal;
    line-height: 1;
}

.vm-name {
    font-size: 0.6rem;
    color: var(--text-muted);
}

.resource-bar {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 3px;
}

.resource-info {
    font-size: 0.7rem;
    color: var(--text-muted);
    white-space: nowrap;
}

.progress {
    width: 100%;
    max-width: 120px;
    height: 6px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 3px;
    overflow: hidden;
}

.progress-bar {
    width: 0;
    height: 100%;
    background: linear-gradient(90deg, #7eb8da, #a3d0eb);
    border-radius: 4px;
}

.progress-bar.high {
    background: linear-gradient(90deg, #f0a020, #d89010);
}

.progress-bar.critical {
    background: linear-gradient(90deg, #ef6b6b, #e04545);
}

.progress-bar.approximate {
    background: linear-gradient(90deg, #888, #aaa);
    opacity: 0.7;
}

.modal-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    z-index: 1000;
    justify-content: center;
    align-items: center;
}

.modal-overlay.active {
    display: flex;
}

.modal {
    background: rgba(15, 20, 35, 0.95);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-radius: 16px;
    border: 1px solid var(--glass-border);
    width: 90%;
    max-width: 750px;
    max-height: 80vh;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.5);
    animation: fadeInUp 0.3s ease-out;
}

.modal-header {
    padding: 20px;
    border-bottom: 1px solid var(--glass-border);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.modal-header h3 {
    margin: 0;
    color: var(--heading-color);
}

.modal-close {
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: var(--text-muted);
    transition: color 0.2s ease;
}

.modal-close:hover {
    color: #ff4757;
}

.modal-body {
    padding: 20px;
    overflow-y: auto;
    flex: 1;
}

.modal-footer {
    padding: 15px 20px;
    border-top: 1px solid var(--glass-border);
    display: flex;
    gap: 10px;
    justify-content: flex-end;
}

/* Alert styles */
.alert {
    padding: 12px 16px;
    border-radius: 8px;
    margin-bottom: 15px;
}

.alert-warning {
    background: rgba(240, 160, 32, 0.15);
    border: 1px solid rgba(240, 160, 32, 0.3);
    color: var(--warning-color);
}

.alert-danger {
    background: rgba(239, 107, 107, 0.15);
    border: 1px solid rgba(239, 107, 107, 0.3);
    color: var(--danger-color);
}

/* VM Edit Form styles */
.disk-info {
    padding: 8px 12px;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 6px;
    margin-bottom: 8px;
    font-size: 0.9rem;
    color: var(--text-muted);
}

.form-hint {
    display: block;
    margin-top: 4px;
    font-size: 0.8rem;
    color: var(--text-muted);
}

#editVmForm .form-group {
    margin-bottom: 20px;
}

#editVmForm input:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    background: rgba(255, 255, 255, 0.02);
}

.snapshot-list {
    list-style: none;
    padding: 0;
    margin: 0 0 20px 0;
}

.snapshot-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--glass-border);
    border-radius: 8px;
    margin-bottom: 8px;
    transition: all 0.2s ease;
}

.snapshot-item:hover {
    background: rgba(126, 184, 218, 0.05);
    border-color: rgba(126, 184, 218, 0.2);
}

.snapshot-info {
    flex: 1;
}

.snapshot-name {
    font-weight: 600;
    color: var(--text-color);
}

.snapshot-date {
    font-size: 0.85rem;
    color: var(--text-muted);
}

.snapshot-actions {
    display: flex;
    gap: 8px;
}

.create-snapshot-form {
    border-top: 1px solid var(--glass-border);
    padding-top: 20px;
}

.create-snapshot-form h4 {
    color: var(--heading-color);
    margin-bottom: 15px;
}

.loading {
    opacity: 0.6;
    pointer-events: none;
}

.loading-cell {
    text-align: center;
    padding: 40px 20px;
    color: var(--text-muted);
    font-size: 0.95rem;
}

.loading-cell .spinner {
    margin-right: 10px;
    vertical-align: middle;
}

.loading-cell.error {
    color: #e8a0a0;
}

.loading-cell.error a {
    color: #7eb8da;
    text-decoration: underline;
    cursor: pointer;
}

.loading-cell.error a:hover {
    color: #a3d0eb;
}

.spinner {
    display: inline-block;
    width: 14px;
    height: 14px;
    border: 2px solid currentColor;
    border-right-color: transparent;
    border-radius: 50%;
    animation: spin 0.75s linear infinite;
}

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

.status-badge.status-pending {
    background: rgba(232, 200, 140, 0.15);
    color: #e8c88c;
    border: 1px solid rgba(232, 200, 140, 0.3);
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.status-badge.status-pending .spinner {
    width: 12px;
    height: 12px;
    border-width: 2px;
    flex-shrink: 0;
}

.toast {
    position: fixed;
    bottom: var(--space-5);
    left: var(--space-5);
    padding: 15px var(--space-5);
    border-radius: var(--radius-lg);
    z-index: 1001;
    animation: slideIn var(--transition-base);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
}

.toast.success {
    background: var(--success-light);
    color: var(--success-text);
    border: 1px solid var(--success-border-hover);
    box-shadow: 0 0 20px rgba(142, 205, 168, 0.15);
}

.toast.error {
    background: var(--danger-light);
    color: var(--danger-text);
    border: 1px solid var(--danger-border-hover);
    box-shadow: 0 0 20px rgba(232, 160, 160, 0.15);
}

.toast.warning {
    background: var(--warning-light);
    color: var(--warning-text);
    border: 1px solid var(--warning-border-hover);
    box-shadow: 0 0 20px rgba(232, 200, 140, 0.15);
}

@keyframes slideIn {
    from {
        transform: translateX(-100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

.toast-fade-out {
    animation: fadeOut 0.3s ease forwards;
}

@keyframes fadeOut {
    from {
        opacity: 1;
        transform: translateX(0);
    }
    to {
        opacity: 0;
        transform: translateX(-20px);
    }
}

/* Confirmation Modal */
.modal-confirm {
    max-width: 400px;
}

.modal-confirm .modal-body p {
    color: var(--text-color);
    font-size: 0.95rem;
    line-height: 1.6;
    margin: 0;
}

.modal-confirm .modal-footer {
    gap: 12px;
}

.dropdown {
    position: relative;
    display: inline-block;
}

.dropdown-menu {
    display: none;
    min-width: 140px;
    background: rgba(15, 20, 35, 0.95);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--glass-border);
    border-radius: 8px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4);
    z-index: 9999;
    overflow: hidden;
}

.dropdown-menu.show {
    display: block;
}

.dropdown-menu a {
    display: block;
    padding: 10px 16px;
    color: var(--text-color);
    text-decoration: none;
    font-size: 0.85rem;
    transition: background 0.2s ease;
}

.dropdown-menu a:hover {
    background: rgba(126, 184, 218, 0.15);
    color: #7eb8da;
}

.table-responsive {
    overflow-x: auto;
    overflow-y: visible;
    -webkit-overflow-scrolling: touch;
    position: relative;
}

.table {
    overflow: visible;
}

.table tbody {
    overflow: visible;
}

.table td {
    overflow: visible;
}

.table-actions {
    display: flex;
    gap: 8px;
    flex-wrap: nowrap;
    white-space: nowrap;
}


.custom-checkbox {
    appearance: none;
    -webkit-appearance: none;
    width: 16px;
    height: 16px;
    border: 1px solid rgba(126, 184, 218, 0.4);
    border-radius: 3px;
    background: rgba(126, 184, 218, 0.1);
    cursor: pointer;
    position: relative;
    transition: all 0.2s ease;
    vertical-align: middle;
    margin: 0;
}

.custom-checkbox:hover {
    border-color: rgba(126, 184, 218, 0.6);
    background: rgba(126, 184, 218, 0.15);
}

.custom-checkbox:checked {
    background: rgba(126, 184, 218, 0.25);
    border-color: rgba(126, 184, 218, 0.6);
}

.custom-checkbox:checked::after {
    content: '✓';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: #7eb8da;
    font-size: 10px;
    font-weight: bold;
}

.checkbox-col {
    width: 40px;
    text-align: center !important;
    vertical-align: middle;
}

.checkbox-col input[type="checkbox"] {
    appearance: none;
    -webkit-appearance: none;
    width: 20px;
    height: 20px;
    border: 2px solid rgba(126, 184, 218, 0.4);
    border-radius: 4px;
    background: rgba(126, 184, 218, 0.1);
    cursor: pointer;
    position: relative;
    transition: all 0.2s ease;
    vertical-align: middle;
    margin: 0;
}

.checkbox-col input[type="checkbox"]:hover {
    border-color: rgba(126, 184, 218, 0.7);
    background: rgba(126, 184, 218, 0.2);
}

.checkbox-col input[type="checkbox"]:checked {
    background: rgba(126, 184, 218, 0.35);
    border-color: rgba(126, 184, 218, 0.8);
}

.checkbox-col input[type="checkbox"]:checked::after {
    content: '✓';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: #7eb8da;
    font-size: 12px;
    font-weight: bold;
}

.table th:nth-child(n+3),
.table td:nth-child(n+3) {
    text-align: center;
}

.table td:nth-child(n+3) .resource-bar {
    justify-content: center;
}

.table td:nth-child(8) .table-actions {
    justify-content: center;
}

/* Dashboard Card - scrollable table with fixed header elements */
.dashboard-card {
    display: flex;
    flex-direction: column;
    max-height: calc(100vh - 140px);
}

.dashboard-card .card-header,
.dashboard-card .dashboard-filter,
.dashboard-card .bulk-actions-bar {
    flex-shrink: 0;
}

.dashboard-card .table-responsive {
    flex: 1;
    overflow-y: auto;
    min-height: 200px;
}

.dashboard-card .dashboard-table thead {
    position: sticky;
    top: 0;
    z-index: 10;
}

.dashboard-card .dashboard-table thead th {
    background: #0a0e1b;
    border-bottom: none;
}

/* Dashboard Filter */
.dashboard-filter {
    padding: 0 0 15px;
    margin-bottom: 15px;
    border-bottom: 1px solid var(--glass-border);
}

.filter-wrapper {
    position: relative;
    max-width: 400px;
}

.filter-icon {
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    width: 18px;
    height: 18px;
    color: var(--text-muted);
    pointer-events: none;
}

.filter-input {
    padding-left: 44px;
    padding-right: 36px;
}

.clear-filter-btn {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    font-size: 20px;
    cursor: pointer;
    color: var(--text-muted);
    line-height: 1;
}

.clear-filter-btn:hover {
    color: var(--text-color);
}

.clear-filter-btn.hidden {
    display: none;
}

#noMatchingMachines {
    padding: 40px 20px;
    text-align: center;
    color: var(--text-muted);
}

#noMatchingMachines.hidden {
    display: none;
}

.machine-main-row.filtered-out,
.machine-details-row.filtered-out {
    display: none;
}

.bulk-actions-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 15px;
    background: rgba(126, 184, 218, 0.08);
    border: 1px solid rgba(126, 184, 218, 0.2);
    border-radius: 8px;
    margin-bottom: 15px;
    animation: fadeInUp 0.2s ease-out;
}

.bulk-selection-info {
    color: #7eb8da;
    font-weight: 500;
}

.bulk-buttons {
    display: flex;
    gap: 10px;
    align-items: center;
}

.force-option {
    display: flex;
    align-items: center;
    gap: 6px;
    color: var(--text-muted);
    font-size: 0.85rem;
    cursor: pointer;
    padding: 0 8px;
}

.force-option input[type="checkbox"] {
    appearance: none;
    -webkit-appearance: none;
    width: 16px;
    height: 16px;
    border: 1px solid rgba(126, 184, 218, 0.4);
    border-radius: 3px;
    background: rgba(126, 184, 218, 0.1);
    cursor: pointer;
    position: relative;
    transition: all 0.2s ease;
    vertical-align: middle;
    margin: 0;
}

.force-option input[type="checkbox"]:hover {
    border-color: rgba(126, 184, 218, 0.6);
    background: rgba(126, 184, 218, 0.15);
}

.force-option input[type="checkbox"]:checked {
    background: rgba(126, 184, 218, 0.25);
    border-color: rgba(126, 184, 218, 0.6);
}

.force-option input[type="checkbox"]:checked::after {
    content: '✓';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: #7eb8da;
    font-size: 9px;
    font-weight: bold;
}

.table tbody tr.selected {
    background-color: rgba(126, 184, 218, 0.08);
}

.table tbody tr.selected:hover {
    background-color: rgba(126, 184, 218, 0.12);
}

@media (max-width: 768px) {
    .filter-wrapper {
        max-width: none;
    }

    .bulk-actions-bar {
        flex-direction: column;
        gap: 12px;
    }

    .bulk-buttons {
        flex-wrap: wrap;
        justify-content: center;
    }

    .checkbox-col {
        width: 28px;
    }
}

@media (max-width: 480px) {
    .bulk-buttons .btn {
        padding: 5px 8px;
        font-size: 0.75rem;
    }

    .force-option {
        font-size: 0.75rem;
    }
}

.vm-name-cell {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 6px;
}

.vm-name-line {
    display: flex;
    align-items: center;
    gap: 6px;
    width: 100%;
}

.vm-ips {
    font-size: 0.6rem;
    color: var(--text-muted);
    font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
    white-space: nowrap;
}

.vm-name {
    color: rgba(230, 240, 255, 0.75);
}

.table td:nth-child(2),
.table th:nth-child(2) {
    min-width: 200px;
}

.owned-badge {
    display: inline-flex;
    align-items: center;
    margin-left: auto;
    padding: 4px 8px;
    font-size: 0.7rem;
    font-weight: 600;
    background: rgba(255, 255, 255, 0.1);
    color: rgba(255, 255, 255, 0.8);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 20px;
    white-space: nowrap;
    vertical-align: middle;
    line-height: 1;
}

.network-mounts-cell {
    min-width: 120px;
    max-width: 280px;
}

.network-mounts {
    display: flex;
    flex-direction: column;
    gap: 2px;
    font-size: 0.7rem;
    font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
    text-align: center;
}

.mount-entry {
    color: var(--text-muted);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.no-mounts {
    color: rgba(255, 255, 255, 0.25);
    font-style: normal;
    font-family: inherit;
}

.ip-initializing {
    color: var(--text-muted);
    font-style: italic;
    font-size: 0.9em;
}

.dashboard-table {
    border-collapse: separate;
    border-spacing: 0;
}

.dashboard-table thead th.machine-col {
    display: flex;
    align-items: center;
    gap: 12px;
}

.dashboard-table thead th.machine-col input[type="checkbox"] {
    appearance: none;
    -webkit-appearance: none;
    width: 16px;
    height: 16px;
    border: 1px solid rgba(126, 184, 218, 0.4);
    border-radius: 3px;
    background: rgba(126, 184, 218, 0.1);
    cursor: pointer;
    position: relative;
    transition: all 0.2s ease;
    flex-shrink: 0;
    margin: 0;
}

.dashboard-table thead th.machine-col input[type="checkbox"]:hover {
    border-color: rgba(126, 184, 218, 0.6);
    background: rgba(126, 184, 218, 0.15);
}

.dashboard-table thead th.machine-col input[type="checkbox"]:checked {
    background: rgba(126, 184, 218, 0.25);
    border-color: rgba(126, 184, 218, 0.6);
}

.dashboard-table thead th.machine-col input[type="checkbox"]:indeterminate {
    background: rgba(126, 184, 218, 0.2);
    border-color: rgba(126, 184, 218, 0.5);
}

.dashboard-table thead th.machine-col input[type="checkbox"]:indeterminate::after {
    content: '−';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: #7eb8da;
    font-size: 12px;
    font-weight: bold;
    line-height: 1;
}

.dashboard-table thead th.machine-col input[type="checkbox"]:checked::after {
    content: '✓';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: #7eb8da;
    font-size: 10px;
    font-weight: bold;
}

.machine-main-row td,
.machine-details-row td {
    background: transparent;
    padding: 12px 16px;
    vertical-align: middle;
    transition: background 0.15s ease;
}

.machine-main-row td {
    border-bottom: none;
    padding-bottom: 6px;
    padding-top: 12px;
}

.machine-details-row td {
    padding-top: 6px;
    border-bottom: 1px solid rgba(224, 229, 232, 0.2);
    padding-bottom: 12px;
}


.machine-cell {
    width: 100%;
}

.machine-name-row {
    display: flex;
    align-items: center;
    gap: 12px;
}

.machine-name-row input[type="checkbox"] {
    appearance: none;
    -webkit-appearance: none;
    width: 16px;
    height: 16px;
    border: 1px solid rgba(126, 184, 218, 0.4);
    border-radius: 3px;
    background: rgba(126, 184, 218, 0.1);
    cursor: pointer;
    position: relative;
    transition: all 0.2s ease;
    flex-shrink: 0;
    margin: 0;
}

.machine-name-row input[type="checkbox"]:hover {
    border-color: rgba(126, 184, 218, 0.6);
    background: rgba(126, 184, 218, 0.15);
}

.machine-name-row input[type="checkbox"]:checked {
    background: rgba(126, 184, 218, 0.25);
    border-color: rgba(126, 184, 218, 0.6);
}

.machine-name-row input[type="checkbox"]:checked::after {
    content: '✓';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: #7eb8da;
    font-size: 10px;
    font-weight: bold;
}

.machine-name-row .vm-name {
    font-size: 0.9rem;
    text-transform: uppercase;
    font-weight: 500;
    color: rgba(186, 188, 192, 0.9);
}

.machine-name-row .owned-badge {
    margin-left: 8px;
}

.status-cell {
    text-align: center;
    width: 80px;
    white-space: nowrap;
}

.actions-cell {
    text-align: center;
    width: 1%;
    white-space: nowrap;
}

.actions-cell .table-actions {
    justify-content: center;
    gap: 6px;
}

.actions-cell .table-actions .btn-sm {
    padding: 6px 10px;
    font-size: 0.75rem;
}

.resource-item.ip-list {
    min-width: 100px;
}

.ip-value {
    font-size: 0.7rem;
    color: var(--text-muted);
    font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
    white-space: nowrap;
}

.resources-cell {
    padding: 6px 16px 12px !important;
}

.resources-separator {
    border-top: 1px dashed rgba(126, 184, 218, 0.08);
    margin-bottom: 10px;
}

.resources-grid {
    display: grid;
    grid-template-columns: auto auto auto 7fr 4fr;
    gap: 47px;
    align-items: start;
}

.resource-item {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 2px;
    min-width: 90px;
}

.resource-label {
    font-size: 0.65rem;
    color: rgba(255, 255, 255, 0.5);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-weight: 500;
}

.resource-item .resource-bar {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 2px;
    width: 100%;
}

.resource-item .resource-info {
    font-size: 0.7rem;
    white-space: nowrap;
    color: var(--text-muted);
}

.resource-item .progress {
    width: 130px;
    max-width: 130px;
}

.resource-item.network-mounts-cell {
    min-width: 100px;
}

.resource-item .network-mounts {
    font-size: 0.7rem;
    text-align: left;
    color: var(--text-muted);
    font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
    white-space: nowrap;
}

.dashboard-table th:nth-child(2) {
    text-align: center;
    width: 100px;
}

.dashboard-table th:nth-child(3) {
    text-align: center;
}

@media (max-width: 768px) {
    .resources-grid {
        grid-template-columns: auto auto auto 7fr 4fr;
        gap: 23px;
    }

    .resource-item {
        min-width: 80px;
    }

    .resource-item .progress {
        width: 60px;
    }

    .resource-item .resource-info {
        font-size: 0.65rem;
    }
}

@media (max-width: 480px) {
    .resources-grid {
        grid-template-columns: 1fr;
        gap: 2px;
    }

    .resource-item {
        flex-direction: row;
        align-items: center;
        gap: 8px;
        width: 100%;
    }

    .resource-label {
        width: 70px;
        flex-shrink: 0;
    }

    .resource-item .resource-bar {
        flex: 1;
    }
}

/* ==========================================================================
   GUIDE PAGE STYLES
   ========================================================================== */

/* Guide Container */
.guide-container {
    max-width: 1400px;
}

/* Guide Controls Bar */
.guide-controls {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
    padding: 15px 20px;
    margin-bottom: 20px;
}

.guide-search-wrapper {
    position: relative;
    flex: 1;
    max-width: 400px;
}

.search-icon {
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    width: 18px;
    height: 18px;
    color: var(--text-muted);
    pointer-events: none;
}

.guide-search-input {
    padding-left: 44px;
    padding-right: 40px;
}

.clear-search-btn {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    padding: 4px;
    cursor: pointer;
    color: var(--text-muted);
    transition: color 0.2s ease;
}

.clear-search-btn:hover {
    color: var(--text-color);
}

.clear-search-btn svg {
    width: 16px;
    height: 16px;
}

.guide-actions {
    display: flex;
    gap: 10px;
}

/* Guide Layout (Sidebar + Main) */
.guide-layout {
    display: grid;
    grid-template-columns: 280px 1fr;
    gap: 25px;
    align-items: start;
}

/* Table of Contents Sidebar */
.guide-toc {
    position: sticky;
    top: 100px;
    max-height: calc(100vh - 140px);
    overflow-y: auto;
    padding: 0;
}

.toc-header {
    padding: 15px 20px;
    border-bottom: 1px solid var(--glass-border);
}

.toc-header h3 {
    margin: 0;
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--link-color);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.toc-nav {
    padding: 10px 0;
}

.toc-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.toc-item {
    margin: 0;
}

.toc-link {
    display: block;
    padding: 10px 20px;
    color: var(--text-color);
    text-decoration: none;
    font-size: 0.9rem;
    border-left: 3px solid transparent;
    transition: all 0.2s ease;
}

.toc-link:hover {
    color: var(--link-color);
    background: rgba(126, 184, 218, 0.05);
    border-left-color: rgba(126, 184, 218, 0.3);
}

.toc-link.active {
    color: var(--primary-color);
    background: rgba(126, 184, 218, 0.1);
    border-left-color: var(--primary-color);
    font-weight: 500;
}

.toc-link.hidden {
    display: none;
}

/* Guide Main Content Area */
.guide-main {
    min-width: 0;
}

/* Guide Cards (Accordion Items) */
.guides-accordion {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.guide-card {
    background: var(--glass-bg);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    border-radius: 12px;
    border: 1px solid var(--glass-border);
    box-shadow: var(--shadow-card);
    overflow: hidden;
    transition: all 0.3s ease;
    animation: fadeInUp 0.5s ease-out;
    animation-fill-mode: both;
}

.guide-card:nth-child(1) { animation-delay: 0s; }
.guide-card:nth-child(2) { animation-delay: 0.05s; }
.guide-card:nth-child(3) { animation-delay: 0.1s; }
.guide-card:nth-child(4) { animation-delay: 0.15s; }
.guide-card:nth-child(5) { animation-delay: 0.2s; }
.guide-card:nth-child(n+6) { animation-delay: 0.25s; }

.guide-card:hover {
    border-color: rgba(126, 184, 218, 0.2);
}

.guide-card.hidden {
    display: none;
}

.guide-card.search-highlight {
    border-color: rgba(126, 184, 218, 0.5);
    box-shadow: 0 0 20px rgba(126, 184, 218, 0.15);
}

/* Accordion Header */
.guide-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 18px 20px;
    cursor: pointer;
    user-select: none;
    transition: background 0.2s ease;
}

.guide-card-header:hover {
    background: rgba(126, 184, 218, 0.05);
}

.guide-card-header:focus {
    outline: none;
    background: rgba(126, 184, 218, 0.08);
}

.guide-card-header:focus-visible {
    outline: 2px solid var(--primary-color);
    outline-offset: -2px;
}

.guide-header-content {
    display: flex;
    align-items: center;
    gap: 15px;
    min-width: 0;
    flex: 1;
}

.guide-icon {
    flex-shrink: 0;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(126, 184, 218, 0.1);
    border-radius: 8px;
    color: var(--primary-color);
    transition: all 0.3s ease;
}

.guide-icon svg {
    width: 20px;
    height: 20px;
}

.guide-card--expanded .guide-icon,
.guide-card-header:hover .guide-icon {
    background: rgba(126, 184, 218, 0.2);
}

.guide-card .guide-title {
    margin: 0;
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--heading-color);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.guide-chevron {
    flex-shrink: 0;
    width: 24px;
    height: 24px;
    color: var(--text-muted);
    transition: transform 0.3s ease, color 0.2s ease;
}

.guide-chevron svg {
    width: 100%;
    height: 100%;
}

.guide-card--expanded .guide-chevron {
    transform: rotate(180deg);
    color: var(--primary-color);
}

/* Accordion Body */
.guide-card-body {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.guide-card-body--expanded {
    max-height: 5000px;
}

.guide-content {
    padding: 0 20px 20px 20px;
    border-top: 1px solid var(--glass-border);
    margin-top: 0;
    padding-top: 20px;
    color: rgba(230, 240, 255, 0.75);
    line-height: 1.7;
}

.guide-content h1,
.guide-content h2,
.guide-content h3,
.guide-content h4,
.guide-content h5,
.guide-content h6 {
    color: rgba(230, 240, 255, 0.85);
}

/* Empty State Icons */
.empty-icon {
    margin-bottom: 20px;
}

.empty-icon svg {
    width: 64px;
    height: 64px;
    color: var(--text-muted);
}

/* Mobile TOC Toggle */
.mobile-toc-toggle {
    display: none;
    position: fixed;
    bottom: 20px;
    right: 20px;
    width: 50px;
    height: 50px;
    background: var(--gradient-primary);
    border: none;
    border-radius: 50%;
    color: #1a1a2e;
    cursor: pointer;
    box-shadow: var(--shadow-button);
    z-index: 100;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    align-items: center;
    justify-content: center;
}

.mobile-toc-toggle:hover {
    transform: scale(1.05);
    box-shadow: var(--shadow-glow);
}

.mobile-toc-toggle svg {
    width: 24px;
    height: 24px;
}

/* ==========================================================================
   GUIDE PAGE RESPONSIVE STYLES
   ========================================================================== */

@media (max-width: 1024px) {
    .guide-layout {
        grid-template-columns: 240px 1fr;
        gap: 20px;
    }

    .guide-toc {
        top: 90px;
    }
}

@media (max-width: 768px) {
    .guide-container {
        position: static;
    }

    .guide-controls {
        flex-direction: column;
        align-items: stretch;
        gap: 15px;
        padding: 15px;
    }

    .guide-search-wrapper {
        max-width: none;
    }

    .guide-actions {
        justify-content: center;
    }

    .guide-layout {
        grid-template-columns: 1fr;
    }

    /* Mobile TOC - Off-canvas */
    .guide-toc {
        position: fixed;
        top: 0;
        left: -300px;
        width: 280px;
        height: 100vh;
        max-height: 100vh;
        z-index: 1101;
        border-radius: 0;
        transition: left 0.3s ease;
        box-shadow: 4px 0 20px rgba(0, 0, 0, 0.5);
    }

    .guide-toc.mobile-open {
        left: 0;
    }

    .toc-header {
        padding: 20px;
    }

    .mobile-toc-toggle {
        display: flex;
    }

    /* Mobile TOC Overlay */
    .toc-overlay {
        display: none;
        position: fixed;
        inset: 0;
        background: rgba(0, 0, 0, 0.6);
        z-index: 1100;
    }

    .toc-overlay.active {
        display: block;
    }

    .guide-card-header {
        padding: 15px;
    }

    .guide-header-content {
        gap: 12px;
    }

    .guide-icon {
        width: 32px;
        height: 32px;
    }

    .guide-icon svg {
        width: 18px;
        height: 18px;
    }

    .guide-card .guide-title {
        font-size: 1rem;
    }

    .guide-content {
        padding: 0 15px 15px 15px;
        padding-top: 15px;
    }
}

@media (max-width: 480px) {
    .guide-container {
        padding: 10px;
    }

    .guide-controls {
        padding: 12px;
    }

    .guide-actions .btn {
        padding: 8px 12px;
        font-size: 0.8rem;
    }

    .guide-card-header {
        padding: 12px;
    }

    .guide-header-content {
        gap: 10px;
    }

    .guide-icon {
        width: 28px;
        height: 28px;
    }

    .guide-icon svg {
        width: 16px;
        height: 16px;
    }

    .guide-card .guide-title {
        font-size: 0.95rem;
    }

    .guide-chevron {
        width: 20px;
        height: 20px;
    }

    .guide-content {
        padding: 12px;
        padding-top: 12px;
    }

    .mobile-toc-toggle {
        width: 44px;
        height: 44px;
        bottom: 15px;
        right: 15px;
    }

    .mobile-toc-toggle svg {
        width: 20px;
        height: 20px;
    }
}

/* Scrollbar Styling for TOC */
.guide-toc::-webkit-scrollbar {
    width: 6px;
}

.guide-toc::-webkit-scrollbar-track {
    background: transparent;
}

.guide-toc::-webkit-scrollbar-thumb {
    background: rgba(126, 184, 218, 0.3);
    border-radius: 3px;
}

.guide-toc::-webkit-scrollbar-thumb:hover {
    background: rgba(126, 184, 218, 0.5);
}

.login-card .btn-primary {
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.9), rgba(255, 255, 255, 0.7));
    color: #0a0e1b;
    border: 1px solid rgba(255, 255, 255, 0.3);
    box-shadow: 0 4px 15px rgba(255, 255, 255, 0.2);
    border-radius: 8px;
}

.login-card .btn-primary:hover,
.login-card .btn-primary:hover:not(:disabled) {
    background: linear-gradient(135deg, #ffffff, rgba(255, 255, 255, 0.85));
    box-shadow: 0 8px 20px rgba(255, 255, 255, 0.3);
    transform: none;
}

/* ==========================================================================
   CHAT WIDGET STYLES
   ========================================================================== */

.chat-widget {
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 1000;
}

.chat-toggle {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: var(--gradient-primary);
    border: none;
    cursor: pointer;
    box-shadow: var(--shadow-button);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    position: relative;
}

.chat-toggle:hover {
    transform: scale(1.05);
    box-shadow: var(--shadow-glow);
}

.chat-icon {
    width: 24px;
    height: 24px;
    color: #1a1a2e;
}

.chat-badge {
    position: absolute;
    top: -5px;
    right: -5px;
    min-width: 20px;
    height: 20px;
    background: var(--danger-color);
    color: white;
    border-radius: 10px;
    font-size: 0.75rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 5px;
}

.chat-panel {
    position: absolute;
    bottom: 70px;
    right: 0;
    width: 360px;
    height: 500px;
    background: rgba(15, 20, 35, 0.95);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-radius: 16px;
    border: 1px solid var(--glass-border);
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.5);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    animation: chatSlideUp 0.3s ease-out;
}

@keyframes chatSlideUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.chat-header {
    padding: 15px 20px;
    background: rgba(126, 184, 218, 0.1);
    border-bottom: 1px solid var(--glass-border);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.chat-header h4 {
    margin: 0;
    color: var(--heading-color);
    font-size: 1rem;
}

.chat-close {
    background: none;
    border: none;
    color: var(--text-muted);
    font-size: 1.5rem;
    cursor: pointer;
    padding: 0;
    line-height: 1;
}

.chat-close:hover {
    color: var(--text-color);
}

.chat-messages {
    flex: 1;
    overflow-y: auto;
    padding: 15px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.chat-message {
    max-width: 80%;
    padding: 10px 14px;
    border-radius: 12px;
    font-size: 0.9rem;
    line-height: 1.4;
    word-wrap: break-word;
}

.chat-message.user {
    align-self: flex-end;
    background: rgba(126, 184, 218, 0.2);
    color: var(--text-color);
    border-bottom-right-radius: 4px;
}

.chat-message.admin {
    align-self: flex-start;
    background: rgba(255, 255, 255, 0.08);
    color: var(--text-color);
    border-bottom-left-radius: 4px;
}

.chat-message-time {
    font-size: 0.7rem;
    color: var(--text-muted);
    margin-top: 4px;
}

.chat-input-form {
    display: flex;
    gap: 10px;
    padding: 15px;
    border-top: 1px solid var(--glass-border);
}

.chat-input {
    flex: 1;
    padding: 10px 14px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--glass-border);
    border-radius: 20px;
    color: var(--text-color);
    font-size: 0.9rem;
}

.chat-input:focus {
    outline: none;
    border-color: rgba(126, 184, 218, 0.5);
}

.chat-input::placeholder {
    color: var(--text-muted);
}

.chat-send-btn {
    padding: 10px 20px;
    background: var(--gradient-primary);
    border: none;
    border-radius: 20px;
    color: #1a1a2e;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.chat-send-btn:hover {
    box-shadow: var(--shadow-button);
}

.chat-send-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* Chat widget mobile responsive */
@media (max-width: 480px) {
    .chat-widget {
        bottom: 15px;
        right: 15px;
    }

    .chat-panel {
        position: fixed;
        bottom: 0;
        right: 0;
        left: 0;
        width: 100%;
        height: 70vh;
        border-radius: 16px 16px 0 0;
    }

    .chat-toggle {
        width: 50px;
        height: 50px;
    }

    .chat-icon {
        width: 20px;
        height: 20px;
    }
}

/* ==========================================================================
   RESTORE MODAL STYLES
   ========================================================================== */

/* Header actions container */
.header-actions {
    display: flex;
    gap: 10px;
    align-items: center;
}

/* Large modal variant */
.modal-lg {
    max-width: 650px;
}

/* Restore wizard steps indicator */
.restore-steps {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
    padding: 0 10px;
}

.step {
    display: flex;
    flex-direction: column;
    align-items: center;
    position: relative;
    flex: 1;
}

.step-number {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    border: 2px solid var(--glass-border);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 0.9rem;
    color: var(--text-muted);
    transition: all 0.3s ease;
    z-index: 1;
}

.step-label {
    margin-top: 8px;
    font-size: 0.75rem;
    color: var(--text-muted);
    text-align: center;
    transition: color 0.3s ease;
}

.step-connector {
    position: absolute;
    top: 18px;
    left: calc(50% + 22px);
    width: calc(100% - 44px);
    height: 2px;
    background: var(--glass-border);
    z-index: 0;
}

.step:last-child .step-connector {
    display: none;
}

.step.active .step-number {
    background: var(--gradient-primary);
    border-color: transparent;
    color: #1a1a2e;
    box-shadow: 0 0 15px rgba(126, 184, 218, 0.4);
}

.step.active .step-label {
    color: var(--primary-color);
}

.step.completed .step-number {
    background: var(--success-color);
    border-color: transparent;
    color: white;
}

.step.completed .step-connector {
    background: var(--success-color);
}

.step.completed .step-label {
    color: var(--success-color);
}

/* Restore step content */
.restore-step-content {
    display: none;
    animation: fadeInUp 0.3s ease-out;
}

.restore-step-content.active {
    display: block;
}

/* Backup list */
.backup-list {
    max-height: 280px;
    overflow-y: auto;
    margin: -5px;
    padding: 5px;
}

.backup-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 14px 16px;
    background: rgba(255, 255, 255, 0.02);
    border: 2px solid var(--glass-border);
    border-radius: 10px;
    margin-bottom: 10px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.backup-item:hover {
    background: rgba(126, 184, 218, 0.05);
    border-color: rgba(126, 184, 218, 0.2);
}

.backup-item.selected {
    background: rgba(126, 184, 218, 0.1);
    border-color: var(--primary-color);
    box-shadow: 0 0 0 1px rgba(126, 184, 218, 0.2);
}

.backup-info {
    flex: 1;
    min-width: 0;
}

.backup-name {
    font-weight: 600;
    color: var(--text-color);
    margin-bottom: 4px;
    word-break: break-all;
}

.backup-meta {
    font-size: 0.8rem;
    color: var(--text-muted);
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
}

.backup-meta span {
    display: inline-flex;
    align-items: center;
    gap: 4px;
}

.backup-select {
    position: relative;
    width: 20px;
    height: 20px;
    border: 2px solid var(--glass-border);
    border-radius: 50%;
    background: transparent;
    transition: all 0.2s ease;
    flex-shrink: 0;
    margin-left: 15px;
}

.backup-select input[type="radio"] {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.backup-item.selected .backup-select {
    background: var(--primary-color);
    border-color: var(--primary-color);
    box-shadow: inset 0 0 0 3px rgba(15, 20, 35, 0.95);
}

/* Restore summary */
.restore-summary {
    padding: 20px;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--glass-border);
    border-radius: 10px;
}

.restore-summary h4 {
    margin: 0 0 15px 0;
    color: var(--heading-color);
    font-size: 1rem;
}

.summary-list {
    margin: 0;
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 10px 15px;
    align-items: baseline;
}

.summary-list dt {
    color: var(--text-muted);
    font-size: 0.85rem;
}

.summary-list dd {
    margin: 0;
    color: var(--text-color);
    font-weight: 500;
    word-break: break-all;
}

/* Restore progress */
.restore-progress {
    text-align: center;
    padding: 30px 20px;
}

.progress-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
}

.progress-header span {
    font-size: 0.9rem;
    color: var(--text-muted);
}

.progress-header strong {
    color: var(--primary-color);
    font-size: 1.1rem;
}

.progress-lg {
    max-width: none;
    height: 12px;
    border-radius: 6px;
}

.progress-lg .progress-bar {
    border-radius: 6px;
}

.progress-status {
    margin-top: 15px;
    font-size: 0.85rem;
    color: var(--text-muted);
}

/* Restore complete/failed states */
.restore-complete,
.restore-failed {
    text-align: center;
    padding: 30px 20px;
}

.success-icon,
.error-icon {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
    font-size: 1.8rem;
}

.success-icon {
    background: rgba(78, 202, 122, 0.15);
    color: var(--success-color);
    border: 2px solid rgba(78, 202, 122, 0.3);
}

.error-icon {
    background: rgba(239, 107, 107, 0.15);
    color: var(--danger-color);
    border: 2px solid rgba(239, 107, 107, 0.3);
}

.restore-complete h4,
.restore-failed h4 {
    margin: 0 0 10px 0;
    font-size: 1.1rem;
}

.restore-complete h4 {
    color: var(--success-color);
}

.restore-failed h4 {
    color: var(--danger-color);
}

.restore-complete p,
.restore-failed p {
    margin: 0;
    color: var(--text-muted);
    font-size: 0.9rem;
}

.restore-failed p {
    background: rgba(239, 107, 107, 0.1);
    padding: 12px;
    border-radius: 6px;
    border: 1px solid rgba(239, 107, 107, 0.2);
}

/* Restore tasks floating indicator */
.restore-tasks-indicator {
    position: fixed;
    bottom: 90px;
    right: 20px;
    background: rgba(15, 20, 35, 0.95);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--glass-border);
    border-radius: 12px;
    padding: 12px 16px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4);
    z-index: 999;
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.restore-tasks-indicator:hover {
    border-color: rgba(126, 184, 218, 0.3);
    transform: translateY(-2px);
}

.restore-tasks-indicator .spinner {
    width: 16px;
    height: 16px;
    border-width: 2px;
}

.restore-tasks-indicator span {
    font-size: 0.85rem;
    color: var(--text-color);
}

/* Scrollbar styling for backup list */
.backup-list::-webkit-scrollbar {
    width: 6px;
}

.backup-list::-webkit-scrollbar-track {
    background: transparent;
}

.backup-list::-webkit-scrollbar-thumb {
    background: rgba(126, 184, 218, 0.3);
    border-radius: 3px;
}

.backup-list::-webkit-scrollbar-thumb:hover {
    background: rgba(126, 184, 218, 0.5);
}

/* Backup filter */
.backup-filter-wrapper {
    margin-bottom: 15px;
}

/* Restoring row in table */
.restoring-row {
    background: linear-gradient(90deg, rgba(126, 184, 218, 0.1) 0%, transparent 100%);
    animation: restoring-pulse 2s ease-in-out infinite;
}

@keyframes restoring-pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.7; }
}

.restoring-name {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--primary-color);
}

.restore-row-progress {
    display: flex;
    align-items: center;
    width: 100%;
    max-width: 250px;
}

.restore-row-progress .progress {
    flex: 1;
    height: 6px;
    background: var(--border-color);
    border-radius: 3px;
}

.restore-row-progress .progress-bar {
    background: var(--primary-color);
    transition: width 0.3s ease;
}

.restore-row-percent {
    margin-left: 8px;
    font-size: 0.85rem;
    color: var(--primary-color);
    min-width: 35px;
}

/* Restore modal responsive */
@media (max-width: 768px) {
    .restore-steps {
        padding: 0;
    }

    .step-number {
        width: 30px;
        height: 30px;
        font-size: 0.8rem;
    }

    .step-label {
        font-size: 0.65rem;
    }

    .step-connector {
        top: 15px;
        left: calc(50% + 18px);
        width: calc(100% - 36px);
    }

    .backup-item {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }

    .backup-select {
        margin-left: 0;
        align-self: flex-end;
    }

    .summary-list {
        grid-template-columns: 1fr;
        gap: 5px;
    }

    .summary-list dt {
        margin-top: 10px;
    }

    .summary-list dt:first-child {
        margin-top: 0;
    }
}

@media (max-width: 480px) {
    .header-actions {
        flex-direction: column;
        gap: 8px;
    }

    .header-actions .btn {
        width: 100%;
    }

    .modal-lg {
        max-width: none;
        width: 95%;
    }

    .restore-steps {
        gap: 5px;
    }

    .step-label {
        display: none;
    }

    .restore-tasks-indicator {
        bottom: 80px;
        right: 15px;
        left: 15px;
    }
}


/* === Backup Modal Styles === */

/* Backup VM list */
.backup-vms-info {
    margin-bottom: 20px;
    padding: 15px;
    background: var(--glass-bg);
    border-radius: 8px;
    border: 1px solid var(--border-color);
}

.backup-vm-list {
    list-style: none;
    padding: 0;
    margin: 10px 0 0 0;
    max-height: 150px;
    overflow-y: auto;
}

.backup-vm-list li {
    padding: 6px 10px;
    background: rgba(126, 184, 218, 0.08);
    border-radius: 4px;
    margin-bottom: 5px;
    font-size: 0.875rem;
}

.backup-vm-list li:last-child {
    margin-bottom: 0;
}

/* Radio group for mode selection */
.radio-group {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.radio-option {
    display: flex;
    flex-direction: column;
    padding: 15px;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s ease;
    background: var(--glass-bg);
}

.radio-option:hover {
    border-color: var(--primary-color);
    background: rgba(126, 184, 218, 0.05);
}

.radio-option input[type="radio"] {
    margin-right: 10px;
}

.radio-option input[type="radio"]:checked + span {
    color: var(--primary-color);
    font-weight: 500;
}

.radio-option small {
    margin-top: 5px;
    margin-left: 24px;
    color: var(--text-muted);
    font-size: 0.8rem;
}

/* Backup progress list */
.backup-progress-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
    max-height: 400px;
    overflow-y: auto;
}

.backup-progress-item {
    background: var(--glass-bg);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 15px;
    transition: all 0.3s ease;
}

.backup-progress-item.completed {
    border-color: var(--success-color);
    background: var(--success-light);
}

.backup-progress-item.failed {
    border-color: var(--danger-color);
    background: var(--danger-light);
}

.backup-progress-info {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

.backup-progress-name {
    font-weight: 500;
}

.backup-progress-status {
    color: var(--text-muted);
    font-size: 0.875rem;
}

.backup-progress-bar-wrapper {
    display: flex;
    align-items: center;
    gap: 10px;
}

.backup-progress-bar-wrapper .progress {
    flex: 1;
    height: 8px;
    background: var(--border-color);
    border-radius: 4px;
    overflow: hidden;
}

.backup-progress-bar-wrapper .progress-bar {
    height: 100%;
    background: var(--primary-color);
    transition: width 0.3s ease;
}

.backup-progress-item.completed .progress-bar {
    background: var(--success-color);
}

.backup-progress-item.failed .progress-bar {
    background: var(--danger-color);
}

.backup-progress-percent {
    min-width: 45px;
    text-align: right;
    font-size: 0.875rem;
    color: var(--text-muted);
}

/* Backing up row in dashboard table */
.backing-up-row {
    background: rgba(126, 184, 218, 0.05);
}

.backing-up-name {
    display: flex;
    align-items: center;
    gap: 10px;
}

.backup-row-progress {
    display: flex;
    align-items: center;
    width: 100%;
    max-width: 250px;
}

.backup-row-progress .progress {
    flex: 1;
    height: 6px;
    background: var(--border-color);
    border-radius: 3px;
}

.backup-row-progress .progress-bar {
    background: var(--primary-color);
    transition: width 0.3s ease;
}

.backup-row-percent {
    margin-left: 8px;
    font-size: 0.85rem;
    color: var(--primary-color);
    min-width: 35px;
}

/* Backup tasks indicator */
.backup-tasks-indicator {
    position: fixed;
    bottom: 20px;
    right: 20px;
    background: var(--glass-bg);
    backdrop-filter: var(--glass-blur);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 12px 16px;
    display: flex;
    align-items: center;
    gap: 10px;
    box-shadow: var(--shadow-card);
    z-index: 1000;
    cursor: pointer;
    transition: all 0.3s ease;
}

.backup-tasks-indicator:hover {
    border-color: var(--primary-color);
    transform: translateY(-2px);
}

.backup-tasks-indicator .spinner {
    width: 16px;
    height: 16px;
    border: 2px solid var(--border-color);
    border-top-color: var(--primary-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@media (max-width: 480px) {
    .backup-tasks-indicator {
        bottom: 80px;
        right: 15px;
        left: 15px;
    }
}
