.navbar {
    background-color: #005b3c;
    min-height: 60px;
    padding: 0 3rem;
}

.navbar .navbar-nav {
    align-items: center;
    gap: 0.5rem;
}

.navbar .nav-link {
    color: #fff;
    font-size: 1rem;
    font-weight: 700;
    padding: 0.65rem 1.1rem;
}

.navbar .nav-link:hover,
.navbar .nav-link:focus {
    color: #fff;
}

.navbar-nav .nav-item.active .nav-link {
    background-color: #f2e318;
    border-radius: 12px;
    box-shadow: 0 2px 6px rgb(0 0 0 / 20%);
    color: #17241e;
    font-weight: 700;
}

.navbar .nav-link-disabled {
    cursor: not-allowed;
    opacity: 1;
}

.navbar .profile-menu-toggle {
    background: transparent;
    border: 0;
}

.navbar .dropdown {
    position: relative;
}

.navbar .dropdown-menu {
    border: 0;
    border-radius: 10px;
    box-shadow: 0 6px 18px rgb(0 0 0 / 18%);
}

/* Keep the account menu anchored to the right edge of its trigger. */
.navbar .profile-menu {
    box-sizing: border-box;
    left: auto;
    max-width: calc(100vw - 2rem);
    right: 0;
}

.navbar .profile-menu .dropdown-item {
    overflow-wrap: anywhere;
}

.global-dashboard-hero {
    background: #fcfbf6;
    min-height: 205px;
    overflow: hidden;
    padding: 2rem clamp(2rem, 5vw, 5rem);
    position: relative;
}

.global-dashboard-hero__content {
    position: relative;
    z-index: 1;
}

.global-dashboard-hero h1 {
    color: #101626;
    font-size: clamp(1.9rem, 3vw, 3rem);
    font-weight: 800;
    letter-spacing: -0.04em;
    margin: 0 0 1.5rem;
}

.global-dashboard-hero__button {
    background-color: #079b68;
    border: 0;
    border-radius: 12px;
    box-shadow: 0 3px 7px rgb(0 0 0 / 15%);
    color: #fff;
    font-size: 1.15rem;
    font-weight: 600;
    padding: 0.85rem 1.5rem;
    position: relative;
    z-index: 1;
}

.global-dashboard-hero__actions {
    align-items: center;
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    position: relative;
    z-index: 1;
}

.global-dashboard-hero__button .bi {
    margin-right: 0.45rem;
    vertical-align: -0.1em;
}

.global-dashboard-hero__secondary-button .bi {
    margin-right: 0.4rem;
}

.global-dashboard-hero__button:hover {
    background-color: #078358;
    color: #fff;
}

.global-dashboard-hero__secondary-button {
    background-color: rgb(255 255 255 / 78%);
    border: 1px solid #006e4b;
    border-radius: 12px;
    color: #005b3c;
    font-weight: 600;
    padding: 0.85rem 1.25rem;
}

.global-dashboard-hero__secondary-button:hover {
    background-color: #e4f2ec;
    border-color: #005b3c;
    color: #00442e;
}

.global-dashboard-hero__image {
    bottom: 0;
    height: 100%;
    object-fit: contain;
    object-position: right bottom;
    position: absolute;
    right: 0;
    width: min(68%, 850px);
}

.dashboard-hero__greeting {
    color: #27302b;
    font-size: 1rem;
    margin: 0 0 0.35rem;
}

.dashboard-hero h1 {
    margin-bottom: 0;
}

.dashboard-page {
    margin-top: 1rem;
    max-width: 1320px;
}

.dashboard-section-title {
    color: #1b2530;
    font-size: 1.35rem;
    font-weight: 800;
    margin: 1.75rem 0 0.9rem;
}

.dashboard-page > .dashboard-section-title:first-child {
    margin-top: 0;
}

.dashboard-stats {
    display: grid;
    gap: 0.9rem;
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.dashboard-stat {
    border-radius: 12px;
    min-height: 130px;
    overflow: hidden;
    padding: 1.1rem 4.5rem 1rem 1.25rem;
    position: relative;
    text-align: left;
}

.dashboard-stat--mine {
    background: #087457;
    color: #fff;
}

.dashboard-stat--highest {
    background: #ffe587;
    color: #102332;
}

.dashboard-stat--place {
    background: #f0ede5;
    color: #102332;
}

.dashboard-stat__label,
.dashboard-stat__hint {
    font-size: 0.95rem;
    margin: 0;
}

.dashboard-stat__label {
    font-weight: 700;
}

.dashboard-stat__value {
    font-size: clamp(2.5rem, 5vw, 3.5rem);
    line-height: 1.05;
}

.dashboard-stat__score {
    align-items: baseline;
    display: flex;
    gap: 0.35rem;
    margin: 0.15rem 0 0.3rem;
}

.dashboard-stat--place .dashboard-stat__value {
    display: block;
    margin: 0.15rem 0 0.3rem;
}

.dashboard-stat__unit {
    font-size: 0.95rem;
    font-weight: 700;
}

.dashboard-stat__icon {
    font-size: 2.75rem;
    opacity: 0.7;
    position: absolute;
    right: 1.4rem;
    top: 50%;
    transform: translateY(-50%);
}

.dashboard-lower {
    display: grid;
    gap: 0.9rem;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    margin-top: 0.9rem;
}

.dashboard-recent {
    background: #fffefa;
    border: 1px solid #eeeae2;
    border-radius: 12px;
    padding: 1.1rem 1.25rem;
}

.dashboard-recent h2 {
    color: #1b2530;
    font-size: 1.1rem;
    font-weight: 700;
    margin: 0 0 0.85rem;
}

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

.dashboard-recent__item {
    align-items: center;
    border-top: 1px solid #eeeae2;
    display: grid;
    gap: 0.75rem;
    grid-template-columns: 72px minmax(0, 1fr) auto;
    padding: 0.7rem 0;
}

.dashboard-recent__item time {
    color: #6a6d73;
    font-size: 0.82rem;
    font-weight: 600;
}

.dashboard-recent__name {
    color: #1b2530;
    font-weight: 600;
}

.dashboard-recent__details {
    min-width: 0;
}

.dashboard-recent__details .dashboard-recent__name {
    display: block;
}

.dashboard-recent__event {
    color: #6a6d73;
    display: block;
    font-size: 0.8rem;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.dashboard-recent__item strong {
    color: #087457;
    font-size: 0.88rem;
    white-space: nowrap;
}

.dashboard-recent__empty {
    color: #6a6d73;
    margin: 0;
}

@media (max-width: 575.98px) {
    .dashboard-stats {
        grid-template-columns: 1fr;
    }

    .dashboard-lower {
        grid-template-columns: 1fr;
    }

    .dashboard-recent__item {
        gap: 0.35rem 0.6rem;
        grid-template-columns: 1fr auto;
    }

    .dashboard-recent__item time {
        grid-column: 1 / -1;
    }
}

.units-list {
    display: grid;
    gap: 0.7rem;
    margin: 1.1rem 0;
}

.unit-card {
    background: #fffefa;
    border: 1px solid #eeeae2;
    border-radius: 14px;
    box-shadow: 0 2px 8px rgb(31 42 35 / 6%);
    overflow: visible;
    position: relative;
}

.unit-card:has(.unit-card__menu[open]) {
    z-index: 10;
}

.unit-card__summary {
    align-items: center;
    display: flex;
    gap: 0.75rem;
    min-height: 82px;
    padding: 0.75rem 1.25rem;
}

.unit-card__toggle {
    background: transparent;
    border: 0;
    color: #111827;
    font-size: 1.25rem;
    padding: 0.25rem;
}

.unit-card__toggle .bi {
    display: block;
    transition: transform 180ms ease;
}

.unit-card__toggle.is-open .bi {
    transform: rotate(90deg);
}

.unit-card__info {
    min-width: 190px;
}

.unit-card__info h2 {
    color: #141923;
    font-size: 1.15rem;
    font-weight: 700;
    margin: 0;
}

.unit-card__info p {
    color: #6a6d73;
    font-size: 0.9rem;
    margin: 0.1rem 0 0;
}

.unit-card__menu {
    margin-left: auto;
    position: relative;
    z-index: 4;
}

.unit-card__menu summary {
    align-items: center;
    background: transparent;
    border: 0;
    color: #59605b;
    cursor: pointer;
    display: flex;
    font-size: 1.3rem;
    height: 34px;
    justify-content: center;
    line-height: 1;
    list-style: none;
    padding: 0.25rem;
    width: 34px;
}

.unit-card__menu summary::-webkit-details-marker {
    display: none;
}

.unit-card__menu-content {
    background: #fff;
    border: 1px solid #eeeae2;
    border-radius: 9px;
    box-shadow: 0 5px 14px rgb(31 42 35 / 14%);
    padding: 0.25rem;
    position: absolute;
    right: 0;
    top: 2.1rem;
    z-index: 3;
}

.unit-card__menu-item {
    border-radius: 6px;
    color: #303935;
    display: block;
    font-size: 0.85rem;
    padding: 0.45rem 0.6rem;
    text-decoration: none;
    white-space: nowrap;
}

.unit-card__menu-item:hover {
    background: #f0ede5;
    color: #303935;
}

.unit-card__menu-item .bi {
    margin-right: 0.35rem;
}

.unit-card__actions {
    display: flex;
    flex: 1;
    flex-wrap: wrap;
    gap: 0.5rem;
    justify-content: flex-end;
}

.unit-card__button {
    align-items: center;
    border-radius: 10px;
    display: inline-flex;
    font-size: 0.9rem;
    font-weight: 600;
    gap: 0.4rem;
    justify-content: center;
    min-width: 138px;
    padding: 0.55rem 0.8rem;
}

.unit-card__button--event {
    background: #f0ede5;
    border: 1px solid #e8e3d8;
    color: #1b2530;
}

.unit-card__button--user {
    background: #079b68;
    border: 1px solid #079b68;
    color: #fff;
}

.unit-card__button--edit {
    background: #fffefa;
    border: 1px solid #e8e3d8;
    color: #1b2530;
}

.unit-card__button--event:hover,
.unit-card__button--edit:hover {
    background: #e7e2d7;
    color: #1b2530;
}

.unit-card__button--user:hover {
    background: #078358;
    color: #fff;
}

.unit-card__details {
    border-top: 1px solid #eeeae2;
    padding: 0.75rem 1.25rem;
}

.unit-members {
    display: grid;
    gap: 0.4rem;
}

.unit-member {
    background: #f7f5ef;
    border-radius: 9px;
}

.unit-member__summary {
    align-items: center;
    display: flex;
    gap: 0.45rem;
    justify-content: flex-start;
    padding: 0.2rem 0.35rem;
}

.unit-member__toggle {
    background: transparent;
    border: 0;
    color: #202833;
    font-weight: 600;
    padding: 0.35rem 0.4rem;
    text-align: left;
}

.unit-member__toggle .bi {
    display: inline-block;
    font-size: 0.85rem;
    margin-right: 0.4rem;
    transition: transform 180ms ease;
}

.unit-member__toggle.is-open .bi {
    transform: rotate(90deg);
}

.unit-member__score {
    color: #078358;
    font-weight: 700;
    margin-left: 0.3rem;
}

.unit-member__points-button {
    background: #e7f3ed;
    border: 1px solid #c7e5d8;
    border-radius: 8px;
    color: #006e4b;
    font-size: 0.8rem;
    font-weight: 600;
    padding: 0.3rem 0.55rem;
}

.unit-member__points-button:hover {
    background: #d5ebdf;
    color: #005b3c;
}

.unit-member__details {
    background: #f7f5ef;
    padding: 0.25rem 1.5rem 0.75rem;
}

.user-point-cards {
    display: grid;
    gap: 0.55rem;
}

.user-point-card {
    background: #fffefa;
    border: 1px solid #e9e4d9;
    border-radius: 9px;
    padding: 0.75rem 0.85rem;
}

.user-point-card__header {
    align-items: flex-start;
    display: flex;
    gap: 0.75rem;
    justify-content: space-between;
}

.user-point-card__header h3 {
    color: #1b2530;
    font-size: 0.95rem;
    font-weight: 700;
    margin: 0;
}

.user-point-card__header strong {
    color: #078358;
    font-size: 0.9rem;
    white-space: nowrap;
}

.user-point-card__fields {
    display: grid;
    gap: 0.35rem;
    margin: 0.65rem 0 0;
}

.user-point-card__field {
    display: grid;
    gap: 0.6rem;
    grid-template-columns: 78px 1fr;
}

.user-point-card__field dt {
    color: #6a6d73;
    font-size: 0.78rem;
    font-weight: 600;
}

.user-point-card__field dd {
    color: #303935;
    font-size: 0.85rem;
    margin: 0;
}

.unit-member__empty {
    color: #6a6d73;
    font-size: 0.85rem;
    margin: 0;
}

.app-form-card {
    background: #fffefa;
    border: 1px solid #eeeae2;
    border-radius: 16px;
    box-shadow: 0 2px 10px rgb(31 42 35 / 7%);
    margin: 2rem auto;
    max-width: 640px;
    padding: 1.75rem !important;
}

.app-form-card h1 {
    color: #141923;
    font-size: 1.65rem;
    font-weight: 700;
    margin-bottom: 1.5rem !important;
}

.user-profile-page {
    padding-top: 2rem;
}

.user-profile-card {
    max-width: 560px;
}

.user-profile-card__fields {
    border-top: 1px solid #e9e4d9;
}

.user-profile-card__field {
    align-items: baseline;
    border-bottom: 1px solid #e9e4d9;
    display: flex;
    gap: 1rem;
    justify-content: space-between;
    padding: 0.8rem 0;
}

.user-profile-card__field span {
    color: #6a6d73;
    font-size: 0.88rem;
}

.user-profile-card__field strong {
    color: #1b2530;
    font-size: 0.95rem;
    min-width: 0;
    overflow-wrap: anywhere;
    text-align: right;
}

.app-form-card .form-label {
    color: #354038;
    font-size: 0.9rem;
    font-weight: 600;
}

.app-form-card .form-control,
.app-form-card .form-select {
    border-color: #dcded8;
    border-radius: 9px;
    padding: 0.65rem 0.8rem;
}

.app-form-card .form-control:focus,
.app-form-card .form-select:focus {
    border-color: #079b68;
    box-shadow: 0 0 0 0.2rem rgb(7 155 104 / 15%);
}

.app-form__actions {
    display: flex;
    gap: 0.7rem;
    margin-top: 1.5rem;
}

.app-form__save,
.app-form__back {
    border-radius: 10px;
    font-weight: 600;
    padding: 0.65rem 1.15rem;
}

.app-form__save {
    background: #079b68;
    border-color: #079b68;
    color: #fff;
}

.app-form__save:hover {
    background: #078358;
    border-color: #078358;
    color: #fff;
}

.probe-add-section {
    flex: 0 0 auto;
    white-space: nowrap;
}

.probe-section-menu {
    margin-left: auto;
    position: relative;
    z-index: 5;
}

.probe-section-menu[open] {
    z-index: 20;
}

.unit-card:has(.probe-section-menu[open]) {
    z-index: 10;
}

.probe-section-menu--card {
    position: absolute;
    right: 1.25rem;
    top: 0.75rem;
}

.unit-card__summary:has(+ .probe-section-menu--card) {
    padding-right: 3.75rem;
}

.probe-section-menu > summary {
    align-items: center;
    color: #59605b;
    cursor: pointer;
    display: flex;
    font-size: 1.25rem;
    height: 34px;
    justify-content: center;
    list-style: none;
    width: 34px;
}

.probe-section-menu > summary::-webkit-details-marker { display: none; }

.probe-section-menu__content {
    background: #fff;
    border: 1px solid #eeeae2;
    border-radius: 9px;
    box-shadow: 0 5px 14px rgb(31 42 35 / 14%);
    min-width: 150px;
    padding: 0.25rem;
    position: absolute;
    right: 0;
    top: 2.1rem;
}

.probe-section-menu__content form { margin: 0; }

.probe-section-menu__item,
.probe-section-menu__delete {
    background: transparent;
    border: 0;
    border-radius: 6px;
    color: #303935;
    display: block;
    font: inherit;
    font-size: 0.85rem;
    line-height: 1.35;
    padding: 0.45rem 0.6rem;
    text-align: left;
    text-decoration: none;
    white-space: nowrap;
    width: 100%;
}

.probe-section-menu__item:hover { background: #f0ede5; color: #303935; }
.probe-section-menu__delete { color: #b42318; }
.probe-section-menu__delete:hover { background: #fff1ef; }

.probe-item {
    align-items: center;
    display: flex;
    gap: 0.5rem;
    padding: 0.2rem 0.35rem 0.2rem 0.75rem;
}

.probe-item > span {
    min-width: 0;
}

.probe-assignment-user {
    align-items: center;
    display: flex;
    gap: 0.75rem;
    justify-content: space-between;
    padding: 0.6rem 0.75rem;
}

.probe-assignment-user__assigned {
    color: #078358;
    font-size: 0.9rem;
    font-weight: 600;
}

.my-probe-progress {
    align-items: center;
    background: #e7e2d7;
    border-radius: 999px;
    display: flex;
    height: 0.7rem;
    margin: 0.85rem 0;
    overflow: hidden;
    position: relative;
}

.my-probe-progress__bar {
    background: #079b68;
    height: 100%;
    transition: width 180ms ease;
}

.my-probe-progress > span {
    color: #27302b;
    font-size: 0.8rem;
    font-weight: 700;
    left: 0.55rem;
    line-height: 1;
    position: absolute;
}

.my-probe-progress--section {
    height: 0.45rem;
    margin: 0 0 0.7rem;
}

.my-probe-item {
    align-items: flex-start;
    display: flex;
    gap: 0.55rem;
    padding: 0.55rem 0.75rem;
}

.my-probe-item .bi {
    color: #858b87;
}

.my-probe-item--completed {
    background: #e6f5ee;
}

.my-probe-item--completed .bi {
    color: #079b68;
}

.my-probe-item__description {
    background: #fffefa;
    border-left: 3px solid #079b68;
    color: #62666c;
    font-size: 0.9rem;
    margin-top: 0.5rem;
    padding: 0.45rem 0.6rem;
}

.my-probe-item__description strong {
    color: #27302b;
    display: block;
    font-size: 0.78rem;
    margin-bottom: 0.2rem;
}

.my-probe-item__description p {
    margin: 0;
}

.probe-submissions {
    border-top: 1px solid #eeeae2;
    margin-top: 1.5rem;
    padding-top: 1.25rem;
}

.probe-submissions h2 {
    color: #141923;
    font-size: 1.2rem;
    font-weight: 700;
    margin-bottom: 0.75rem;
}

.probe-submissions__heading {
    color: #62666c;
    font-size: 1rem;
    font-weight: 700;
    margin: 1.25rem 0 0.5rem;
}

.probe-submissions__person {
    align-items: center;
    background: #f7f5ef;
    border-radius: 9px;
    color: #27302b;
    display: flex;
    justify-content: space-between;
    margin-top: 0.45rem;
    padding: 0.7rem 0.8rem;
    text-decoration: none;
}

.probe-submissions__person span:last-child {
    color: #62666c;
    font-size: 0.9rem;
}

.probe-submissions__person:hover {
    background: #eeeae2;
    color: #27302b;
}

.probe-completion__cancel {
    background: #fffefa;
    border: 1px solid #d5d1c9;
    color: #62666c;
}

.my-probes-heading {
    color: #141923;
    font-size: 1.2rem;
    font-weight: 700;
    margin: 1.25rem 0 0.75rem;
}

@media (max-width: 575.98px) {
    .probe-submissions__person {
        align-items: flex-start;
        flex-direction: column;
        gap: 0.2rem;
    }

}

.app-form__back {
    background: #f0ede5;
    border-color: #e1dcd1;
    color: #27302b;
}

.app-form__back:hover {
    background: #e7e2d7;
    color: #27302b;
}

.auth-page {
    padding-top: 2rem;
}

.auth-card {
    max-width: 480px;
}

.auth-card__links {
    border-top: 1px solid #e9e4d9;
    display: grid;
    gap: 0.6rem;
    margin-top: 1.5rem;
    padding-top: 1.25rem;
}

.auth-card__links a {
    color: #087c55;
    font-weight: 600;
    text-decoration: none;
}

.auth-card__links a:hover {
    color: #005b3c;
    text-decoration: underline;
}

.user-points-page {
    padding-top: 2rem;
}

.user-points-card {
    background: #fffefa;
    border: 1px solid #eeeae2;
    border-radius: 16px;
    box-shadow: 0 2px 10px rgb(31 42 35 / 7%);
    margin: 0 auto;
    max-width: 640px;
    padding: 1.5rem;
}

.user-points-card h1 {
    color: #141923;
    font-size: 1.55rem;
    font-weight: 700;
    margin: 0 0 1.25rem;
}

.user-points-table {
    --bs-table-bg: transparent;
    --bs-table-striped-bg: #f7f5ef;
    border: 1px solid #e9e4d9;
    border-radius: 10px;
    margin: 0;
    overflow: hidden;
}

.user-points-table > :not(caption) > * > * {
    border-color: #e9e4d9;
    padding: 0.65rem 0.75rem;
}

.user-points-table thead th {
    background: #f0ede5;
    color: #59605b;
    font-size: 0.78rem;
    font-weight: 700;
}

.user-points-table .form-check-input {
    cursor: pointer;
    margin: 0;
}

.user-points-table .form-check-label {
    cursor: pointer;
    font-weight: 600;
}

.periods-page {
    padding-top: 2rem;
}

.periods-card {
    background: #fffefa;
    border: 1px solid #eeeae2;
    border-radius: 16px;
    box-shadow: 0 2px 10px rgb(31 42 35 / 7%);
    margin: 0 auto;
    max-width: 1000px;
    padding: 1.5rem;
}

.periods-card h1 {
    color: #141923;
    font-size: 1.65rem;
    font-weight: 700;
    margin: 0 0 1.25rem;
}

.periods-table {
    --bs-table-bg: transparent;
    --bs-table-striped-bg: #f7f5ef;
    border: 1px solid #e9e4d9;
    border-radius: 10px;
    margin: 0;
    overflow: hidden;
}

.periods-table > :not(caption) > * > * {
    border-color: #e9e4d9;
    padding: 0.65rem 0.75rem;
    vertical-align: middle;
}

.periods-table thead th {
    background: #f0ede5;
    color: #59605b;
    font-size: 0.78rem;
    font-weight: 700;
}

.periods-table__actions {
    display: flex;
    gap: 0.45rem;
    white-space: nowrap;
}

.periods-table__view,
.periods-table__edit,
.periods-table__delete {
    border-radius: 8px;
    font-size: 0.85rem;
    font-weight: 600;
    padding: 0.4rem 0.65rem;
}

.periods-table__view {
    background: #079b68;
    border-color: #079b68;
    color: #fff;
}

.periods-table__view:hover {
    background: #078358;
    color: #fff;
}

.periods-table__edit {
    background: #f0ede5;
    border-color: #e1dcd1;
    color: #27302b;
}

.periods-table__edit:hover {
    background: #e7e2d7;
    color: #27302b;
}

.periods-table__delete {
    background: #fff4f2;
    border-color: #f0c9c2;
    color: #b42318;
}

.periods-table__delete:hover {
    background: #fce3df;
    color: #912018;
}

.periods-table__actions form {
    margin: 0;
}

.periods-list {
    display: grid;
    gap: 0.7rem;
}

.period-card {
    align-items: center;
    background: #f7f5ef;
    border: 1px solid #e9e4d9;
    border-radius: 12px;
    display: flex;
    gap: 1rem;
    justify-content: space-between;
    padding: 0.9rem 1rem;
}

.period-card__info h2 {
    color: #1b2530;
    font-size: 1.05rem;
    font-weight: 700;
    margin: 0 0 0.5rem;
}

.period-card__dates {
    display: flex;
    flex-wrap: wrap;
    gap: 0.9rem;
}

.period-card__date {
    display: grid;
    gap: 0.1rem;
}

.period-card__date span {
    color: #6a6d73;
    font-size: 0.72rem;
}

.period-card__date strong {
    color: #3d4740;
    font-size: 0.85rem;
}

.period-card__actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.45rem;
    justify-content: flex-end;
}

.period-card__actions form {
    margin: 0;
}

.period-show-page {
    padding-top: 2rem;
}

.period-show-card {
    background: #fffefa;
    border: 1px solid #eeeae2;
    border-radius: 16px;
    box-shadow: 0 2px 10px rgb(31 42 35 / 7%);
    margin: 0 auto;
    max-width: 900px;
    padding: 1.5rem;
}

.period-show-card__header {
    align-items: flex-start;
    display: flex;
    gap: 1rem;
    justify-content: space-between;
    margin-bottom: 1.25rem;
}

.period-show-card__header h1 {
    color: #141923;
    font-size: 1.65rem;
    font-weight: 700;
    margin: 0;
}

.period-show-card__header p {
    color: #6a6d73;
    margin: 0.25rem 0 0;
}

.criteria-page {
    padding-top: 2rem;
}

.criteria-card {
    background: #fffefa;
    border: 1px solid #eeeae2;
    border-radius: 16px;
    box-shadow: 0 2px 10px rgb(31 42 35 / 7%);
    margin: 0 auto;
    max-width: 900px;
    padding: 1.5rem;
}

.criteria-card__header {
    align-items: center;
    display: flex;
    gap: 1rem;
    justify-content: space-between;
    margin-bottom: 1.25rem;
}

.criteria-card__header h1 {
    color: #141923;
    font-size: 1.65rem;
    font-weight: 700;
    margin: 0;
}

.criteria-card__new {
    align-items: center;
    background: #079b68;
    border-color: #079b68;
    border-radius: 10px;
    color: #fff;
    display: inline-flex;
    font-weight: 600;
    gap: 0.4rem;
    padding: 0.6rem 0.85rem;
}

.criteria-card__new:hover {
    background: #078358;
    color: #fff;
}

.criteria-table {
    --bs-table-bg: transparent;
    --bs-table-striped-bg: #f7f5ef;
    border: 1px solid #e9e4d9;
    border-radius: 10px;
    margin: 0;
    overflow: hidden;
}

.criteria-table > :not(caption) > * > * {
    border-color: #e9e4d9;
    padding: 0.65rem 0.75rem;
    vertical-align: middle;
}

.criteria-table thead th {
    background: #f0ede5;
    color: #59605b;
    font-size: 0.78rem;
    font-weight: 700;
}

.criteria-table td:last-child {
    white-space: nowrap;
}

.criteria-table td:last-child form {
    display: inline;
    margin: 0;
}

.criteria-table__edit,
.criteria-table__delete {
    border-radius: 8px;
    font-size: 0.85rem;
    font-weight: 600;
    padding: 0.4rem 0.65rem;
}

.criteria-table__edit {
    background: #f0ede5;
    border-color: #e1dcd1;
    color: #27302b;
    margin-right: 0.35rem;
}

.criteria-table__edit:hover {
    background: #e7e2d7;
    color: #27302b;
}

.criteria-table__delete {
    background: #fff4f2;
    border-color: #f0c9c2;
    color: #b42318;
}

.criteria-table__delete:hover {
    background: #fce3df;
    color: #912018;
}

.criteria-list {
    display: grid;
    gap: 0.7rem;
}

.criteria-item {
    align-items: center;
    background: #f7f5ef;
    border: 1px solid #e9e4d9;
    border-radius: 12px;
    display: flex;
    gap: 1rem;
    justify-content: space-between;
    padding: 0.8rem 1rem;
}

.criteria-item__info h2 {
    color: #1b2530;
    font-size: 1.05rem;
    font-weight: 700;
    margin: 0 0 0.4rem;
}

.criteria-item__meta {
    display: flex;
    flex-wrap: wrap;
    gap: 0.45rem;
}

.criteria-item__score,
.criteria-item__access {
    border-radius: 999px;
    font-size: 0.78rem;
    font-weight: 600;
    padding: 0.25rem 0.5rem;
}

.criteria-item__score {
    background: #e7f3ed;
    color: #006e4b;
}

.criteria-item__access {
    background: #f0ede5;
    color: #665d50;
}

.criteria-item__actions {
    display: flex;
    gap: 0.45rem;
}

.criteria-item__actions form {
    margin: 0;
}

.users-page {
    padding-top: 2rem;
}

.users-card {
    background: #fffefa;
    border: 1px solid #eeeae2;
    border-radius: 16px;
    box-shadow: 0 2px 10px rgb(31 42 35 / 7%);
    margin: 0 auto;
    max-width: 900px;
    padding: 1.5rem;
}

.users-card__header {
    align-items: center;
    display: flex;
    gap: 1rem;
    justify-content: space-between;
    margin-bottom: 1.25rem;
}

.users-card__header h1 {
    color: #141923;
    font-size: 1.65rem;
    font-weight: 700;
    margin: 0;
}

.users-card__new {
    align-items: center;
    background: #079b68;
    border-color: #079b68;
    border-radius: 10px;
    color: #fff;
    display: inline-flex;
    font-weight: 600;
    gap: 0.4rem;
    padding: 0.6rem 0.85rem;
}

.users-card__new:hover {
    background: #078358;
    color: #fff;
}

.users-list {
    display: grid;
    gap: 0.7rem;
}

.user-card {
    align-items: center;
    background: #f7f5ef;
    border: 1px solid #e9e4d9;
    border-radius: 12px;
    display: flex;
    gap: 1rem;
    justify-content: space-between;
    padding: 0.8rem 1rem;
}

.user-card__info h2 {
    color: #1b2530;
    font-size: 1.05rem;
    font-weight: 700;
    margin: 0;
}

.user-card__info p {
    color: #6a6d73;
    font-size: 0.85rem;
    margin: 0.2rem 0 0.45rem;
}

.user-card__meta {
    display: flex;
    flex-wrap: wrap;
    gap: 0.45rem;
}

.user-card__role,
.user-card__unit {
    border-radius: 999px;
    font-size: 0.78rem;
    font-weight: 600;
    padding: 0.25rem 0.5rem;
}

.user-card__role {
    background: #e7f3ed;
    color: #006e4b;
}

.user-card__unit {
    background: #fff4d6;
    border: 1px solid #f0d787;
    color: #755b0b;
}

.user-card__unit .bi {
    margin-right: 0.2rem;
}

.user-card__actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.45rem;
    justify-content: flex-end;
}

.user-card__actions form {
    margin: 0;
}

.user-card__edit,
.user-card__delete {
    border-radius: 8px;
    font-size: 0.85rem;
    font-weight: 600;
    padding: 0.4rem 0.65rem;
}

.user-card__edit {
    background: #f0ede5;
    border-color: #e1dcd1;
    color: #27302b;
}

.user-card__edit:hover {
    background: #e7e2d7;
    color: #27302b;
}

.user-card__delete {
    background: #fff4f2;
    border-color: #f0c9c2;
    color: #b42318;
}

.user-card__delete:hover {
    background: #fce3df;
    color: #912018;
}

.users-hero {
    background: #fcfbf6;
    min-height: 205px;
    overflow: hidden;
    padding: 2rem clamp(2rem, 5vw, 5rem);
    position: relative;
}

.users-hero__content {
    position: relative;
    z-index: 1;
}

.users-hero h1 {
    color: #101626;
    font-size: clamp(1.9rem, 3vw, 3rem);
    font-weight: 800;
    letter-spacing: -0.04em;
    margin: 0 0 1.5rem;
}

.users-hero__new {
    align-items: center;
    background: #079b68;
    border-color: #079b68;
    border-radius: 12px;
    box-shadow: 0 3px 7px rgb(0 0 0 / 15%);
    color: #fff;
    display: inline-flex;
    font-size: 1.15rem;
    font-weight: 600;
    gap: 0.4rem;
    padding: 0.85rem 1.5rem;
}

.users-hero__new:hover {
    background: #078358;
    color: #fff;
}

.users-hero__image {
    bottom: 0;
    height: 100%;
    object-fit: contain;
    object-position: right bottom;
    position: absolute;
    right: 0;
    width: min(62%, 760px);
}

.users-page {
    max-width: 1320px;
    padding-top: 1.5rem;
}

.users-card {
    background: transparent;
    border: 0;
    box-shadow: none;
    max-width: none;
    padding: 0;
}

.users-filter-bar {
    align-items: center;
    background: #fffefa;
    border: 1px solid #eeeae2;
    border-radius: 14px;
    box-shadow: 0 2px 8px rgb(31 42 35 / 6%);
    display: grid;
    gap: 0.75rem;
    grid-template-columns: minmax(260px, 1fr) minmax(190px, 0.35fr) minmax(190px, 0.35fr);
    margin-bottom: 1rem;
    padding: 0.75rem;
}

.users-filter-bar__search {
    align-items: center;
    display: flex;
    position: relative;
}

.users-filter-bar__search .bi {
    color: #6a6d73;
    left: 0.8rem;
    position: absolute;
}

.users-filter-bar__search .form-control {
    padding-left: 2.35rem;
}

.users-filter-bar .form-control,
.users-filter-bar .form-select {
    border-color: #dcded8;
    border-radius: 9px;
    min-height: 42px;
}

.users-list {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 0.9rem;
}

.user-card {
    align-items: stretch;
    background: #fff;
    flex-direction: column;
    justify-content: center;
    min-height: 130px;
    padding: 1rem;
    position: relative;
}

.users-list {
    align-items: start;
}

.user-card__menu {
    position: absolute;
    right: 0.6rem;
    top: 0.55rem;
}

.user-card__menu summary {
    color: #59605b;
    cursor: pointer;
    font-size: 1.2rem;
    line-height: 1;
    list-style: none;
    padding: 0.25rem;
}

.user-card__menu summary::-webkit-details-marker {
    display: none;
}

.user-card__menu-content {
    background: #fff;
    border: 1px solid #eeeae2;
    border-radius: 9px;
    box-shadow: 0 5px 14px rgb(31 42 35 / 14%);
    padding: 0.25rem;
    position: absolute;
    right: 0;
    top: 1.9rem;
    z-index: 2;
}

.user-card__menu-content form {
    margin: 0;
}

.user-card__menu-item,
.user-card__menu-delete {
    display: block;
    width: 100%;
}

.user-card__menu-item {
    border-radius: 6px;
    color: #303935;
    font-size: 0.85rem;
    padding: 0.4rem 0.55rem;
    text-decoration: none;
    white-space: nowrap;
}

.user-card__menu-item:hover {
    background: #f0ede5;
    color: #303935;
}

.user-card__menu-item .bi,
.user-card__menu-delete .bi {
    margin-right: 0.35rem;
}

.user-card__menu-delete {
    background: transparent;
    border: 0;
    border-radius: 6px;
    color: #b42318;
    font-size: 0.85rem;
    padding: 0.4rem 0.55rem;
    white-space: nowrap;
}

.user-card__menu-delete:hover {
    background: #fff4f2;
}

.users-filter-bar__empty {
    color: #6a6d73;
    margin: 1rem 0 0;
    text-align: center;
}

@media (max-width: 991.98px) {
    .users-list {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .users-filter-bar {
        grid-template-columns: 1fr 1fr;
    }

    .users-filter-bar__search {
        grid-column: 1 / -1;
    }
}

@media (max-width: 575.98px) {
    .users-hero {
        min-height: 185px;
        padding: 1.25rem;
    }

    .users-hero__image {
        opacity: 0.35;
        width: 100%;
    }

    .users-hero__new {
        width: 100%;
    }

    .users-filter-bar,
    .users-list {
        grid-template-columns: 1fr;
    }

    .users-filter-bar__search {
        grid-column: auto;
    }
}

.events-page {
    max-width: 1320px;
    padding-top: 2rem;
}

.polls-list {
    display: grid;
    gap: 1rem;
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.poll-card {
    background: #fffefa;
    border: 1px solid #e8e4d9;
    border-radius: 16px;
    box-shadow: 0 2px 10px rgb(31 42 35 / 7%);
    display: flex;
    flex-direction: column;
    min-height: 220px;
    padding: 1.5rem;
}

.poll-card__header {
    align-items: flex-start;
    display: flex;
    gap: 1rem;
    justify-content: space-between;
}

.poll-card h2 {
    color: #18221d;
    font-size: 1.25rem;
    font-weight: 700;
    line-height: 1.3;
    margin: 0;
}

.poll-card__status {
    align-items: center;
    border-radius: 999px;
    display: inline-flex;
    flex: 0 0 auto;
    font-size: 0.78rem;
    font-weight: 700;
    justify-content: center;
    line-height: 1;
    min-height: 32px;
    padding: 0.45rem 0.75rem;
    text-align: center;
}

.poll-card__status--draft {
    background: #f0ede5;
    color: #5e655f;
}

.poll-card__status--active {
    background: #ddf3e9;
    color: #08774f;
}

.poll-card__status--archived {
    background: #e8ecea;
    color: #46534a;
}

.poll-card__description {
    color: #626a64;
    margin: 0.8rem 0 0;
}

.poll-card__meta {
    color: #58635b;
    display: flex;
    flex-wrap: wrap;
    font-size: 0.9rem;
    gap: 0.75rem 1.1rem;
    margin: 1rem 0;
}

.poll-card__meta span {
    align-items: center;
    display: inline-flex;
    gap: 0.35rem;
}

.poll-card__actions {
    align-items: center;
    display: flex;
    flex-wrap: wrap;
    gap: 0.65rem;
    margin-top: auto;
}

.poll-card__actions form {
    margin: 0;
}

@media (min-width: 768px) {
    .poll-card__actions > .btn,
    .poll-card__actions > form {
        flex: 0 0 calc(50% - 0.325rem);
        max-width: calc(50% - 0.325rem);
    }

    .poll-card__actions > :only-child {
        flex-basis: 100%;
        max-width: 100%;
    }

    .poll-card__actions form .btn {
        width: 100%;
    }
}

.poll-card__open {
    background: #079b68;
    border-color: #079b68;
    border-radius: 10px;
    color: #fff;
    font-weight: 600;
    padding: 0.6rem 1rem;
}

.poll-card__open:hover {
    background: #078358;
    border-color: #078358;
    color: #fff;
}

.poll-card__delete {
    background: #fff4f2;
    border-color: #f0c9c2;
    border-radius: 10px;
    color: #b42318;
    font-weight: 600;
    padding: 0.6rem 1rem;
}

.poll-card__delete:hover {
    background: #fce3df;
    border-color: #e5aea5;
    color: #912018;
}

.poll-show-page {
    padding-top: 2rem;
}

.poll-show-card {
    background: #fffefa;
    border: 1px solid #eeeae2;
    border-radius: 16px;
    box-shadow: 0 2px 10px rgb(31 42 35 / 7%);
    margin: 0 auto 2rem;
    max-width: 640px;
    padding: 1.75rem;
}

.poll-show-card__header {
    align-items: flex-start;
    display: flex;
    gap: 1rem;
    justify-content: space-between;
}

.poll-show-card h1 {
    color: #141923;
    font-size: 1.65rem;
    font-weight: 700;
    margin: 0 0 0.55rem;
}

.poll-show-card__details {
    border-top: 1px solid #e9e4d9;
    color: #46534a;
    margin-top: 1.25rem;
    padding-top: 1rem;
}

.poll-show-card__details p {
    margin-bottom: 0.45rem;
}

.poll-show-card__actions {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    margin: 1.4rem 0;
}

.poll-show-card__actions form {
    margin: 0;
}

.poll-vote,
.poll-results {
    border-top: 1px solid #e9e4d9;
    margin-top: 1.4rem;
    padding-top: 1.25rem;
}

.poll-show-card__notice {
    background: #edf6f1;
    border-radius: 10px;
    color: #38604d;
    margin: 1.4rem 0;
    padding: 0.85rem 1rem;
}

.poll-results-summary {
    background: linear-gradient(135deg, #eef7f1, #f8f5ed);
    border: 1px solid #d9e8dc;
    border-radius: 14px;
    margin-bottom: 1.5rem;
    overflow: hidden;
}

.poll-results-summary__total {
    padding: 1.1rem 1.25rem 0.9rem;
    text-align: center;
}

.poll-results-summary__eyebrow {
    align-items: center;
    color: #4e6657;
    display: flex;
    font-size: 0.85rem;
    font-weight: 700;
    gap: 0.4rem;
    justify-content: center;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.poll-results-summary__total strong {
    color: #145a38;
    display: block;
    font-size: 2.7rem;
    font-variant-numeric: tabular-nums;
    line-height: 1.1;
    margin-top: 0.25rem;
}

.poll-results-summary__breakdown {
    background: rgb(255 255 255 / 55%);
    border-top: 1px solid #d9e8dc;
    display: grid;
    grid-template-columns: repeat(2, 1fr);
}

.poll-results-summary__metric {
    align-items: center;
    display: grid;
    gap: 0.15rem 0.5rem;
    grid-template-columns: auto 1fr auto;
    padding: 0.8rem 0.9rem;
}

.poll-results-summary__metric + .poll-results-summary__metric {
    border-left: 1px solid #d9e8dc;
}

.poll-results-summary__metric i {
    font-size: 1.15rem;
    grid-row: span 2;
}

.poll-results-summary__metric span {
    color: #53635a;
    font-size: 0.78rem;
}

.poll-results-summary__metric strong {
    font-size: 1.35rem;
    grid-column: 2;
    line-height: 1;
}

.poll-results-summary__metric--decisive i,
.poll-results-summary__metric--decisive strong {
    color: #187344;
}

.poll-results-summary__metric--advisory i,
.poll-results-summary__metric--advisory strong {
    color: #6a5a83;
}

@media (max-width: 420px) {
    .poll-results-summary__breakdown {
        grid-template-columns: 1fr;
    }

    .poll-results-summary__metric + .poll-results-summary__metric {
        border-left: 0;
        border-top: 1px solid #d9e8dc;
    }
}

.poll-show-card > .app-form__back {
    margin-top: 1.5rem;
}

.calendar-page,
.calendar-event-form-page,
.calendar-event-page {
    max-width: 1320px;
    padding-top: 2rem;
}

.calendar-management {
    background: #fffefa;
    border: 1px solid #e8e4d9;
    border-radius: 14px;
    margin-bottom: 1.25rem;
    padding: 0.9rem 1.1rem;
}

.calendar-management summary {
    color: #005b3c;
    cursor: pointer;
    font-weight: 700;
}

.calendar-management__content {
    align-items: end;
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-top: 1rem;
}

.calendar-source-form {
    align-items: end;
    display: flex;
    flex: 1 1 560px;
    flex-wrap: wrap;
    gap: 0.65rem;
}

.calendar-source-form .form-label {
    flex-basis: 100%;
    margin: 0;
}

.calendar-source-form .form-control {
    flex: 1 1 280px;
}

.calendar-management__synced {
    color: #6a6d73;
    flex-basis: 100%;
    font-size: 0.85rem;
    margin: 0;
}

.calendar-toolbar {
    align-items: center;
    display: flex;
    justify-content: space-between;
    margin-bottom: 1rem;
}

.calendar-toolbar h2 {
    color: #1b2530;
    font-size: 1.4rem;
    font-weight: 800;
    margin: 0;
}

.calendar-toolbar__button {
    background: #fffefa;
    border: 1px solid #e8e4d9;
    border-radius: 9px;
    color: #005b3c;
    font-size: 1.25rem;
    line-height: 1;
    min-width: 42px;
}

.calendar-grid {
    background: #e8e4d9;
    border: 1px solid #e8e4d9;
    display: grid;
    gap: 1px;
    grid-template-columns: repeat(7, minmax(0, 1fr));
}

.calendar-grid__weekday {
    background: #f5f2e9;
    color: #526058;
    font-size: 0.8rem;
    font-weight: 700;
    padding: 0.6rem;
    text-align: center;
}

.calendar-grid__day {
    background: #fffefa;
    min-height: 130px;
    padding: 0.45rem;
}

.calendar-grid__day--outside {
    background: #f7f5ef;
}

.calendar-grid__day--today .calendar-grid__date {
    background: #087457;
    border-radius: 999px;
    color: #fff;
}

.calendar-grid__date {
    color: #38453c;
    display: inline-flex;
    font-size: 0.82rem;
    font-weight: 700;
    height: 25px;
    justify-content: center;
    min-width: 25px;
    padding-top: 0.25rem;
}

.calendar-grid__event {
    background: #ddf3e9;
    border-radius: 5px;
    color: #075b3e;
    display: block;
    font-size: 0.78rem;
    font-weight: 600;
    margin-top: 0.3rem;
    overflow: hidden;
    padding: 0.3rem 0.4rem;
    text-decoration: none;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.calendar-grid__event:hover {
    background: #bde7d2;
    color: #00442e;
}

.calendar-agenda {
    display: none;
}

.calendar-event-card {
    background: #fffefa;
    border: 1px solid #e8e4d9;
    border-radius: 16px;
    margin: 0 auto;
    max-width: 720px;
    padding: 1.5rem;
}

.calendar-event-card__header {
    align-items: flex-start;
    display: flex;
    gap: 1rem;
    justify-content: space-between;
}

.calendar-event-card h1 {
    color: #18221d;
    font-size: 1.7rem;
    font-weight: 800;
    margin: 0;
}

.calendar-event-card__header p,
.calendar-event-card__note {
    color: #647068;
    margin: 0.4rem 0 1.25rem;
}

.calendar-event-card__description {
    border-top: 1px solid #e8e4d9;
    margin-top: 1.25rem;
    padding-top: 1.25rem;
}

.calendar-event-card__menu {
    position: relative;
}

.calendar-event-card__menu summary {
    color: #005b3c;
    cursor: pointer;
    font-size: 1.25rem;
    list-style: none;
}

.calendar-event-card__menu summary::-webkit-details-marker {
    display: none;
}

.calendar-event-card__menu-content {
    background: #fff;
    border: 1px solid #e8e4d9;
    border-radius: 9px;
    box-shadow: 0 5px 14px rgb(0 0 0 / 12%);
    min-width: 150px;
    padding: 0.35rem;
    position: absolute;
    right: 0;
    top: 1.9rem;
    z-index: 5;
}

.calendar-event-card__menu-item,
.calendar-event-card__menu-delete {
    background: transparent;
    border: 0;
    border-radius: 6px;
    color: #243029;
    display: block;
    font: inherit;
    padding: 0.45rem 0.6rem;
    text-align: left;
    text-decoration: none;
    width: 100%;
}

.calendar-event-card__menu-delete {
    color: #b42318;
}

@media (max-width: 767.98px) {
    .calendar-page,
    .calendar-event-form-page,
    .calendar-event-page {
        padding-top: 1.25rem;
    }

    .calendar-grid {
        display: none;
    }

    .calendar-agenda {
        display: grid;
        gap: 1rem;
    }

    .calendar-agenda__day {
        background: #fffefa;
        border: 1px solid #e8e4d9;
        border-radius: 12px;
        overflow: hidden;
    }

    .calendar-agenda__day h2 {
        background: #f5f2e9;
        color: #314138;
        font-size: 0.95rem;
        font-weight: 800;
        margin: 0;
        padding: 0.7rem 0.9rem;
    }

    .calendar-agenda__event {
        border-top: 1px solid #eeeae2;
        color: #1b2530;
        display: grid;
        gap: 0.2rem;
        padding: 0.75rem 0.9rem;
        text-decoration: none;
    }

    .calendar-agenda__event span,
    .calendar-agenda__event small,
    .calendar-agenda__empty {
        color: #647068;
    }

    .calendar-source-form,
    .calendar-source-form .form-control {
        flex-basis: 100%;
    }
}

@media (max-width: 767.98px) {
    .polls-list {
        grid-template-columns: 1fr;
    }
}

.events-card {
    background: transparent;
    border: 0;
    box-shadow: none;
    max-width: none;
    padding: 0;
}

.events-card__header {
    align-items: center;
    display: flex;
    gap: 1rem;
    justify-content: space-between;
    margin-bottom: 1.25rem;
}

.events-card__header h1 {
    color: #141923;
    font-size: 1.65rem;
    font-weight: 700;
    margin: 0;
}

.events-card__new {
    align-items: center;
    background: #079b68;
    border-color: #079b68;
    border-radius: 10px;
    color: #fff;
    display: inline-flex;
    font-weight: 600;
    gap: 0.4rem;
    padding: 0.6rem 0.85rem;
}

.events-card__new:hover {
    background: #078358;
    color: #fff;
}

.events-hero {
    background: #fcfbf6;
    min-height: 205px;
    overflow: hidden;
    padding: 2rem clamp(2rem, 5vw, 5rem);
    position: relative;
}

.events-hero__content {
    position: relative;
    z-index: 1;
}

.events-hero h1 {
    color: #101626;
    font-size: clamp(1.9rem, 3vw, 3rem);
    font-weight: 800;
    letter-spacing: -0.04em;
    margin: 0 0 1.5rem;
}

.events-hero__new {
    align-items: center;
    background: #079b68;
    border-color: #079b68;
    border-radius: 12px;
    box-shadow: 0 3px 7px rgb(0 0 0 / 15%);
    color: #fff;
    display: inline-flex;
    font-size: 1.15rem;
    font-weight: 600;
    gap: 0.4rem;
    padding: 0.85rem 1.5rem;
}

.events-hero__new:hover {
    background: #078358;
    color: #fff;
}

.events-hero__image {
    bottom: 0;
    height: 100%;
    object-fit: contain;
    object-position: right bottom;
    position: absolute;
    right: 0;
    width: min(62%, 760px);
}

.events-list {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 0.9rem;
}

.events-filter-bar {
    align-items: center;
    background: #fffefa;
    border: 1px solid #eeeae2;
    border-radius: 14px;
    box-shadow: 0 2px 8px rgb(31 42 35 / 6%);
    display: grid;
    gap: 0.75rem;
    grid-template-columns: minmax(260px, 1fr) minmax(190px, 0.35fr) minmax(190px, 0.35fr);
    margin-bottom: 1rem;
    padding: 0.75rem;
}

.events-filter-bar__search {
    align-items: center;
    display: flex;
    position: relative;
}

.events-filter-bar__search .bi {
    color: #6a6d73;
    left: 0.8rem;
    position: absolute;
}

.events-filter-bar__search .form-control {
    padding-left: 2.35rem;
}

.events-filter-bar .form-control,
.events-filter-bar .form-select {
    border-color: #dcded8;
    border-radius: 9px;
    min-height: 42px;
}

.events-filter-bar__empty {
    color: #6a6d73;
    margin: 1rem 0 0;
    text-align: center;
}

.event-card {
    align-items: stretch;
    background: #fff;
    border: 1px solid #e9e4d9;
    border-radius: 12px;
    display: grid;
    gap: 1.25rem;
    grid-template-columns: 92px minmax(0, 1fr) 32px;
    padding: 1.15rem;
}

.event-card__date-column {
    align-items: center;
    align-self: start;
    display: flex;
    flex-direction: column;
}

.event-card__date-block {
    align-items: center;
    background: #fff;
    border: 2px solid #079b68;
    border-radius: 10px;
    color: #006e4b;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 0.55rem 0.45rem;
    width: 100%;
}

.event-card__date-block .bi {
    font-size: 0.9rem;
    margin-bottom: 0.2rem;
}

.event-card__date-block strong {
    font-size: 1.8rem;
    line-height: 1;
}

.event-card__date-block span {
    font-size: 0.75rem;
    font-weight: 700;
    margin-top: 0.25rem;
}

.event-card__calendar {
    align-items: center;
    background: #e7f3ed;
    border: 1px solid #c7e5d8;
    border-radius: 10px;
    color: #006e4b;
    display: inline-flex;
    flex-direction: row;
    font-size: 0.95rem;
    gap: 0.2rem;
    margin-bottom: 0.65rem;
    max-width: 100%;
    padding: 0.4rem 0.55rem;
    width: fit-content;
}

.event-card__calendar .bi {
    font-size: 1.1rem;
}

.event-card__info h2 {
    color: #1b2530;
    font-size: 1.05rem;
    font-weight: 700;
    margin: 0 0 0.7rem;
}

.event-card__meta {
    display: flex;
    flex-wrap: wrap;
    gap: 0.6rem;
}

.event-card__meta span {
    border-radius: 999px;
    font-size: 0.78rem;
    font-weight: 600;
    padding: 0.25rem 0.5rem;
}

.event-card__criteria {
    background: transparent;
    color: #665d50;
}

.event-card__score {
    align-items: baseline;
    background: transparent;
    color: #006e4b;
    display: inline-flex;
    gap: 0.2rem;
    margin-top: 0.55rem;
    padding: 0 !important;
}

.event-card__score strong {
    font-size: 1.15rem;
    line-height: 1;
}

.event-card__unit {
    background: #fff4d6;
    border: 1px solid #f0d787;
    color: #755b0b;
}

.event-card__unit .bi {
    margin-right: 0.2rem;
}

.event-card__actions {
    display: flex;
    gap: 0.45rem;
    margin-top: auto;
}

.event-card__actions form {
    margin: 0;
}

.event-card__menu {
    grid-column: 3;
    grid-row: 1;
    position: relative;
}

.event-card__menu summary {
    align-items: center;
    background: transparent;
    border: 0;
    color: #59605b;
    cursor: pointer;
    display: flex;
    font-size: 1.2rem;
    height: 32px;
    justify-content: center;
    line-height: 1;
    list-style: none;
    padding: 0.25rem;
    width: 32px;
}

.event-card__menu summary::-webkit-details-marker {
    display: none;
}

.event-card__menu-content {
    background: #fff;
    border: 1px solid #eeeae2;
    border-radius: 9px;
    box-shadow: 0 5px 14px rgb(31 42 35 / 14%);
    padding: 0.25rem;
    position: absolute;
    right: 0;
    top: 1.9rem;
    z-index: 2;
}

.event-card__menu-content form {
    margin: 0;
}

.event-card__menu-item,
.event-card__menu-delete {
    display: block;
    width: 100%;
}

.event-card__menu-item {
    border-radius: 6px;
    color: #303935;
    font-size: 0.85rem;
    padding: 0.4rem 0.55rem;
    text-decoration: none;
    white-space: nowrap;
}

.event-card__menu-item:hover {
    background: #f0ede5;
    color: #303935;
}

.event-card__menu-delete {
    background: transparent;
    border: 0;
    border-radius: 6px;
    color: #b42318;
    font-size: 0.85rem;
    padding: 0.4rem 0.55rem;
    white-space: nowrap;
}

.event-card__menu-delete:hover {
    background: #fff4f2;
}

.event-card__menu-item .bi,
.event-card__menu-delete .bi {
    margin-right: 0.35rem;
}

.event-card__edit,
.event-card__delete {
    border-radius: 8px;
    font-size: 0.85rem;
    font-weight: 600;
    padding: 0.4rem 0.65rem;
}

.event-card__edit {
    background: #f0ede5;
    border-color: #e1dcd1;
    color: #27302b;
}

.event-card__edit:hover {
    background: #e7e2d7;
    color: #27302b;
}

.event-card__delete {
    background: #fff4f2;
    border-color: #f0c9c2;
    color: #b42318;
}

.event-card__delete:hover {
    background: #fce3df;
    color: #912018;
}

@media (max-width: 991.98px) {
    .events-list {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .events-filter-bar {
        grid-template-columns: 1fr 1fr;
    }

    .events-filter-bar__search {
        grid-column: 1 / -1;
    }
}

@media (max-width: 575.98px) {
    .events-hero {
        min-height: 185px;
        padding: 1.25rem;
    }

    .events-hero__image {
        opacity: 0.35;
        width: 100%;
    }

    .events-hero__new {
        width: 100%;
    }

    .events-card {
        padding: 1rem;
    }

    .events-filter-bar {
        grid-template-columns: 1fr;
    }

    .events-filter-bar__search {
        grid-column: auto;
    }

    .events-list {
        grid-template-columns: 1fr;
    }

    .events-card__header {
        align-items: stretch;
        flex-direction: column;
    }

    .events-card__new,
    .event-card__actions .btn,
    .event-card__actions form {
        width: 100%;
    }

    .event-card {
        align-items: stretch;
    }

    .event-card__calendar {
        align-self: flex-start;
        flex-direction: row;
    }

    .event-card__actions {
        flex-direction: column;
    }
}

@media (max-width: 575.98px) {
    .users-card {
        padding: 1rem;
    }

    .users-card__header {
        align-items: stretch;
        flex-direction: column;
    }

    .users-card__new,
    .user-card__actions .btn,
    .user-card__actions form {
        width: 100%;
    }

    .user-card {
        align-items: stretch;
        flex-direction: column;
    }

    .user-card__actions {
        flex-direction: column;
    }
}

@media (max-width: 575.98px) {
    .criteria-card {
        padding: 1rem;
    }

    .criteria-card__header {
        align-items: stretch;
        flex-direction: column;
    }

    .criteria-card__new,
    .criteria-item__actions .btn,
    .criteria-item__actions form {
        width: 100%;
    }

    .criteria-item {
        align-items: stretch;
        flex-direction: column;
    }

    .criteria-item__actions {
        flex-direction: column;
    }
}

.period-units-list {
    display: grid;
    gap: 0.7rem;
}

.period-unit-card {
    background: #fffefa;
    border: 1px solid #eeeae2;
    border-radius: 12px;
    overflow: hidden;
}

.period-unit-card__summary {
    align-items: center;
    display: flex;
    gap: 0.75rem;
    min-height: 70px;
    padding: 0.65rem 1rem;
}

.period-unit-card__details {
    border-top: 1px solid #eeeae2;
    padding: 0.7rem 1rem;
}

@media (max-width: 575.98px) {
    .period-show-card {
        padding: 1rem;
    }

    .period-show-card__header {
        align-items: stretch;
        flex-direction: column;
    }

    .period-show-card__header .btn {
        width: 100%;
    }
}

.app-modal {
    inset: 0;
    position: fixed;
    z-index: 1100;
}

.app-modal__backdrop {
    background: rgb(15 24 20 / 45%);
    inset: 0;
    position: absolute;
}

.app-modal__dialog {
    background: #fffefa;
    border: 1px solid #eeeae2;
    border-radius: 16px;
    box-shadow: 0 16px 40px rgb(15 24 20 / 25%);
    left: 50%;
    max-width: 430px;
    padding: 1.5rem;
    position: absolute;
    top: 50%;
    transform: translate(-50%, -50%);
    width: calc(100% - 2rem);
}

.app-modal__dialog h2 {
    color: #1b2530;
    font-size: 1.35rem;
    font-weight: 700;
    margin: 0 0 0.65rem;
}

.app-modal__dialog p {
    color: #62666c;
    margin: 0;
}

.app-modal__actions {
    display: flex;
    gap: 0.65rem;
    justify-content: flex-end;
    margin-top: 1.4rem;
}

.app-modal__actions .btn {
    font-size: 0.85rem;
    padding: 0.4rem 0.65rem;
}

.app-modal__confirm {
    background: #079b68;
    border-color: #079b68;
    color: #fff;
}

.app-modal__confirm:hover {
    background: #078358;
    border-color: #078358;
    color: #fff;
}

@media (max-width: 575.98px) {
    .periods-card {
        padding: 1rem;
    }

    .periods-table th:nth-child(2),
    .periods-table td:nth-child(2),
    .periods-table th:nth-child(3),
    .periods-table td:nth-child(3),
    .periods-table th:nth-child(4),
    .periods-table td:nth-child(4) {
        display: none;
    }

    .periods-table__actions {
        align-items: stretch;
        flex-direction: column;
    }

    .periods-table__actions .btn,
    .periods-table__actions form {
        width: 100%;
    }

    .period-card {
        align-items: stretch;
        flex-direction: column;
    }

    .period-card__dates {
        justify-content: space-between;
    }

    .period-card__actions {
        align-items: stretch;
        flex-direction: column;
    }

    .period-card__actions .btn,
    .period-card__actions form {
        width: 100%;
    }
}

.periods-card__empty {
    color: #6a6d73;
    margin: 0;
}

@media (max-width: 991.98px) {
    .navbar {
        min-height: auto;
        padding: 0.45rem 1rem;
    }

    .navbar-toggler {
        border-color: rgb(255 255 255 / 75%);
    }

    .navbar .navbar-nav {
        align-items: stretch;
        gap: 0;
    }

    .navbar .nav-link {
        padding: 0.55rem 0.85rem;
    }

    .navbar-collapse {
        margin-top: 0.55rem;
    }

    .navbar-collapse .navbar-nav:first-child {
        padding-top: 0.35rem;
    }

    .global-dashboard-hero {
        min-height: 185px;
        padding: 1.25rem;
    }

    .global-dashboard-hero__image {
        opacity: 0.38;
        width: 100%;
    }

    .global-dashboard-hero__actions {
        align-items: stretch;
        flex-direction: column;
    }

    .global-dashboard-hero__actions form,
    .global-dashboard-hero__actions .btn {
        width: 100%;
    }

    .unit-card__summary {
        align-items: flex-start;
        flex-wrap: wrap;
        min-height: 0;
        padding: 0.75rem 1rem;
    }

    .unit-card__info {
        flex: 1;
        min-width: 0;
    }

    .unit-card__info h2 {
        font-size: 1.05rem;
    }

    .unit-card__actions {
        flex-basis: 100%;
        display: grid;
        gap: 0.55rem;
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .unit-card__button {
        font-size: 0.8rem;
        gap: 0.25rem;
        line-height: 1.2;
        min-height: 64px;
        min-width: 0;
        padding: 0.5rem 0.35rem;
        white-space: normal;
        width: 100%;
    }

    .unit-card__details {
        padding: 0.75rem 1.25rem;
    }
}

/* Custom button colors matching navbar theme */
.btn-primary {
    background-color: #af9b84;
    border-color: #af9b84;
    color: white;
}

.btn-primary:hover {
    background-color: #8f7b64;
    border-color: #8f7b64;
}

.btn-warning {
    background-color: #F2E318;
    border-color: #F2E318;
    color: #333;
}

.btn-warning:hover {
    background-color: #d2c316;
    border-color: #d2c316;
}

.btn-success {
    background-color: #179767;
    border-color: #179767;
}

.btn-success:hover {
    background-color: #147a55;
    border-color: #147a55;
}

.btn-info {
    background-color: #af9b84;
    border-color: #af9b84;
    opacity: 0.8;
}

.btn-info:hover {
    background-color: #8f7b64;
    border-color: #8f7b64;
    opacity: 1;
}
