/* ProBuhalterija personalo dokumentų sistema — ProBankConvert dizaino tokens */

:root {
    --primary: #1b4a5a;
    --primary-light: #e8f0f3;
    --primary-dark: #143d4a;
    --gold: #c4a96a;
    --gold-light: #f5f0e4;
    --navy: #1b4a5a;
    --navy-light: #2a6070;
    --text: #32373c;
    --text-light: #69727d;
    --text-muted: #abb8c3;
    --bg: #ffffff;
    --bg-light: #f7f8f9;
    --green: #39b54a;
    --red: #d64545;
    --shadow: 0 2px 20px rgba(27, 74, 90, 0.06);
    --shadow-lg: 0 8px 40px rgba(27, 74, 90, 0.12);
    --radius: 12px;
    --radius-lg: 20px;
    --radius-pill: 30px;
}

* { box-sizing: border-box; }

body {
    margin: 0;
    font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    color: var(--text);
    background: var(--bg-light);
    line-height: 1.5;
}

a { color: var(--primary); text-decoration: none; }
a:hover { color: var(--primary-dark); }

/* Navigation */
.nav {
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid rgba(27, 74, 90, 0.1);
    padding: 16px 32px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    position: sticky;
    top: 0;
    z-index: 100;
}

.nav-brand {
    display: flex;
    align-items: center;
    gap: 14px;
    font-weight: 600;
    color: var(--primary);
    font-size: 16px;
    text-decoration: none;
}

.nav-brand:hover { color: var(--primary); }

.nav-logo {
    height: 36px;
    width: auto;
    display: block;
}

.nav-brand-divider {
    color: var(--text-muted);
    font-size: 18px;
    line-height: 1;
}

.nav-brand-section {
    color: var(--text-light);
    font-weight: 500;
    letter-spacing: 0.01em;
}

.nav-user {
    display: flex;
    align-items: center;
    gap: 12px;
    color: var(--text-light);
    font-size: 14px;
}

.nav-user a { color: var(--primary); font-weight: 500; }

/* Container */
.container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 32px;
}

.container-narrow {
    max-width: 540px;
    margin: 0 auto;
    padding: 32px;
}

/* Headings */
h1 { font-size: 28px; font-weight: 700; color: var(--primary); margin: 0 0 8px; }
h2 { font-size: 20px; font-weight: 600; color: var(--primary); margin: 32px 0 12px; }
h3 { font-size: 16px; font-weight: 600; color: var(--text); margin: 0 0 8px; }
.subtitle { color: var(--text-light); margin: 0 0 24px; }

/* Cards */
.card {
    background: white;
    border-radius: var(--radius-lg);
    padding: 24px;
    box-shadow: var(--shadow);
    margin-bottom: 16px;
    transition: box-shadow 0.2s, transform 0.2s;
}

.card-link {
    display: block;
    color: inherit;
}

.card-link:hover {
    box-shadow: var(--shadow-lg);
    transform: translateY(-2px);
    color: inherit;
}

.card-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
}

.card-icon {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    background: var(--primary-light);
    color: var(--primary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    font-weight: 700;
    flex-shrink: 0;
}

.card-arrow {
    color: var(--text-muted);
    font-size: 20px;
}

/* Grid */
.grid {
    display: grid;
    gap: 16px;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
}

/* Forms */
.form-group { margin-bottom: 16px; }

label {
    display: block;
    font-size: 13px;
    font-weight: 600;
    color: var(--text-light);
    margin-bottom: 6px;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

input[type="text"],
input[type="email"],
input[type="password"],
textarea,
select {
    width: 100%;
    padding: 12px 16px;
    font-size: 15px;
    font-family: inherit;
    border: 1px solid rgba(27, 74, 90, 0.15);
    border-radius: var(--radius);
    background: white;
    color: var(--text);
    transition: border-color 0.2s, box-shadow 0.2s;
}

input:focus, textarea:focus, select:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(27, 74, 90, 0.1);
}

textarea { min-height: 80px; resize: vertical; }

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 24px;
    font-size: 15px;
    font-weight: 600;
    font-family: inherit;
    border: none;
    border-radius: var(--radius);
    cursor: pointer;
    transition: all 0.2s;
    text-decoration: none;
}

.btn-primary {
    background: var(--primary);
    color: white;
}
.btn-primary:hover { background: var(--primary-dark); color: white; }

.btn-gold {
    background: var(--gold);
    color: white;
}
.btn-gold:hover { background: #b6985a; color: white; }

.btn-outline {
    background: transparent;
    color: var(--primary);
    border: 1px solid rgba(27, 74, 90, 0.2);
}
.btn-outline:hover { background: var(--primary-light); }

.btn-block { width: 100%; }
.btn-sm { padding: 8px 16px; font-size: 13px; }

/* Tables */
.data-table {
    width: 100%;
    border-collapse: collapse;
    background: white;
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--shadow);
}

.data-table th {
    text-align: left;
    padding: 14px 16px;
    background: var(--primary-light);
    color: var(--primary);
    font-weight: 600;
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.data-table td {
    padding: 14px 16px;
    border-top: 1px solid rgba(27, 74, 90, 0.08);
    font-size: 14px;
}

.data-table tr:hover td { background: var(--bg-light); }

/* Detail key/value list */
.kv-list {
    display: grid;
    grid-template-columns: 200px 1fr;
    gap: 12px 24px;
}

.kv-list dt {
    font-size: 13px;
    font-weight: 600;
    color: var(--text-light);
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.kv-list dd {
    margin: 0;
    font-size: 15px;
    color: var(--text);
}

.kv-list dd.empty {
    color: var(--text-muted);
    font-style: italic;
}

/* Alerts */
.alert {
    padding: 12px 16px;
    border-radius: var(--radius);
    margin-bottom: 16px;
    font-size: 14px;
}

.alert-error {
    background: rgba(214, 69, 69, 0.1);
    color: var(--red);
    border: 1px solid rgba(214, 69, 69, 0.2);
}

.alert-success {
    background: rgba(57, 181, 74, 0.1);
    color: var(--green);
    border: 1px solid rgba(57, 181, 74, 0.2);
}

/* Badges */
.badge {
    display: inline-block;
    padding: 4px 10px;
    border-radius: var(--radius-pill);
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.badge-success { background: rgba(57, 181, 74, 0.15); color: var(--green); }
.badge-muted { background: rgba(27, 74, 90, 0.08); color: var(--text-light); }
.badge-gold { background: var(--gold-light); color: #8a7541; }
.badge-warn { background: rgba(196, 169, 106, 0.2); color: #8a7541; }

/* Login screen */
.login-page {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--primary-light), white);
}

.login-card {
    background: white;
    border-radius: var(--radius-lg);
    padding: 40px;
    box-shadow: var(--shadow-lg);
    width: 100%;
    max-width: 400px;
}

.login-header {
    text-align: center;
    margin-bottom: 32px;
}

.login-mark {
    width: 64px;
    height: 64px;
    border-radius: 16px;
    background: linear-gradient(135deg, var(--primary), var(--navy-light));
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 28px;
    margin: 0 auto 16px;
}

.login-logo {
    height: 80px;
    width: auto;
    display: block;
    margin: 0 auto 24px;
}

/* Empty state */
.empty {
    text-align: center;
    padding: 64px 24px;
    color: var(--text-light);
}

.empty-icon {
    font-size: 48px;
    margin-bottom: 16px;
    opacity: 0.4;
}

/* Document actions row */
.doc-actions {
    display: grid;
    gap: 12px;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
}

.doc-action-card {
    border: 1px solid rgba(27, 74, 90, 0.12);
    border-radius: var(--radius);
    padding: 16px;
    background: white;
    transition: all 0.2s;
}

.doc-action-card:hover {
    border-color: var(--primary);
    box-shadow: var(--shadow);
}

.doc-action-card form { margin: 0; }

.doc-action-card h3 { margin: 0 0 12px; }

/* Breadcrumbs */
.breadcrumbs {
    display: flex;
    gap: 8px;
    align-items: center;
    color: var(--text-light);
    font-size: 14px;
    margin-bottom: 8px;
}

.breadcrumbs a { color: var(--primary); }
.breadcrumbs span.sep { color: var(--text-muted); }

/* Responsive */
@media (max-width: 700px) {
    .nav { padding: 12px 16px; }
    .container, .container-narrow { padding: 16px; }
    .kv-list { grid-template-columns: 1fr; gap: 4px 0; }
    .kv-list dt { margin-top: 12px; }
}
