/* app_v2.css — Custom styles untuk Pendaftaran Atlet KONI */

/* Kartu header warna-warni agar lebih tegas */
.card-header h6 {
    font-weight: 600;
    letter-spacing: 0.3px;
}

/* Tabel: baris hover lebih jelas */
.table-hover tbody tr:hover {
    background-color: rgba(13, 110, 253, 0.06);
}

/* Badge status */
.badge {
    font-size: 0.78em;
    padding: 0.4em 0.7em;
}

/* Form labels tebal */
.form-label {
    font-weight: 500;
    font-size: 0.9rem;
}

/* Warna latar body sedikit abu-abu */
body {
    background-color: #f5f7fa;
    padding-bottom: 100px;
}

body.has-admin-sidebar {
    min-height: 100vh;
    padding-bottom: 0;
    overflow-x: hidden;
    background: #f3f6fa;
}

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

.app-sidebar {
    --bs-offcanvas-width: 252px;
    color: #dbe8ff;
    background: linear-gradient(180deg, #092f63 0%, #071d3e 100%);
    border-right: 0;
}

.app-sidebar-header {
    min-height: 72px;
    padding: 0.85rem 1rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.app-sidebar-brand {
    display: flex;
    gap: 0.7rem;
    align-items: center;
    min-width: 0;
    color: #fff;
    text-decoration: none;
}

.app-sidebar-brand > span:last-child {
    min-width: 0;
}

.app-sidebar-brand strong,
.app-sidebar-brand small {
    display: block;
    line-height: 1.2;
}

.app-sidebar-brand strong {
    font-size: 1rem;
    letter-spacing: 0.01em;
}

.app-sidebar-brand small {
    margin-top: 0.18rem;
    overflow: hidden;
    color: #a9c1e1;
    font-size: 0.7rem;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.app-sidebar-logo {
    display: grid;
    width: 38px;
    height: 38px;
    flex: 0 0 38px;
    place-items: center;
    color: #0a376f;
    font-size: 1rem;
    background: #fff;
    border-radius: 0.65rem;
}

.app-sidebar-body {
    display: block;
    padding: 0.9rem 0.75rem 1.25rem;
    overflow-y: auto;
}

.app-sidebar-user {
    display: flex;
    gap: 0.75rem;
    align-items: center;
    padding: 0.65rem 0.7rem;
    margin-bottom: 0.7rem;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 0.8rem;
}

.app-sidebar-user small,
.app-sidebar-user strong {
    display: block;
}

.app-sidebar-user > div {
    min-width: 0;
}

.app-sidebar-user strong {
    overflow: hidden;
    font-size: 0.86rem;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.app-sidebar-user small {
    color: #9eb9df;
    font-size: 0.75rem;
}

.app-sidebar-avatar {
    display: grid;
    width: 34px;
    height: 34px;
    flex: 0 0 34px;
    place-items: center;
    color: #082b5c;
    background: #fff;
    border-radius: 50%;
}

.app-sidebar-nav {
    display: grid;
    gap: 0.15rem;
}

.app-sidebar-nav a {
    display: flex;
    gap: 0.75rem;
    align-items: center;
    min-height: 42px;
    padding: 0.58rem 0.72rem;
    color: #c9d9ef;
    font-size: 0.88rem;
    font-weight: 500;
    text-decoration: none;
    border-radius: 0.65rem;
    transition: color 0.15s ease, background-color 0.15s ease;
}

.app-sidebar-nav a:hover,
.app-sidebar-nav a.active {
    color: #fff;
    background: rgba(46, 140, 255, 0.25);
}

.app-sidebar-nav a.active {
    background: rgba(64, 150, 255, 0.24);
    box-shadow: inset 3px 0 #75b5ff;
}

.app-sidebar-nav i {
    width: 1.15rem;
    text-align: center;
}

.app-sidebar-label {
    padding: 0.9rem 0.72rem 0.3rem;
    color: #7798c5;
    font-size: 0.7rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
}

.app-content {
    min-width: 0;
    min-height: 100vh;
}

.app-main {
    width: 100%;
    max-width: 1540px;
    margin-right: auto;
    margin-left: auto;
    padding-right: clamp(1rem, 2.3vw, 2rem);
    padding-left: clamp(1rem, 2.3vw, 2rem);
}

.app-mobile-header {
    position: sticky;
    top: 0;
    z-index: 1020;
    min-height: 58px;
    background: #0a376f;
    box-shadow: 0 0.25rem 1rem rgba(8, 43, 92, 0.18);
}

.app-mobile-header .container-fluid {
    display: grid;
    grid-template-columns: 44px minmax(0, 1fr) auto;
    gap: 0.65rem;
    align-items: center;
}

.app-mobile-header .navbar-toggler {
    padding: 0.3rem 0.45rem;
    border-color: rgba(255, 255, 255, 0.28);
}

.app-mobile-header .navbar-brand {
    overflow: hidden;
    font-size: 1rem;
    font-weight: 600;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.app-mobile-role {
    padding: 0.25rem 0.5rem;
    color: #d9e8fb;
    font-size: 0.68rem;
    font-weight: 600;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 999px;
}

@media (min-width: 992px) {
    .app-layout {
        display: block;
    }

    .app-sidebar {
        position: fixed !important;
        top: 0;
        bottom: 0;
        left: 0;
        width: 252px !important;
        height: 100vh;
        visibility: visible !important;
        transform: none !important;
        box-shadow: 0.35rem 0 1.4rem rgba(8, 31, 66, 0.12);
    }

    .app-sidebar .offcanvas-header,
    .app-sidebar .offcanvas-body {
        display: block;
    }

    .app-sidebar .offcanvas-header {
        display: flex;
    }

    .app-content {
        width: calc(100% - 252px);
        margin-left: 252px;
    }

    .app-mobile-header {
        display: none;
    }
}

@media (max-width: 991.98px) {
    .app-sidebar {
        width: min(86vw, 280px) !important;
    }

    .app-main {
        padding-top: 1.25rem !important;
    }
}

@media (max-width: 575.98px) {
    .app-main {
        padding-right: 0.75rem;
        padding-left: 0.75rem;
    }

    .app-main > .d-flex:first-child h1 {
        font-size: 1.35rem;
    }
}

/* Navbar brand spacing */
.navbar-brand {
    letter-spacing: 0.5px;
}

/* Pagination active state */
.page-item.active .page-link {
    z-index: 1;
}

/* Filter daftar atlet: satu baris di desktop, responsif di layar kecil. */
.athlete-filter-bar {
    position: relative;
    z-index: 20;
    display: flex;
    align-items: flex-start;
    gap: 0.5rem;
    padding: 0.75rem;
    background: #fff;
    border: 1px solid #dee2e6;
    border-radius: 0.75rem;
    box-shadow: 0 0.125rem 0.375rem rgba(33, 37, 41, 0.06);
}

.athlete-filter-field {
    min-width: 0;
}

.athlete-filter-org {
    flex: 1.35 1 220px;
}

.athlete-filter-cabor {
    position: relative;
    z-index: 30;
    flex: 1.15 1 190px;
}

.athlete-filter-status {
    flex: 0.9 1 170px;
}

.athlete-filter-search {
    flex: 1.2 1 200px;
}

.athlete-filter-bar .btn {
    white-space: nowrap;
}

.athlete-filter-bar .choices {
    margin-bottom: 0;
}

.athlete-filter-bar .choices__inner {
    min-height: 38px;
    padding: 5px 34px 4px 10px;
    border-color: #dee2e6;
    border-radius: 0.375rem;
    background: #fff;
    font-size: 1rem;
}

.athlete-filter-bar .choices.is-focused .choices__inner,
.athlete-filter-bar .choices.is-open .choices__inner {
    border-color: #86b7fe;
    box-shadow: 0 0 0 0.25rem rgba(13, 110, 253, 0.25);
}

.athlete-filter-bar .choices__list--dropdown,
.athlete-filter-bar .choices__list[aria-expanded] {
    z-index: 1100;
    margin-top: 0.25rem;
    border-radius: 0.5rem;
    box-shadow: 0 0.75rem 1.75rem rgba(33, 37, 41, 0.18);
}

.athlete-filter-bar .choices__list--dropdown .choices__list,
.athlete-filter-bar .choices__list[aria-expanded] .choices__list {
    max-height: 300px;
}

@media (max-width: 1199.98px) {
    .athlete-filter-bar {
        flex-wrap: wrap;
    }

    .athlete-filter-field {
        flex: 1 1 calc(33.333% - 0.5rem);
    }
}

@media (max-width: 767.98px) {
    .athlete-filter-field {
        flex-basis: calc(50% - 0.5rem);
    }
}

/* Responsive card spacing */
@media (max-width: 576px) {
    .card-body {
        padding: 1rem;
    }

    .athlete-filter-bar {
        padding: 0.625rem;
    }

    .athlete-filter-field,
    .athlete-filter-submit,
    .athlete-filter-reset {
        width: 100%;
        flex-basis: 100%;
    }
}
