/* Base font size */
html {
  font-size: 14px;
  position: relative; /* keep full height */
  min-height: 100%;
}

@media (min-width: 768px) {
  html {
    font-size: 16px;
  }
}

/* Focus outlines for accessibility */
.btn:focus, 
.btn:active:focus, 
.btn-link.nav-link:focus, 
.form-control:focus, 
.form-check-input:focus {
  box-shadow: 0 0 0 0.1rem white, 0 0 0 0.25rem #258cfb;
}

/* Body flex layout for sticky footer */
body {
    display: flex;
    flex-direction: column;
    min-height: 100vh; /* full viewport height */
    margin: 0;
    overflow-x: hidden;
}

/* Main grows to push footer down */
main {
  flex: 1 0 auto;
}

/*handling the mobile*/
/* Handling the mobile */
@media (max-width: 768px) {
    body {
        /* This is the missing piece: turn off flex on mobile */
        display: block !important;
    }

    .main-wrapper {
        margin-left: 0 !important;
        width: 100%;
        position: relative;
    }

    .sidebar {
        /* Ensure it's off-screen by default on mobile */
        position: fixed;
        width: 85%;
        height: 100vh;
        z-index: 2000;
        /* Use your existing transition */
        left: 0;
    }

        /* If your JS adds 'closed' class, make sure it moves far enough */
        .sidebar.closed {
            transform: translateX(-100%);
        }

    /* Ensure the toggle button stays visible on top of the content */
    .sidebar-toggle {
        display: block;
        position: fixed;
        top: 10px;
        left: 10px;
        z-index: 2100;
    }
    /* Shift the Navbar brand/logo to the right so it doesn't hit the toggle */
    .navbar-brand {
        margin-left: 50px;
        font-size: 1.2rem; /* Make text smaller on mobile to fit */
    }
}

/* Header navbar styling */
header nav.navbar {
  min-height: 80px; /* bigger navbar */
}

header nav.navbar .navbar-brand {
  font-size: 1.6rem;
}

/* Footer styling */
footer {
    background-color: #19508a; /* AFM brand color */
    padding: 2rem 0; /* bigger footer */
    flex-shrink: 0; /* prevent shrinking */
    text-align: center;
}

footer p, footer a {
  color: #ffffff;
}

footer a:hover {
  text-decoration: underline;
}

/* Feature icons color */
.feature-icon {
  color: #d5ac51;
}

/* Hero Section Styling */
.hero-section {
  background-color: #265d97; /* AFM brand color */
  margin: 0;       /* flush with header */
  padding: 4rem 0; /* vertical spacing inside hero */
  border: none;
}

.hero-section h1,
.hero-section p {
  margin: 0;
}

.hero-section .btn-light {
  color: #265d97;
  font-weight: 600;
}

.hero-section img {
  max-height: 300px;
}

.card {
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.card:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 20px rgba(0,0,0,0.1);
}

/* Sidebar Styling */
.sidebar {
  position: fixed;
  top: 0;
  left: 0;
  width: 250px;
  height: 100%;
  background-color: #265d97; /* AFM color */
  padding: 2rem 1rem;
  overflow-y: auto;
  transition: transform 0.3s ease;
  z-index: 1050; /* above main content */
  transform: translateX(0); /* visible by default */
}

/* When sidebar is closed */
.sidebar.closed {
  transform: translateX(-100%);
}

/* Sidebar links */
.sidebar ul.nav li a {
  color: white;
  font-weight: 500;
  margin-bottom: 1rem;
  display: block;
}

.sidebar ul.nav li a:hover {
  color: #d5ac51; /* highlight on hover */
  text-decoration: none;
}

/* Main content shift when sidebar is present */
.main-wrapper {
  margin-left: 250px; /* same as sidebar width */
  transition: margin-left 0.3s ease;
  padding-top: 0;
}

.main-wrapper.sidebar-closed {
  margin-left: 0;
}

/* Hamburger toggle button */
.sidebar-toggle {
  position: fixed;
  top: 1rem;
  left: 1rem;
  z-index: 1100;
  background-color: #265d97; /* AFM color */
  border: none;
  color: white;
  font-size: 1.5rem;
  padding: 0.5rem 0.8rem;
  border-radius: 0.3rem;
  cursor: pointer;
}

.sidebar-toggle:hover {
  background-color: #1d4370; /* darker shade on hover */
}

/* Close button inside sidebar */
#closeSidebar {
  background: none;
  border: none;
  color: white;
  font-size: 2rem;
  cursor: pointer;
}

.container-fluid.px-0 {
  padding-top: 0 !important;
}

/* Provincial Admin Dashboard Card Styles */
.provincial-card {
    min-height: 220px; /* ensures all cards are same height */
}

    .provincial-card .card-text.display-6 {
        font-size: 2rem;
    }

@media (max-width: 575.98px) {
    .provincial-card .card-body a.btn {
        font-size: 0.9rem;
    }
}

/*Style for admin/users*/
/* Avatar circle for a modern list look */
.avatar-circle {
  width: 40px;
  height: 40px;
  background-color: #265d97;
  color: white;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: bold;
  font-size: 0.9rem;
}

/* Cleaner table styling */
.table thead th {
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  font-weight: 600;
  border-top: none;
  color: #6c757d;
}

/* Role Badges */
.role-badge {
  background-color: #f0f4f8;
  color: #265d97;
  border: 1px solid #d1d9e6;
  font-weight: 500;
  padding: 0.5em 0.8em;
}

/* Row hover effect */
.table-hover tbody tr:hover {
  background-color: #f8faff;
  transition: background-color 0.2s ease;
}

/* Style for the select dropdown to look less "default" */
.form-select-sm {
  border-radius: 6px;
  border: 1px solid #dee2e6;
}

/*Style for register and login*/
/* Card improvements */
.card {
  border-radius: 12px;
}

/* Section headers in the form */
.text-primary {
  color: #19508a !important;
}

/* Floating labels adjustments */
.form-floating > .form-control:focus,
.form-floating > .form-control:not(:placeholder-shown) {
  padding-top: 1.625rem;
  padding-bottom: 0.625rem;
}

/* Button hover effect */
.btn-primary:hover {
  background-color: #265d97 !important;
  transform: translateY(-1px);
  transition: all 0.2s ease;
}

/* Small labels for non-floating selects */
.form-label.small {
  font-size: 0.75rem;
  margin-bottom: 2px;
}

/* Custom background for login inputs */
.bg-light {
  background-color: #f8f9fa !important;
}

/* Rounded corners for the login card */
.rounded-4 {
  border-radius: 1rem !important;
}

/* Soft transition for the inputs */
.form-control:focus {
  background-color: #fff !important;
  box-shadow: 0 0 0 0.25rem rgba(25, 80, 138, 0.1);
  border: 1px solid #19508a;
}

/* Secondary button styling */
.btn-outline-primary {
  border-color: #19508a;
  color: #19508a;
}

.btn-outline-primary:hover {
  background-color: #19508a;
  border-color: #19508a;
  color: #fff;
}

/* Success Icon Animation */
.bi-check-circle-fill {
  display: inline-block;
  animation: pulse 2s infinite;
}

@keyframes pulse {
  0% { transform: scale(1); opacity: 1; }
  50% { transform: scale(1.05); opacity: 0.8; }
  100% { transform: scale(1); opacity: 1; }
}

/* Alert Styling for Dev mode */
.alert-warning {
  background-color: #fff3cd;
  color: #856404;
  font-size: 0.9rem;
  border-radius: 8px;
}

/*Style for church*/
/* Custom Icon Box */
.icon-box {
  width: 60px;
  height: 60px;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: #f0f4f8 !important;
}

/* Subtle letter spacing for labels */
.tracking-wider {
  letter-spacing: 0.05rem;
}

/* Fix input group focus styling */
.input-group:focus-within .input-group-text {
  border-color: #19508a;
  background-color: #fff !important;
  transition: all 0.2s ease;
}

.input-group:focus-within .form-control {
  box-shadow: none; /* Let the parent container handle the look */
}

/* Alert styling for validation summary */
.alert-danger {
  background-color: #fceaea;
  color: #b02a37;
}

/* Danger card styling */
.border-danger {
  border: 1px solid #dc3545 !important;
}

/* Background for the summary area */
.bg-light {
  background-color: #f8f9fa !important;
}

/* Alert styling within the delete page */
.alert-warning {
  background-color: #fff3cd;
  color: #856404;
  border-radius: 10px;
}

/* Red button hover state */
.btn-danger:hover {
  background-color: #bb2d3b;
  box-shadow: 0 4px 8px rgba(220, 53, 69, 0.3);
}

/* Custom Profile Header Gradient */
.bg-primary-gradient {
  background: linear-gradient(45deg, #19508a 0%, #265d97 100%);
}

/* Card image positioning */
.card-header-icon {
  margin-top: -50px; /* Optional: if you want the logo to overlap the gradient */
}

/* Text styles for descriptions */
.lh-base {
  line-height: 1.6 !important;
}

/* Vertical divider for desktop */
@media (min-width: 768px) {
  .border-end {
      border-right: 1px solid #dee2e6 !important;
  }
}
/* AFM Gold Button Style */
.btn-gold {
  background-color: #d5ac51;
  border: none;
  color: #fff;
  font-weight: 600;
  transition: all 0.3s ease;
}

.btn-gold:hover {
  background-color: #c49b42; /* Slightly darker gold on hover */
  color: #fff;
  transform: translateY(-1px);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
}

.btn-gold:active {
  transform: translateY(0);
}
/* Table Avatar Icon */
.avatar-circle-blue {
  width: 45px;
  height: 45px;
  background-color: #f0f4f8;
  color: #19508a;
  border-radius: 12px; /* Squircle look */
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
}

/* Button Group Styling */
.btn-white {
  background-color: #fff;
  color: #444;
}

.btn-white:hover {
  background-color: #f8f9fa;
}

/* Hover effect for rows */
.table-hover tbody tr:hover {
  background-color: rgba(213, 172, 81, 0.05) !important; /* Very light AFM Gold tint */
  transition: background-color 0.2s ease;
}

/* Text Truncation */
.text-truncate {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/*the user management style on the regional admin */

.no-pending-card {
    background: linear-gradient(135deg, #d5ac51, #b38f3d);
    color: white;
    padding: 20px 25px; /* reduced padding */
    border-radius: 16px;
    box-shadow: 0 8px 20px rgba(0,0,0,0.08); /* slightly softer shadow */
    animation: pulse 2.5s infinite;
    max-width: 400px; /* limits width */
    margin: 2rem auto; /* centers the card horizontally */
    text-align: center;
}

    .no-pending-card i {
        display: block;
        font-size: 1.8rem; /* slightly smaller icon */
        margin-bottom: 0.5rem;
    }

    .no-pending-card h5 {
        font-size: 1.1rem; /* smaller heading */
        margin-bottom: 0.25rem;
    }

    .no-pending-card p {
        font-size: 0.9rem; /* smaller description */
        color: rgba(255,255,255,0.85);
    }

@keyframes pulse {
    0% {
        transform: scale(1);
        box-shadow: 0 8px 20px rgba(0,0,0,0.08);
    }

    50% {
        transform: scale(1.02);
        box-shadow: 0 12px 28px rgba(0,0,0,0.12);
    }

    100% {
        transform: scale(1);
        box-shadow: 0 8px 20px rgba(0,0,0,0.08);
    }
}

/*the branch admin dashboard*/
@media (min-width: 768px) {
    .btn-add-member {
        width: auto;
    }
}

@media (max-width: 992px) {
    .dashboard-grid {
        grid-template-columns: 1fr;
    }
}



/* ── Google Font ──────────────────────────────────────────── */
    @import url('https://fonts.googleapis.com/css2?family=DM+Sans:wght@300;400;500;600;700&family=DM+Mono:wght@400;500&display=swap');

    /* ── Design Tokens ────────────────────────────────────────── */
    :root {
        --navy:       #19508a;
        --navy-dark:  #0f3460;
        --navy-mid:   #265d97;
        --gold:       #d5ac51;
        --gold-dark:  #b38f3d;
        --gold-light: rgba(213,172,81,.12);
        --surface:    #ffffff;
        --surface-2:  #f7f9fc;
        --border:     #e8edf4;
        --text:       #1a2840;
        --text-muted: #6b7a94;
        --radius:     16px;
        --radius-sm:  10px;
        --shadow-sm:  0 2px 12px rgba(25,80,138,.08);
        --shadow-md:  0 8px 32px rgba(25,80,138,.13);
        --shadow-lg:  0 20px 60px rgba(25,80,138,.18);
    }

    /* ── Reset scoped to page ─────────────────────────────────── */
    .rp-wrap * { box-sizing: border-box; font-family: 'DM Sans', sans-serif; }


    /* ── Page body ────────────────────────────────────────────── */
    .rp-body { background: var(--surface-2); padding: 0 0 4rem; margin-top: -3rem; position: relative; z-index: 1; }

    /* ── Filter toolbar ───────────────────────────────────────── */
    .rp-toolbar {
        background: var(--surface);
        border: 1px solid var(--border);
        border-radius: var(--radius);
        padding: 1rem 1.5rem;
        display: flex; align-items: center; flex-wrap: wrap; gap: 1rem;
        box-shadow: var(--shadow-sm);
        margin-bottom: 2rem;
    }
    .rp-toolbar-label { font-size: .75rem; font-weight: 600; color: var(--text-muted); text-transform: uppercase; letter-spacing: .07em; }
    .rp-filter-btn {
        border: 1.5px solid var(--border); background: transparent;
        color: var(--text-muted); font-size: .82rem; font-weight: 500;
        padding: .4rem 1rem; border-radius: 50px; cursor: pointer;
        transition: all .2s;
    }
    .rp-filter-btn.active, .rp-filter-btn:hover {
        border-color: var(--navy); background: var(--navy); color: white;
    }
    .rp-export-btn {
        margin-left: auto; border: 1.5px solid var(--gold);
        background: var(--gold-light); color: var(--gold-dark);
        font-size: .82rem; font-weight: 600; padding: .4rem 1.1rem;
        border-radius: 50px; cursor: pointer; transition: all .2s;
        display: flex; align-items: center; gap: .4rem;
    }
    .rp-export-btn:hover { background: var(--gold); color: white; }

    /* ── KPI Cards ────────────────────────────────────────────── */
    .kpi-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(175px, 1fr)); gap: 1.25rem; margin-bottom: 2rem; }
    .kpi-card {
        background: var(--surface); border-radius: var(--radius);
        border: 1px solid var(--border); padding: 1.4rem 1.5rem;
        box-shadow: var(--shadow-sm); position: relative; overflow: hidden;
        transition: transform .25s, box-shadow .25s;
    }
    .kpi-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-md); }
    .kpi-card::before {
        content: ''; position: absolute; top: 0; left: 0; right: 0; height: 3px;
        background: var(--accent, var(--navy));
    }
    .kpi-icon {
        width: 42px; height: 42px; border-radius: 12px;
        background: var(--accent-light, rgba(25,80,138,.1));
        color: var(--accent, var(--navy));
        display: flex; align-items: center; justify-content: center;
        font-size: 1.1rem; margin-bottom: 1rem;
    }
    .kpi-label { font-size: .72rem; font-weight: 600; text-transform: uppercase; letter-spacing: .07em; color: var(--text-muted); margin-bottom: .3rem; }
    .kpi-value { font-size: 1.9rem; font-weight: 700; color: var(--text); line-height: 1; font-family: 'DM Mono', monospace; }
    .kpi-sub   { font-size: .75rem; color: var(--text-muted); margin-top: .35rem; }
    .kpi-trend { display: inline-flex; align-items: center; gap: .25rem; font-size: .72rem; font-weight: 600; padding: .15rem .5rem; border-radius: 50px; }
    .kpi-trend.up   { background: rgba(34,197,94,.12); color: #16a34a; }
    .kpi-trend.down { background: rgba(239,68,68,.1);  color: #dc2626; }

    /* ── Chart Cards ──────────────────────────────────────────── */
    .chart-card {
        background: var(--surface); border: 1px solid var(--border);
        border-radius: var(--radius); padding: 1.75rem;
        box-shadow: var(--shadow-sm); height: 100%;
        transition: box-shadow .25s;
    }
    .chart-card:hover { box-shadow: var(--shadow-md); }
    .chart-card-header { display: flex; align-items: flex-start; justify-content: space-between; margin-bottom: 1.5rem; }
    .chart-card-title  { font-size: .95rem; font-weight: 700; color: var(--text); margin: 0; }
    .chart-card-sub    { font-size: .78rem; color: var(--text-muted); margin-top: .2rem; }
    .chart-badge       { font-size: .72rem; font-weight: 600; padding: .3rem .8rem; border-radius: 50px; background: var(--gold-light); color: var(--gold-dark); white-space: nowrap; }
    .chart-wrap        { position: relative; width: 100%; }

    /* ── Tabs inside chart card ───────────────────────────────── */
    .chart-tabs { display: flex; gap: .4rem; margin-bottom: 1.25rem; }
    .chart-tab  { border: 1px solid var(--border); background: transparent; color: var(--text-muted); font-size: .75rem; font-weight: 500; padding: .3rem .85rem; border-radius: 50px; cursor: pointer; transition: all .2s; }
    .chart-tab.active, .chart-tab:hover { background: var(--navy); border-color: var(--navy); color: white; }

    /* ── Progress / Rank table ────────────────────────────────── */
    .rank-list { list-style: none; padding: 0; margin: 0; }
    .rank-item { display: flex; align-items: center; gap: .9rem; padding: .75rem 0; border-bottom: 1px solid var(--border); }
    .rank-item:last-child { border-bottom: none; }
    .rank-num  { font-size: .7rem; font-weight: 700; color: var(--text-muted); width: 18px; text-align: center; }
    .rank-name { flex: 1; font-size: .85rem; font-weight: 500; color: var(--text); }
    .rank-bar-wrap { flex: 2; background: var(--border); border-radius: 50px; height: 6px; overflow: hidden; }
    .rank-bar  { height: 100%; border-radius: 50px; background: linear-gradient(90deg, var(--navy), var(--navy-mid)); transition: width 1s cubic-bezier(.4,0,.2,1); }
    .rank-val  { font-size: .8rem; font-weight: 600; color: var(--text); font-family: 'DM Mono', monospace; min-width: 40px; text-align: right; }

    /* ── Summary insight strip ────────────────────────────────── */
    .insight-strip {
        background: linear-gradient(135deg, var(--navy-dark), var(--navy-mid));
        border-radius: var(--radius); padding: 1.5rem 2rem;
        display: flex; align-items: center; gap: 1.5rem; flex-wrap: wrap;
        margin-bottom: 2rem; box-shadow: var(--shadow-md);
    }
    .insight-item { flex: 1; min-width: 130px; }
    .insight-item-label { font-size: .68rem; font-weight: 600; text-transform: uppercase; letter-spacing: .08em; color: rgba(255,255,255,.55); margin-bottom: .3rem; }
    .insight-item-val   { font-size: 1.4rem; font-weight: 700; color: #fff; font-family: 'DM Mono', monospace; }
    .insight-divider    { width: 1px; height: 40px; background: rgba(255,255,255,.15); }

    /* ── Sparkline strip ──────────────────────────────────────── */
    .spark-row { display: flex; gap: 1.25rem; margin-bottom: 2rem; flex-wrap: wrap; }
    .spark-card { flex: 1; min-width: 160px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-sm); padding: 1.1rem 1.25rem; box-shadow: var(--shadow-sm); }
    .spark-title { font-size: .72rem; font-weight: 600; text-transform: uppercase; letter-spacing: .07em; color: var(--text-muted); }
    .spark-val   { font-size: 1.3rem; font-weight: 700; color: var(--text); font-family: 'DM Mono', monospace; }
    .spark-canvas { display: block; width: 100%; height: 36px; margin-top: .5rem; }

    /* ── Responsive ───────────────────────────────────────────── */
    @media (max-width: 768px) {
        .rp-toolbar { flex-direction: column; align-items: flex-start; }
        .rp-export-btn { margin-left: 0; }
        .insight-divider { display: none; }
    }


     /* ── Users index  ──────────────────────────────────────────── */
     /* Management Specific Refinements */
.management-header {
    background: var(--surface);
    border-radius: var(--radius);
    border-left: 5px solid var(--gold);
    box-shadow: var(--shadow-sm);
}

.search-container {
    position: relative;
}

.search-container i {
    position: absolute;
    left: 15px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
}

.search-input {
    padding-left: 45px !important;
    border-radius: 50px !important;
    border: 1px solid var(--border);
    height: 50px;
}

.table-card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1.25rem 1.5rem;
    border-bottom: 1px solid var(--border);
    background: var(--surface-2);
}

/* Subtle Table Row Badges */
.status-indicator {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    display: inline-block;
    margin-right: 8px;
}

.bg-pending { background-color: #f59e0b; box-shadow: 0 0 8px rgba(245, 158, 11, 0.4); }
.bg-approved { background-color: #10b981; box-shadow: 0 0 8px rgba(16, 185, 129, 0.4); }

.action-btn-sm {
    padding: 5px 15px;
    border-radius: 50px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    transition: 0.2s;
}


    /* Notification Badge - Modern Gold/Navy styling */
    .badge-gold {
        background-color: #d5ac51 !important;
        color: #1a4571 !important;
        font-weight: 700;
        font-size: 0.7rem;
        border: 2px solid #265d97; /* Matches your navbar color */
    }

    /* Dropdown Menu Styling */
    .notification-dropdown {
        min-width: 320px;
        border: none;
        border-radius: 12px;
        box-shadow: 0 10px 25px rgba(0,0,0,0.2);
        overflow: hidden;
        padding: 0;
        margin-top: 10px !important;
    }

    .dropdown-header-custom {
        background-color: #1a4571;
        color: white;
        padding: 12px 16px;
        font-weight: 600;
        display: flex;
        justify-content: space-between;
        align-items: center;
    }

    /* Notification Items */
    .notification-item {
        padding: 12px 16px;
        border-bottom: 1px solid #f0f0f0;
        transition: background 0.2s;
        display: flex;
        align-items: center;
        text-wrap: balance;
    }

    .notification-item:hover {
        background-color: #f8faff;
        text-decoration: none;
    }

    .notification-icon {
        width: 40px;
        height: 40px;
        border-radius: 50%;
        display: flex;
        align-items: center;
        justify-content: center;
        margin-right: 12px;
        flex-shrink: 0;
    }

    .bg-soft-gold { background-color: rgba(213, 172, 81, 0.15); color: #b38f3d; }
    .bg-soft-navy { background-color: rgba(26, 69, 113, 0.1); color: #1a4571; }


    
/* ================================
   Notification Dropdown Centering
   ================================ */

.centered-notifications {
    position: absolute;
    left: 50% !important;
    transform: translateX(-50%);
    top: 100%;
    min-width: 320px;
    max-width: 90vw; /* responsive on small screens */
    width: 360px;
    border-radius: 12px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.15);
    z-index: 1050;
}

/* Mobile responsiveness */
@media (max-width: 576px) {
    .centered-notifications {
        width: 95vw;
        left: 50% !important;
        transform: translateX(-50%);
    }
}

/*event responsiveness*/
.event-table th {
    white-space: nowrap;
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.03rem;
    color: #6c757d;
}

.event-table td {
    vertical-align: middle;
}

.event-description {
    max-width: 200px;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
}

.event-actions .btn {
    min-width: 36px;
    height: 34px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

/* Tablet */
@media (max-width: 991.98px) {
    .event-table th,
    .event-table td {
        padding-left: 0.75rem;
        padding-right: 0.75rem;
    }

    .avatar-circle-blue {
        display: none;
    }

    .event-description {
        max-width: 150px;
    }
}

/* Mobile */
@media (max-width: 767.98px) {
    .table-responsive {
        overflow: visible;
    }

    .event-table thead {
        display: none;
    }

    .event-table,
    .event-table tbody,
    .event-table tr,
    .event-table td {
        display: block;
        width: 100%;
    }

        .event-table tbody {
            padding: 12px;
        }

            .event-table tbody tr {
                margin-bottom: 16px;
                padding: 16px;
                background-color: #ffffff;
                border: 1px solid #e9ecef;
                border-radius: 16px;
                box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
            }

                .event-table tbody tr:last-child {
                    margin-bottom: 0;
                }

        .event-table td {
            display: flex;
            justify-content: space-between;
            align-items: flex-start;
            gap: 20px;
            padding: 12px 0 !important;
            border: none;
            border-bottom: 1px solid #eeeeee;
            text-align: right !important;
        }

            .event-table td::before {
                content: attr(data-label);
                flex-shrink: 0;
                font-weight: 600;
                font-size: 0.8rem;
                color: #6c757d;
                text-transform: uppercase;
                text-align: left;
            }

            .event-table td:first-child {
                display: block;
                padding-top: 0 !important;
                text-align: left !important;
            }

                .event-table td:first-child::before {
                    display: none;
                }

            .event-table td:last-child {
                padding-bottom: 0 !important;
                border-bottom: none;
                align-items: center;
            }

    .event-identity {
        align-items: flex-start !important;
    }

    .avatar-circle-blue {
        display: flex;
        flex-shrink: 0;
    }

    .event-information {
        min-width: 0;
    }

    .event-description {
        max-width: 100%;
        white-space: normal;
        overflow: visible;
        text-overflow: initial;
    }

    .event-date {
        align-items: flex-end;
    }

    .event-actions {
        display: inline-flex;
        flex-wrap: nowrap;
    }
}
.event-pagination {
    background-color: #ffffff;
}

    .event-pagination .btn {
        min-width: 100px;
    }

        .event-pagination .btn.disabled {
            pointer-events: none;
            opacity: 0.55;
        }

@media (max-width: 575.98px) {
    .event-pagination > div {
        flex-direction: column;
        align-items: stretch !important;
    }

    .event-pagination .text-muted {
        text-align: center;
    }

    .event-pagination .d-flex {
        justify-content: center;
    }

    .event-pagination .btn {
        flex: 1;
    }
}

/*WhatsApp*/
.notification-table th {
    white-space: nowrap;
    font-size: .8rem;
    text-transform: uppercase;
    color: #6c757d;
}

.notification-table td {
    vertical-align: middle;
}

/* Mobile */
@media (max-width:768px) {

    .table-responsive {
        overflow: visible;
    }

    .notification-table thead {
        display: none;
    }

    .notification-table,
    .notification-table tbody,
    .notification-table tr,
    .notification-table td {
        display: block;
        width: 100%;
    }

        .notification-table tbody {
            padding: 12px;
        }

        .notification-table tr {
            background: #fff;
            border: 1px solid #e9ecef;
            border-radius: 16px;
            margin-bottom: 18px;
            padding: 18px;
            box-shadow: 0 .25rem .75rem rgba(0,0,0,.08);
        }

        .notification-table td {
            display: flex;
            justify-content: space-between;
            align-items: flex-start;
            gap: 20px;
            padding: 10px 0 !important;
            border: none;
            border-bottom: 1px solid #f1f1f1;
            text-align: right;
        }

            .notification-table td:last-child {
                border-bottom: none;
            }

            .notification-table td::before {
                content: attr(data-label);
                font-weight: 600;
                color: #6c757d;
                text-transform: uppercase;
                font-size: .75rem;
                min-width: 90px;
                text-align: left;
            }

            /* Recipient row becomes the card header */

            .notification-table td:first-child {
                display: block;
                text-align: left;
                padding-top: 0 !important;
            }

                .notification-table td:first-child::before {
                    display: none;
                }
}

@media (max-width: 575.98px) {
    .pagination {
        flex-wrap: wrap;
        justify-content: center;
    }

    .page-link {
        padding: 0.45rem 0.7rem;
    }
}

/*the nationa pop up html card*/
.user-details-modal .modal-dialog {
    width: calc(100% - 2rem);
    max-width: 970px;
    margin: 1rem auto;
}

.user-details-modal .modal-content {
    max-height: calc(100vh - 2rem);
    overflow: hidden;
}

.user-details-modal .modal-header,
.user-details-modal .modal-footer {
    flex-shrink: 0;
    background-color: #ffffff;
}

.user-details-modal .modal-body {
    overflow-y: auto;
    max-height: calc(100vh - 190px);
}

html {
    overflow-y: scroll;
}

body.modal-open {
    padding-right: 0 !important;
}

/* ============================================================
   SATELLITE DASHBOARD - RESPONSIVE DESIGN
   ============================================================ */

.satellite-dashboard-page {
    max-width: 100%;
}

    /* Prevent cards and charts from becoming wider than screen */
    .satellite-dashboard-page .card,
    .satellite-dashboard-page .chart-card {
        min-width: 0;
        max-width: 100%;
    }

    /* ============================================================
   TABLES
   ============================================================ */

    .satellite-dashboard-page .table-responsive {
        width: 100%;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }

        .satellite-dashboard-page .table-responsive table {
            min-width: 850px;
        }

    /* Prevent long information from breaking layout */
    .satellite-dashboard-page td,
    .satellite-dashboard-page th,
    .satellite-dashboard-page .card,
    .satellite-dashboard-page .modal-content {
        overflow-wrap: break-word;
    }

    /* ============================================================
   CHARTS
   ============================================================ */

    .satellite-dashboard-page .chart-wrap {
        position: relative;
        width: 100%;
        min-width: 0;
    }

        .satellite-dashboard-page .chart-wrap canvas {
            max-width: 100% !important;
        }

/* ============================================================
   LARGE TABLET / SMALL LAPTOP
   ============================================================ */

@media (max-width: 991.98px) {

    .satellite-dashboard-page .chart-card-header {
        flex-wrap: wrap;
        gap: 15px;
    }

        .satellite-dashboard-page .chart-card-header .d-flex.gap-2 {
            flex-wrap: wrap;
        }

    .satellite-dashboard-page .chart-wrap {
        width: 100%;
    }
}

/* ============================================================
   TABLET / MOBILE
   ============================================================ */

@media (max-width: 767.98px) {

    /* --------------------------------------------------------
       PAGE
       -------------------------------------------------------- */

    .satellite-dashboard-page {
        padding-top: 1rem !important;
        padding-bottom: 1rem !important;
    }

        /* --------------------------------------------------------
       CARDS
       -------------------------------------------------------- */

        .satellite-dashboard-page .card {
            border-radius: 16px !important;
        }

        .satellite-dashboard-page .card-header {
            padding: 1rem !important;
        }

        .satellite-dashboard-page .card-body {
            padding: 1rem;
        }

        /* --------------------------------------------------------
       CARD HEADERS
       -------------------------------------------------------- */

        .satellite-dashboard-page
        .card-header
        .d-flex.justify-content-between {
            align-items: stretch !important;
        }

        /* --------------------------------------------------------
       EXPORT PDF / MEMBER BADGES
       -------------------------------------------------------- */

        .satellite-dashboard-page
        .card-header
        .d-flex.gap-2.align-items-center {
            width: 100%;
            flex-wrap: wrap;
        }

            .satellite-dashboard-page
            .card-header
            .d-flex.gap-2.align-items-center
            .btn {
                flex: 1 1 auto;
            }

        /* --------------------------------------------------------
       FORMS / SEARCH / FILTERS
       -------------------------------------------------------- */

        .satellite-dashboard-page .input-group {
            width: 100%;
        }

        .satellite-dashboard-page .form-select,
        .satellite-dashboard-page .form-control {
            width: 100%;
            min-height: 44px;
        }

        /* --------------------------------------------------------
       TABLES
       -------------------------------------------------------- */

        .satellite-dashboard-page .table-responsive {
            padding-left: 0 !important;
            padding-right: 0 !important;
        }

            .satellite-dashboard-page .table-responsive table {
                min-width: 800px;
            }

        .satellite-dashboard-page .table th,
        .satellite-dashboard-page .table td {
            white-space: nowrap;
            padding: 0.75rem;
        }

            /* Allow member names to wrap */

            .satellite-dashboard-page .table td:nth-child(2) {
                white-space: normal;
                min-width: 180px;
            }

        /* --------------------------------------------------------
       CHARTS
       -------------------------------------------------------- */

        .satellite-dashboard-page .chart-card {
            padding: 1rem;
        }

        .satellite-dashboard-page .chart-card-header {
            display: flex;
            flex-direction: column;
            align-items: flex-start !important;
            gap: 12px;
        }

            .satellite-dashboard-page .chart-card-header > div {
                width: 100%;
            }

            .satellite-dashboard-page
            .chart-card-header
            .d-flex.gap-2 {
                width: 100%;
                display: flex;
            }

        .satellite-dashboard-page .chart-tab {
            flex: 1;
            text-align: center;
        }

        .satellite-dashboard-page .chart-wrap {
            overflow-x: auto;
            overflow-y: hidden;
        }

        /* --------------------------------------------------------
       SECTION DIVIDER
       -------------------------------------------------------- */

        .satellite-dashboard-page .section-divider-label {
            white-space: nowrap;
            font-size: 0.9rem;
        }

        /* --------------------------------------------------------
       PAGINATION
       -------------------------------------------------------- */

        .satellite-dashboard-page .card-footer {
            padding: 1rem !important;
        }

            .satellite-dashboard-page
            .card-footer
            .d-flex.justify-content-between {
                flex-direction: column;
                align-items: stretch !important;
            }

            .satellite-dashboard-page
            .card-footer
            .d-flex.gap-2 {
                width: 100%;
            }

                .satellite-dashboard-page
                .card-footer
                .d-flex.gap-2
                .btn {
                    flex: 1;
                }

        /* --------------------------------------------------------
       MODALS
       -------------------------------------------------------- */

        .satellite-dashboard-page .modal-dialog {
            margin: 0.75rem;
        }

        .satellite-dashboard-page .modal-body {
            padding: 1rem !important;
        }

        .satellite-dashboard-page .modal-footer {
            padding: 1rem;
            gap: 10px;
            flex-wrap: wrap;
        }
}

/* ============================================================
   SMALL MOBILE PHONES
   ============================================================ */

@media (max-width: 575.98px) {

    /* --------------------------------------------------------
       PAGE SPACING
       -------------------------------------------------------- */

    .satellite-dashboard-page {
        padding-left: 12px !important;
        padding-right: 12px !important;
    }

        /* --------------------------------------------------------
       DASHBOARD NUMBERS
       -------------------------------------------------------- */

        .satellite-dashboard-page .fs-3 {
            font-size: 1.5rem !important;
        }

        /* --------------------------------------------------------
       CARD HEADINGS
       -------------------------------------------------------- */

        .satellite-dashboard-page .card-header h5 {
            font-size: 1rem;
        }

        /* --------------------------------------------------------
       EXPORT PDF
       -------------------------------------------------------- */

        .satellite-dashboard-page
        .card-header
        .btn-danger {
            width: 100%;
        }

        /* --------------------------------------------------------
       SEARCH
       -------------------------------------------------------- */

        .satellite-dashboard-page .form-control {
            font-size: 0.9rem;
        }

        /* --------------------------------------------------------
       CHARTS
       -------------------------------------------------------- */

        .satellite-dashboard-page .chart-wrap {
            height: 240px !important;
        }

        .satellite-dashboard-page
        .chart-card-header
        .d-flex.gap-2 {
            flex-direction: column;
        }

        .satellite-dashboard-page .chart-tab {
            width: 100%;
        }

        /* --------------------------------------------------------
       TABLES
       -------------------------------------------------------- */

        .satellite-dashboard-page .table-responsive table {
            min-width: 760px;
        }

        /* --------------------------------------------------------
       PAGINATION
       -------------------------------------------------------- */

        .satellite-dashboard-page .card-footer small {
            text-align: center;
            width: 100%;
        }

        /* --------------------------------------------------------
       MODALS
       -------------------------------------------------------- */

        .satellite-dashboard-page .modal-dialog {
            margin: 0.5rem;
            max-width: calc(100% - 1rem);
        }

        .satellite-dashboard-page .modal-content {
            border-radius: 16px !important;
        }

        .satellite-dashboard-page .modal-body .col-md-6,
        .satellite-dashboard-page .modal-body .col-md-12 {
            width: 100%;
        }

        .satellite-dashboard-page .modal-footer {
            flex-direction: column;
            align-items: stretch !important;
        }

            .satellite-dashboard-page .modal-footer > div,
            .satellite-dashboard-page .modal-footer > form {
                width: 100%;
            }

            .satellite-dashboard-page .modal-footer .d-flex {
                width: 100%;
                flex-direction: column;
            }

            .satellite-dashboard-page .modal-footer .btn {
                width: 100%;
            }

            .satellite-dashboard-page .modal-footer form .btn {
                width: 100%;
            }

        /* --------------------------------------------------------
       RANKING
       -------------------------------------------------------- */

        .satellite-dashboard-page .rank-item {
            gap: 8px;
        }

        .satellite-dashboard-page .rank-name {
            font-size: 0.8rem;
        }
}

/* ============================================================
   VERY SMALL PHONES
   ============================================================ */

@media (max-width: 380px) {

    .satellite-dashboard-page {
        padding-left: 8px !important;
        padding-right: 8px !important;
    }

        .satellite-dashboard-page .card-header,
        .satellite-dashboard-page .card-body,
        .satellite-dashboard-page .card-footer {
            padding-left: 0.8rem !important;
            padding-right: 0.8rem !important;
        }

        .satellite-dashboard-page .chart-card {
            padding: 0.8rem;
        }
}