﻿
:root{
    --app-bg: #f6f8fb;
    --surface: #ffffff;
    --surface-2: #f1f4f8;
    --text: #0f172a;
    --muted: #64748b;
    --border: rgba(15, 23, 42, 0.10);
    --radius: 12px;
    --shadow-sm: 0 1px 2px rgba(15, 23, 42, .06);
    --shadow-md: 0 10px 30px rgba(15, 23, 42, .10);
    --focus: 0 0 0 .25rem rgba(13,110,253,.18);
}

html, body { height: 100%; }
body{
    background: radial-gradient(1200px 600px at 10% 0%, #eaf2ff 0%, transparent 60%),
    radial-gradient(900px 500px at 90% 10%, #edf7ff 0%, transparent 55%),
    var(--app-bg);
    color: var(--text);
}

/* layout */
.page-header{
    display:flex;
    gap: 1rem;
    align-items: start;
    justify-content: space-between;
    margin: 1.25rem 0 1rem;
}
.page-title{
    margin: 0;
    font-weight: 700;
    letter-spacing: -.02em;
}
.page-subtitle{
    margin: .25rem 0 0;
    color: var(--muted);
    font-size: .95rem;
}

/* cards */
.card.app-card{
    border: 1px solid var(--border);
    border-radius: var(--radius);
    box-shadow: var(--shadow-sm);
}
.card.app-card .card-header{
    background: linear-gradient(180deg, var(--surface) 0%, var(--surface-2) 160%);
    border-bottom: 1px solid var(--border);
}
.surface{
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    box-shadow: var(--shadow-sm);
}

/* forms */
.form-control, .form-select{
    border-color: rgba(15, 23, 42, .14);
    border-radius: 12px;
}
.form-control:focus, .form-select:focus{
    box-shadow: var(--focus);
}
.input-group-text{
    border-radius: 12px;
    border-color: rgba(15, 23, 42, .14);
    background: #f8fafc;
}

/* buttons */
.btn{
    border-radius: 12px;
}
.btn-primary{
    box-shadow: 0 10px 20px rgba(13,110,253,.18);
}

/* tables */
.table {
    border-collapse: separate;
    border-spacing: 0;
    overflow: hidden;
    border-radius: var(--radius);
    border: 1px solid var(--border);
}
.table thead th{
    background: #f8fafc;
    border-bottom: 1px solid var(--border);
    color: #0b1220;
    font-weight: 600;
}
.table tbody td,
.table tbody th{
    border-top: 1px solid rgba(15, 23, 42, .06);
}

.table tbody tr:hover{
    background: rgba(13,110,253,.035);
}

.sticky-actions{
    position: sticky;
    top: .75rem;
    z-index: 1020;
    background: rgba(255,255,255,.78);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: .75rem;
}

.sticky-actions.is-stuck{
    box-shadow: var(--shadow-md);
}

.surface-hover{
    transition: transform .15s ease, box-shadow .15s ease;
}
.surface-hover:hover{
    transform: translateY(-1px);
    box-shadow: var(--shadow-md);
}

.hr-soft{
    border: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(15,23,42,.12), transparent);
    margin: 1rem 0;
}

.input-group .password-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    min-width: 44px;
    border: 1px solid var(--bs-border-color, #dee2e6);
    border-left: 0;
    background: var(--bs-body-bg, #fff);
    color: var(--bs-secondary-color, #6c757d);
    cursor: pointer;
    user-select: none;
    border-top-right-radius: var(--radius) !important;
    border-bottom-right-radius: var(--radius) !important;
    padding: 0;
}

.input-group .password-toggle i {
    font-size: 1.05rem;
    line-height: 1;
}

.input-group .password-toggle:hover {
    background: var(--bs-tertiary-bg, #f8f9fa);
    color: var(--bs-body-color, #212529);
}

.input-group .password-toggle:focus-visible {
    outline: 0;
    box-shadow: 0 0 0 0.25rem rgba(13, 110, 253, 0.15);
}

.input-group:has(.password-toggle:focus-visible) .form-control {
    border-color: rgba(13, 110, 253, 0.45);
}