/* Alpha Gh Bundle - Main CSS */
:root {
    --primary: #161938;
    --secondary: #111829;
    --accent: #F99B15;
    --light-blue: #5c8dff;
    --accent-strong: #ff8f1f;
    --surface-soft: #f3f5fb;
    --surface-card: #ffffff;
    /* Backward-compat aliases */
    --ghana-green: #161938;
    --ghana-red: #ff8f1f;
    --ghana-gold: #F99B15;
    --ghana-black: #000000;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    background: var(--surface-soft);
    color: #212529;
}

.main-content {
    flex: 1;
}

.site-messages {
    width: 100%;
    margin: 0;
    padding: 0;
}

.site-message {
    background: linear-gradient(165deg, rgba(24, 35, 57, 0.96), rgba(19, 30, 52, 0.94));
    border: 1px solid rgba(135, 160, 205, 0.24);
    color: #eef3ff;
    box-shadow: 0 12px 24px rgba(2, 8, 28, 0.18);
    border-radius: 0;
    margin: 0;
    padding: 0.95rem 1.25rem;
}

.site-message.alert-success {
    border-color: rgba(60, 186, 101, 0.35);
}

.site-message.alert-info {
    border-color: rgba(92, 141, 255, 0.35);
}

.site-message.alert-warning {
    border-color: rgba(249, 155, 21, 0.45);
}

.site-message.alert-danger {
    border-color: rgba(255, 143, 31, 0.45);
}

/* Navbar */
.navbar-brand {
    font-size: 1.4rem;
    letter-spacing: 0.5px;
}

/* Global site navbar */
.site-navbar {
    background: linear-gradient(95deg, #111829 0%, #161938 58%, #0f1628 100%);
    border-bottom: 1px solid rgba(255, 255, 255, 0.12);
    backdrop-filter: blur(10px);
    box-shadow: 0 6px 22px rgba(5, 9, 28, 0.22);
    transition: background 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}

.site-navbar.scrolled {
    background: linear-gradient(95deg, rgba(17, 24, 41, 0.96) 0%, rgba(22, 25, 56, 0.96) 58%, rgba(15, 22, 40, 0.96) 100%);
    border-bottom-color: rgba(249, 155, 21, 0.28);
    box-shadow: 0 12px 30px rgba(3, 7, 22, 0.36);
}

.site-brand {
    display: inline-flex;
    align-items: center;
    gap: 0.7rem;
    color: #fff;
    text-decoration: none;
    padding: 0.12rem 0;
}

.brand-mark {
    width: 40px;
    min-width: 40px;
    max-width: 40px;
    height: 40px;
    min-height: 40px;
    max-height: 40px;
    border-radius: 10px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #ffffff 0%, #e7e7ef 100%);
    color: #f14a35;
    font-size: 1.05rem;
    overflow: hidden;
}

.brand-logo-img {
    display: block;
    width: 40px !important;
    max-width: 40px !important;
    min-width: 40px;
    height: 40px !important;
    max-height: 40px !important;
    min-height: 40px;
    object-fit: cover;
}

.brand-copy {
    display: inline-flex;
    flex-direction: column;
    line-height: 1.1;
}

.brand-title {
    font-weight: 700;
    font-size: 1.15rem;
    color: #f8f9ff;
}

.brand-subtitle {
    font-size: 0.78rem;
    color: rgba(233, 236, 248, 0.7);
}

.site-navbar .nav-link {
    color: rgba(233, 236, 248, 0.84);
    font-weight: 600;
    font-size: 0.95rem;
    border-radius: 8px;
    padding: 0.38rem 0.65rem;
    transition: color 0.2s ease, background-color 0.2s ease;
}

.site-navbar .nav-link:hover,
.site-navbar .nav-link:focus,
.site-navbar .nav-link.active {
    color: #fff;
    background: rgba(255, 255, 255, 0.08);
}

.site-navbar .dropdown-menu {
    background: #141d34;
    border: 1px solid rgba(255, 255, 255, 0.12);
}

.site-navbar .dropdown-item {
    color: rgba(233, 236, 248, 0.86);
}

.site-navbar .dropdown-item:hover,
.site-navbar .dropdown-item:focus {
    color: #fff;
    background: rgba(249, 155, 21, 0.16);
}

.site-navbar-toggler {
    border-color: rgba(255, 255, 255, 0.55);
    border-width: 1px;
    color: #fff;
}

.site-navbar-toggler .navbar-toggler-icon {
    filter: invert(1);
}

.site-navbar-toggler .bi-list {
    color: #fff;
    font-size: 1.4rem;
    opacity: 1;
}

.site-sidebar-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 42px;
    min-height: 42px;
}

.btn-site-accent {
    background: linear-gradient(135deg, #f99b15 0%, #ff8f1f 100%);
    border: none;
    color: #161938;
    font-weight: 700;
    border-radius: 10px;
    padding: 0.55rem 1.2rem;
    box-shadow: 0 8px 18px rgba(249, 155, 21, 0.32);
}

.btn-site-accent:hover {
    color: #10162a;
    filter: brightness(1.03);
}

.btn-site-outline {
    border: 1px solid rgba(255, 255, 255, 0.22);
    color: #f4f6ff;
    border-radius: 10px;
    padding: 0.5rem 1rem;
}

.btn-site-outline:hover {
    color: #fff;
    border-color: rgba(255, 255, 255, 0.4);
    background: rgba(255, 255, 255, 0.08);
}

.btn-site-ghost {
    border: 1px dashed rgba(249, 155, 21, 0.5);
    color: var(--accent);
    border-radius: 10px;
    padding: 0.5rem 1rem;
    font-weight: 600;
}

.btn-site-ghost:hover {
    color: #111829;
    background: var(--accent);
    border-color: var(--accent);
}

.navbar-action-group {
    display: flex;
    gap: 0.5rem;
    align-items: center;
}

/* Service Cards */
.service-card {
    border: 2px solid transparent;
    transition: all 0.3s ease;
    border-radius: 12px;
}

.service-card:hover {
    border-color: var(--accent);
    transform: translateY(-4px);
    box-shadow: 0 8px 24px rgba(15, 48, 87, 0.15) !important;
}

.service-icon {
    font-size: 3rem;
    color: var(--accent);
    display: block;
}

/* Hero */
.hero-section {
    padding: 80px 0;
}

/* Buttons */
.btn-ghana-green,
.btn-primary-blue {
    background-color: var(--primary);
    color: white;
    border: none;
}

.btn-ghana-green:hover,
.btn-primary-blue:hover {
    background-color: var(--secondary);
    color: white;
}

.btn-ghana-gold {
    background-color: var(--accent);
    color: #111829;
    border: none;
}

.btn-ghana-gold:hover {
    background-color: var(--accent-strong);
    color: #0f1528;
}

.btn-ghana-red {
    background-color: var(--accent-strong);
    color: white;
    border: none;
}

/* Cards */
.card {
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(3, 8, 28, 0.22);
}

/* Tables */
.table th {
    font-weight: 600;
}

/* Footer */
.footer a {
    text-decoration: none;
    transition: color 0.2s;
}

.footer a:hover {
    color: #fff !important;
}

.site-footer {
    background: linear-gradient(135deg, #0f1628 0%, #161938 52%, #17142d 100%);
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    color: rgba(233, 236, 248, 0.88);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.05);
}

.site-footer h5 {
    color: #f4f6ff;
    font-weight: 700;
}

.text-muted-light {
    color: rgba(233, 236, 248, 0.74);
}

.site-footer-content {
    font-size: 1rem;
}

.site-footer .row>div {
    position: relative;
}

.footer-brand-wrap {
    display: flex;
    align-items: flex-start;
    gap: 0.85rem;
}

.footer-logo-img {
    width: 40px !important;
    height: 40px !important;
    object-fit: cover;
}

.footer-links li,
.footer-contact li {
    margin-bottom: 0.5rem;
}

.footer-links a {
    color: rgba(233, 236, 248, 0.82);
}

.footer-links a:hover {
    color: var(--accent);
}

.footer-links a {
    transition: color 0.2s ease, transform 0.2s ease;
    display: inline-block;
}

.footer-links a:hover {
    transform: translateX(2px);
}

.footer-contact li {
    color: rgba(233, 236, 248, 0.84);
}

.footer-contact i {
    color: var(--accent);
    margin-right: 0.45rem;
}

.footer-social {
    display: flex;
    gap: 0.9rem;
}

.footer-social a {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.07);
    color: #fff;
}

.footer-social a:hover {
    background: rgba(249, 155, 21, 0.2);
    color: var(--accent);
}

.text-accent {
    color: var(--accent);
}

.site-footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    color: rgba(233, 236, 248, 0.78);
    text-align: center;
}

/* Auth pages */
.auth-shell {
    min-height: calc(100vh - 170px);
    display: flex;
    align-items: center;
    background:
        radial-gradient(circle at 15% 20%, rgba(92, 141, 255, 0.2), transparent 38%),
        radial-gradient(circle at 85% 80%, rgba(249, 155, 21, 0.16), transparent 34%),
        linear-gradient(135deg, #151a36 0%, #111829 100%);
}

.auth-card {
    border: 1px solid rgba(255, 255, 255, 0.14);
    background: rgba(18, 25, 48, 0.86);
    box-shadow: 0 24px 48px rgba(5, 8, 22, 0.35);
    border-radius: 20px;
    overflow: hidden;
    --auth-autofill-shadow-size: 1000px;
}

.auth-card .card-header {
    background: linear-gradient(135deg, #1b2551 0%, #111829 100%) !important;
    border-bottom: 1px solid rgba(255, 255, 255, 0.12);
}

.auth-card .card-body {
    color: #e9ecf8;
}

.auth-card .form-label {
    color: #e9ecf8;
}

.auth-card .form-control {
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: #f4f6ff;
}

.auth-card .form-control::placeholder,
.auth-card textarea::placeholder {
    color: rgba(233, 236, 248, 0.62);
}

.auth-card .form-control:-webkit-autofill,
.auth-card .form-control:-webkit-autofill:hover,
.auth-card .form-control:-webkit-autofill:focus {
    -webkit-text-fill-color: #f4f6ff;
    caret-color: #f4f6ff;
    -webkit-box-shadow: 0 0 0 var(--auth-autofill-shadow-size) #1a2040 inset;
    box-shadow: 0 0 0 var(--auth-autofill-shadow-size) #1a2040 inset;
}

.auth-card .form-control:focus {
    border-color: rgba(249, 155, 21, 0.7);
    box-shadow: 0 0 0 0.2rem rgba(249, 155, 21, 0.22);
    background: rgba(255, 255, 255, 0.08);
}

.auth-card .agent-registration-form fieldset {
    padding: 1.25rem;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 0.5rem;
    color: #e9ecf8;
}

.auth-card .agent-registration-form fieldset legend {
    width: auto;
    padding: 0 0.5rem;
    margin-bottom: 1rem;
    color: #e9ecf8;
}

.auth-card .agent-registration-form fieldset .text-muted {
    color: rgba(233, 236, 248, 0.55) !important;
}

.auth-card .agent-registration-form fieldset .form-control,
.auth-card .agent-registration-form fieldset .form-select,
.auth-card .agent-registration-form fieldset textarea {
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: #f4f6ff;
}

.auth-card .agent-registration-form fieldset .form-control::placeholder,
.auth-card .agent-registration-form fieldset textarea::placeholder {
    color: rgba(233, 236, 248, 0.45);
}

.auth-card .agent-registration-form fieldset .form-control:focus,
.auth-card .agent-registration-form fieldset .form-select:focus,
.auth-card .agent-registration-form fieldset textarea:focus {
    border-color: rgba(249, 155, 21, 0.7);
    box-shadow: 0 0 0 0.2rem rgba(249, 155, 21, 0.22);
    background: rgba(255, 255, 255, 0.08);
    color: #f4f6ff;
}


.auth-card .agent-registration-form fieldset .form-text {
    color: rgba(233, 236, 248, 0.55);
}

.auth-card .agent-registration-form .form-label {
    color: #e9ecf8;
}

.agent-register-form {
    --agent-register-input-text: var(--bs-body-color, #212529);
    --agent-register-placeholder-text: var(--bs-secondary-color, #6c757d);
}

.agent-register-form .form-control,
.agent-register-form textarea {
    color: var(--agent-register-input-text);
}

.agent-register-form .form-control::placeholder,
.agent-register-form textarea::placeholder {
    color: var(--agent-register-placeholder-text);
}

.auth-card hr {
    border-color: rgba(255, 255, 255, 0.14);
    opacity: 1;
}

.auth-card .alert-info {
    background: rgba(92, 141, 255, 0.15);
    border-color: rgba(92, 141, 255, 0.35);
    color: #c5d8ff;
}

.auth-card .alert-success {
    background: rgba(40, 167, 69, 0.15);
    border-color: rgba(40, 167, 69, 0.35);
    color: #b2dfbc;
}

.auth-card .alert-info .alert-heading,
.auth-card .alert-success .alert-heading {
    color: inherit;
}

.auth-card a {
    color: #8fc7ff;
}

.auth-card a:hover {
    color: #ffd092;
}

.auth-btn {
    background: linear-gradient(135deg, #f5c31a 0%, #ff8f12 100%);
    border: none;
    color: #111829;
    font-weight: 700;
}

.auth-btn:hover {
    color: #0f1528;
    filter: brightness(1.04);
}

/* Wallet card */
.wallet-card {
    background: linear-gradient(135deg, var(--primary) 0%, var(--accent) 100%);
    border-radius: 16px;
}

/* Status badges */
.status-pending {
    background-color: var(--accent);
    color: #111829;
}

.status-completed {
    background-color: var(--accent);
    color: #fff;
}

.status-failed {
    background-color: var(--accent-strong);
    color: #fff;
}

/* ─── Mobile / Responsive ─── */

/* Nav tabs — scrollable on small screens */
.nav-tabs {
    flex-wrap: nowrap;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
}

.nav-tabs::-webkit-scrollbar {
    display: none;
}

.nav-tabs .nav-item {
    flex-shrink: 0;
}

@media (max-width: 767.98px) {

    .site-navbar .navbar-collapse {
        margin-top: 0.75rem;
        background: linear-gradient(180deg, rgba(17, 24, 41, 0.98) 0%, rgba(22, 25, 56, 0.98) 100%);
        border: 1px solid rgba(255, 255, 255, 0.1);
        border-radius: 14px;
        padding: 0.9rem;
        box-shadow: 0 14px 24px rgba(3, 7, 22, 0.33);
    }

    .site-navbar .nav-link {
        padding: 0.62rem 0.7rem;
    }

    .site-navbar .btn,
    .site-navbar .btn-site-ghost {
        width: 100%;
        text-align: center;
    }

    .navbar-action-group {
        width: 100%;
        flex-direction: column;
        gap: 0.55rem;
    }

    .site-footer {
        padding-top: 2.5rem !important;
        padding-bottom: 2.5rem !important;
    }

    .footer-brand-wrap {
        align-items: center;
    }

    .site-footer-content h5,
    .site-footer-content p,
    .site-footer-content li {
        text-align: left;
    }

    .site-footer-content .col-md-6,
    .site-footer-content .col-md-2,
    .site-footer-content .col-md-3 {
        padding-top: 0.2rem;
        padding-bottom: 0.2rem;
    }

    .auth-shell {
        min-height: auto;
        padding: 2rem 0;
    }

    /* Landing hero */
    .landing-hero {
        padding: 60px 0 40px !important;
    }

    /* Hero stats — remove right border when they wrap */
    .hero-stat {
        border-right: none !important;
        border-bottom: 1px solid rgba(255, 255, 255, .12);
    }

    .hero-stat:last-child {
        border-bottom: none;
    }

    /* Admin content */
    .admin-content {
        padding: 1rem !important;
    }

    /* Topbar padding */
    .admin-topbar,
    .customer-topbar,
    .agent-topbar {
        padding: .5rem .75rem;
    }
}

@media (max-width: 575.98px) {

    .brand-title {
        font-size: 1rem;
    }

    .brand-subtitle {
        font-size: 0.72rem;
    }

    .site-brand {
        max-width: 220px;
    }

    /* General hero heading */
    .hero-section h1 {
        font-size: 1.75rem;
    }

    .service-icon {
        font-size: 2rem;
    }

    /* Landing service card text */
    .service-card-landing h5 {
        font-size: .95rem;
    }

    .service-card-landing .text-muted.small {
        font-size: .75rem;
    }

    /* Container horizontal padding */
    .admin-content {
        padding: .75rem !important;
    }
}

/* Custom scrollbar */
::-webkit-scrollbar {
    width: 6px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
}

::-webkit-scrollbar-thumb {
    background: var(--accent);
    border-radius: 3px;
}

/* Section label & headings */
.section-label {
    display: inline-block;
    color: var(--accent);
    font-size: .75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .12em;
    margin-bottom: .5rem;
}

.section-heading {
    color: var(--primary);
}

.bg-off-white {
    background: #f4f8fb;
}

.hero-subtitle {
    color: rgba(255, 255, 255, .8);
}

.hero-subtitle-dim {
    color: rgba(255, 255, 255, .6);
}

/* Icon colour/background utilities used on landing & about pages */
.icon-color-accent {
    color: var(--accent);
}

.icon-color-primary {
    color: var(--primary);
}

.icon-color-gold {
    color: var(--accent);
}

.icon-color-red {
    color: var(--accent-strong);
}

.icon-color-green {
    color: var(--primary);
}

.icon-color-purple {
    color: var(--light-blue);
}

.icon-bg-accent {
    background: rgba(249, 155, 21, .14);
}

.icon-bg-primary {
    background: rgba(22, 25, 56, .1);
}

.icon-bg-gold {
    background: rgba(249, 155, 21, .15);
}

.icon-bg-red {
    background: rgba(255, 143, 31, .14);
}

.icon-bg-green {
    background: rgba(22, 25, 56, .12);
}

.icon-bg-purple {
    background: rgba(92, 141, 255, .14);
}

.bg-primary-custom {
    background: var(--primary);
}

.dot-xs {
    font-size: .6rem;
}

.store-link-section {
    background: linear-gradient(135deg, rgba(22, 25, 56, 0.06) 0%, rgba(92, 141, 255, 0.08) 100%);
    border: 1px solid rgba(22, 25, 56, 0.2);
    border-radius: 0.375rem;
}

/* ─── Persistent site sidebar (customer / agent) ─── */
.site-wrapper {
    display: flex;
    min-height: calc(100vh - 56px);
    /* subtract navbar height */
    flex: 1;
}

.site-sidebar {
    width: 220px;
    min-width: 220px;
    background: linear-gradient(180deg, #111829 0%, #161938 72%, #0f1628 100%);
    color: #cdd3da;
    display: flex;
    flex-direction: column;
    flex-shrink: 0;
    position: sticky;
    top: 0;
    height: calc(100vh - 56px);
    overflow-y: auto;
}

.site-sidebar .sidebar-brand {
    padding: 1rem 1.25rem;
    border-bottom: 1px solid rgba(255, 255, 255, .1);
    color: #fff;
    font-weight: 700;
    font-size: .95rem;
}

.site-sidebar .nav-section {
    padding: .45rem 1rem .15rem;
    font-size: .68rem;
    text-transform: uppercase;
    letter-spacing: .08em;
    color: rgba(233, 236, 248, 0.58);
    margin-top: .4rem;
}

.site-sidebar button.nav-section-toggle {
    width: 100%;
    background: none;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    text-align: left;
}

.site-sidebar button.nav-section-toggle .sidebar-chevron {
    transition: transform .2s ease;
    margin-left: auto;
    font-size: .6rem;
}

.site-sidebar button.nav-section-toggle.collapsed .sidebar-chevron {
    transform: rotate(-90deg);
}

.site-sidebar .sidebar-link {
    color: #cdd3da;
    padding: .45rem 1.25rem;
    display: flex;
    align-items: center;
    gap: .55rem;
    text-decoration: none;
    font-size: .875rem;
    transition: background .15s;
    border: none;
}

.site-sidebar .sidebar-link.sidebar-logout-btn {
    width: 100%;
    background: none;
    text-align: left;
    font-size: .875rem;
}

.site-sidebar a.sidebar-link:hover,
.site-sidebar a.sidebar-link.active,
.site-sidebar button.sidebar-link:hover {
    background: rgba(255, 255, 255, .1);
    color: #fff;
}

.site-sidebar .sidebar-link i {
    font-size: .9rem;
    width: 1rem;
    text-align: center;
}

.site-sidebar .sub-links a.sidebar-link {
    font-size: .83rem;
    padding: .38rem 1.25rem .38rem 2rem;
}

.site-main {
    flex: 1;
    display: flex;
    flex-direction: column;
    overflow-x: hidden;
    background: var(--surface-soft);
    min-width: 0;
}

.site-topbar {
    background: var(--surface-card);
    border-bottom: 1px solid rgba(22, 25, 56, 0.12);
    padding: .5rem 1rem;
}

/* Bootstrap role colors aligned with home-page palette */
.btn-success,
.bg-success {
    background-color: var(--primary) !important;
    border-color: var(--primary) !important;
}

.btn-outline-success {
    color: var(--primary);
    border-color: var(--primary);
}

.btn-outline-success:hover,
.btn-outline-success:focus {
    color: #fff;
    background-color: var(--primary);
    border-color: var(--primary);
}

.text-success {
    color: var(--primary) !important;
}

.btn-warning,
.bg-warning {
    background-color: var(--accent) !important;
    border-color: var(--accent) !important;
    color: #111829 !important;
}

.text-warning {
    color: var(--accent-strong) !important;
}

/* Overlay for mobile sidebar */
.site-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, .45);
    z-index: 1040;
}

.site-overlay.show {
    display: block;
}

@media (max-width: 991.98px) {
    .site-sidebar {
        display: none;
        position: fixed;
        top: 56px;
        left: 0;
        height: calc(100vh - 56px);
        z-index: 1050;
    }

    .site-sidebar.show {
        display: flex;
    }
}
