body {
    background: linear-gradient(145deg, #eef3f7 0%, #f8fafc 52%, #e7eef3 100%);
    color: #17212b;
    font-family: 'Trebuchet MS', 'Segoe UI', sans-serif;
    min-height: 100vh;
}

.welcome-text {
    font-family: 'Nunito', 'Trebuchet MS', sans-serif;
    font-size: 1.05rem;
    font-weight: 800;
    letter-spacing: .01em;
}

.header-datetime {
    display: inline-block;
    margin-left: 10px;
    padding-left: 10px;
    border-left: 1px solid rgba(255, 255, 255, .35);
    color: rgba(255, 255, 255, .78);
    font-family: 'Nunito', sans-serif;
    font-size: .78rem;
    font-weight: 700;
    white-space: nowrap;
}

.header-gmt {
    margin-left: 8px;
    color: #9ce3e2;
    font-family: 'Nunito', sans-serif;
    font-size: .72rem;
    font-weight: 800;
    white-space: nowrap;
}

.language-flags {
    display: flex;
    gap: 4px;
    margin-right: 12px;
}

.language-flags a {
    font-size: 1.05rem;
    line-height: 1;
    text-decoration: none;
    filter: saturate(.85);
    transition: transform .15s ease, filter .15s ease;
}

.language-flags a:hover {
    filter: saturate(1.3);
    transform: translateY(-2px);
}

.home-search-panel {
    padding: 18px;
    background: rgba(255, 255, 255, .86);
    border: 1px solid #d5e0e7;
    border-radius: 8px;
    box-shadow: 0 6px 18px rgba(20, 48, 70, .07);
}

/* Navbar con sfondo blu #002060 */
.navbar {
    background: #032565 !important;
    box-shadow: 0 4px 18px rgba(7, 29, 53, .24);
    border-bottom: 3px solid #52c7c9;
}

.navbar-brand {
    color: white !important;
    font-weight: bold;
    letter-spacing: .02em;
}

.logo-text {
    display: inline-block;
    margin-right: 14px;
    color: #ffffff;
    font-family: 'AR Berkley', 'Berkshire Swash', cursive;
    font-size: 2.45rem;
    font-weight: 400;
    line-height: 1;
    text-shadow: 0 2px 8px rgba(0, 0, 0, .22);
    vertical-align: middle;
}

.lro-word {
    white-space: nowrap;
}

.lro-letter {
    font-family: 'AR Berkley', 'Berkshire Swash', cursive;
}

.lro-blue {
    color: #16a9e1;
}

.lro-yellow {
    color: #ffe500;
}

.lro-red {
    color: #f5222d;
}

.footer {
    background: linear-gradient(100deg, #071d35 0%, #0b4161 100%);
    color: white;
    border-top: 3px solid #52c7c9;
}

.footer-brand {
    color: #ffffff;
    font-family: 'Nunito', sans-serif;
    font-weight: 800;
    margin-bottom: 8px;
}

.footer-powered {
    color: #9ce3e2;
    font-weight: 700;
    margin-bottom: 4px;
}

.footer-member {
    color: rgba(255, 255, 255, .78);
    margin-bottom: 0;
}

.berkley-brand {
    font-family: 'AR Berkley', 'Berkshire Swash', cursive;
    font-size: 1.18rem;
    letter-spacing: .01em;
}

.navbar-brand:hover {
    color: #e0e0e0 !important;
}

.nav-link {
    color: rgba(255,255,255,0.9) !important;
}

.nav-link:hover {
    color: white !important;
    background-color: rgba(82, 199, 201, .18);
    border-radius: 6px;
}

.dropdown-menu {
    background-color: white;
}

.dropdown-item:hover {
    background-color: #0b4161;
    color: white;
}

.container.mt-4 {
    max-width: 1440px;
}

h1, h2, h3, h4 {
    color: #102c42;
    letter-spacing: .01em;
}

.access-control-nav {
    padding: 12px 14px;
    background: linear-gradient(100deg, #dceff0, #edf7f7);
    border: 1px solid #a7d8d9;
    border-left: 5px solid #159a9c;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(11, 65, 97, .08);
}

.access-control-nav .btn-outline-primary {
    color: #0b6973;
    border-color: #51aeb1;
}

.access-control-nav .btn-outline-primary:hover {
    color: white;
    background-color: #0b6973;
}

.transfer-form {
    min-width: 170px;
}

.transfer-form .form-select {
    font-size: .82rem;
}

.access-parameters {
    padding: 16px;
    margin-bottom: 18px;
    background: #f2f8f9;
    border: 1px solid #b9dfe0;
    border-radius: 8px;
}

.support-type-choice {
    border-width: 2px;
    padding: 12px;
}

form.row.g-2.mb-3,
form.row.g-2.mb-4 {
    padding: 12px;
    background-color: rgba(255, 255, 255, .72);
    border: 1px solid #d5e0e7;
    border-radius: 8px;
}

/* Cards */
.card {
    box-shadow: 0 8px 24px rgba(20, 48, 70, .08);
    margin-bottom: 20px;
    border-radius: 8px;
    border: none;
    overflow: hidden;
}

.card-header {
    background: linear-gradient(100deg, #0b4161, #116b78);
    color: white;
    font-weight: 600;
    border-radius: 8px 8px 0 0 !important;
}

/* Tables */
.table {
    background-color: white;
    margin-bottom: 0;
}

.table thead {
    background-color: #eaf2f5;
    color: #173b52;
}

.table-filter-row th {
    padding: 6px;
    background: #f6fafb;
}

.table-filter-row input {
    min-width: 78px;
}

.table-pagination {
    font-size: .88rem;
}

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

.table tbody tr:hover {
    background-color: #f0f8f8;
}

/* Buttons */
.btn-primary {
    background-color: #0b4161 !important;
    border-color: #0b4161 !important;
}

.btn-primary:hover {
    background-color: #072d45 !important;
    border-color: #072d45 !important;
}

/* Forms */
.form-control:focus, .form-select:focus {
    border-color: #159a9c;
    box-shadow: 0 0 0 0.2rem rgba(21, 154, 156, 0.2);
}

.form-label {
    font-weight: 500;
    color: #333;
}

/* Alerts */
.alert {
    border-radius: 6px;
}

/* Badges */
.badge {
    padding: 0.5em 0.75em;
}

/* Login page */
.login-container {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #061a3a 0%, #0b4161 58%, #159a9c 100%);
}

.login-card {
    box-shadow: 0 10px 30px rgba(0,0,0,0.3);
    overflow: hidden;
}

.login-card .card-header {
    background: #032565;
    border-bottom: 4px solid #52c7c9;
}

.login-logo-text {
    color: #ffffff;
    font-family: 'AR Berkley', 'Berkshire Swash', cursive;
    font-size: 3.2rem;
    line-height: 1;
    text-shadow: 0 2px 8px rgba(0, 0, 0, .28);
}

.login-title {
    color: #ffffff;
    font-family: 'Nunito', sans-serif;
    font-size: 1.3rem;
    font-weight: 800;
}

.login-card .nav-tabs {
    gap: 6px;
    border-bottom: 2px solid #cbd9e2;
}

.login-card .nav-tabs .nav-link {
    color: #315066 !important;
    background: #edf3f6;
    border: 1px solid #cbd9e2;
    border-bottom: 0;
    border-radius: 6px 6px 0 0;
    font-weight: 800;
}

.login-card .nav-tabs .nav-link:hover {
    color: #032565 !important;
    background: #dceff0;
}

.login-card .nav-tabs .nav-link.active {
    color: #ffffff !important;
    background: #0b6973;
    border-color: #0b6973;
}

.login-language-switcher a {
    color: #0b6973;
    font-size: .8rem;
    font-weight: 800;
    text-decoration: none;
}

.login-language-switcher a:hover {
    color: #032565;
    text-decoration: underline;
}

/* Utility classes */
.text-primary {
    color: #0b4161 !important;
}

.bg-primary {
    background-color: #0b4161 !important;
}

.border-primary {
    border-color: #0b4161 !important;
}

@media (max-width: 768px) {
    .navbar-brand {
        max-width: calc(100vw - 90px);
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

    .logo-text {
        margin-right: 8px;
        font-size: 1.8rem;
    }

    .header-datetime {
        display: none;
    }

    .header-gmt {
        display: none;
    }

    .language-flags {
        margin-right: 8px;
    }

    .table {
        min-width: 720px;
    }

    .card-body {
        overflow-x: auto;
    }
}

.summary-tile {
    min-height: 132px;
    padding: 18px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    background: rgba(255, 255, 255, .86);
    border: 1px solid #d5e0e7;
    border-radius: 8px;
    box-shadow: 0 6px 18px rgba(20, 48, 70, .07);
}

.summary-tile strong {
    color: #0b4161;
    font-size: 1.8rem;
}

.summary-tile small {
    color: #607687;
    font-weight: 700;
}

.summary-icon {
    color: #159a9c;
    font-size: 1.2rem;
}

.alert-tile {
    border-color: #f0c36d;
}

.message-tile {
    border-color: #a9c9ee;
}

.dashboard-notifications .list-group-item {
    border-left: 0;
    border-right: 0;
}

/* Dark theme overrides for shared Bootstrap components. */
[data-theme="dark"] body {
    background: linear-gradient(145deg, #101923 0%, #17232d 52%, #0d151d 100%);
    color: #e4edf2;
}

[data-theme="dark"] .theme-toggle {
    color: #ffe500;
}

.theme-toggle {
    color: #ffffff;
    border: 0;
    padding: .45rem .65rem;
}

.theme-toggle:hover,
.theme-toggle:focus {
    color: #ffe500;
    background: rgba(82, 199, 201, .18);
}

[data-theme="dark"] h1,
[data-theme="dark"] h2,
[data-theme="dark"] h3,
[data-theme="dark"] h4,
[data-theme="dark"] h5,
[data-theme="dark"] h6,
[data-theme="dark"] .form-label {
    color: #e4edf2;
}

[data-theme="dark"] .home-search-panel,
[data-theme="dark"] .summary-tile,
[data-theme="dark"] .card,
[data-theme="dark"] form.row.g-2.mb-3,
[data-theme="dark"] form.row.g-2.mb-4,
[data-theme="dark"] .access-parameters {
    background-color: #1d2b36;
    border-color: #334957;
    color: #e4edf2;
}

[data-theme="dark"] .card-header {
    background: linear-gradient(100deg, #0b4161, #0d5963);
}

[data-theme="dark"] .table {
    --bs-table-bg: #1d2b36;
    --bs-table-color: #e4edf2;
    --bs-table-border-color: #334957;
}

[data-theme="dark"] .table thead,
[data-theme="dark"] .table-filter-row th {
    background-color: #263b48;
    color: #d7e6ec;
}

[data-theme="dark"] .table tbody tr:hover {
    background-color: #29404d;
}

[data-theme="dark"] .form-control,
[data-theme="dark"] .form-select {
    background-color: #15222c;
    border-color: #4a6573;
    color: #e4edf2;
}

[data-theme="dark"] .form-control::placeholder {
    color: #9eb0ba;
}

[data-theme="dark"] .dropdown-menu,
[data-theme="dark"] .modal-content {
    background-color: #1d2b36;
    color: #e4edf2;
}

[data-theme="dark"] .dropdown-item,
[data-theme="dark"] .modal-header,
[data-theme="dark"] .modal-footer {
    color: #e4edf2;
    border-color: #334957;
}

[data-theme="dark"] .dropdown-item:hover {
    background-color: #0b6973;
}

[data-theme="dark"] .text-muted {
    color: #aebfc8 !important;
}