:root {
    --primary: #e11d48;
    --primary-dark: #be123c;
    --text: #0f172a;
    --muted: #475569;
    --bg: #ffffff;
    --card: #f8fafc;
    --border: #e2e8f0;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: "Inter", system-ui, -apple-system, sans-serif;
    color: var(--text);
    background: var(--bg);
}

a {
    text-decoration: none;
    color: inherit;
}

/* ===== Header ===== */
.topbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 32px;
    border-bottom: 1px solid #eee;
    position: relative;
    background: #fff;
    z-index: 20;
}

.logo {
    display: flex;
    align-items: center;
}

.logo img {
    height: 35px;
    width: auto;
    object-fit: contain;
}

@media (max-width: 768px) {
    .logo img {
        height: 32px;
    }
}

.nav a {
    margin: 0 10px;
    font-weight: 600;
}

.menu-toggle {
    display: none;
    background: none;
    border: none;
    font-size: 1.6rem;
}

.desktop-cta {
    margin-left: 12px;
}

.btn-primary {
    background: #d32f2f;
    color: white;
    padding: 12px 20px;
    border: none;
    border-radius: 6px;
    cursor: pointer;
}

.btn-outline {
    background-color: rgb(71, 71, 233);
    color: white;
    padding: 12px 20px;
    border-radius: 6px;
    cursor: pointer;
}

/* ===== Hero (default for homepage) ===== */
.hero {
    position: relative;
    padding: 80px 32px;
    background-image: var(--hero-desktop);
    background-size: cover;
    background-position: center;
    color: white;
    overflow: hidden;
}

.hero-overlay {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.45);
    pointer-events: none;
}

.hero-content {
    position: relative;
    max-width: 720px;
    z-index: 1;
}

.hero-content h1 {
    font-size: 2.6rem;
    margin: 12px 0;
}

.hero-content p {
    font-size: 1.1rem;
    margin-bottom: 16px;
}

.badge {
    display: inline-block;
    background: #ffecec;
    color: #d32f2f;
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 0.85rem;
}

.hero-actions {
    display: flex;
    gap: 14px;
    margin: 16px 0;
    flex-wrap: wrap;
}

.hero-stats {
    display: flex;
    gap: 20px;
    margin-top: 20px;
    flex-wrap: wrap;
}

.hero-stats h3 {
    color: #ffb3b3;
}

/* ===== Hero with form (donor/request pages only) ===== */
.hero-with-form {
    padding-bottom: 100px;
}

.hero-with-form .floating-form {
    position: relative;
    margin: 30px auto 0;
    width: min(720px, 92%);
    background: rgba(255, 255, 255, 0.75);
    border: 1px solid rgba(255, 255, 255, 0.6);
    backdrop-filter: blur(18px);
    border-radius: 18px;
    padding: 24px;
    color: #222;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.25);
}

/* ===== Forms ===== */
.form-card {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.form-card input,
.form-card select {
    padding: 12px;
    border: 1px solid #ccc;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.95);
    color: #222;
}

.form-card input::placeholder {
    color: #666;
}

/* ===== Sections ===== */
.section {
    padding: 48px 32px;
}

/* ===== How It Works (New Look) ===== */
.how-it-works {
    background: #fff7f7;
    text-align: center;
}

.how-it-works h2 {
    font-size: 2rem;
    margin-bottom: 8px;
}

.section-subtitle {
    color: #555;
    margin-bottom: 30px;
}

.how-steps {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 18px;
    flex-wrap: wrap;
}

.step-card {
    width: 260px;
    padding: 24px;
    border-radius: 16px;
    color: #222;
    text-align: left;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.step-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 14px 36px rgba(0, 0, 0, 0.15);
}

.step-1 {
    background: #ffecec;
    border: 1px solid #ffd6d6;
}

.step-2 {
    background: #e8f4ff;
    border: 1px solid #cce6ff;
}

.step-3 {
    background: #e9fff0;
    border: 1px solid #c8f5d8;
}

.step-badge {
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    font-weight: 700;
    margin-bottom: 12px;
    background: white;
    border: 2px solid #d32f2f;
    color: #d32f2f;
}

.step-arrow {
    font-size: 2rem;
    color: #d32f2f;
    font-weight: bold;
}

.btn-scroll {
    transform: translateY(4px);
    transition: transform 0.2s ease;
}

.table-wrapper {
    width: 100%;
    overflow-x: auto;
}

.donor-table {
    width: 100%;
    border-collapse: collapse;
    background: #fff;
    border-radius: 12px;
    overflow: hidden;
    min-width: 900px;
}

.donor-table th,
.donor-table td {
    padding: 14px 16px;
    border-bottom: 1px solid #eee;
    text-align: left;
}

.donor-table th {
    background: #f7f7f7;
    font-weight: 700;
}

.summary-card {
    background: #fff;
    padding: 16px 18px;
    border-radius: 12px;
    margin-bottom: 16px;
    box-shadow: 0 8px 22px rgba(0, 0, 0, 0.06);
}

.actions-row {
    display: flex;
    gap: 12px;
    align-items: center;
    margin-bottom: 16px;
    flex-wrap: wrap;
}

.group-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 12px;
    margin: 16px 0;
}

.group-card {
    background: #fff;
    padding: 16px;
    border-radius: 10px;
    text-align: center;
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.05);
}

.accept-panel {
    margin-top: 24px;
}

.status-success {
    background: #e9f9ef;
    padding: 16px;
    border-radius: 12px;
}

.status-error {
    background: #ffe8e8;
    padding: 16px;
    border-radius: 12px;
}

.muted {
    color: #666;
}

.success-card {
    max-width: 720px;
    margin: 40px auto;
    padding: 32px;
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.08);
    text-align: center;
}

.status-success {
    background: #e9f9ef;
    padding: 16px;
    border-radius: 12px;
}

.status-error {
    background: #ffe8e8;
    padding: 16px;
    border-radius: 12px;
}

/* ====== Responsive Header ====== */
.menu-toggle {
    display: none;
    background: transparent;
    border: 0;
    font-size: 26px;
    cursor: pointer;
    margin-left: 10px;
}

.desktop-cta {
    margin-left: 12px;
}

.nav a.active {
    font-weight: 700;
    color: #0f172a;
}

@media (max-width: 960px) {
    .nav {
        display: none;
        position: absolute;
        top: 72px;
        right: 16px;
        background: #fff;
        box-shadow: 0 10px 24px rgba(15, 23, 42, 0.15);
        border-radius: 12px;
        padding: 12px;
        flex-direction: column;
        gap: 8px;
        z-index: 50;
    }

    .nav.open {
        display: flex;
    }

    .menu-toggle {
        display: inline-block;
    }

    .desktop-cta {
        display: none;
    }
}

/* ====== Check Request Page Responsive ====== */
.check-wrapper {
    max-width: 1100px;
    margin: 40px auto;
    padding: 0 16px 40px;
}

.check-hero {
    display: grid;
    grid-template-columns: 1fr 420px;
    gap: 24px;
    align-items: center;
}

@media (max-width: 900px) {
    .check-hero {
        grid-template-columns: 1fr;
    }

    .check-card {
        width: 100%;
    }
}

.table-wrap {
    overflow-x: auto;
}

.status-table {
    min-width: 920px;
}

@media (max-width: 900px) {
    .how-steps {
        flex-direction: column;
    }

    .step-arrow {
        transform: rotate(90deg);
    }
}

/* ===== Feature Strip (Animated Gradient) ===== */
.feature-strip {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 18px;
    margin-top: 10px;
}

.feature-card {
    position: relative;
    border-radius: 18px;
    padding: 24px;
    color: #fff;
    overflow: hidden;
    isolation: isolate;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.feature-card::before {
    content: "";
    position: absolute;
    inset: -50%;
    background: linear-gradient(120deg, #ff5f6d, #ffc371, #42a5f5, #66bb6a);
    background-size: 300% 300%;
    animation: gradientMove 8s ease infinite;
    z-index: -2;
}

.feature-card::after {
    content: "";
    position: absolute;
    inset: 2px;
    background: rgba(0, 0, 0, 0.35);
    border-radius: 16px;
    z-index: -1;
}

.feature-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 16px 36px rgba(0, 0, 0, 0.25);
}

@keyframes gradientMove {
    0% {
        background-position: 0% 50%;
    }

    50% {
        background-position: 100% 50%;
    }

    100% {
        background-position: 0% 50%;
    }
}

.feature-icon {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.4rem;
    margin-bottom: 12px;
    background: rgba(255, 255, 255, 0.2);
}

.feature-btn {
    display: inline-block;
    margin-top: 14px;
    padding: 10px 16px;
    border-radius: 8px;
    background: #fff;
    color: #111;
    font-weight: 600;
    transition: transform 0.2s ease, background 0.2s ease;
}

.feature-btn:hover {
    transform: translateY(-2px);
    background: #ffecec;
}

@media (max-width: 900px) {
    .feature-strip {
        grid-template-columns: 1fr;
    }
}

/* ===== Footer ===== */
.footer {
    text-align: center;
    padding: 40px 20px;
    border-top: 1px solid #eee;
}

/* ===== Responsive ===== */
@media (max-width: 900px) {
    .hero {
        padding: 60px 20px;
        background-image: var(--hero-mobile);
    }
}

@media (max-width: 768px) {
    .nav {
        display: none;
        flex-direction: column;
        gap: 12px;
        position: absolute;
        top: 60px;
        right: 20px;
        background: white;
        padding: 16px;
        border: 1px solid #eee;
        border-radius: 10px;
    }

    .nav.show {
        display: flex;
    }

    .menu-toggle {
        display: block;
    }

    .desktop-cta {
        display: none;
    }
}

/* ===== Check Request - Modern UI ===== */
.check-wrapper {
    max-width: 1100px;
    margin: 40px auto;
    padding: 0 16px 40px;
}

.check-hero {
    display: grid;
    grid-template-columns: 1fr 420px;
    gap: 24px;
    align-items: center;
}

.check-hero-text h1 {
    font-size: 2.2rem;
    margin: 10px 0 8px;
}

.check-hero-text p {
    color: #444;
}

.quick-stats {
    display: flex;
    gap: 14px;
    margin-top: 18px;
    flex-wrap: wrap;
}

.stat-card {
    background: #fff;
    border: 1px solid #eee;
    border-radius: 12px;
    padding: 12px 14px;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.06);
}

.check-card {
    background: #fff;
    padding: 24px;
    border-radius: 16px;
    border: 1px solid #eee;
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.08);
}

.check-form label {
    display: block;
    font-weight: 600;
    margin-bottom: 12px;
}

.check-form input {
    width: 100%;
    padding: 12px 14px;
    border-radius: 10px;
    border: 1px solid #ddd;
    margin-top: 6px;
}

.check-form .wide {
    width: 100%;
    margin-top: 10px;
}

/* ===== Result Box ===== */
.results-section {
    margin-top: 40px;
}

.result-box {
    margin-top: 16px;
    background: #fff;
    border-radius: 14px;
    border: 1px solid #eee;
    padding: 16px;
    box-shadow: 0 10px 24px rgba(0, 0, 0, 0.06);
}

.empty-state {
    color: #666;
    font-style: italic;
}

/* ===== Table Styling ===== */
.table-wrap {
    overflow-x: auto;
}

.status-table {
    width: 100%;
    border-collapse: collapse;
    min-width: 900px;
    border: 1px solid #e5e7eb;
}

.status-table th,
.status-table td {
    border: 1px solid #e5e7eb;
    padding: 12px 14px;
    text-align: left;
}

.status-table th {
    background: #f8fafc;
    font-weight: 700;
}

.status-table tr:nth-child(even) {
    background: #fafafa;
}

.badge-green {
    background: #e9f9ef;
    color: #117a37;
    padding: 4px 10px;
    border-radius: 20px;
    font-weight: 600;
}

.badge-yellow {
    background: #fff4d6;
    color: #a16207;
    padding: 4px 10px;
    border-radius: 20px;
    font-weight: 600;
}

/* ===== Responsive ===== */
@media (max-width: 900px) {
    .check-hero {
        grid-template-columns: 1fr;
    }
}

.guidance-form {
    background: var(--card);
    border: 1px solid var(--border);
    padding: 20px;
    border-radius: 16px;
}

.guidance-form .grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
    margin-bottom: 16px;
}

.guidance-form label {
    display: flex;
    flex-direction: column;
    gap: 8px;
    font-weight: 600;
}

.guidance-form input,
.guidance-form select {
    padding: 10px 12px;
    border-radius: 10px;
    border: 1px solid var(--border);
}

.guidance-output {
    margin-top: 18px;
    padding: 16px;
    background: #fff;
    border: 1px solid var(--border);
    border-radius: 12px;
}

.guidance-list {
    display: grid;
    gap: 12px;
}

.guidance-item {
    display: grid;
    grid-template-columns: 42px 1fr;
    align-items: start;
    gap: 12px;
    padding: 14px 16px;
    border-radius: 14px;
    border: 1px solid #e2e8f0;
    background: linear-gradient(135deg, #fff1f2, #f8fafc);
}

.guidance-item:nth-child(2n) {
    background: linear-gradient(135deg, #ecfeff, #f8fafc);
}

.guidance-item:nth-child(3n) {
    background: linear-gradient(135deg, #ecfdf3, #f8fafc);
}

.guidance-number {
    width: 34px;
    height: 34px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    background: var(--primary);
    color: #fff;
    font-weight: 700;
    font-size: 14px;
}

.guidance-text {
    color: var(--text);
    line-height: 1.5;
    font-weight: 500;
}

@media (max-width: 900px) {
    .guidance-form .grid {
        grid-template-columns: 1fr;
    }
}

.guidance-section {
    margin-top: 18px;
    padding: 16px;
    background: #fff;
    border: 1px solid var(--border);
    border-radius: 12px;
}

.guidance-section h4 {
    margin-bottom: 10px;
    font-size: 1rem;
}

.doc-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

.doc-card {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 12px;
}

.doc-card h5 {
    margin-bottom: 8px;
    color: #0f172a;
}

.doc-card ul,
.precaution-list {
    padding-left: 18px;
    color: #334155;
}

.precaution-list li {
    margin-bottom: 6px;
}

@media (max-width: 900px) {
    .doc-grid {
        grid-template-columns: 1fr;
    }
}