:root {
    --cvas-primary: #1e3a8a;
    --cvas-primary-light: #2563eb;
    --cvas-success: #16a34a;
    --cvas-warning: #d97706;
    --cvas-danger: #dc2626;
    --cvas-info: #2563eb;
    --cvas-muted: #6b7280;
    --cvas-card-shadow: 0 4px 6px -1px rgb(0 0 0 / 0.1);
}

.cvas-card {
    background: #fff;
    border-radius: 0.5rem;
    box-shadow: var(--cvas-card-shadow);
    padding: 1.5rem;
}

.cvas-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    font-weight: 600;
    border-radius: 0.375rem;
    transition: background-color 0.15s, opacity 0.15s;
}

.cvas-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.cvas-input {
    width: 100%;
    padding: 0.5rem 0.75rem;
    border: 1px solid #d1d5db;
    border-radius: 0.375rem;
}

.cvas-input:focus {
    outline: none;
    border-color: var(--cvas-primary-light);
    box-shadow: 0 0 0 2px rgb(37 99 235 / 0.2);
}

.cvas-badge {
    display: inline-block;
    padding: 0.125rem 0.5rem;
    border-radius: 9999px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
}

.cvas-badge-pending { background: #fef3c7; color: #92400e; }
.cvas-badge-approved { background: #dcfce7; color: #166534; }
.cvas-badge-rejected { background: #fee2e2; color: #991b1b; }
.cvas-badge-completed { background: #dbeafe; color: #1e40af; }

.cvas-hero {
    background: linear-gradient(135deg, rgba(30, 58, 138, 0.92), rgba(17, 24, 39, 0.88)),
                linear-gradient(180deg, #1e3a8a 0%, #111827 100%);
}

.cvas-toast-container {
    position: fixed;
    top: 1rem;
    right: 1rem;
    z-index: 9999;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    max-width: 24rem;
}

.cvas-toast {
    padding: 0.75rem 1rem;
    border-radius: 0.5rem;
    color: #fff;
    font-size: 0.875rem;
    box-shadow: 0 10px 15px -3px rgb(0 0 0 / 0.15);
    animation: cvas-toast-in 0.25s ease-out;
}

.cvas-toast-success { background: var(--cvas-success); }
.cvas-toast-error { background: var(--cvas-danger); }
.cvas-toast-info { background: var(--cvas-info); }
.cvas-toast-warning { background: var(--cvas-warning); }

@keyframes cvas-toast-in {
    from { opacity: 0; transform: translateX(1rem); }
    to { opacity: 1; transform: translateX(0); }
}

.cvas-skeleton {
    background: linear-gradient(90deg, #f3f4f6 25%, #e5e7eb 50%, #f3f4f6 75%);
    background-size: 200% 100%;
    animation: cvas-shimmer 1.2s infinite;
    border-radius: 0.25rem;
    height: 1rem;
}

@keyframes cvas-shimmer {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

.cvas-empty-state {
    text-align: center;
    padding: 2rem 1rem;
    color: var(--cvas-muted);
}

.cvas-empty-state i {
    font-size: 2rem;
    margin-bottom: 0.75rem;
    opacity: 0.5;
}

.cvas-insight-card {
    cursor: pointer;
    transition: transform 0.15s, box-shadow 0.15s;
}

.cvas-insight-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 16px -4px rgb(0 0 0 / 0.12);
}

.cvas-peak-warning {
    background: #fffbeb;
    border: 1px solid #fcd34d;
    color: #92400e;
    border-radius: 0.375rem;
    padding: 0.75rem;
    font-size: 0.875rem;
}

.cvas-suggestion-chip {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    margin: 0.25rem;
    background: #eff6ff;
    color: #1d4ed8;
    border: 1px solid #bfdbfe;
    border-radius: 9999px;
    font-size: 0.75rem;
    cursor: pointer;
    transition: background 0.15s;
}

.cvas-suggestion-chip:hover {
    background: #dbeafe;
}

.cvas-autocomplete-list {
    position: absolute;
    z-index: 50;
    width: 100%;
    max-height: 12rem;
    overflow-y: auto;
    background: #fff;
    border: 1px solid #d1d5db;
    border-radius: 0.375rem;
    box-shadow: var(--cvas-card-shadow);
    margin-top: 0.25rem;
}

.cvas-autocomplete-item {
    padding: 0.5rem 0.75rem;
    cursor: pointer;
    font-size: 0.875rem;
}

.cvas-autocomplete-item:hover,
.cvas-autocomplete-item.active {
    background: #eff6ff;
}

.cvas-field-error {
    color: var(--cvas-danger);
    font-size: 0.75rem;
    margin-top: 0.25rem;
}

.cvas-sidebar-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgb(0 0 0 / 0.5);
    z-index: 40;
}

.cvas-sidebar-overlay.open {
    display: block;
}

@media (max-width: 767px) {
    .cvas-admin-sidebar {
        position: fixed;
        left: -16rem;
        top: 0;
        bottom: 0;
        z-index: 50;
        transition: left 0.25s ease;
    }

    .cvas-admin-sidebar.open {
        left: 0;
    }
}

.cvas-welfare-alert-row {
    border-left: 4px solid var(--cvas-danger);
}

/* Landing page */
.cvas-nav {
    background: rgba(15, 23, 42, 0.95);
    backdrop-filter: blur(8px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.cvas-logo-mark {
    width: 2.5rem;
    height: 2.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #2563eb, #1e3a8a);
    border-radius: 0.5rem;
    font-size: 1.1rem;
}

.cvas-nav-cta {
    background: #2563eb;
    color: #fff;
    padding: 0.5rem 1rem;
    border-radius: 0.375rem;
    font-weight: 600;
    transition: background 0.15s;
}

.cvas-nav-cta:hover {
    background: #1d4ed8;
    color: #fff;
}

.cvas-hero-modern {
    background: linear-gradient(145deg, #0f172a 0%, #1e3a8a 45%, #172554 100%);
}

.cvas-hero-photo {
    background-image: url('../img/hero.png');
    background-size: cover;
    background-position: center 30%;
    background-repeat: no-repeat;
}

.cvas-hero-overlay {
    background: linear-gradient(105deg, rgba(15, 23, 42, 0.92) 0%, rgba(30, 58, 138, 0.78) 45%, rgba(15, 23, 42, 0.55) 100%);
}

.cvas-hero-grid {
    background-image:
        radial-gradient(circle at 20% 50%, rgba(59, 130, 246, 0.15) 0%, transparent 50%),
        radial-gradient(circle at 80% 20%, rgba(99, 102, 241, 0.12) 0%, transparent 40%),
        linear-gradient(rgba(255,255,255,0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255,255,255,0.03) 1px, transparent 1px);
    background-size: auto, auto, 48px 48px, 48px 48px;
}

.cvas-stat-card {
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 0.75rem;
    padding: 1rem 1.25rem;
    backdrop-filter: blur(4px);
}

.cvas-stat-value {
    font-size: 1.25rem;
    font-weight: 700;
    color: #fff;
}

.cvas-stat-label {
    font-size: 0.75rem;
    color: #93c5fd;
    margin-top: 0.25rem;
}

.cvas-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.375rem;
    padding: 0.25rem 0.75rem;
    border-radius: 9999px;
    font-size: 0.75rem;
    font-weight: 600;
}

.cvas-pill-live {
    background: rgba(34, 197, 94, 0.15);
    color: #86efac;
    border: 1px solid rgba(34, 197, 94, 0.3);
}

.cvas-pill-active {
    background: #dcfce7;
    color: #166534;
}

.cvas-pill-soon {
    background: #f1f5f9;
    color: #475569;
    font-size: 0.65rem;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    border: 1px solid #e2e8f0;
}

.cvas-btn-primary {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: #2563eb;
    color: #fff;
    font-weight: 700;
    padding: 0.875rem 1.75rem;
    border-radius: 0.5rem;
    transition: background 0.15s, transform 0.15s;
}

.cvas-btn-primary:hover {
    background: #1d4ed8;
    color: #fff;
    transform: translateY(-1px);
}

.cvas-btn-secondary {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
    font-weight: 700;
    padding: 0.875rem 1.75rem;
    border-radius: 0.5rem;
    border: 1px solid rgba(255, 255, 255, 0.2);
    transition: background 0.15s;
}

.cvas-btn-secondary:hover {
    background: rgba(255, 255, 255, 0.18);
    color: #fff;
}

.cvas-feature-card {
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 0.75rem;
    padding: 1.5rem;
    transition: box-shadow 0.2s, transform 0.2s;
}

.cvas-feature-card:hover {
    box-shadow: 0 12px 24px -8px rgb(0 0 0 / 0.1);
    transform: translateY(-2px);
}

.cvas-feature-highlight {
    border-color: #86efac;
    background: linear-gradient(180deg, #f0fdf4 0%, #fff 100%);
}

.cvas-feature-icon {
    width: 2.75rem;
    height: 2.75rem;
    border-radius: 0.625rem;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.125rem;
    margin-bottom: 1rem;
}

.cvas-step-card {
    text-align: center;
    background: #fff;
    border-radius: 0.75rem;
    padding: 1.5rem 1rem;
    border: 1px solid #e2e8f0;
}

.cvas-step-num {
    width: 2.5rem;
    height: 2.5rem;
    background: #1e3a8a;
    color: #fff;
    border-radius: 9999px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    margin: 0 auto 0.75rem;
}

.cvas-roadmap-card {
    border-radius: 0.75rem;
    padding: 1.5rem;
    border: 1px solid #e2e8f0;
}

.cvas-roadmap-live {
    background: #f0fdf4;
    border-color: #bbf7d0;
}

.cvas-roadmap-future {
    background: #f8fafc;
    border-color: #e2e8f0;
}

.cvas-trust-strip {
    background: linear-gradient(135deg, #1e3a8a, #0f172a);
}

.cvas-badge-verified { background: #dcfce7; color: #166534; }
.cvas-badge-unverified { background: #ffedd5; color: #9a3412; }

/* Visit scheduling pickers */
.cvas-schedule-steps {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 1.25rem;
    flex-wrap: wrap;
}

.cvas-schedule-step {
    flex: 1;
    min-width: 4rem;
    text-align: center;
    padding: 0.5rem 0.25rem;
    border-radius: 0.375rem;
    background: #f1f5f9;
    color: #64748b;
    font-size: 0.7rem;
    font-weight: 600;
    border: 2px solid transparent;
    transition: all 0.15s;
}

.cvas-schedule-step.active {
    background: #eff6ff;
    color: #1d4ed8;
    border-color: #93c5fd;
}

.cvas-schedule-step.done {
    background: #f0fdf4;
    color: #166534;
}

.cvas-date-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(5.5rem, 1fr));
    gap: 0.5rem;
}

.cvas-date-card {
    border: 2px solid #e2e8f0;
    border-radius: 0.625rem;
    padding: 0.625rem 0.5rem;
    text-align: center;
    cursor: pointer;
    background: #fff;
    transition: all 0.15s;
}

.cvas-date-card:hover {
    border-color: #93c5fd;
    background: #f8fafc;
}

.cvas-date-card.selected {
    border-color: #2563eb;
    background: #eff6ff;
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.15);
}

.cvas-date-card .weekday {
    font-size: 0.65rem;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    color: #64748b;
    font-weight: 600;
}

.cvas-date-card .day-num {
    font-size: 1.35rem;
    font-weight: 700;
    color: #0f172a;
    line-height: 1.2;
}

.cvas-date-card .month {
    font-size: 0.7rem;
    color: #64748b;
}

.cvas-date-card .spots {
    font-size: 0.6rem;
    color: #2563eb;
    margin-top: 0.25rem;
}

.cvas-time-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(6.5rem, 1fr));
    gap: 0.5rem;
}

.cvas-time-btn {
    border: 2px solid #e2e8f0;
    border-radius: 0.5rem;
    padding: 0.625rem 0.5rem;
    text-align: center;
    cursor: pointer;
    background: #fff;
    font-size: 0.875rem;
    font-weight: 600;
    color: #0f172a;
    transition: all 0.15s;
}

.cvas-time-btn:hover {
    border-color: #93c5fd;
    background: #f8fafc;
}

.cvas-time-btn.selected {
    border-color: #2563eb;
    background: #2563eb;
    color: #fff;
}

.cvas-time-btn.admin-selected {
    border-color: #2563eb;
    background: #eff6ff;
    color: #1d4ed8;
}

.cvas-time-btn .spots-left {
    display: block;
    font-size: 0.65rem;
    font-weight: 400;
    color: #64748b;
    margin-top: 0.125rem;
}

.cvas-time-btn.selected .spots-left {
    color: #bfdbfe;
}

.cvas-slot-day-group {
    border: 1px solid #e2e8f0;
    border-radius: 0.625rem;
    margin-bottom: 0.75rem;
    overflow: hidden;
}

.cvas-slot-day-header {
    background: #f8fafc;
    padding: 0.75rem 1rem;
    font-weight: 600;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid #e2e8f0;
}

.cvas-slot-day-times {
    padding: 0.75rem 1rem;
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.cvas-slot-chip {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.375rem 0.625rem;
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 9999px;
    font-size: 0.8rem;
}

.cvas-slot-chip.closed {
    opacity: 0.55;
    background: #f1f5f9;
}

.cvas-picker-label {
    font-size: 0.875rem;
    font-weight: 600;
    color: #334155;
    margin-bottom: 0.5rem;
    display: flex;
    align-items: center;
    gap: 0.375rem;
}

.cvas-picker-hint {
    font-size: 0.75rem;
    color: #64748b;
    margin-bottom: 0.5rem;
}

.cvas-picker-section {
    margin-bottom: 1.25rem;
}

.cvas-picker-section.disabled {
    opacity: 0.45;
    pointer-events: none;
}
