/* app.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;
    }
}

/* Audit log tetap terbaca pada area konten yang lebih sempit. */
.audit-summary-card .card-body {
    padding: 1rem 1.1rem;
}

.audit-table-card {
    overflow: hidden;
}

.audit-table-card table {
    min-width: 1040px;
}

.audit-table-card thead th {
    position: sticky;
    top: 0;
    z-index: 2;
    white-space: nowrap;
}

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

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

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

/* Halaman pencarian NIK atlet dan pelatih. */
.person-search-shell {
    max-width: 1050px;
}

.person-search-hero {
    position: relative;
    overflow: hidden;
    padding: 2.25rem;
    color: #fff;
    background: linear-gradient(125deg, #082b5c 0%, #0d6efd 62%, #2e8cff 100%);
    border-radius: 1.25rem;
    box-shadow: 0 1rem 2.5rem rgba(8, 43, 92, 0.2);
}

.person-search-hero::after {
    position: absolute;
    right: -45px;
    bottom: -80px;
    width: 230px;
    height: 230px;
    content: '';
    border: 42px solid rgba(255, 255, 255, 0.1);
    border-radius: 50%;
}

.person-search-kicker {
    margin-bottom: 0.75rem;
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

.person-search-card {
    margin-top: -1.25rem;
    border-radius: 1rem;
}

.person-result-card {
    position: relative;
    overflow: hidden;
    border-radius: 1rem;
}

.person-result-accent {
    height: 5px;
}

.accent-athlete {
    background: linear-gradient(90deg, #0d6efd, #54a0ff);
}

.accent-coach {
    background: linear-gradient(90deg, #f0ad00, #ffd666);
}

.person-photo-frame,
.person-photo-frame img,
.person-photo-placeholder {
    width: 92px;
    height: 112px;
    border-radius: 0.75rem;
}

.person-photo-frame {
    overflow: hidden;
    background: #e9eef5;
    box-shadow: inset 0 0 0 1px rgba(33, 37, 41, 0.08);
}

.person-photo-frame img {
    object-fit: cover;
}

.person-photo-placeholder {
    display: grid;
    place-items: center;
    color: #8b98a9;
    font-size: 2.5rem;
}

.person-result-details {
    display: grid;
    gap: 1rem;
}

.person-result-details div {
    display: grid;
    grid-template-columns: minmax(135px, 0.7fr) 1.3fr;
    gap: 1rem;
}

.person-result-details dt {
    color: #667085;
    font-size: 0.82rem;
    font-weight: 600;
}

.person-result-details dd {
    margin: 0;
    font-weight: 600;
}

.person-search-empty-icon {
    color: #aeb8c4;
    font-size: 3.5rem;
}

body.embed-page {
    min-height: 100vh;
    padding-bottom: 1rem;
    background: transparent;
}

.embed-page main.container {
    max-width: 1100px;
    padding-top: 1rem !important;
    padding-bottom: 1rem !important;
}

.embed-page .person-search-hero {
    padding-top: 1.75rem;
    padding-bottom: 1.75rem;
}

@media (max-width: 575.98px) {
    .person-search-hero {
        padding: 1.5rem;
        border-radius: 1rem;
    }

    .person-result-details div {
        grid-template-columns: 1fr;
        gap: 0.2rem;
    }
}
