/* ==========================================================================
   BloodBridgeBD - Blood Donation Network Stylesheet (Upgraded Design System)
   Features: Anti-text-wrapping, Fixed Heights, Glassmorphism, Micro-animations,
             Ultra-responsive Mobile Layout, & High Contrast Medical Palette
   ========================================================================== */

:root {
    /* Color Palette */
    --primary-red: #e63946;
    --primary-dark-red: #c1121f;
    --primary-glow: rgba(230, 57, 70, 0.25);
    --secondary-slate: #1d3557;
    --secondary-dark: #0f172a;
    --whatsapp-green: #25d366;
    --whatsapp-dark: #128c7e;
    
    /* Text Colors */
    --text-main: #0f172a;
    --text-muted: #475569;
    --text-light: #94a3b8;
    
    /* Backgrounds */
    --bg-main: #f8fafc;
    --bg-card: #ffffff;
    --bg-glass: rgba(255, 255, 255, 0.92);
    
    /* Status colors */
    --status-available: #059669;
    --status-available-bg: #d1fae5;
    --status-busy: #d97706;
    --status-busy-bg: #fef3c7;
    --status-urgent: #dc2626;
    --status-urgent-bg: #fee2e2;
    
    /* Shadows */
    --shadow-sm: 0 2px 6px rgba(0, 0, 0, 0.04);
    --shadow-md: 0 8px 24px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 20px 40px rgba(230, 57, 70, 0.14);
    --shadow-card: 0 10px 25px -5px rgba(15, 23, 42, 0.06), 0 8px 10px -6px rgba(15, 23, 42, 0.02);
    
    /* Radius & Transitions */
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 20px;
    --radius-full: 9999px;
    --transition: all 0.22s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Reset & Base Styles */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, sans-serif;
    background-color: var(--bg-main);
    color: var(--text-main);
    line-height: 1.5;
    overflow-x: hidden;
}

html[lang="bn"] body,
html[lang="bn"] button,
html[lang="bn"] input,
html[lang="bn"] select,
html[lang="bn"] textarea {
    font-family: 'Noto Sans Bengali', 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, sans-serif;
}

h1, h2, h3, h4, h5, h6 {
    font-family: 'Outfit', sans-serif;
    font-weight: 700;
    color: var(--secondary-slate);
    line-height: 1.2;
}

html[lang="bn"] h1,
html[lang="bn"] h2,
html[lang="bn"] h3,
html[lang="bn"] h4,
html[lang="bn"] h5,
html[lang="bn"] h6 {
    font-family: 'Noto Sans Bengali', 'Outfit', sans-serif;
}

a {
    color: var(--primary-red);
    text-decoration: none;
    transition: var(--transition);
}

a:hover {
    color: var(--primary-dark-red);
}

button {
    font-family: inherit;
    cursor: pointer;
    border: none;
    outline: none;
    background: none;
}

/* Helper Utilities */
.container {
    width: 100%;
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 1.5rem;
}

.text-center { text-align: center; }
.mb-4 { margin-bottom: 1.5rem; }
.mt-3 { margin-top: 1rem; }
.hidden { display: none !important; }

/* Gradient Text */
.gradient-text {
    background: linear-gradient(135deg, var(--primary-red) 0%, #b91c1c 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* Emergency Announcement Bar */
.emergency-bar {
    background: linear-gradient(90deg, #991b1b 0%, #dc2626 50%, #b91c1c 100%);
    color: #ffffff;
    font-size: 0.85rem;
    padding: 0.55rem 0;
    box-shadow: 0 2px 10px rgba(185, 28, 28, 0.25);
    white-space: nowrap;
    overflow-y: auto !important;
    overflow-x: hidden !important;
}

.emergency-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1.5rem;
    flex-wrap: nowrap;
}

.pulse-dot {
    width: 10px;
    height: 10px;
    background-color: #facc15;
    border-radius: 50%;
    display: inline-block;
    flex-shrink: 0;
    box-shadow: 0 0 0 0 rgba(250, 204, 21, 0.7);
    animation: pulseGlow 1.5s infinite;
}

.emergency-text {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    overflow: hidden;
    text-overflow: ellipsis;
    transition: opacity 0.3s ease-in-out;
}

.emergency-text.fade-out {
    opacity: 0;
}

.emergency-link {
    color: #ffffff;
    text-decoration: underline;
    font-weight: 700;
    white-space: nowrap;
}

.hotline {
    background: rgba(255, 255, 255, 0.2);
    padding: 0.25rem 0.85rem;
    border-radius: var(--radius-full);
    font-size: 0.8rem;
    white-space: nowrap;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

/* Navigation Bar - NO TEXT WRAPPING FIX */
.navbar {
    position: sticky;
    top: 0;
    z-index: 1000;
    background: var(--bg-glass);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-bottom: 1px solid rgba(226, 232, 240, 0.9);
    padding: 0.75rem 0;
    transition: var(--transition);
}

.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
    max-width: 100%;
    padding-left: 30px;
    padding-right: 30px;
}

.brand-logo {
    display: flex;
    align-items: center;
    gap: 0.85rem;
    white-space: nowrap;
    flex-shrink: 0;
    text-decoration: none;
    transition: transform 0.25s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.brand-logo:hover {
    transform: translateY(-1px);
}

.logo-icon {
    width: 52px;
    height: 52px;
    border-radius: 16px;
    background: linear-gradient(135deg, #ffffff 0%, #fff1f2 60%, #ffe4e6 100%);
    border: 1.5px solid #fecdd3;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 10px 25px -5px rgba(225, 29, 72, 0.2), 0 4px 10px rgba(0, 0, 0, 0.03);
    flex-shrink: 0;
    position: relative;
    overflow: hidden;
    transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.brand-logo:hover .logo-icon {
    box-shadow: 0 14px 28px rgba(225, 29, 72, 0.32), 0 0 0 4px rgba(254, 205, 211, 0.5);
    border-color: #fda4af;
    transform: scale(1.05);
}

.logo-icon img,
.logo-img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    display: block;
    transition: transform 0.35s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.brand-logo:hover .logo-img {
    transform: scale(1.08);
}

.logo-drop {
    width: 29px;
    height: 36px;
    border-radius: 16px 16px 16px 4px;
    background: linear-gradient(145deg, #ff4d6d 0%, var(--primary-red) 50%, var(--primary-dark-red) 100%);
    box-shadow: inset 0 2px 4px rgba(255, 255, 255, 0.4), 0 6px 14px rgba(193, 18, 31, 0.3);
    transform: rotate(-45deg);
    position: relative;
    transition: transform 0.3s ease;
}

.logo-drop::after {
    content: "";
    position: absolute;
    top: 6px;
    left: 6px;
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.6);
}

.logo-hero-badge {
    position: absolute;
    z-index: 3;
    color: #ffffff;
    font-size: 0.88rem;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.4));
    display: flex;
    align-items: center;
    justify-content: center;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -48%);
}

.logo-title {
    font-size: 1.48rem;
    font-weight: 800;
    color: #0f172a;
    letter-spacing: -0.02em;
    line-height: 1.1;
    display: flex;
    align-items: center;
}

.logo-title .highlight {
    background: linear-gradient(135deg, #e11d48 0%, #be123c 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    font-weight: 900;
}

.bd-mark {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin-left: 0.4rem;
    padding: 0.15rem 0.4rem;
    border-radius: 6px;
    background: linear-gradient(135deg, #059669 0%, #047857 100%);
    color: #ffffff;
    font-size: 0.68rem;
    font-weight: 900;
    letter-spacing: 0.5px;
    box-shadow: 0 2px 6px rgba(5, 150, 105, 0.25);
    border: 1px solid rgba(255, 255, 255, 0.3);
}

.logo-subtitle {
    display: block;
    font-size: 0.64rem;
    text-transform: uppercase;
    letter-spacing: 0.9px;
    color: #64748b;
    font-weight: 700;
    margin-top: 1px;
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    white-space: nowrap;
}

.nav-item {
    font-weight: 700;
    color: var(--text-main);
    font-size: 0.92rem;
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    padding: 0.5rem 0.75rem;
    border-radius: var(--radius-sm);
    white-space: nowrap; /* CRITICAL: Prevents text line wrapping */
}

.nav-item:hover, .nav-item.active {
    color: var(--primary-red);
    background-color: #fff1f2;
}

.badge-count {
    background-color: var(--primary-red);
    color: white;
    font-size: 0.72rem;
    padding: 2px 7px;
    border-radius: var(--radius-full);
    font-weight: 800;
    margin-left: 2px;
    display: inline-block;
    white-space: nowrap;
}

.nav-actions {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex-shrink: 0;
    white-space: nowrap;
}

.language-selector {
    height: 42px;
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    padding: 0 0.75rem;
    border: 1.5px solid #cbd5e1;
    border-radius: var(--radius-md);
    background-color: #ffffff;
    color: var(--secondary-slate);
    font-size: 0.9rem;
    font-weight: 800;
    box-shadow: var(--shadow-sm);
}

.language-selector i {
    color: var(--primary-red);
}

.language-selector select {
    border: 0;
    outline: 0;
    background: transparent;
    color: inherit;
    font: inherit;
    cursor: pointer;
}

.mobile-menu-btn {
    display: none;
    font-size: 1.4rem;
    color: var(--secondary-slate);
    padding: 0.5rem;
    border-radius: var(--radius-sm);
}

.mobile-menu-btn:hover {
    background-color: #f1f5f9;
}

.mobile-only-actions {
    display: none;
}

.table-responsive {
    display: block;
    width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

.profile-menu {
    position: relative;
    flex-shrink: 0;
}

.profile-menu-toggle {
    height: 44px;
    display: inline-flex;
    align-items: center;
    gap: 0.55rem;
    padding: 0 0.85rem 0 0.45rem;
    border: 1.5px solid #cbd5e1;
    border-radius: var(--radius-md);
    background: #ffffff;
    color: var(--secondary-slate);
    font-weight: 800;
    box-shadow: var(--shadow-sm);
}

.profile-initial {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary-red) 0%, var(--primary-dark-red) 100%);
    color: #ffffff;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-weight: 900;
}

.profile-name {
    max-width: 130px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.profile-dropdown {
    position: absolute;
    right: 0;
    top: calc(100% + 0.55rem);
    min-width: 190px;
    background: #ffffff;
    border: 1.5px solid #e2e8f0;
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-md);
    padding: 0.45rem;
    z-index: 1200;
}

.profile-dropdown a,
.profile-dropdown button {
    width: 100%;
    display: flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.7rem 0.8rem;
    border-radius: var(--radius-sm);
    color: var(--secondary-slate);
    font-size: 0.9rem;
    font-weight: 800;
    text-align: left;
}

.profile-dropdown a:hover,
.profile-dropdown button:hover {
    background: #fff1f2;
    color: var(--primary-red);
}

/* Mobile Header Profile Icon (Show when logged out on mobile) */
.mobile-header-profile-btn {
    display: none;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: #fff1f2;
    color: var(--primary-red);
    border: 1.5px solid #fecdd3;
    font-size: 1.4rem;
    box-shadow: 0 4px 12px rgba(225, 29, 72, 0.15);
    transition: all 0.25s ease;
    cursor: pointer;
}

.mobile-header-profile-btn:hover {
    background: linear-gradient(135deg, #e11d48 0%, #be123c 100%);
    color: #ffffff;
    border-color: #be123c;
    transform: scale(1.05);
}

/* BUTTON SYSTEM - FIXED NO WRAPPING & BROKEN BUTTON FIX */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.55rem;
    padding: 0.65rem 1.35rem;
    height: 44px; /* Fixed height for clean button alignment */
    border-radius: var(--radius-md);
    font-weight: 700;
    font-size: 0.92rem;
    white-space: nowrap; /* CRITICAL: Fixes broken button line wrapping */
    transition: var(--transition);
    user-select: none;
    box-sizing: border-box;
    cursor: pointer;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary-red) 0%, var(--primary-dark-red) 100%);
    color: #ffffff !important;
    box-shadow: 0 4px 14px rgba(230, 57, 70, 0.35);
    border: none;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 22px rgba(230, 57, 70, 0.45);
}

.btn-pulse {
    animation: btnGlow 2.5s infinite;
}

.btn-outline {
    background-color: #ffffff;
    border: 1.8px solid var(--primary-red);
    color: var(--primary-red) !important;
    border-radius: 14px;
    box-shadow: 0 2px 10px rgba(225, 29, 72, 0.08);
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

.btn-outline i {
    transition: transform 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

.btn-outline:hover {
    background: linear-gradient(135deg, #e11d48 0%, #be123c 100%) !important;
    color: #ffffff !important;
    border-color: #be123c !important;
    transform: translateY(-2.5px);
    box-shadow: 0 8px 24px rgba(225, 29, 72, 0.38) !important;
}

.btn-outline:hover i {
    color: #ffffff !important;
    transform: translateX(-4px);
}

.btn-secondary {
    background-color: #ffffff;
    color: var(--secondary-slate) !important;
    border: 1.5px solid #cbd5e1;
    border-radius: 14px;
    box-shadow: 0 2px 8px rgba(15, 23, 42, 0.05);
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

.btn-secondary i {
    transition: transform 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

.btn-secondary:hover {
    background-color: var(--secondary-slate) !important;
    color: #ffffff !important;
    border-color: var(--secondary-slate) !important;
    transform: translateY(-2.5px);
    box-shadow: 0 8px 20px rgba(15, 23, 42, 0.22) !important;
}

.btn-secondary:hover i {
    color: #ffffff !important;
    transform: translateX(-4px);
}

.btn-whatsapp {
    background-color: #25d366;
    color: #ffffff !important;
    border: none;
    box-shadow: 0 4px 12px rgba(37, 211, 102, 0.3);
}

.btn-whatsapp:hover {
    background-color: #128c7e;
    color: #ffffff !important;
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(37, 211, 102, 0.4);
}

.btn-urgent {
    background: linear-gradient(135deg, #dc2626 0%, #991b1b 100%);
    color: #ffffff !important;
    box-shadow: 0 4px 14px rgba(220, 38, 38, 0.35);
    border: none;
}

.btn-urgent:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(220, 38, 38, 0.45);
}

.btn-donate {
    background: linear-gradient(135deg, #d97706 0%, #b45309 100%);
    color: #ffffff !important;
    box-shadow: 0 4px 14px rgba(217, 119, 6, 0.35);
    border: none;
    font-weight: 800;
}

.btn-donate:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(217, 119, 6, 0.45);
}

.btn-eye {
    padding: 0.45rem 0.65rem;
    font-size: 0.9rem;
    color: var(--secondary-slate);
    border-color: #cbd5e1;
}

.btn-eye:hover {
    background-color: var(--secondary-slate);
    color: #ffffff;
    border-color: var(--secondary-slate);
}

.btn-search {
    padding: 0 1.75rem;
    font-size: 0.98rem;
}

/* Hero & Search Filter Section */
.hero-section {
    position: relative;
    padding: 3.5rem 0 4rem;
    background: linear-gradient(180deg, #ffffff 0%, #f8fafc 100%);
    overflow: hidden;
}

.hero-bg-blobs {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 1;
}

.blob {
    position: absolute;
    border-radius: 50%;
    filter: blur(90px);
    opacity: 0.12;
}

.blob-1 {
    top: -10%;
    left: -5%;
    width: 500px;
    height: 500px;
    background: var(--primary-red);
}

.blob-2 {
    bottom: -10%;
    right: -5%;
    width: 550px;
    height: 550px;
    background: var(--secondary-slate);
}

.hero-container {
    position: relative;
    z-index: 2;
}

.hero-header {
    text-align: center;
    max-width: 800px;
    margin: 0 auto 2.5rem;
}

.hero-tag {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    background-color: #ffe4e6;
    color: var(--primary-dark-red);
    padding: 0.4rem 1.1rem;
    border-radius: var(--radius-full);
    font-size: 0.88rem;
    font-weight: 700;
    margin-bottom: 1.25rem;
    border: 1px solid #fecdd3;
}

.hero-title {
    font-size: 3.1rem;
    letter-spacing: -1.2px;
    margin-bottom: 1rem;
    line-height: 1.15;
}

.hero-description {
    font-size: 1.15rem;
    color: var(--text-muted);
    line-height: 1.6;
}

/* Filter Card UI - UPGRADED & ACCESSIBLE */
.filter-card {
    background: var(--bg-card);
    border-radius: var(--radius-lg);
    padding: 2rem 2.25rem;
    box-shadow: var(--shadow-lg);
    border: 1.5px solid #e2e8f0;
}

.filter-card-header {
    margin-bottom: 1.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.filter-card-header h2 {
    font-size: 1.35rem;
    display: flex;
    align-items: center;
    gap: 0.6rem;
}

.filter-subtitle {
    color: var(--text-muted);
    font-size: 0.88rem;
}

.filter-form {
    display: grid;
    grid-template-columns: 1fr 1fr auto auto;
    gap: 1.25rem;
    align-items: flex-end;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.45rem;
}

.form-group label {
    font-size: 0.88rem;
    font-weight: 700;
    color: var(--secondary-slate);
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

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

.form-control, .form-control-sm {
    width: 100%;
    height: 46px; /* Fixed height for inputs */
    padding: 0 1rem;
    border: 1.5px solid #cbd5e1;
    border-radius: var(--radius-md);
    font-size: 0.95rem;
    background-color: #ffffff;
    color: var(--text-main);
    font-weight: 500;
    transition: var(--transition);
    appearance: none;
    background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2064748b' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6 9 12 15 18 9'%3e%3c/polyline%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right 1rem center;
    background-size: 1.1em;
}

select.form-control {
    padding-right: 2.5rem;
}

input[type="text"].form-control,
input[type="tel"].form-control,
input[type="email"].form-control,
input[type="date"].form-control,
input[type="number"].form-control {
    background-image: none;
}

.form-control-sm {
    height: 38px;
    padding: 0 0.8rem;
    font-size: 0.88rem;
    border-radius: var(--radius-sm);
}

.form-control:focus, .form-control-sm:focus {
    border-color: var(--primary-red);
    box-shadow: 0 0 0 4px var(--primary-glow);
    outline: none;
}

/* Toggle Switch */
.checkbox-group {
    justify-content: flex-end;
}

.toggle-container {
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    cursor: pointer;
    user-select: none;
    min-height: 46px;
    height: auto;
    padding: 0.35rem 0.5rem;
}

.toggle-container input {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
}

.toggle-switch {
    width: 48px;
    height: 26px;
    background-color: #cbd5e1;
    border-radius: var(--radius-full);
    position: relative;
    transition: var(--transition);
    flex-shrink: 0;
}

.toggle-switch::before {
    content: "";
    position: absolute;
    top: 3px;
    left: 3px;
    width: 20px;
    height: 20px;
    background-color: white;
    border-radius: 50%;
    transition: var(--transition);
    box-shadow: 0 2px 4px rgba(0,0,0,0.15);
}

.toggle-container input:checked + .toggle-switch {
    background-color: var(--primary-red);
}

.toggle-container input:checked + .toggle-switch::before {
    transform: translateX(22px);
}

.toggle-label {
    font-weight: 700;
    font-size: 0.9rem;
    color: var(--secondary-slate);
    white-space: normal;
    word-break: break-word;
    line-height: 1.35;
}

.form-actions {
    display: flex;
    gap: 0.6rem;
    white-space: nowrap;
}

/* Quick Select Pills */
.quick-pills-container {
    margin-top: 1.5rem;
    padding-top: 1.25rem;
    border-top: 1px dashed #e2e8f0;
    display: flex;
    align-items: center;
    gap: 1rem;
    flex-wrap: wrap;
}

.quick-pills-label {
    font-size: 0.85rem;
    font-weight: 800;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.quick-pills {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.pill-btn {
    background: #f1f5f9;
    border: 1.5px solid #e2e8f0;
    color: var(--text-main);
    padding: 0.4rem 1rem;
    border-radius: var(--radius-full);
    font-size: 0.88rem;
    font-weight: 700;
    transition: var(--transition);
    white-space: nowrap;
}

.pill-btn:hover, .pill-btn.active {
    background-color: var(--primary-red);
    color: #ffffff;
    border-color: var(--primary-red);
    box-shadow: 0 4px 12px rgba(230, 57, 70, 0.3);
}

/* Donors Results Section */
.results-section {
    padding: 4rem 0;
}

.results-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    margin-bottom: 2rem;
    flex-wrap: wrap;
    gap: 1rem;
}

.section-title {
    font-size: 2.1rem;
    margin-bottom: 0.35rem;
}

.section-subtitle {
    color: var(--text-muted);
    font-size: 1rem;
}

.results-toolbar {
    display: flex;
    align-items: center;
    gap: 1.25rem;
    flex-wrap: wrap;
}

.results-sort {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    white-space: nowrap;
}

.results-sort label {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    font-size: 0.88rem;
    font-weight: 700;
    color: var(--secondary-slate);
    white-space: nowrap;
    margin: 0;
}

.view-toggle-group {
    display: inline-flex;
    background: #e2e8f0;
    padding: 3px;
    border-radius: var(--radius-md);
    gap: 3px;
}

.view-btn {
    padding: 0.45rem 0.85rem;
    border-radius: var(--radius-sm);
    font-size: 0.88rem;
    font-weight: 700;
    color: var(--text-muted);
    background: transparent;
    cursor: pointer;
    transition: var(--transition);
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    border: none;
}

.view-btn.active {
    background: #ffffff;
    color: var(--primary-red);
    box-shadow: var(--shadow-sm);
}

.view-btn:hover:not(.active) {
    color: var(--secondary-slate);
}

/* Initial Search State */
.initial-search-state {
    text-align: center;
    padding: 3.5rem 1.5rem;
    background: #ffffff;
    border-radius: var(--radius-lg);
    border: 2px dashed #cbd5e1;
    margin: 1.5rem 0;
    box-shadow: var(--shadow-sm);
}

.initial-search-card {
    max-width: 540px;
    margin: 0 auto;
}

.initial-icon {
    font-size: 3.2rem;
    color: var(--primary-red);
    margin-bottom: 1rem;
    display: inline-block;
    background: #fff1f2;
    width: 80px;
    height: 80px;
    line-height: 80px;
    border-radius: 50%;
}

.initial-search-card h3 {
    font-size: 1.4rem;
    margin-bottom: 0.5rem;
    color: var(--secondary-slate);
}

.initial-search-card p {
    color: var(--text-muted);
    font-size: 0.96rem;
    line-height: 1.5;
}

/* Desktop List View Container & Rows */
.donors-list-container {
    display: flex;
    flex-direction: column;
    gap: 0.85rem;
    margin-top: 1.5rem;
}

.donor-list-row {
    display: grid;
    grid-template-columns: 60px 1.8fr 1.3fr minmax(170px, auto) auto;
    align-items: center;
    gap: 1.25rem;
    background: #ffffff;
    padding: 1.1rem 1.35rem;
    border-radius: var(--radius-md);
    border: 1.5px solid #e2e8f0;
    box-shadow: var(--shadow-card);
    transition: var(--transition);
}

.donor-list-row:hover {
    transform: none;
    border-color: #fecdd3;
    box-shadow: var(--shadow-md);
}

/* Deactivated / Status-based Donor Card & Row Styling */
.donor-card.status-cooldown,
.donor-list-row.status-cooldown {
    background-color: #fff8f8 !important;
    border-color: #fca5a5 !important;
    box-shadow: 0 2px 8px rgba(239, 68, 68, 0.06) !important;
}

.donor-card.status-cooldown:hover,
.donor-list-row.status-cooldown:hover {
    transform: none;
    border-color: #f87171 !important;
}

.donor-card.status-cooldown .donor-blood-badge,
.donor-list-row.status-cooldown .donor-blood-badge,
.donor-card.status-cooldown .blood-badge {
    background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%) !important;
    opacity: 0.85;
}

.donor-card.status-unavailable,
.donor-list-row.status-unavailable {
    background-color: #f1f5f9 !important;
    border-color: #cbd5e1 !important;
    opacity: 0.85;
    box-shadow: none !important;
}

.donor-card.status-unavailable:hover,
.donor-list-row.status-unavailable:hover {
    transform: none;
    border-color: #94a3b8 !important;
}

.donor-card.status-unavailable .donor-blood-badge,
.donor-list-row.status-unavailable .donor-blood-badge,
.donor-card.status-unavailable .blood-badge {
    background: linear-gradient(135deg, #64748b 0%, #475569 100%) !important;
    color: #ffffff !important;
    box-shadow: none !important;
}

.donor-card.deactivated .donor-avatar,
.donor-card.status-unavailable .donor-avatar {
    background: #94a3b8 !important;
    color: #ffffff !important;
}

.status-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.38rem 0.8rem;
    border-radius: var(--radius-full);
    font-size: 0.8rem;
    font-weight: 700;
    white-space: nowrap;
    line-height: 1.2;
}

.status-badge.available {
    background-color: #dcfce7 !important;
    color: #15803d !important;
    border: 1px solid #bbf7d0 !important;
}

.status-badge.cooldown,
.status-pill.cooldown {
    background-color: #fef3c7 !important;
    color: #92400e !important;
    border: 1px solid #fde68a !important;
}

.status-badge.unavailable,
.status-pill.unavailable {
    background-color: #e2e8f0 !important;
    color: #475569 !important;
    border: 1px solid #cbd5e1 !important;
}

.btn-disabled,
.btn-disabled:hover,
a.btn-disabled,
a.btn-disabled:hover,
button.btn-disabled,
button.btn-disabled:hover {
    opacity: 0.45 !important;
    pointer-events: none !important;
    cursor: not-allowed !important;
    box-shadow: none !important;
    transform: none !important;
    filter: grayscale(0.6) !important;
    background: #e2e8f0 !important;
    color: #64748b !important;
    border-color: #cbd5e1 !important;
}

.list-col-badge {
    display: flex;
    align-items: center;
    justify-content: center;
}

.list-col-badge .donor-blood-badge,
.list-col-badge .blood-badge {
    margin: 0;
    flex-shrink: 0;
}

.list-col-info {
    display: flex;
    flex-direction: column;
    gap: 0.2rem;
    min-width: 0;
}

.list-donor-name {
    font-size: 1.05rem;
    font-weight: 800;
    color: var(--secondary-slate);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.list-donor-location {
    font-size: 0.86rem;
    color: var(--text-muted);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.list-col-stats {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
    font-size: 0.85rem;
    color: var(--text-muted);
    min-width: 0;
}

.list-col-status {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    min-width: 170px;
}

.list-col-actions {
    display: flex;
    gap: 0.5rem;
    justify-content: flex-end;
    align-items: center;
    flex-shrink: 0;
    min-width: 210px;
}

.list-col-actions .btn {
    padding: 0.45rem 0.75rem;
    font-size: 0.82rem;
}

@media (max-width: 1200px) {
    .donor-list-row {
        grid-template-columns: 55px 1.5fr 1.2fr minmax(160px, auto) auto;
        gap: 0.85rem;
        padding: 1rem;
    }
}

/* Pagination UI */
.pagination-container {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0.45rem;
    margin-top: 2.5rem;
    flex-wrap: wrap;
}

.page-btn {
    min-width: 40px;
    height: 40px;
    padding: 0 0.65rem;
    border-radius: var(--radius-md);
    border: 1.5px solid #cbd5e1;
    background: #ffffff;
    font-weight: 800;
    font-size: 0.9rem;
    color: var(--secondary-slate);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: var(--transition);
}

.page-btn:hover:not(:disabled) {
    border-color: var(--primary-red);
    color: var(--primary-red);
    background-color: #fff1f2;
}

.page-btn.active {
    background: var(--primary-red);
    color: #ffffff;
    border-color: var(--primary-red);
    box-shadow: 0 4px 12px rgba(230, 57, 70, 0.35);
}

.page-btn:disabled {
    opacity: 0.45;
    cursor: not-allowed;
}

.page-info-text {
    font-size: 0.9rem;
    font-weight: 700;
    color: var(--text-muted);
    margin: 0 0.5rem;
}

/* Donor Cards Grid */
.donors-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
    gap: 1.75rem;
}

/* Donor Card Design */
.donor-card {
    background: var(--bg-card);
    border-radius: var(--radius-md);
    padding: 1.6rem;
    border: 1.5px solid #e2e8f0;
    box-shadow: var(--shadow-card);
    transition: var(--transition);
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.donor-card:hover {
    transform: none;
    box-shadow: var(--shadow-md);
    border-color: #cbd5e1;
}

.donor-card-top {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 1.25rem;
    gap: 0.75rem;
}

.donor-avatar-wrap {
    display: flex;
    align-items: center;
    gap: 0.85rem;
}

.donor-avatar {
    width: 52px;
    height: 52px;
    border-radius: 50%;
    background: linear-gradient(135deg, #e2e8f0 0%, #cbd5e1 100%);
    color: var(--secondary-slate);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.35rem;
    font-weight: 800;
    flex-shrink: 0;
}

.donor-info h3 {
    font-size: 1.15rem;
    color: var(--secondary-slate);
    margin-bottom: 0.15rem;
}

.donor-location {
    font-size: 0.85rem;
    color: var(--text-muted);
    display: flex;
    align-items: center;
    gap: 0.3rem;
}

/* Blood Drop Badge */
.blood-badge {
    width: 48px;
    height: 48px;
    background: linear-gradient(135deg, var(--primary-red) 0%, var(--primary-dark-red) 100%);
    color: white;
    border-radius: 50% 50% 50% 0;
    transform: rotate(-45deg);
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 12px rgba(230, 57, 70, 0.35);
    flex-shrink: 0;
}

.blood-badge span {
    transform: rotate(45deg);
    font-weight: 800;
    font-size: 1rem;
    letter-spacing: -0.5px;
}

.donor-details-list {
    list-style: none;
    margin-bottom: 1.25rem;
    display: flex;
    flex-direction: column;
    gap: 0.65rem;
    font-size: 0.88rem;
    color: var(--text-main);
    background: #f8fafc;
    padding: 0.9rem 1.1rem;
    border-radius: var(--radius-sm);
    border: 1px solid #f1f5f9;
}

.donor-details-list li {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.detail-label {
    color: var(--text-muted);
    font-weight: 600;
}

.detail-value {
    font-weight: 700;
}

/* Availability Pills */
.status-pill {
    font-size: 0.76rem;
    font-weight: 800;
    padding: 0.25rem 0.7rem;
    border-radius: var(--radius-full);
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    white-space: nowrap;
}

.status-pill.available {
    background-color: var(--status-available-bg);
    color: var(--status-available);
}

.status-pill.busy {
    background-color: var(--status-busy-bg);
    color: var(--status-busy);
}

.donor-actions {
    display: flex;
    gap: 0.6rem;
}

.donor-actions .btn {
    flex: 1;
    padding: 0 0.5rem;
    font-size: 0.88rem;
}

/* Empty State */
.empty-state {
    text-align: center;
    padding: 4rem 2rem;
    background-color: white;
    border-radius: var(--radius-lg);
    border: 2px dashed #cbd5e1;
    max-width: 600px;
    margin: 2rem auto;
}

.empty-icon {
    font-size: 3.5rem;
    color: var(--text-light);
    margin-bottom: 1rem;
}

.empty-state h3 {
    font-size: 1.4rem;
    margin-bottom: 0.5rem;
}

.empty-state p {
    color: var(--text-muted);
    margin-bottom: 1.5rem;
}

.empty-actions {
    display: flex;
    justify-content: center;
    gap: 1rem;
}

/* Urgent Requests Section */
.dashboard-section {
    padding: 4.5rem 0;
    background: #ffffff;
}

.dashboard-shell {
    display: grid;
    grid-template-columns: 0.9fr 1.1fr;
    gap: 2rem;
    align-items: start;
    background: #f8fafc;
    border: 1.5px solid #e2e8f0;
    border-radius: var(--radius-lg);
    padding: 2rem;
    box-shadow: var(--shadow-card);
}

.guideline-item-card:hover {
    border-color: #fca5a5 !important;
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(225, 29, 72, 0.08) !important;
}

.dashboard-summary {
    display: flex;
    flex-direction: column;
    gap: 0.85rem;
}

.dashboard-profile-card {
    margin-top: 0.75rem;
    background: #ffffff;
    border: 1.5px solid #e2e8f0;
    border-radius: var(--radius-md);
    padding: 1.25rem;
    display: flex;
    gap: 1rem;
    align-items: flex-start;
    box-shadow: var(--shadow-sm);
}

.dashboard-avatar {
    width: 64px;
    height: 64px;
    border-radius: 50% 50% 50% 0;
    transform: rotate(-45deg);
    background: linear-gradient(135deg, var(--primary-red) 0%, var(--primary-dark-red) 100%);
    color: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 900;
    flex-shrink: 0;
    line-height: 1;
    box-shadow: 0 8px 18px rgba(230, 57, 70, 0.3);
}

.dashboard-avatar span {
    transform: rotate(45deg);
}

.dashboard-profile-main {
    min-width: 0;
}

.dashboard-profile-main h3 {
    font-size: 1.25rem;
    margin-bottom: 0.25rem;
}

.dashboard-profile-main p {
    color: var(--text-muted);
    font-size: 0.9rem;
    margin-bottom: 0.7rem;
}

.dashboard-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 0.55rem;
}

.dashboard-meta span:not(.status-pill) {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    background: #f1f5f9;
    border: 1px solid #e2e8f0;
    color: var(--secondary-slate);
    border-radius: var(--radius-full);
    padding: 0.3rem 0.7rem;
    font-size: 0.78rem;
    font-weight: 800;
}

.dashboard-form {
    background: #ffffff;
    border: 1.5px solid #e2e8f0;
    border-radius: var(--radius-md);
    padding: 1.5rem;
    box-shadow: var(--shadow-sm);
}

.dashboard-actions {
    margin-top: 1.5rem;
    padding-top: 1.25rem;
    border-top: 1px solid #f1f5f9;
    display: flex;
    gap: 0.75rem;
    justify-content: flex-end;
    flex-wrap: wrap;
}

.urgent-section {
    padding: 4.5rem 0;
    background: #f1f5f9;
}

.section-header-flex {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    margin-bottom: 2.25rem;
    flex-wrap: wrap;
    gap: 1rem;
}

.badge-urgent {
    background-color: #fee2e2;
    color: #dc2626;
    font-weight: 800;
    font-size: 0.8rem;
    padding: 0.3rem 0.85rem;
    border-radius: var(--radius-full);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.urgent-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(360px, 1fr));
    gap: 1.5rem;
}

.urgent-card {
    background: #ffffff;
    border-radius: var(--radius-md);
    padding: 1.6rem;
    border-left: 5px solid var(--primary-red);
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
    position: relative;
    overflow: visible;
}

.urgent-card:hover {
    box-shadow: var(--shadow-md);
    transform: translateY(-3px);
}

.urgent-share-dropdown-wrap {
    position: relative;
    display: inline-block;
}

.urgent-quick-share-btn {
    background: rgba(225, 29, 72, 0.08);
    color: var(--primary-red);
    border: 1px solid rgba(225, 29, 72, 0.2);
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 0.85rem;
    transition: all 0.2s ease;
}

.urgent-share-dropdown-wrap:hover .urgent-quick-share-btn,
.urgent-quick-share-btn:hover {
    background: var(--primary-red);
    color: #ffffff;
    border-color: var(--primary-red);
    transform: scale(1.08);
    box-shadow: 0 4px 10px rgba(225, 29, 72, 0.25);
}

/* Minimalist Upward Pop-up Menu */
.urgent-share-popup-up {
    position: absolute;
    bottom: calc(100% + 10px);
    right: 0;
    display: flex;
    align-items: center;
    gap: 0.35rem;
    background: #ffffff;
    padding: 0.35rem 0.5rem;
    border-radius: 30px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15), 0 2px 6px rgba(0, 0, 0, 0.08);
    border: 1px solid #e2e8f0;
    opacity: 0;
    visibility: hidden;
    transform: translateY(6px);
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 1000;
    white-space: nowrap;
}

/* Minimal Arrow Indicator */
.urgent-share-popup-up::after {
    content: '';
    position: absolute;
    bottom: -6px;
    right: 17px;
    border-width: 6px 6px 0 6px;
    border-style: solid;
    border-color: #ffffff transparent transparent transparent;
}

.urgent-share-dropdown-wrap:hover .urgent-share-popup-up,
.urgent-share-dropdown-wrap.active-share .urgent-share-popup-up {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.share-icon-btn {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    border: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 0.85rem;
    color: #ffffff;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}

.share-icon-btn:hover {
    transform: scale(1.15);
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
}

.share-icon-btn.btn-fb { background: #1877f2; }
.share-icon-btn.btn-wa { background: #25d366; }
.share-icon-btn.btn-msg { background: #0084ff; }
.share-icon-btn.btn-copy { background: #e11d48; }

.urgent-card-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

.urgent-blood-badge {
    background: var(--primary-red);
    color: white;
    font-weight: 800;
    font-size: 1.1rem;
    padding: 0.35rem 0.9rem;
    border-radius: var(--radius-sm);
}

.urgent-units {
    background: #fff1f2;
    color: #be123c;
    font-weight: 800;
    font-size: 0.8rem;
    padding: 0.35rem 0.75rem;
    border-radius: var(--radius-full);
}

.urgent-patient {
    font-size: 1.25rem;
    margin-bottom: 0.6rem;
}

.urgent-info {
    font-size: 0.9rem;
    color: var(--text-muted);
    margin-bottom: 1.25rem;
    display: flex;
    flex-direction: column;
    gap: 0.45rem;
}

.urgent-info i {
    width: 20px;
    color: var(--primary-red);
}

.urgent-card-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 1rem;
    border-top: 1px solid #f1f5f9;
}

/* Compatibility Guide */
.compatibility-section {
    padding: 5rem 0;
}

.compat-grid {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 2rem;
    align-items: start;
}

.compat-table-card, .compat-info-card {
    background: white;
    border-radius: var(--radius-md);
    padding: 1.75rem;
    box-shadow: var(--shadow-card);
    border: 1.5px solid #e2e8f0;
}

.compat-table {
    width: 100%;
    border-collapse: collapse;
    text-align: left;
}

.compat-table th, .compat-table td {
    padding: 0.95rem 1rem;
    border-bottom: 1px solid #f1f5f9;
    font-size: 0.92rem;
}

.compat-table th {
    background-color: #f8fafc;
    font-weight: 700;
    color: var(--secondary-slate);
}

.badge-blood {
    display: inline-block;
    padding: 0.25rem 0.65rem;
    border-radius: var(--radius-sm);
    font-weight: 800;
    color: white;
    background-color: var(--primary-red);
}

.info-list {
    list-style: none;
    margin-top: 1rem;
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
}

.info-list li {
    display: flex;
    gap: 1rem;
}

.info-list i {
    font-size: 1.3rem;
    margin-top: 0.2rem;
}

.info-list p {
    font-size: 0.85rem;
    color: var(--text-muted);
}

/* Stats Section */
.stats-section {
    padding: 4rem 0;
    background: linear-gradient(135deg, var(--secondary-slate) 0%, var(--secondary-dark) 100%);
    color: white;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 2rem;
    text-align: center;
}

.stat-icon {
    font-size: 2.2rem;
    color: var(--primary-light-red);
    margin-bottom: 0.5rem;
}

.stat-number {
    font-family: 'Outfit', sans-serif;
    font-size: 2.75rem;
    font-weight: 800;
    margin-bottom: 0.2rem;
}

.stat-label {
    color: #94a3b8;
    font-size: 0.95rem;
    font-weight: 600;
}

/* Footer */
.footer {
    background-color: #0b1329;
    color: #94a3b8;
    padding: 4rem 0 0;
    font-size: 0.9rem;
}

.footer-container {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1.5fr;
    gap: 3rem;
    margin-bottom: 3rem;
}

.footer-brand .logo-title {
    color: white;
}

.footer-brand p {
    margin: 1rem 0;
}

.social-links {
    display: flex;
    gap: 0.75rem;
}

.social-links a {
    width: 36px;
    height: 36px;
    background: rgba(255, 255, 255, 0.08);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.social-links a:hover {
    background: var(--primary-red);
}

.footer-col h4 {
    color: white;
    font-size: 1.1rem;
    margin-bottom: 1.2rem;
}

.footer-col ul {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
}

.footer-col ul a {
    color: #94a3b8;
}

.footer-col ul a:hover {
    color: white;
}

.footer-blood-tags {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 0.5rem;
}

.footer-blood-tags span {
    background: rgba(255, 255, 255, 0.08);
    color: white;
    text-align: center;
    padding: 0.3rem;
    border-radius: var(--radius-sm);
    font-weight: 700;
    font-size: 0.8rem;
}

.footer-bottom {
    background-color: #050b18;
    padding: 1.25rem 0;
    text-align: center;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
}

/* Modals */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    height: 100dvh;
    z-index: 2500;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1.5rem;
    overflow-y: auto !important;
    -webkit-overflow-scrolling: touch;
}

.modal-backdrop {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(15, 23, 42, 0.65);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    z-index: 1;
}

.modal .modal-container {
    position: relative;
    z-index: 2;
    background: #ffffff;
    border-radius: var(--radius-lg);
    width: 100%;
    max-width: 720px;
    max-height: 90vh;
    max-height: 90dvh;
    display: flex;
    flex-direction: column;
    overflow-y: auto !important;
    overflow-x: hidden;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    animation: modalSlideUp 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    -webkit-overflow-scrolling: touch;
    overscroll-behavior: contain;
}

.modal .modal-form {
    padding: 1.75rem;
    padding-bottom: 3.5rem !important;
    overflow-y: auto !important;
    -webkit-overflow-scrolling: touch;
}

.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    height: 100dvh;
    background: rgba(15, 23, 42, 0.7);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    z-index: 10000 !important; /* Render above mobile-bottom-nav (z-index 9990) */
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1.5rem;
    opacity: 1;
    transition: opacity 0.3s ease;
    overflow-y: auto !important;
    -webkit-overflow-scrolling: touch;
}

.modal-container {
    background: #ffffff;
    border-radius: var(--radius-lg);
    width: 100%;
    max-width: 720px;
    max-height: 90vh;
    max-height: 90dvh;
    display: flex;
    flex-direction: column;
    overflow-y: auto !important;
    overflow-x: hidden;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    animation: modalSlideUp 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    -webkit-overflow-scrolling: touch;
    overscroll-behavior: contain;
}

.modal-container.modal-md {
    max-width: 520px;
}

.modal-header {
    padding: 1.5rem 2rem;
    border-bottom: 1px solid #f1f5f9;
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: sticky;
    top: 0;
    background: #ffffff;
    z-index: 20;
    flex-shrink: 0;
}

.modal-title-wrap {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.modal-icon {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    flex-shrink: 0;
}

.red-icon {
    background-color: #ffe4e6;
    color: var(--primary-red);
}

.modal-header h3 {
    font-size: 1.25rem;
}

.modal-header p {
    font-size: 0.85rem;
    color: var(--text-muted);
}

.modal-close {
    background: none;
    font-size: 1.8rem;
    color: var(--text-muted);
    padding: 0.2rem 0.5rem;
}

.modal-close:hover {
    color: var(--primary-red);
}

.modal-form {
    padding: 1.75rem 2rem;
    overflow: visible;
    flex: 1 1 auto;
}

.form-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.25rem;
}

.form-help {
    font-size: 0.75rem;
    color: var(--text-muted);
}

.modal-footer {
    display: flex;
    justify-content: flex-end;
    gap: 0.75rem;
    margin-top: 2rem;
    padding-top: 1.25rem;
    border-top: 1px solid #f1f5f9;
}

/* Toast Notifications */
.toast-container {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    z-index: 3000;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.toast {
    background: var(--secondary-slate);
    color: white;
    padding: 0.85rem 1.4rem;
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-lg);
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-weight: 600;
    animation: toastIn 0.3s forwards;
    border-left: 4px solid var(--primary-red);
}

.toast.success { border-left-color: var(--status-available); }
.toast.info { border-left-color: #3b82f6; }

/* Keyframe Animations */
@keyframes pulseGlow {
    0% { box-shadow: 0 0 0 0 rgba(250, 204, 21, 0.7); }
    70% { box-shadow: 0 0 0 8px rgba(250, 204, 21, 0); }
    100% { box-shadow: 0 0 0 0 rgba(250, 204, 21, 0); }
}

@keyframes btnGlow {
    0%, 100% { box-shadow: 0 4px 14px rgba(230, 57, 70, 0.35); }
    50% { box-shadow: 0 4px 22px rgba(230, 57, 70, 0.65); }
}

@keyframes modalSlideUp {
    from { opacity: 0; transform: translateY(20px) scale(0.97); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}

@keyframes toastIn {
    from { opacity: 0; transform: translateX(50px); }
    to { opacity: 1; transform: translateX(0); }
}

/* ==========================================================================
   ADVANCED ULTRA-RESPONSIVE MEDIA QUERIES (DESKTOP, TABLET, MOBILE)
   ========================================================================== */

/* Laptop & Desktop below 1200px */
@media (max-width: 1200px) {
    .nav-links {
        gap: 0.85rem;
    }
    .nav-item {
        padding: 0.4rem 0.55rem;
        font-size: 0.86rem;
    }
    .btn {
        padding: 0.6rem 0.9rem;
        font-size: 0.86rem;
    }
    .language-selector {
        padding: 0 0.55rem;
    }
    .profile-name {
        display: none;
    }
    .filter-form {
        grid-template-columns: repeat(2, 1fr);
    }
    .donors-grid, .urgent-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* Tablets below 992px */
@media (max-width: 992px) {
    .hero-title {
        font-size: 2.3rem;
    }
    .hero-description {
        font-size: 1rem;
    }
    
    /* Navigation Drawer */
    .nav-links {
        display: none;
    }
    .nav-links.active {
        display: flex;
        flex-direction: column;
        align-items: stretch;
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        background: rgba(255, 255, 255, 0.98);
        backdrop-filter: blur(20px);
        -webkit-backdrop-filter: blur(20px);
        padding: 1.25rem 1.5rem;
        box-shadow: 0 20px 40px rgba(15, 23, 42, 0.15);
        border-bottom: 2px solid rgba(230, 57, 70, 0.15);
        gap: 0.65rem;
        z-index: 1001;
        animation: modalSlideUp 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    }
    .nav-links.active .nav-item {
        width: 100%;
        padding: 0.85rem 1.15rem;
        border-radius: var(--radius-md);
        font-size: 0.98rem;
        background-color: var(--bg-main);
        border: 1px solid #e2e8f0;
        justify-content: flex-start;
    }
    .nav-links.active .nav-item.active {
        background-color: #fff1f2;
        border-color: #fecdd3;
    }
    
    .mobile-menu-btn {
        display: inline-flex;
        align-items: center;
        justify-content: center;
    }

    .mobile-only-actions {
        display: flex;
        flex-direction: column;
        gap: 0.55rem;
        width: 100%;
        margin-top: 0.5rem;
        padding-top: 0.75rem;
        border-top: 1px solid #e2e8f0;
    }

    .mobile-only-actions .btn {
        width: 100%;
        justify-content: center;
    }

    .nav-actions #openUrgentModalBtn,
    .nav-actions #openLoginModalBtn,
    .nav-actions #openRegisterModalBtn {
        display: none !important;
    }

    .mobile-header-profile-btn:not(.hidden) {
        display: inline-flex !important;
    }

    .filter-card {
        padding: 1.5rem 1.25rem;
    }
    .compat-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    .dashboard-shell {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    .footer-container {
        grid-template-columns: repeat(2, 1fr);
        gap: 2rem;
    }
}

/* Mobile Devices below 768px */
@media (max-width: 768px) {
    .container {
        padding: 0 1rem;
    }
    
    /* Emergency Bar */
    .emergency-bar {
        white-space: normal;
        padding: 0.65rem 0;
    }
    .emergency-content {
        flex-direction: column;
        gap: 0.45rem;
        text-align: center;
        justify-content: center;
    }
    .emergency-text {
        font-size: 0.8rem;
        line-height: 1.35;
        text-align: center;
        justify-content: center;
        flex-wrap: wrap;
    }
    .hotline {
        display: inline-flex;
        margin-top: 0.2rem;
    }

    /* Navbar Actions on Mobile */
    .nav-container {
        gap: 0.5rem;
        padding-left: 15px;
        padding-right: 15px;
    }
    .nav-actions {
        gap: 0.4rem;
    }
    .nav-actions .btn {
        padding: 0.45rem 0.7rem;
        font-size: 0.8rem;
    }
    .nav-actions #openUrgentModalBtn {
        display: none;
    }

    /* Hero Section */
    .hero-section {
        padding: 2rem 0 2.5rem;
    }
    .hero-title {
        font-size: 1.85rem;
        line-height: 1.25;
    }
    .hero-description {
        font-size: 0.92rem;
    }

    /* Filters */
    .filter-card-header {
        flex-direction: column !important;
        align-items: flex-start !important;
        gap: 0.5rem !important;
    }
    .filter-form {
        grid-template-columns: 1fr;
        gap: 0.85rem;
    }
    .checkbox-group {
        justify-content: flex-start;
    }
    .form-actions {
        flex-direction: column;
        width: 100%;
        gap: 0.65rem;
    }
    .form-actions .btn {
        width: 100%;
        justify-content: center;
    }

    /* Horizontal Scrollable Pills on Mobile */
    .quick-pills {
        display: flex;
        flex-wrap: nowrap;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        padding-bottom: 0.5rem;
        gap: 0.45rem;
        scrollbar-width: none;
    }
    .quick-pills::-webkit-scrollbar {
        display: none;
    }
    .pill-btn {
        flex-shrink: 0;
        font-size: 0.8rem;
        padding: 0.35rem 0.75rem;
    }

    /* Hide View Toggle Tabs on Mobile (Default Grid View) */
    .view-toggle-group {
        display: none !important;
    }

    /* Cards Grid */
    .donors-grid, .urgent-grid {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    .donor-card-body, .urgent-card {
        padding: 1.15rem 1rem;
    }
    .donor-card-actions {
        flex-direction: column;
        gap: 0.55rem;
    }
    .donor-card-actions .btn {
        width: 100%;
        justify-content: center;
    }

    /* Form Grid */
    .form-grid {
        grid-template-columns: 1fr;
        gap: 0.85rem;
    }

    /* Stats Grid */
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 0.85rem;
    }

    /* Footer */
    .footer-container {
        grid-template-columns: 1fr;
        gap: 2rem;
        text-align: center;
    }
    .footer-brand, .footer-social {
        justify-content: center;
    }

    /* Modals Native Bottom-Sheet for Mobile (Fixed Scroll & Height Clipping) */
    .modal-overlay {
        padding: 0.5rem 0 0 0 !important;
        align-items: flex-end !important;
        justify-content: center !important;
        overflow-y: auto !important;
        -webkit-overflow-scrolling: touch;
    }

    .modal-container {
        max-width: 100% !important;
        width: 100% !important;
        max-height: calc(100dvh - 20px) !important;
        border-radius: 24px 24px 0 0 !important;
        margin: 0 !important;
        padding: 0 !important;
        box-shadow: 0 -10px 40px rgba(0, 0, 0, 0.35) !important;
        animation: modalSlideUpSheet 0.3s cubic-bezier(0.16, 1, 0.3, 1) !important;
        position: relative;
        display: flex !important;
        flex-direction: column !important;
        overflow-y: auto !important;
        overflow-x: hidden !important;
        -webkit-overflow-scrolling: touch !important;
    }

    .modal-container::before {
        content: '';
        display: block;
        width: 38px;
        height: 5px;
        background: #cbd5e1;
        border-radius: 10px;
        margin: 10px auto 4px auto;
        flex-shrink: 0;
    }

    .modal-header {
        padding: 0.85rem 1.15rem 0.75rem !important;
        position: sticky;
        top: 0;
        background: #ffffff;
        z-index: 20;
        flex-shrink: 0;
    }

    .modal-header h3 {
        font-size: 1.1rem !important;
        line-height: 1.3;
    }

    .modal-icon {
        width: 36px !important;
        height: 36px !important;
        font-size: 1rem !important;
    }

    .modal-form,
    .profile-modal-content {
        flex: 1 1 auto !important;
        padding: 1.15rem 1.15rem 1.5rem !important;
        overflow-y: auto !important;
        -webkit-overflow-scrolling: touch !important;
    }

    .form-grid,
    .form-grid-inner {
        grid-template-columns: 1fr !important;
        gap: 0.85rem !important;
    }

    .form-group {
        margin-bottom: 0.85rem;
    }

    .form-group label {
        font-size: 0.85rem !important;
        margin-bottom: 0.35rem !important;
    }

    .form-control {
        height: 46px !important;
        font-size: 0.92rem !important;
        padding: 0.65rem 0.85rem !important;
        border-radius: 10px !important;
    }

    .address-cards-wrapper {
        grid-template-columns: 1fr !important;
        gap: 0.75rem !important;
    }

    .address-card {
        padding: 1rem !important;
        border-radius: 14px !important;
    }

    .modal-footer {
        flex-direction: column-reverse;
        gap: 0.65rem;
        padding: 1rem 0 0.5rem 0 !important;
        position: static !important;
        background: transparent !important;
        z-index: 1;
        border-top: 1px solid #f1f5f9;
        box-shadow: none !important;
        margin-top: 1rem;
    }

    .modal-footer .btn {
        width: 100%;
        justify-content: center;
    }

    /* Dashboard */
    .dashboard-section {
        padding: 2rem 0;
    }
    .dashboard-shell {
        padding: 1rem;
    }
    .dashboard-profile-card {
        flex-direction: column;
        text-align: center;
        gap: 1rem;
    }
    .dashboard-actions {
        flex-direction: column;
        gap: 0.65rem;
    }
    .dashboard-actions .btn {
        width: 100%;
        justify-content: center;
    }
}

@keyframes modalSlideUpSheet {
    from { transform: translateY(100%); }
    to { transform: translateY(0); }
}

/* Small Mobile & Smartphones (360px - 480px, 375px, 395px, 412px) */
@media (max-width: 480px) {
    .brand-logo {
        gap: 0.5rem;
    }
    .logo-icon {
        width: 38px;
        height: 38px;
        border-radius: 10px;
    }
    .logo-title {
        font-size: 1.05rem;
    }
    .bd-mark {
        margin-left: 0.18rem;
        padding: 0.05rem 0.22rem;
        font-size: 0.55rem;
    }
    .brand-logo .logo-subtitle {
        display: none;
    }

    .nav-actions .btn-outline,
    .nav-actions #openLoginModalBtn {
        display: none;
    }
    
    .language-selector {
        height: 36px;
        padding: 0 0.45rem;
        font-size: 0.8rem;
    }
    .language-selector i {
        display: none;
    }
    .profile-menu-toggle {
        padding: 0 0.45rem;
    }
    .profile-menu-toggle i {
        display: none;
    }
    .hero-title {
        font-size: 1.48rem !important;
        line-height: 1.25 !important;
    }
    .hero-description {
        font-size: 0.88rem !important;
    }
    .section-title {
        font-size: 1.3rem !important;
    }
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 0.65rem;
    }
    .stat-card {
        padding: 0.85rem 0.65rem;
    }
    .stat-number {
        font-size: 1.35rem;
    }
}

/* Extra Small Screens (360px, 375px, 395px Width Fixes) */
@media (max-width: 395px) {
    .container {
        padding: 0 0.75rem !important;
    }
    .hero-title {
        font-size: 1.35rem !important;
    }
    .modal-form {
        padding: 1rem 0.85rem 1.25rem !important;
    }
    .form-control {
        font-size: 0.88rem !important;
        padding: 0.55rem 0.75rem !important;
    }
    .donor-card-top {
        gap: 0.5rem;
    }
    .donor-avatar {
        width: 42px;
        height: 42px;
        font-size: 1.1rem;
    }
}


/* ==========================================================================
   DONATION MODAL & WIZARD STYLING (FIXED & RESPONSIVE)
   ========================================================================== */
.modal-donate-upgrade {
    max-width: 560px !important;
    border-radius: 24px !important;
    overflow-y: auto !important;
    overflow-x: hidden !important;
    padding: 0 !important;
    border: 1.5px solid rgba(225, 29, 72, 0.25) !important;
    box-shadow: 0 25px 60px rgba(15, 23, 42, 0.25) !important;
}

.modal-header-donate {
    background: linear-gradient(135deg, #fff1f2 0%, #ffe4e6 100%);
    padding: 1.25rem 1.5rem;
    border-bottom: 1.5px solid #fecdd3;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.donate-badge-icon {
    width: 44px;
    height: 44px;
    border-radius: 14px;
    background: linear-gradient(135deg, #e11d48 0%, #be123c 100%);
    color: #ffffff;
    font-size: 1.3rem;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 6px 16px rgba(225, 29, 72, 0.35);
    flex-shrink: 0;
}

.donate-header-desc {
    font-size: 0.82rem;
    color: #475569;
    margin: 0.2rem 0 0;
    line-height: 1.4;
}

/* Step Wizard Controller */
.donate-step-wizard {
    display: flex;
    align-items: center;
    justify-content: space-between;
    position: relative;
    margin: 1rem 1.5rem 0.85rem;
    padding: 0.75rem 1.1rem;
    background: #f8fafc;
    border-radius: 16px;
    border: 1.5px solid #e2e8f0;
}

.step-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.35rem;
    z-index: 2;
    position: relative;
    flex-shrink: 0;
    text-align: center;
}

.step-num {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: #ffffff;
    color: #64748b;
    font-weight: 800;
    font-size: 0.85rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    border: 2px solid #cbd5e1;
    box-shadow: 0 2px 6px rgba(15, 23, 42, 0.04);
}

.step-title {
    font-size: 0.76rem;
    font-weight: 700;
    color: #64748b;
    transition: color 0.3s ease;
    white-space: nowrap;
}

.step-line {
    flex: 1;
    height: 3px;
    background: #cbd5e1;
    margin: 0 0.4rem;
    margin-top: -1.2rem;
    transition: background 0.3s ease;
    border-radius: 2px;
}

.step-item.active .step-num {
    background: linear-gradient(135deg, #e11d48 0%, #be123c 100%);
    color: #ffffff;
    border-color: #e11d48;
    box-shadow: 0 4px 14px rgba(225, 29, 72, 0.4);
    transform: scale(1.08);
}

.step-item.active .step-title {
    color: #be123c;
    font-weight: 800;
}

.step-item.completed .step-num {
    background: #10b981;
    color: #ffffff;
    border-color: #059669;
}

.step-item.completed .step-title {
    color: #047857;
    font-weight: 700;
}

.step-line.active {
    background: linear-gradient(90deg, #10b981 0%, #e11d48 100%);
}

.notice-text {
    flex: 1;
}

.custom-amount-wrap {
    position: relative;
    display: flex;
    align-items: center;
}

.custom-amount-symbol {
    position: absolute;
    left: 1rem;
    font-weight: 800;
    color: #e11d48;
    font-size: 1.05rem;
    z-index: 2;
    pointer-events: none;
}

.custom-amount-input {
    padding-left: 2.25rem !important;
    font-weight: 700;
    font-size: 0.98rem !important;
    border-radius: 14px !important;
}

.btn-donate-primary,
.btn-submit-donate {
    background: linear-gradient(135deg, #e11d48 0%, #be123c 100%) !important;
    color: #ffffff !important;
    font-weight: 800 !important;
    padding: 0.75rem 1.35rem !important;
    border-radius: 14px !important;
    border: none !important;
    box-shadow: 0 6px 18px rgba(225, 29, 72, 0.35) !important;
    transition: all 0.2s ease !important;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.btn-donate-primary:hover,
.btn-submit-donate:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(225, 29, 72, 0.45) !important;
}

.btn-copy-accent {
    background: #ffffff !important;
    border: 1.5px solid #be185d !important;
    color: #be185d !important;
    font-weight: 800 !important;
    border-radius: 10px !important;
    padding: 0.35rem 0.85rem !important;
    font-size: 0.78rem !important;
    transition: all 0.2s ease;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
}

.btn-copy-accent:hover {
    background: #fdf2f8 !important;
    transform: translateY(-1px);
}

.payment-instruction-box {
    background: #f8fafc;
    border: 1.5px solid #e2e8f0;
    border-radius: 14px;
    padding: 1rem 1.15rem;
}

.trx-input-box {
    letter-spacing: 1.5px;
    font-weight: 800;
    text-transform: uppercase;
    font-family: monospace;
    font-size: 1.05rem !important;
    border-radius: 14px !important;
    text-align: center;
    border: 2px solid #cbd5e1 !important;
}

.trx-input-box:focus {
    border-color: #e11d48 !important;
    box-shadow: 0 0 0 3px rgba(225, 29, 72, 0.15) !important;
}

/* Success View Styling */
.success-icon-wrap {
    display: flex;
    justify-content: center;
    margin-bottom: 1.25rem;
    margin-top: 1rem;
}

.success-heart-pulse {
    width: 72px;
    height: 72px;
    border-radius: 50%;
    background: linear-gradient(135deg, #ecfdf5 0%, #d1fae5 100%);
    border: 2px solid #a7f3d0;
    color: #10b981;
    font-size: 2.35rem;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 8px 25px rgba(16, 185, 129, 0.3);
}

.success-heading {
    font-size: 1.35rem;
    font-weight: 800;
    color: #0f172a;
    margin: 0 0 0.5rem;
}

.success-subtext {
    font-size: 0.88rem;
    color: #475569;
    line-height: 1.6;
    max-width: 440px;
    margin: 0 auto 1.25rem;
}

.success-badge-tag {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    background: #fff7ed;
    color: #c2410c;
    border: 1.5px solid #ffedd5;
    font-size: 0.82rem;
    font-weight: 800;
    padding: 0.4rem 0.9rem;
    border-radius: 20px;
    margin-bottom: 1rem;
}

@media (max-width: 600px) {
    .modal-donate-upgrade {
        max-width: 95% !important;
        border-radius: 20px !important;
    }
    .donate-step-wizard {
        margin: 0.75rem 0.85rem 0.75rem;
        padding: 0.5rem 0.65rem;
    }
    .step-num {
        width: 30px;
        height: 30px;
        font-size: 0.75rem;
    }
    .step-title {
        font-size: 0.68rem;
    }
    .donation-notice-box {
        margin: 0 0.85rem 0.85rem;
        padding: 0.75rem 0.85rem;
        font-size: 0.8rem;
    }
    .amount-pills-row {
        flex-wrap: wrap;
        gap: 0.4rem;
    }
    .amount-pill {
        flex: 1 1 calc(33.33% - 0.4rem);
        padding: 0.65rem 0.4rem;
        min-height: 48px;
        font-size: 0.8rem;
    }
    .payment-method-tabs {
        gap: 0.35rem;
    }
    .pay-tab-logo-img {
        height: 36px;
        max-height: 100%;
        width: 100%;
        max-width: 100px;
    }
}

/* ==========================================================================
   DONATION MODAL & VOLUNTEERS/PARTNERS STYLING
   ========================================================================== */
.donation-notice-box {
    display: flex;
    align-items: flex-start;
    gap: 0.9rem;
    background: linear-gradient(135deg, #fefce8 0%, #fffbeb 100%);
    border: 1.5px solid #fde68a;
    padding: 1rem 1.25rem;
    border-radius: 16px;
    margin: 1rem 1.5rem 1.25rem;
    font-size: 0.88rem;
    color: #92400e;
    box-shadow: 0 4px 14px rgba(217, 119, 6, 0.05);
}

.donation-notice-box .notice-icon {
    width: 38px;
    height: 38px;
    border-radius: 10px;
    background: #fef3c7;
    color: #d97706;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.15rem;
    flex-shrink: 0;
}

.donation-notice-box p {
    margin: 0.25rem 0 0;
    line-height: 1.5;
    color: #78350f;
    font-size: 0.84rem;
}

.amount-pills-row {
    display: flex;
    gap: 0.65rem;
    margin-top: 0.5rem;
    margin-bottom: 0.65rem;
}

.amount-pill {
    flex: 1;
    padding: 0.6rem 0.35rem;
    border: 1.5px solid #e2e8f0;
    background: #ffffff;
    border-radius: 14px;
    font-weight: 800;
    font-size: 0.88rem;
    color: #334155;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
    box-shadow: 0 2px 6px rgba(15, 23, 42, 0.02);
    white-space: nowrap;
}

.amount-pill:hover {
    border-color: #fcd34d;
    background: #fffdf5;
}

.amount-pill.active {
    background: linear-gradient(135deg, #fffbeb 0%, #fef3c7 100%);
    border-color: #d97706 !important;
    color: #92400e !important;
    box-shadow: 0 4px 14px rgba(217, 119, 6, 0.25) !important;
}

.payment-method-tabs {
    display: flex;
    gap: 0.6rem;
    margin-bottom: 1.25rem;
}

.pay-tab {
    flex: 1;
    padding: 0.4rem 0.5rem;
    height: 64px;
    border: 2px solid #cbd5e1;
    background: #ffffff;
    border-radius: 18px;
    cursor: pointer;
    transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(15, 23, 42, 0.04);
}

.pay-tab-logo-img {
    height: 52px;
    max-height: 100%;
    width: auto;
    max-width: 100%;
    object-fit: contain;
    transform: scale(1.5);
    transition: transform 0.25s ease;
}

.pay-tab:hover .pay-tab-logo-img {
    transform: scale(1.65);
}

.pay-tab.active .pay-tab-logo-img {
    transform: scale(1.6);
}

.pay-tab-title {
    font-weight: 800;
    letter-spacing: -0.2px;
}

.pay-tab-bkash:hover {
    border-color: #fbcfe8;
    background: #fdf2f8;
}

.pay-tab-nagad:hover {
    border-color: #fed7aa;
    background: #fff7ed;
}

.pay-tab-rocket:hover {
    border-color: #e9d5ff;
    background: #faf5ff;
}

.pay-tab-bkash.active {
    background: #fdf2f8 !important;
    border-color: #e2136e !important;
    color: #be185d !important;
    box-shadow: 0 4px 16px rgba(226, 19, 110, 0.2) !important;
}

.pay-tab-nagad.active {
    background: #fff7ed !important;
    border-color: #ea580c !important;
    color: #c2410c !important;
    box-shadow: 0 4px 16px rgba(234, 88, 12, 0.2) !important;
}

.pay-tab-rocket.active {
    background: #faf5ff !important;
    border-color: #802781 !important;
    color: #6b21a8 !important;
    box-shadow: 0 4px 16px rgba(128, 39, 129, 0.2) !important;
}

.personal-pay-warning {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    background: #eff6ff;
    border: 1.5px solid #bfdbfe;
    padding: 0.9rem 1.1rem;
    border-radius: 14px;
    font-size: 0.85rem;
    color: #1e40af;
    margin-bottom: 1.25rem;
}

.personal-pay-warning i {
    font-size: 1.25rem;
    color: #2563eb;
    flex-shrink: 0;
    margin-top: 0.1rem;
}

.payment-details-card {
    background: #ffffff;
    border: 1.5px solid #e2e8f0;
    padding: 1.35rem;
    border-radius: 18px;
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
    box-shadow: 0 4px 16px rgba(15, 23, 42, 0.03);
}

.pay-account-box {
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
}

.pay-label {
    font-size: 0.8rem;
    font-weight: 800;
    color: #64748b;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.pay-number-wrap {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: #f8fafc;
    padding: 0.75rem 1.1rem;
    border-radius: 12px;
    border: 1.5px solid #cbd5e1;
}

.pay-number {
    font-size: 1.35rem;
    font-weight: 900;
    color: #0f172a;
    letter-spacing: 1px;
}

.qr-code-box {
    background: #f8fafc;
    padding: 1.25rem;
    border-radius: 14px;
    border: 1px solid #e2e8f0;
}

.qr-placeholder {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 1.5rem;
    background: #ffffff;
    border-radius: 12px;
    border: 2px dashed #cbd5e1;
}

.qr-icon {
    font-size: 4rem;
    color: var(--secondary-slate);
}

.qr-label {
    font-weight: 800;
    font-size: 0.9rem;
    color: var(--secondary-slate);
}

/* Volunteers & Partners Page Grid Styles */
.page-hero {
    padding: 3rem 0 2rem;
    background: linear-gradient(180deg, #ffffff 0%, #f8fafc 100%);
}

.page-title {
    font-size: 2.2rem;
    margin: 0.5rem 0;
}

.page-subtitle {
    font-size: 1.05rem;
    color: var(--text-muted);
    max-width: 650px;
    margin: 0 auto;
}

.volunteers-section, .partners-section {
    padding: 2.5rem 0 4rem;
}

.volunteers-grid, .partners-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 1.5rem;
}

.volunteer-card {
    background: #ffffff;
    border-radius: var(--radius-lg);
    padding: 1.6rem 1.4rem;
    border: 1.5px solid #e2e8f0;
    box-shadow: var(--shadow-card);
    transition: var(--transition);
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    position: relative;
}

.volunteer-card:hover {
    transform: none;
    box-shadow: 0 8px 24px rgba(15, 23, 42, 0.06);
    border-color: #cbd5e1;
}

.volunteer-avatar-box {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    margin-bottom: 1.1rem;
}

.volunteer-avatar-wrap {
    position: relative;
    display: inline-block;
}

.volunteer-avatar-img {
    width: 96px;
    height: 96px;
    border-radius: 50%;
    object-fit: cover;
    border: 3.5px solid #ffffff;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.12), 0 0 0 2.5px var(--primary-red);
    transition: var(--transition);
}

.volunteer-card:hover .volunteer-avatar-img {
    transform: scale(1.04);
}

.badge-role {
    font-size: 0.76rem;
    font-weight: 800;
    padding: 0.25rem 0.8rem;
    border-radius: var(--radius-full);
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    white-space: nowrap;
    text-transform: uppercase;
    letter-spacing: 0.3px;
}

.badge-role.badge-founder {
    background: #fff7ed;
    color: #c2410c;
    border: 1px solid #ffedd5;
}

.badge-role.badge-cofounder {
    background: #fffbeb;
    color: #b45309;
    border: 1px solid #fde68a;
}

.badge-role.badge-developer {
    background: #f3e8ff;
    color: #6b21a8;
    border: 1px solid #e9d5ff;
}

.badge-role.badge-designer {
    background: #fce7f3;
    color: #9d174d;
    border: 1px solid #fbcfe8;
}

.badge-role.badge-admin {
    background: #e0f2fe;
    color: #0369a1;
    border: 1px solid #bae6fd;
}

.badge-role.badge-coordinator {
    background: #dcfce7;
    color: #15803d;
    border: 1px solid #bbf7d0;
}

.volunteer-name {
    font-size: 1.25rem;
    font-weight: 800;
    color: var(--secondary-slate);
    margin-bottom: 0.35rem;
}

.volunteer-designation, .volunteer-location {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.45rem;
    font-size: 0.88rem;
    color: var(--text-muted);
    margin-bottom: 0.35rem;
}

.volunteer-actions {
    display: flex;
    gap: 0.6rem;
    width: 100%;
    margin-top: 1.25rem;
    padding-top: 1rem;
    border-top: 1px solid #f1f5f9;
}

.volunteer-actions .btn {
    flex: 1;
    justify-content: center;
}

.partner-logo-wrap {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1rem;
}

.partner-icon-box {
    width: 52px;
    height: 52px;
    border-radius: 14px;
    background: #fff1f2;
    color: var(--primary-red);
    font-size: 1.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.partner-desc {
    font-size: 0.9rem;
    color: var(--text-muted);
    line-height: 1.5;
    margin-bottom: 1.25rem;
}

.partner-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-top: 1rem;
    border-top: 1px solid #f1f5f9;
    font-size: 0.85rem;
    color: var(--text-muted);
}

/* Clean & Modern Volunteers UI */
.volunteer-card {
    background: #ffffff !important;
    border-radius: 16px !important;
    padding: 1.4rem !important;
    border: 1.5px solid #e2e8f0 !important;
    box-shadow: 0 4px 16px rgba(15, 23, 42, 0.04) !important;
    transition: all 0.3s ease !important;
    display: flex;
    flex-direction: column;
    text-align: left;
    position: relative;
}

.volunteer-card.hidden-card {
    display: none !important;
}

.volunteer-card:hover {
    transform: none !important;
    box-shadow: 0 8px 24px rgba(15, 23, 42, 0.06) !important;
    border-color: #cbd5e1 !important;
}

.volunteer-avatar-box {
    display: flex !important;
    flex-direction: row !important;
    align-items: center !important;
    justify-content: space-between !important;
    width: 100% !important;
    margin-bottom: 1rem !important;
}

.volunteer-avatar-img {
    width: 80px !important;
    height: 80px !important;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid #ffffff !important;
    box-shadow: 0 6px 16px rgba(15, 23, 42, 0.1), 0 0 0 2px #e2e8f0;
    background: #f8fafc;
    transition: var(--transition);
}

.volunteer-card:hover .volunteer-avatar-img {
    box-shadow: 0 8px 20px rgba(220, 38, 38, 0.18), 0 0 0 2px var(--primary-red);
}

.volunteer-card-body {
    padding: 0;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    text-align: left;
    width: 100%;
}

.volunteer-name {
    font-size: 1.2rem;
    font-weight: 800;
    color: var(--secondary-slate);
    margin-bottom: 0.3rem;
}

.volunteer-designation, .volunteer-location {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 0.45rem;
    font-size: 0.88rem;
    color: var(--text-muted);
    margin-bottom: 0.3rem;
}

.volunteer-stats-ribbon {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1rem;
    background: #ffffff;
    border: 1.5px solid #e2e8f0;
    border-radius: var(--radius-lg);
    padding: 1.25rem 1.5rem;
    margin-top: 2rem;
    box-shadow: var(--shadow-sm);
}

.ribbon-item {
    display: flex;
    align-items: center;
    gap: 0.85rem;
    text-align: left;
}

.ribbon-icon {
    width: 48px;
    height: 48px;
    border-radius: 14px;
    background: #fff1f2;
    color: var(--primary-red);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.3rem;
    flex-shrink: 0;
}

.ribbon-val {
    font-size: 1.25rem;
    font-weight: 800;
    color: var(--secondary-slate);
    line-height: 1.1;
}

.ribbon-label {
    font-size: 0.82rem;
    color: var(--text-muted);
}

.volunteer-filter-bar {
    display: flex;
    justify-content: center;
    gap: 0.5rem;
    flex-wrap: wrap;
    margin-bottom: 2rem;
}

.volunteer-filter-btn {
    padding: 0.5rem 1.1rem;
    border-radius: var(--radius-full);
    font-weight: 700;
    font-size: 0.88rem;
    border: 1.5px solid #cbd5e1;
    background: #ffffff;
    color: var(--secondary-slate);
    cursor: pointer;
    transition: var(--transition);
}

.volunteer-filter-btn:hover, .volunteer-filter-btn.active {
    background: var(--secondary-slate);
    color: #ffffff;
    border-color: var(--secondary-slate);
    box-shadow: 0 4px 12px rgba(15, 23, 42, 0.15);
}

.volunteer-cta-box {
    background: linear-gradient(135deg, #1e293b 0%, #0f172a 100%);
    border-radius: var(--radius-xl);
    padding: 3rem 2rem;
    color: #ffffff;
    text-align: center;
    margin-top: 3.5rem;
    position: relative;
    overflow: hidden;
    box-shadow: 0 20px 40px rgba(15, 23, 42, 0.2);
}

.volunteer-cta-box h2 {
    font-size: 1.8rem;
    font-weight: 800;
    margin-bottom: 0.75rem;
    color: #ffffff;
}

.volunteer-cta-box p {
    color: #94a3b8;
    max-width: 580px;
    margin: 0 auto 1.5rem;
    font-size: 1rem;
}

/* ==========================================================================
   NATIVE ANDROID / MOBILE PWA APP STYLES & ZERO-BREAK RESPONSIVENESS
   ========================================================================== */

html, body {
    overflow-x: hidden !important;
    width: 100% !important;
    max-width: 100vw !important;
    -webkit-tap-highlight-color: transparent;
}

body {
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Touch Active Feedback */
button, .btn, .pill-btn, .donor-card, .partner-card-enhanced, .volunteer-card {
    touch-action: manipulation;
}

button:active, .btn:active, .pill-btn:active {
    transform: scale(0.96) !important;
}

/* Mobile Bottom Navigation Bar */
.mobile-bottom-nav {
    display: none;
}

@media (max-width: 768px) {
    body {
        padding-bottom: 78px !important;
    }

    .mobile-bottom-nav {
        display: flex !important;
        position: fixed !important;
        bottom: 0 !important;
        left: 0 !important;
        right: 0 !important;
        height: 66px !important;
        background: rgba(15, 23, 42, 0.95) !important;
        backdrop-filter: blur(16px) !important;
        -webkit-backdrop-filter: blur(16px) !important;
        border-top: 1px solid rgba(255, 255, 255, 0.12) !important;
        z-index: 9990 !important;
        align-items: center !important;
        justify-content: space-around !important;
        padding: 0 0.25rem !important;
        box-shadow: 0 -8px 25px rgba(0, 0, 0, 0.4) !important;
    }

    .mobile-nav-item {
        display: flex !important;
        flex-direction: column !important;
        align-items: center !important;
        justify-content: center !important;
        gap: 0.2rem !important;
        color: #94a3b8 !important;
        text-decoration: none !important;
        font-size: 0.7rem !important;
        font-weight: 700 !important;
        padding: 0.35rem 0.5rem !important;
        border-radius: 12px !important;
        transition: all 0.2s ease !important;
        flex: 1 !important;
        text-align: center !important;
    }

    .mobile-nav-item i {
        font-size: 1.15rem !important;
        transition: transform 0.2s ease !important;
    }

    .mobile-nav-item:hover,
    .mobile-nav-item.active {
        color: #fb7185 !important;
        background: rgba(225, 29, 72, 0.14) !important;
    }

    .mobile-nav-item.active i {
        transform: translateY(-2px) !important;
    }
}

/* Comprehensive Native Mobile Responsiveness Rules */
@media (max-width: 640px) {
    .container {
        padding-left: 1rem !important;
        padding-right: 1rem !important;
    }

    /* Hero Section Responsive */
    .hero {
        padding: 2rem 0 3rem !important;
    }

    .hero-title {
        font-size: 1.8rem !important;
        line-height: 1.25 !important;
    }

    .hero-subtitle {
        font-size: 0.95rem !important;
    }

    .hero-stats {
        flex-direction: column !important;
        gap: 0.75rem !important;
    }

    /* Donors Grid */
    #donorsGrid {
        grid-template-columns: 1fr !important;
        gap: 1.1rem !important;
    }

    /* Donors List Row Responsive Transformation */
    .donor-list-row {
        flex-direction: column !important;
        align-items: stretch !important;
        gap: 0.85rem !important;
        padding: 1rem !important;
        border-radius: 18px !important;
        box-shadow: 0 4px 14px rgba(15, 23, 42, 0.05) !important;
    }

    .donor-list-row > div {
        width: 100% !important;
    }

    .list-col-badge {
        display: flex !important;
        justify-content: space-between !important;
        align-items: center !important;
        width: 100% !important;
    }

    .list-col-actions {
        display: flex !important;
        gap: 0.5rem !important;
        width: 100% !important;
        margin-top: 0.25rem !important;
    }

    .list-col-actions .btn {
        flex: 1 !important;
        justify-content: center !important;
        padding: 0.65rem 0.5rem !important;
        font-size: 0.88rem !important;
        border-radius: 12px !important;
    }

    /* Modals Responsive */
    .modal-container {
        width: 94vw !important;
        max-height: 88vh !important;
        overflow-y: auto !important;
        padding: 1.25rem 1rem !important;
        border-radius: 20px !important;
    }

    /* Form Controls & Inputs */
    .form-control, .btn {
        min-height: 48px !important;
        border-radius: 14px !important;
    }

    .search-form-card {
        padding: 1.25rem 0.85rem !important;
        border-radius: 20px !important;
    }

    /* Urgent Request Cards Grid */
    .urgent-grid, #urgentGrid {
        grid-template-columns: 1fr !important;
        gap: 1rem !important;
    }

    /* Partners Page Grid */
    .partner-grid-enhanced {
        grid-template-columns: 1fr !important;
    }

    /* Volunteers Ribbon & Cards */
    .volunteer-stats-ribbon {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 0.85rem !important;
        padding: 1rem !important;
    }

    .volunteers-grid {
        grid-template-columns: 1fr !important;
    }
}

/* Dashboard Logout Button - Show on Mobile Screen Only */
#dashLogoutBtn {
    display: none;
}

@media (max-width: 991px) {
    .dashboard-shell {
        grid-template-columns: 1fr !important;
    }
}

@media (max-width: 768px) {
    #dashLogoutBtn {
        display: inline-flex !important;
    }

    .dashboard-section {
        padding: 1.25rem 0 2.5rem !important;
    }
    
    .dashboard-shell {
        padding: 1.25rem 1rem !important;
        border-radius: 20px !important;
        gap: 1.25rem !important;
    }

    .dashboard-profile-card {
        flex-direction: column !important;
        text-align: center !important;
        align-items: center !important;
        padding: 1.15rem 1rem !important;
        border-radius: 16px !important;
        gap: 1rem !important;
    }

    .dashboard-meta {
        justify-content: center !important;
        flex-wrap: wrap !important;
    }

    .dashboard-actions {
        flex-direction: column-reverse !important;
        width: 100% !important;
        gap: 0.75rem !important;
    }

    .dashboard-actions .btn {
        width: 100% !important;
        justify-content: center !important;
    }
}

@media (max-width: 480px) {
    .logo-title {
        font-size: 1.25rem !important;
    }
    .logo-subtitle {
        display: none !important;
    }
    .brand-logo {
        gap: 0.5rem !important;
    }
}

/* Dashboard Desktop 2-Column Grid Layout (Right Side Security Box) */
.dashboard-main-grid {
    display: grid;
    grid-template-columns: 1fr 340px;
    gap: 1.5rem;
    align-items: start;
    margin-top: 1.5rem;
}

@media (max-width: 991px) {
    .dashboard-main-grid {
        grid-template-columns: 1fr !important;
        gap: 1.25rem !important;
    }
}

/* Dashboard Mobile & 360px Responsive Layout */
@media (max-width: 480px) {
    .security-card {
        padding: 1.15rem 1rem !important;
        border-radius: 16px !important;
    }

    .donor-guidelines-card {
        padding: 1.15rem 1rem !important;
        border-radius: 16px !important;
        margin-top: 1.5rem !important;
    }

    .guidelines-list {
        grid-template-columns: 1fr !important;
        gap: 0.85rem !important;
    }

    #btnShowChangePasswordFields {
        font-size: 0.88rem !important;
        padding: 0.7rem 0.75rem !important;
    }
}

@media (max-width: 360px) {
    .dashboard-shell {
        padding: 1rem 0.75rem !important;
    }

    .security-header h3 {
        font-size: 1rem !important;
    }

    .security-header p {
        font-size: 0.75rem !important;
    }

    .form-control {
        font-size: 0.85rem !important;
        padding: 0.65rem 0.85rem !important;
    }
}

/* ==========================================================================
   PREMIUM MODAL ENHANCEMENTS (#loginModal & #forgotPasswordModal)
   ========================================================================== */

.modal-container {
    position: relative !important;
    background: #ffffff !important;
    border: 1.5px solid rgba(226, 232, 240, 0.95) !important;
    border-radius: 28px !important;
    box-shadow: 0 30px 80px -15px rgba(15, 23, 42, 0.28), 0 0 2px rgba(15, 23, 42, 0.1) !important;
    transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.3s ease !important;
    overflow-y: auto !important;
    overflow-x: hidden !important;
    -webkit-overflow-scrolling: touch !important;
}

.modal-header {
    border-bottom: 1px solid #f1f5f9;
    padding: 1.5rem 3.75rem 1.25rem 1.75rem !important;
    margin-bottom: 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: linear-gradient(180deg, #ffffff 0%, #f8fafc 100%);
}

.modal-title-wrap {
    display: flex;
    align-items: center;
    gap: 0.9rem;
}

.modal-icon.red-icon {
    width: 50px;
    height: 50px;
    border-radius: 16px;
    background: linear-gradient(135deg, #fff1f2 0%, #ffe4e6 100%);
    color: #e11d48;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.35rem;
    box-shadow: 0 6px 16px rgba(225, 29, 72, 0.16);
    flex-shrink: 0;
}

.modal-title-wrap h3 {
    font-size: 1.3rem;
    font-weight: 800;
    color: #0f172a;
    margin: 0;
    line-height: 1.3;
}

.modal-title-wrap p {
    font-size: 0.84rem;
    color: #64748b;
    margin: 0.2rem 0 0;
    line-height: 1.4;
}

/* TOP RIGHT CORNER FLOATING HIGH-CONTRAST CLOSE BUTTON */
.modal-close {
    position: absolute !important;
    top: 1.1rem !important;
    right: 1.15rem !important;
    width: 38px !important;
    height: 38px !important;
    border-radius: 50% !important;
    background: #ffffff !important;
    border: 1.5px solid #cbd5e1 !important;
    color: #475569 !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    padding: 0 !important;
    margin: 0 !important;
    font-size: 1.1rem !important;
    line-height: 1 !important;
    cursor: pointer !important;
    transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1) !important;
    z-index: 50 !important;
    box-shadow: 0 4px 12px rgba(15, 23, 42, 0.1) !important;
}

.modal-close i {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    width: 100% !important;
    height: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
}

.modal-close:hover {
    background: #e11d48 !important;
    color: #ffffff !important;
    border-color: #e11d48 !important;
    transform: rotate(90deg) scale(1.08) !important;
    box-shadow: 0 6px 18px rgba(225, 29, 72, 0.35) !important;
}

.modal-form {
    padding: 1.75rem;
}

.modal-form .form-group {
    margin-bottom: 1.25rem;
}

.modal-form label {
    font-weight: 700;
    font-size: 0.88rem;
    color: #334155;
    margin-bottom: 0.5rem;
    display: block;
}

.modal-form .form-control {
    border-radius: 14px;
    border: 1.5px solid #cbd5e1;
    padding: 0.8rem 1.1rem;
    font-size: 0.94rem;
    background: #f8fafc;
    transition: all 0.2s ease;
}

.modal-form .form-control:focus {
    background: #ffffff;
    border-color: #e11d48;
    box-shadow: 0 0 0 4px rgba(225, 29, 72, 0.12);
}

.modal-footer {
    border-top: 1px solid #f1f5f9;
    padding: 1.25rem 1.75rem;
    display: flex;
    gap: 0.85rem;
    justify-content: flex-end;
    background: #fafafa;
}

.modal-container .btn-primary {
    background: linear-gradient(135deg, #e11d48 0%, #be123c 100%) !important;
    border: none !important;
    border-radius: 14px !important;
    padding: 0.8rem 1.5rem !important;
    font-weight: 800 !important;
    font-size: 0.94rem !important;
    color: #ffffff !important;
    box-shadow: 0 6px 20px rgba(225, 29, 72, 0.32) !important;
    transition: all 0.2s ease !important;
}

.modal-container .btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 26px rgba(225, 29, 72, 0.45) !important;
}

.modal-container .btn-secondary {
    background: #f1f5f9 !important;
    border: 1.5px solid #e2e8f0 !important;
    border-radius: 14px !important;
    padding: 0.8rem 1.25rem !important;
    font-weight: 700 !important;
    font-size: 0.9rem !important;
    color: #475569 !important;
    transition: all 0.2s ease !important;
}

.modal-container .btn-secondary:hover {
    background: #e2e8f0 !important;
    color: #0f172a !important;
}

/* Donor Confirmation Card (Step 2) */
.donor-confirm-card {
    background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
    border: 1.5px solid #e2e8f0;
    border-left: 4px solid #e11d48 !important;
    border-radius: 20px;
    padding: 1.35rem;
    margin-bottom: 1.35rem;
    box-shadow: 0 6px 16px rgba(15, 23, 42, 0.04);
}

.donor-confirm-card h4 {
    font-size: 0.96rem;
    font-weight: 800;
    color: #0f172a;
    margin: 0 0 0.85rem;
    border-bottom: 1px dashed #cbd5e1;
    padding-bottom: 0.6rem;
    display: flex;
    align-items: center;
    gap: 0.45rem;
}

.donor-confirm-grid {
    display: flex;
    flex-direction: column;
    gap: 0.55rem;
    font-size: 0.88rem;
    color: #334155;
}

.donor-confirm-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.25rem 0;
}

.donor-confirm-item label {
    font-weight: 600;
    color: #64748b;
    margin: 0;
}

/* Registration Modal Native Smooth Scroll & 390px Mobile Responsive UI */
#registerModal .modal-container {
    max-height: 88vh !important;
    max-height: 88dvh !important;
    overflow-y: auto !important;
    -webkit-overflow-scrolling: touch !important;
}

#registerModal .modal-header {
    position: sticky !important;
    top: 0 !important;
    background: #ffffff !important;
    z-index: 50 !important;
}

#registerModal .modal-form {
    overflow: visible !important;
}

/* Toggle Switch Component */
.toggle-container {
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    cursor: pointer;
    user-select: none;
}

.toggle-container input[type="checkbox"] {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
    pointer-events: none;
}

.toggle-switch {
    position: relative;
    width: 44px;
    height: 24px;
    background-color: #cbd5e1;
    border-radius: 30px;
    transition: background-color 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    flex-shrink: 0;
    display: inline-block;
}

.toggle-switch::after {
    content: '';
    position: absolute;
    top: 2px;
    left: 2px;
    width: 20px;
    height: 20px;
    background-color: #ffffff;
    border-radius: 50%;
    transition: transform 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
}

.toggle-container input[type="checkbox"]:checked + .toggle-switch {
    background-color: #10b981;
}

.toggle-container input[type="checkbox"]:checked + .toggle-switch::after {
    transform: translateX(20px);
}

.toggle-label {
    font-weight: 700;
    font-size: 0.9rem;
    color: #1e293b;
}

@media (max-width: 768px) {
    #registerModal.modal-overlay {
        padding: 0 !important;
    }

    #registerModal .modal-container {
        width: 100% !important;
        max-width: 100% !important;
        height: 100vh !important;
        height: 100dvh !important;
        max-height: 100dvh !important;
        margin: 0 !important;
        border-radius: 0 !important;
    }

    #registerModal .modal-container::before {
        display: none !important;
    }

    #registerModal .modal-header {
        position: sticky !important;
        top: 0 !important;
        left: 0 !important;
        right: 0 !important;
        background: #ffffff !important;
        z-index: 50 !important;
        flex-shrink: 0 !important;
        margin: 0 !important;
        border: none !important;
        border-bottom: none !important;
        box-shadow: none !important;
    }

    #registerModal .modal-form {
        padding: 1rem 1rem 1.5rem !important;
    }

    .address-cards-wrapper {
        grid-template-columns: 1fr !important;
        gap: 0.85rem !important;
    }

    #registerModal .modal-footer {
        position: static !important;
        box-shadow: none !important;
        border-top: 1px solid #e2e8f0;
        padding: 1rem 0 0.5rem 0 !important;
        margin-top: 1.25rem;
        flex-direction: column-reverse;
        gap: 0.65rem;
    }

    #registerModal .modal-footer .btn {
        width: 100% !important;
        justify-content: center;
    }

    #registerModal .modal-footer .btn-primary,
    #registerModal .modal-footer button[type="submit"] {
        font-size: 0.85rem !important;
        padding: 0.7rem 1rem !important;
    }

    #registerModal .modal-footer .btn-primary span {
        font-size: 0.85rem !important;
    }
}

.donor-confirm-item span {
    font-weight: 800;
    color: #0f172a;
}


/* Sticky Modal Headers for Smooth Internal Scrolling */
.modal-header {
    position: sticky !important;
    top: 0 !important;
    background: #ffffff !important;
    z-index: 35 !important;
    flex-shrink: 0 !important;
    border: none !important;
    border-bottom: none !important;
    box-shadow: none !important;
}

.modal-header-donate {
    position: sticky !important;
    top: 0 !important;
    background: linear-gradient(135deg, #fff1f2 0%, #ffe4e6 100%) !important;
    z-index: 35 !important;
    flex-shrink: 0 !important;
}


.btn-success-green {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%) !important;
    color: #ffffff !important;
    border: none !important;
    font-weight: 800 !important;
    box-shadow: 0 8px 20px rgba(16, 185, 129, 0.35) !important;
    transition: all 0.25s ease !important;
}
.btn-success-green:hover {
    transform: translateY(-2px) !important;
    box-shadow: 0 12px 25px rgba(16, 185, 129, 0.5) !important;
}
