/* The few things the template does not do on its own. */
.sidenav .nav-link.active { font-weight: 600; }
.show-once { word-break: break-all; font-family: ui-monospace, SFMono-Regular, Menlo, monospace; }
.stat-tile .material-symbols-rounded { font-size: 1.6rem; }
.state-badge { letter-spacing: .02em; }
.state-badge::before { content: "● "; }
.state-Active::before { color: #4caf50; }
.state-PendingVerification::before { color: #fb8c00; }
.state-Suspended::before { color: #e91e63; }
.state-Disabled::before { color: #7b809a; }
.state-Completed::before { color: #4caf50; }
.state-Accepted::before { color: #1a73e8; }
.state-Pending::before { color: #fb8c00; }
.state-Failed::before { color: #7b809a; }
.state-RefundFailed::before { color: #e91e63; }
.toast-stack { position: fixed; right: 1rem; bottom: 1rem; z-index: 1080; width: 22rem; }
.page-header.auth { background: linear-gradient(135deg, #344767 0%, #1a2035 100%); }
.cursor-pointer { cursor: pointer; }
.table td, .table th { white-space: nowrap; }
.invalid-feedback.d-block { display: block; }

/* ---- Forms that explain themselves: bordered fields, a label above, a hint below. */
h1:focus, h2:focus, h3:focus { outline: none; }
.section-title { font-size: .72rem; letter-spacing: .08em; text-transform: uppercase; color: #7b809a; font-weight: 700; margin: 1.5rem 0 .75rem; display: flex; align-items: center; gap: .4rem; }
.section-title .material-symbols-rounded { font-size: 1.1rem; }
.field { margin-bottom: 1.1rem; }
.field > label { display: block; font-size: .8rem; font-weight: 600; color: #344767; margin-bottom: .35rem; }
.field > label .req { color: #e91e63; margin-left: .15rem; }
.field .form-control, .field .form-select { border: 1px solid #d2d6da; border-radius: .5rem; padding: .55rem .75rem; background: #fff; font-size: .9rem; }
.field .form-control:focus, .field .form-select:focus { border-color: #344767; box-shadow: 0 0 0 3px rgba(52, 71, 103, .12); }
.field .hint { font-size: .74rem; color: #7b809a; margin-top: .3rem; }
.field .prefix { position: relative; }
.field .prefix > span { position: absolute; left: .75rem; top: 50%; transform: translateY(-50%); color: #7b809a; font-size: .9rem; }
.field .prefix > .form-control { padding-left: 1.7rem; }
.quick-action { display: flex; align-items: center; gap: .6rem; padding: .9rem 1rem; border-radius: .75rem; background: #fff; box-shadow: 0 2px 6px rgba(0,0,0,.05); color: #344767; text-decoration: none; }
.quick-action:hover { box-shadow: 0 6px 14px rgba(0,0,0,.08); color: #344767; }
.quick-action .material-symbols-rounded { font-size: 1.5rem; }
.quick-action small { display: block; color: #7b809a; font-size: .75rem; }

/* ---- Theme: blue accent over the Material Dashboard base. */
:root { --pb-blue: #1a56db; --pb-blue-dark: #1545b0; --pb-blue-soft: #e8effc; --pb-ink: #1f2a44; --pb-muted: #6b7280; }
body.bg-gray-100 { background-color: #f3f5f9 !important; }
a { color: var(--pb-blue); }
.btn.bg-gradient-dark, .btn.bg-gradient-dark:hover, .btn.bg-gradient-dark:focus { background-image: linear-gradient(195deg, var(--pb-blue), var(--pb-blue-dark)); box-shadow: 0 4px 12px rgba(26, 86, 219, .25); }
.btn.btn-outline-dark { border-color: #d2d6da; color: var(--pb-ink); }
.btn.btn-outline-dark:hover { background: var(--pb-blue-soft); border-color: var(--pb-blue); color: var(--pb-blue); }
.btn-lg.bg-gradient-dark { padding: .85rem 1.6rem; font-size: .95rem; border-radius: .75rem; }
.icon-shape.bg-gradient-dark { background-image: linear-gradient(195deg, var(--pb-blue), var(--pb-blue-dark)) !important; }
.card { border-radius: 1rem; box-shadow: 0 2px 10px rgba(31, 42, 68, .05); }
.text-dark.font-weight-bold:hover { color: var(--pb-blue) !important; }

/* Sidenav */
.sidenav { border-radius: 1rem; }
.sidenav .navbar-brand { display: flex; align-items: center; gap: .6rem; }
.sidenav .navbar-brand .brand-text { display: flex; flex-direction: column; line-height: 1.1; }
.sidenav .navbar-brand .brand-text strong { color: var(--pb-ink); font-size: 1.05rem; }
.sidenav .navbar-brand .brand-text small { color: var(--pb-muted); font-size: .75rem; }
.sidenav .nav-link { border-radius: .6rem; margin: .1rem .75rem; padding: .55rem .85rem; color: var(--pb-ink) !important; }
.sidenav .nav-link .material-symbols-rounded { font-size: 1.3rem; margin-right: .25rem; color: var(--pb-ink); opacity: .75; }
.sidenav .nav-link.active { background: var(--pb-blue-soft); color: var(--pb-blue) !important; font-weight: 600; }
.sidenav .nav-link.active .material-symbols-rounded { color: var(--pb-blue); opacity: 1; }
.sidenav .nav-link:hover { background: #f3f5f9; }
.sidenav-collapse-btn { position: absolute; right: .6rem; top: 1rem; border: 0; background: transparent; color: var(--pb-muted); cursor: pointer; }
body.g-sidenav-hidden .sidenav { transform: translateX(-20rem); }
body.g-sidenav-hidden .main-content { margin-left: 0 !important; }

/* Navbar: avatar with initials and a menu */
.avatar-initials { width: 2.2rem; height: 2.2rem; border-radius: 50%; background: var(--pb-blue-soft); color: var(--pb-blue); font-weight: 700; font-size: .8rem; display: inline-flex; align-items: center; justify-content: center; }
.user-menu { position: relative; }
.user-menu .menu { position: absolute; right: 0; top: calc(100% + .5rem); min-width: 14rem; background: #fff; border-radius: .75rem; box-shadow: 0 10px 30px rgba(31, 42, 68, .15); padding: .5rem; z-index: 1050; }
.user-menu .menu a, .user-menu .menu button { display: flex; align-items: center; gap: .5rem; width: 100%; padding: .55rem .75rem; border-radius: .5rem; color: var(--pb-ink); background: transparent; border: 0; text-align: left; font-size: .875rem; cursor: pointer; }
.user-menu .menu a:hover, .user-menu .menu button:hover { background: var(--pb-blue-soft); color: var(--pb-blue); }

/* Sections and fields */
.section-head { display: flex; gap: 1rem; align-items: flex-start; margin-bottom: 1.25rem; }
.section-head .icon-badge { flex: 0 0 auto; width: 3rem; height: 3rem; border-radius: .9rem; background: var(--pb-blue-soft); color: var(--pb-blue); display: inline-flex; align-items: center; justify-content: center; }
.section-head .icon-badge .material-symbols-rounded { font-size: 1.6rem; }
.section-head .section-title { margin: 0 0 .25rem; color: var(--pb-blue); }
.section-head p { margin: 0; color: var(--pb-muted); font-size: .85rem; }
.field > label { color: var(--pb-ink); }
.field .form-control:focus, .field .form-select:focus { border-color: var(--pb-blue); box-shadow: 0 0 0 3px rgba(26, 86, 219, .15); }
.field .prefix > span { color: var(--pb-muted); display: inline-flex; }
.field .prefix > span.currency { font-weight: 700; background: var(--pb-blue-soft); color: var(--pb-blue); border-radius: .4rem; padding: .15rem .45rem; left: .45rem; }
.field .prefix > span.currency + .form-control { padding-left: 2.6rem; }
.field .prefix > span .material-symbols-rounded { font-size: 1.15rem; }
.field .prefix > span.icon + .form-control { padding-left: 2.3rem; }
.state-badge { background: var(--pb-blue-soft) !important; color: var(--pb-ink) !important; }
.quick-action .material-symbols-rounded { color: var(--pb-blue); }
.stat-tile h4 { color: var(--pb-ink); }
