input,
select,
textarea {
    max-width: 100%;
}

.sidebar .nav-item .nav-link span {
    font-size: 0.92rem;
}

.topbar .form-control,
.topbar select {
    min-width: 220px;
}

.fu-company-switcher {
    margin-bottom: 0;
    display: flex;
    align-items: center;
    margin-top: 0;
}

.fu-company-nav-item {
    max-width: none;
}

.fu-company-inline {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    flex-wrap: nowrap;
}

.fu-company-inline-label {
    font-size: 0.78rem;
    color: #7c879b;
    font-weight: 700;
    white-space: nowrap;
}

.fu-company-select {
    min-width: 0;
    width: 220px;
    font-weight: 700;
    color: #2f3a56;
}

.fu-company-select:focus {
    box-shadow: none;
}

.fu-user-toggle {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.fu-user-avatar {
    width: 2.35rem;
    height: 2.35rem;
    border-radius: 999px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #4e73df 0%, #2749b3 100%);
    color: #fff;
    box-shadow: 0 10px 20px rgba(78, 115, 223, 0.22);
}

.topbar .dropdown-list .dropdown-header,
.topbar .dropdown-menu .dropdown-header {
    font-size: 0.68rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: #98a2b3;
    background: transparent;
}

@media (max-width: 991.98px) {
    .fu-company-select {
        width: 150px;
    }

    .fu-company-inline {
        gap: 0.45rem;
    }

    .fu-company-inline-label {
        display: none;
    }
}

.card {
    border: 0;
}

.table td,
.table th {
    vertical-align: middle;
}

.card .dataTables_wrapper {
    padding: 1rem 1.25rem 0.75rem;
}

.card .dataTables_wrapper .row:first-child,
.card .dataTables_wrapper .row:last-child {
    margin-left: 0;
    margin-right: 0;
}

.card .dataTables_wrapper .dataTables_filter,
.card .dataTables_wrapper .dataTables_length {
    margin-bottom: 0.75rem;
}

.card .dataTables_wrapper .dataTables_info,
.card .dataTables_wrapper .dataTables_paginate {
    padding-top: 0.85rem;
    padding-bottom: 0.25rem;
}

.card .dataTables_wrapper table.dataTable {
    margin-top: 0 !important;
    margin-bottom: 0 !important;
}

.card .table-responsive {
    padding-left: 0.15rem;
    padding-right: 0.15rem;
}

.collapse-inner .nav-item {
    list-style: none;
}

.collapse-inner .nav-link {
    color: #3a3b45;
    padding: 0.65rem 1rem;
    display: block;
    font-size: .85rem;
}

.collapse-inner .nav-link:hover {
    text-decoration: none;
    background-color: #eaecf4;
    border-radius: .35rem;
}

.collapse-inner .collapse-inner {
    padding-left: .5rem;
}

.form-check-input {
    margin-top: .3rem;
}

.fu-login-card {
    max-width: 480px;
    margin: 0 auto;
}

.crud-page-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.crud-page-title {
    margin-bottom: 0.25rem;
    color: #1f2937;
    font-weight: 700;
}

.crud-page-subtitle {
    margin-bottom: 0;
    color: #858796;
}

.crud-card {
    border-radius: 0.85rem;
    overflow: hidden;
}

.crud-card .card-header {
    background: #fff;
    border-bottom: 1px solid #e3e6f0;
    padding: 1rem 1.25rem;
}

.crud-card .card-header h6 {
    margin: 0;
    color: #4e73df;
    font-weight: 700;
}

.crud-card .card-body {
    padding: 1.35rem 1.25rem;
}

.crud-form-grid .form-group,
.crud-form-grid .form-check {
    margin-bottom: 1rem;
}

.crud-form-section {
    padding: 1rem 1rem 0.35rem;
    border: 1px solid #e3e6f0;
    border-radius: 0.75rem;
    background: #fff;
    height: 100%;
}

.crud-form-section-title {
    font-size: 0.9rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    color: #4e73df;
    margin-bottom: 1rem;
}

.btn {
    border-radius: 0.7rem;
    font-weight: 700;
    letter-spacing: 0.01em;
    transition: transform 0.16s ease, box-shadow 0.18s ease, background-color 0.18s ease, border-color 0.18s ease, color 0.18s ease;
    box-shadow: 0 8px 18px rgba(31, 41, 55, 0.08);
}

.btn:hover,
.btn:focus {
    transform: translateY(-1px);
    box-shadow: 0 12px 24px rgba(31, 41, 55, 0.12);
}

.btn:active {
    transform: translateY(0);
    box-shadow: 0 6px 14px rgba(31, 41, 55, 0.1);
}

.btn-sm {
    border-radius: 0.62rem;
    padding: 0.42rem 0.8rem;
    font-weight: 700;
}

.btn-primary {
    background: linear-gradient(135deg, #4e73df 0%, #3458c5 100%);
    border-color: #3458c5;
}

.btn-primary:hover,
.btn-primary:focus {
    background: linear-gradient(135deg, #4568d1 0%, #2f4fb1 100%);
    border-color: #2f4fb1;
}

.btn-outline-primary,
.btn-outline-secondary,
.btn-outline-info,
.btn-outline-warning,
.btn-outline-danger {
    background-color: #fff;
}

.btn-outline-primary:hover,
.btn-outline-secondary:hover,
.btn-outline-info:hover,
.btn-outline-warning:hover,
.btn-outline-danger:hover,
.btn-outline-primary:focus,
.btn-outline-secondary:focus,
.btn-outline-info:focus,
.btn-outline-warning:focus,
.btn-outline-danger:focus {
    color: #fff;
}

.btn-outline-secondary {
    border-color: #d5dbea;
    color: #5f6b85;
}

.btn-outline-secondary:hover,
.btn-outline-secondary:focus {
    background: linear-gradient(135deg, #6b7280 0%, #4b5563 100%);
    border-color: #4b5563;
}

.crud-actions {
    display: flex;
    gap: 0.75rem;
    margin-top: 1.5rem;
    flex-wrap: wrap;
}

.crud-table-actions {
    display: inline-flex;
    gap: 0.5rem;
    justify-content: flex-end;
    flex-wrap: wrap;
}

.crud-actions .btn,
.crud-page-header .btn {
    min-height: 42px;
    padding-left: 1rem;
    padding-right: 1rem;
}

.crud-table-actions .btn {
    min-width: 88px;
}

.crud-table-actions .btn-sm {
    min-height: 34px;
    padding-left: 0.75rem;
    padding-right: 0.75rem;
}

.crud-inline-form .btn {
    min-width: auto;
}

.crud-inline-form {
    display: inline-block;
    margin: 0;
}

.crud-delete-box {
    max-width: 640px;
}

.crud-delete-icon {
    width: 56px;
    height: 56px;
    border-radius: 16px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: rgba(231, 74, 59, 0.12);
    color: #e74a3b;
    font-size: 1.35rem;
    margin-bottom: 1rem;
}

.crud-kv {
    display: grid;
    grid-template-columns: 140px 1fr;
    gap: 0.5rem 1rem;
    margin-top: 1rem;
}

.crud-kv dt {
    margin: 0;
    color: #6b7280;
    font-weight: 600;
}

.crud-kv dd {
    margin: 0;
    color: #1f2937;
}

.crud-listbox {
    min-height: 220px;
}

.crud-check-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 0.75rem;
}

.crud-empty-state {
    padding: 2.5rem 1.5rem;
    text-align: center;
    color: #858796;
}

.fu-contact-card {
    border: 1px solid #e3e6f0;
    border-radius: 0.85rem;
    padding: 1rem 1rem 0.85rem;
    background: #fff;
    margin-bottom: 1rem;
}

.fu-contact-card:last-child {
    margin-bottom: 0;
}

.fu-agenda-card {
    border: 1px solid #e3e6f0;
    border-radius: 0.85rem;
    padding: 1rem;
    background: linear-gradient(180deg, #ffffff 0%, #fbfcff 100%);
    margin-bottom: 1rem;
}

.fu-agenda-card:last-child {
    margin-bottom: 0;
}

.fu-activity-row {
    padding: 0.9rem 0;
    border-bottom: 1px solid #eef1f7;
}

.fu-activity-row:first-child {
    padding-top: 0;
}

.fu-activity-row:last-child {
    padding-bottom: 0;
    border-bottom: 0;
}

.fu-guide-widget {
    display: flex;
    justify-content: flex-end;
    margin-bottom: 1rem;
}

.fu-guide-trigger {
    display: inline-flex;
    align-items: center;
    gap: 0.55rem;
    border: 1px solid #c9d8ff;
    background: #ffffff;
    color: #3157c8;
    border-radius: 999px;
    padding: 0.45rem 0.9rem 0.45rem 0.5rem;
    font-weight: 700;
    box-shadow: 0 8px 24px rgba(78, 115, 223, 0.12);
    transition: all 0.2s ease;
}

.fu-guide-trigger:hover,
.fu-guide-trigger:focus {
    outline: none;
    text-decoration: none;
    background: #f8fbff;
    border-color: #9fb9ff;
}

.fu-guide-trigger-icon {
    width: 28px;
    height: 28px;
    border-radius: 999px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #4e73df 0%, #3559c7 100%);
    color: #fff;
    font-size: 0.95rem;
    font-weight: 800;
    line-height: 1;
}

.fu-guide-trigger-text {
    font-size: 0.88rem;
}

.fu-guide-widget .collapse,
.fu-guide-widget .collapsing {
    width: min(420px, 100%);
}

.fu-guide-panel {
    margin-top: 0.75rem;
    padding: 1rem 1.1rem;
    border: 1px solid #dbe7ff;
    border-radius: 0.85rem;
    background: linear-gradient(180deg, #f8fbff 0%, #eef5ff 100%);
}

.fu-guide-title {
    font-size: 0.92rem;
    font-weight: 800;
    color: #3157c8;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    margin-bottom: 0.4rem;
}

.fu-guide-description {
    color: #4b5563;
    margin-bottom: 0.55rem;
}

.fu-guide-list {
    margin: 0;
    padding-left: 1.1rem;
    color: #4b5563;
}

.fu-guide-list li + li {
    margin-top: 0.3rem;
}

.min-vh-100 {
    min-height: 100vh;
}

.login-shell {
    border-radius: 1rem;
    overflow: hidden;
}

.login-page-wrapper {
    min-height: 100vh;
    background:
        radial-gradient(circle at top left, rgba(78, 115, 223, 0.18), transparent 30%),
        radial-gradient(circle at bottom right, rgba(28, 200, 138, 0.16), transparent 25%),
        #f8f9fc;
}

.login-brand-panel {
    min-height: 620px;
    background:
        linear-gradient(135deg, rgba(78, 115, 223, 0.96), rgba(34, 74, 190, 0.92)),
        radial-gradient(circle at top left, rgba(255, 255, 255, 0.24), transparent 35%);
    color: #fff;
    position: relative;
}

.login-brand-panel::after {
    content: "";
    position: absolute;
    inset: 2rem;
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: 1rem;
}

.login-brand-content {
    position: relative;
    z-index: 1;
    padding: 3.5rem;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.login-brand-content h1 {
    color: #fff;
    font-size: 2.3rem;
    font-weight: 800;
    margin-bottom: 1rem;
}

.login-brand-content p {
    color: rgba(255, 255, 255, 0.88);
    font-size: 1.05rem;
    line-height: 1.8;
}

.login-brand-badge {
    width: 72px;
    height: 72px;
    border-radius: 20px;
    background: rgba(255, 255, 255, 0.14);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 1.8rem;
    margin-bottom: 1.5rem;
    box-shadow: 0 18px 40px rgba(15, 23, 42, 0.18);
}

.login-shell .form-control-user {
    height: calc(1.5em + 1.5rem + 2px);
}

.dt-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.dt-buttons .btn {
    min-width: 88px;
}
