/**
 * HomeHelp.ch - Main Styles
 * L'aide de confiance pour parents - Riviera vaudoise
 */

/* =====================================================
   VARIABLES & THEME
   ===================================================== */
:root {
    --primary: #0D9488;
    --primary-dark: #0F766E;
    --primary-light: #5EEAD4;
    --primary-bg: #F0FDFA;

    --coral: #FB7185;
    --coral-dark: #E11D48;
    --warm: #FBBF24;

    --secondary: #1f2937;
    --success: #22c55e;
    --warning: #f59e0b;
    --danger: #ef4444;
    --info: #6366f1;

    --bg-primary: #FAFAF9;
    --bg-card: #ffffff;
    --bg-warm: #FEF7ED;
    --border-color: #e5e7eb;

    --text-primary: #111827;
    --text-secondary: #6b7280;
    --text-muted: #9ca3af;

    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
    --shadow-primary: 0 8px 24px rgba(13, 148, 136, 0.20);

    --radius-sm: 0.375rem;
    --radius-md: 0.5rem;
    --radius-lg: 0.75rem;
    --radius-xl: 1rem;
    --radius-2xl: 1.5rem;
}

* { box-sizing: border-box; }

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background-color: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
}

/* =====================================================
   LOADING
   ===================================================== */
.loading-spinner {
    width: 48px;
    height: 48px;
    border: 4px solid #e5e7eb;
    border-top-color: var(--primary);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}
@keyframes spin {
    to { transform: rotate(360deg); }
}
.loading-dots::after {
    display: inline-block;
    width: 1ch;
    overflow: hidden;
    vertical-align: bottom;
    animation: dots 1.5s steps(4, end) infinite;
    content: "...";
}
@keyframes dots {
    0% { width: 0; }
    100% { width: 1.2em; }
}

/* =====================================================
   BUTTONS
   ===================================================== */
.btn-primary {
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    color: white;
    padding: 0.75rem 1.5rem;
    border-radius: var(--radius-lg);
    font-weight: 600;
    box-shadow: var(--shadow-primary);
    transition: all 0.2s;
    border: none;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    text-decoration: none;
}
.btn-primary:hover {
    transform: translateY(-1px);
    box-shadow: 0 12px 28px rgba(13, 148, 136, 0.30);
}
.btn-primary:disabled {
    background: #D1D5DB;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

.btn-coral {
    background: linear-gradient(135deg, var(--coral), var(--coral-dark));
    color: white;
    padding: 0.75rem 1.5rem;
    border-radius: var(--radius-lg);
    font-weight: 600;
    box-shadow: 0 8px 24px rgba(225, 29, 72, 0.20);
    transition: all 0.2s;
    border: none;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    text-decoration: none;
}
.btn-coral:hover {
    transform: translateY(-1px);
    box-shadow: 0 12px 28px rgba(225, 29, 72, 0.30);
}

.btn-secondary {
    background-color: #F3F4F6;
    color: var(--secondary);
    padding: 0.75rem 1.5rem;
    border-radius: var(--radius-lg);
    transition: all 0.2s;
    border: none;
    cursor: pointer;
    font-weight: 500;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    text-decoration: none;
}
.btn-secondary:hover { background-color: #E5E7EB; }

.btn-outline {
    background: transparent;
    color: var(--primary);
    padding: 0.7rem 1.45rem;
    border-radius: var(--radius-lg);
    border: 2px solid var(--primary);
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    text-decoration: none;
}
.btn-outline:hover {
    background: var(--primary);
    color: white;
}

.btn-ghost {
    background: transparent;
    color: var(--text-secondary);
    padding: 0.5rem 1rem;
    border-radius: var(--radius-lg);
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    border: none;
    text-decoration: none;
}
.btn-ghost:hover { background: #F3F4F6; color: var(--text-primary); }

.btn-sm { padding: 0.5rem 1rem; font-size: 0.875rem; }
.btn-lg { padding: 1rem 2rem; font-size: 1.125rem; }
.btn-xl { padding: 1.125rem 2.5rem; font-size: 1.125rem; border-radius: 1rem; }
.btn-icon { width: 2.5rem; height: 2.5rem; padding: 0; }
.btn-block { width: 100%; }

/* =====================================================
   HEADER / NAV
   ===================================================== */
.app-header {
    position: sticky;
    top: 0;
    z-index: 50;
    background: rgba(255, 255, 255, 0.92);
    backdrop-filter: saturate(180%) blur(12px);
    -webkit-backdrop-filter: saturate(180%) blur(12px);
    border-bottom: 1px solid var(--border-color);
}
.header-inner {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0.75rem 1.5rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
}
.brand {
    display: inline-flex;
    align-items: center;
    gap: 0.6rem;
    font-weight: 800;
    font-size: 1.25rem;
    color: var(--text-primary);
    text-decoration: none;
    letter-spacing: -0.01em;
}
.brand-mark {
    width: 36px; height: 36px;
    border-radius: 12px;
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    display: inline-flex; align-items: center; justify-content: center;
    color: white; font-size: 1.05rem;
    box-shadow: var(--shadow-primary);
}
.brand-suffix {
    color: var(--primary);
    font-weight: 700;
}
.nav-links {
    display: none;
    gap: 0.25rem;
    align-items: center;
}
@media (min-width: 900px) {
    .nav-links { display: inline-flex; }
}
.nav-link {
    padding: 0.5rem 0.85rem;
    border-radius: var(--radius-lg);
    color: var(--text-secondary);
    font-weight: 500;
    text-decoration: none;
    transition: all 0.15s;
    cursor: pointer;
}
.nav-link:hover { background: var(--primary-bg); color: var(--primary-dark); }
.nav-link.active { color: var(--primary-dark); background: var(--primary-bg); }

.city-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.45rem 0.85rem;
    background: white;
    border: 1.5px solid var(--primary-light);
    color: var(--primary-dark);
    border-radius: 999px;
    font-weight: 600;
    font-size: 0.875rem;
    cursor: pointer;
    transition: all 0.15s;
}
.city-pill:hover { background: var(--primary-bg); }

/* =====================================================
   HERO
   ===================================================== */
.hero {
    position: relative;
    background: linear-gradient(180deg, #ECFDF5 0%, var(--bg-primary) 100%);
    padding: 4rem 1.5rem 3rem;
    overflow: hidden;
    isolation: isolate;
}
.hero::before {
    content: '';
    position: absolute;
    inset: 0;
    background-image:
        radial-gradient(circle at 20% 10%, rgba(13, 148, 136, 0.08), transparent 40%),
        radial-gradient(circle at 80% 30%, rgba(251, 113, 133, 0.08), transparent 40%);
    pointer-events: none;
    z-index: 1;
}

.hero-video {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    z-index: 0;
    pointer-events: none;
    opacity: 0.95;
}
.hero-overlay {
    position: absolute;
    inset: 0;
    z-index: 1;
    pointer-events: none;
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.55) 0%, rgba(255, 255, 255, 0.78) 55%, rgba(236, 253, 245, 0.92) 100%),
        linear-gradient(135deg, rgba(13, 148, 136, 0.08), rgba(251, 113, 133, 0.06));
}
.hero-with-video .hero-eyebrow {
    background: rgba(255, 255, 255, 0.92);
    backdrop-filter: saturate(140%) blur(4px);
    -webkit-backdrop-filter: saturate(140%) blur(4px);
}
@media (prefers-reduced-motion: reduce) {
    .hero-video { display: none; }
}

.hero-inner {
    position: relative;
    z-index: 2;
    max-width: 1100px;
    margin: 0 auto;
    text-align: center;
}
.hero-eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.4rem 0.9rem;
    background: white;
    border: 1px solid var(--border-color);
    border-radius: 999px;
    font-size: 0.85rem;
    color: var(--primary-dark);
    font-weight: 600;
    box-shadow: var(--shadow-sm);
    margin-bottom: 1.25rem;
}
.hero-eyebrow .dot {
    width: 8px; height: 8px;
    border-radius: 50%;
    background: var(--success);
    box-shadow: 0 0 0 3px rgba(34, 197, 94, 0.25);
    animation: pulse 1.6s infinite;
}
@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}
.hero h1 {
    font-size: 2.25rem;
    font-weight: 800;
    line-height: 1.1;
    letter-spacing: -0.025em;
    color: var(--text-primary);
    margin-bottom: 1rem;
    min-height: 2.7em;
}
.hero h1 .accent { color: var(--primary); }
@media (min-width: 768px) {
    .hero h1 { font-size: 3.25rem; }
}
@media (min-width: 1100px) {
    .hero h1 { font-size: 3.75rem; }
}

.hero-rotating {
    display: inline-block;
    transition: opacity 0.35s ease, transform 0.35s ease;
    will-change: opacity, transform;
}
.hero-rotating.is-in {
    opacity: 1;
    transform: translateY(0);
}
.hero-rotating.is-out {
    opacity: 0;
    transform: translateY(-8px);
}
@media (prefers-reduced-motion: reduce) {
    .hero-rotating { transition: none; }
    .hero-rotating.is-out { opacity: 1; transform: none; }
}
.hero p.lead {
    font-size: 1.125rem;
    color: var(--text-secondary);
    max-width: 640px;
    margin: 0 auto 2rem;
    line-height: 1.55;
}
.hero-cta-row {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    justify-content: center;
}
.hero-stats {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1rem;
    max-width: 720px;
    margin: 2.5rem auto 0;
}
.hero-stat {
    background: white;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-xl);
    padding: 1rem 0.75rem;
    text-align: center;
    box-shadow: var(--shadow-sm);
}
.hero-stat .num {
    font-size: 1.4rem;
    font-weight: 800;
    color: var(--primary);
    line-height: 1;
}
.hero-stat .lbl {
    font-size: 0.75rem;
    color: var(--text-secondary);
    margin-top: 0.35rem;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

/* =====================================================
   CITY SELECTOR (homepage + sticky)
   ===================================================== */
.city-selector {
    display: flex;
    flex-wrap: wrap;
    gap: 0.6rem;
    justify-content: center;
    margin: 1.5rem auto 0;
}
.city-card {
    background: white;
    border: 2px solid var(--border-color);
    border-radius: var(--radius-xl);
    padding: 1rem 1.25rem;
    cursor: pointer;
    transition: all 0.18s;
    min-width: 160px;
    text-align: left;
    text-decoration: none;
    color: inherit;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}
.city-card:hover {
    border-color: var(--primary-light);
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}
.city-card.active {
    border-color: var(--primary);
    background: var(--primary-bg);
}
.city-card .pin {
    width: 38px; height: 38px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary-light), var(--primary));
    color: white;
    display: inline-flex; align-items: center; justify-content: center;
    font-size: 1rem;
    flex-shrink: 0;
}
.city-card .name {
    font-weight: 700;
    line-height: 1.1;
}
.city-card .meta {
    font-size: 0.72rem;
    color: var(--text-secondary);
    margin-top: 0.15rem;
}

/* =====================================================
   SECTIONS / CONTAINERS
   ===================================================== */
.section {
    max-width: 1280px;
    margin: 0 auto;
    padding: 3rem 1.5rem;
}
.section-tight { padding: 1.5rem 1.5rem; }
.section h2 {
    font-size: 1.75rem;
    font-weight: 800;
    letter-spacing: -0.02em;
    margin-bottom: 0.5rem;
}
.section h2 .accent { color: var(--primary); }
.section .subtitle {
    color: var(--text-secondary);
    margin-bottom: 1.75rem;
    max-width: 640px;
}

/* =====================================================
   CARDS
   ===================================================== */
.card {
    background: var(--bg-card);
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--border-color);
    overflow: hidden;
}
.card-body { padding: 1.25rem; }

/* HELPER CARD */
.helper-card {
    background: white;
    border-radius: var(--radius-xl);
    border: 1px solid var(--border-color);
    overflow: hidden;
    transition: all 0.25s;
    cursor: pointer;
    display: flex;
    flex-direction: column;
}
.helper-card:hover {
    border-color: var(--primary-light);
    transform: translateY(-3px);
    box-shadow: var(--shadow-lg);
}
.helper-card-cover {
    position: relative;
    aspect-ratio: 4/3;
    background: linear-gradient(135deg, #ECFDF5, #FEF7ED);
    overflow: hidden;
}
.helper-card-cover img {
    width: 100%; height: 100%;
    object-fit: cover;
    transition: transform 0.4s;
}
.helper-card:hover .helper-card-cover img { transform: scale(1.05); }
.helper-card-avatar-fallback {
    width: 100%; height: 100%;
    display: flex; align-items: center; justify-content: center;
    color: var(--primary);
    font-size: 3rem;
    font-weight: 700;
}
.badge-floating {
    position: absolute;
    top: 0.75rem;
    padding: 0.3rem 0.7rem;
    border-radius: 999px;
    font-size: 0.72rem;
    font-weight: 700;
    box-shadow: var(--shadow-sm);
}
.badge-now {
    left: 0.75rem;
    background: var(--success);
    color: white;
}
.badge-now .dot {
    display: inline-block;
    width: 7px; height: 7px;
    border-radius: 50%;
    background: white;
    margin-right: 0.35rem;
    vertical-align: middle;
}
.badge-featured {
    right: 0.75rem;
    background: linear-gradient(135deg, var(--warm), #F59E0B);
    color: white;
}
.fav-btn {
    position: absolute;
    top: 0.75rem; right: 0.75rem;
    width: 2.25rem; height: 2.25rem;
    background: white;
    border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    box-shadow: var(--shadow-md);
    cursor: pointer;
    transition: all 0.2s;
    border: none;
    color: var(--text-secondary);
}
.fav-btn:hover { transform: scale(1.1); }
.fav-btn.active { background: #fee2e2; color: #ef4444; }

.helper-card-content { padding: 1rem 1.1rem 1.1rem; }
.helper-card-title {
    font-size: 1.05rem;
    font-weight: 700;
    line-height: 1.25;
    margin-bottom: 0.2rem;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.helper-card-meta {
    color: var(--text-secondary);
    font-size: 0.85rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0.65rem;
}
.helper-card-services {
    display: flex; flex-wrap: wrap; gap: 0.3rem;
    margin-bottom: 0.75rem;
}
.svc-chip {
    background: var(--primary-bg);
    color: var(--primary-dark);
    padding: 0.2rem 0.55rem;
    border-radius: 999px;
    font-size: 0.7rem;
    font-weight: 600;
}
.helper-card-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-top: 1px dashed var(--border-color);
    padding-top: 0.7rem;
}
.helper-card-rate {
    font-weight: 800;
    color: var(--primary-dark);
    font-size: 1.1rem;
}
.helper-card-rate .per { font-weight: 500; color: var(--text-secondary); font-size: 0.8rem; }
.helper-card-rating {
    display: inline-flex; align-items: center; gap: 0.3rem;
    font-size: 0.85rem; color: var(--text-secondary);
}
.helper-card-rating .star { color: var(--warm); }

/* =====================================================
   GRID
   ===================================================== */
.grid-helpers {
    display: grid;
    gap: 1.25rem;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
}

/* =====================================================
   URGENCY BANNER
   ===================================================== */
.urgency-banner {
    background: linear-gradient(135deg, #FEF2F2, #FEE2E2);
    border: 2px dashed var(--coral-dark);
    border-radius: var(--radius-2xl);
    padding: 1.5rem 1.75rem;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    align-items: center;
    text-align: center;
}
@media (min-width: 768px) {
    .urgency-banner {
        flex-direction: row;
        text-align: left;
    }
}
.urgency-icon {
    width: 56px; height: 56px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--coral), var(--coral-dark));
    color: white;
    display: inline-flex; align-items: center; justify-content: center;
    font-size: 1.4rem;
    box-shadow: 0 8px 24px rgba(225, 29, 72, 0.30);
    flex-shrink: 0;
    animation: heartbeat 2s infinite;
}
@keyframes heartbeat {
    0%, 100% { transform: scale(1); }
    20% { transform: scale(1.08); }
    40% { transform: scale(1); }
    60% { transform: scale(1.05); }
}
.urgency-text { flex: 1; }
.urgency-text h3 {
    font-size: 1.25rem; font-weight: 800;
    color: var(--coral-dark); margin-bottom: 0.25rem;
}
.urgency-text p { color: var(--text-secondary); font-size: 0.9rem; }

/* =====================================================
   FEATURE GRID (How it works / Services)
   ===================================================== */
.feature-grid {
    display: grid;
    gap: 1rem;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
}
.feature-card {
    background: white;
    border-radius: var(--radius-xl);
    padding: 1.5rem;
    border: 1px solid var(--border-color);
    transition: all 0.2s;
}
.feature-card:hover {
    border-color: var(--primary-light);
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}
.feature-icon {
    width: 52px; height: 52px;
    border-radius: 16px;
    display: inline-flex; align-items: center; justify-content: center;
    margin-bottom: 1rem;
    font-size: 1.4rem;
}
.feature-icon.ic-1 { background: var(--primary-bg); color: var(--primary); }
.feature-icon.ic-2 { background: #FEF7ED; color: #D97706; }
.feature-icon.ic-3 { background: #FCE7F3; color: var(--coral-dark); }
.feature-icon.ic-4 { background: #E0E7FF; color: #6366F1; }
.feature-card h4 { font-size: 1.1rem; font-weight: 700; margin-bottom: 0.4rem; }
.feature-card p { color: var(--text-secondary); font-size: 0.92rem; line-height: 1.5; }

/* Steps */
.step-card {
    background: white;
    border-radius: var(--radius-xl);
    padding: 1.5rem;
    border: 1px solid var(--border-color);
    text-align: center;
    position: relative;
}
.step-num {
    position: absolute;
    top: -16px; left: 50%;
    transform: translateX(-50%);
    width: 36px; height: 36px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    color: white;
    display: inline-flex; align-items: center; justify-content: center;
    font-weight: 800;
    box-shadow: var(--shadow-primary);
}

/* =====================================================
   TRUST / SOCIAL PROOF
   ===================================================== */
.trust-row {
    display: flex; flex-wrap: wrap; gap: 0.75rem;
    justify-content: center;
}
.trust-pill {
    background: white;
    border: 1px solid var(--border-color);
    border-radius: 999px;
    padding: 0.5rem 1rem;
    font-size: 0.85rem;
    color: var(--text-secondary);
    display: inline-flex; align-items: center; gap: 0.5rem;
}
.trust-pill i { color: var(--primary); }

/* Testimonial card */
.testimonial {
    background: white;
    border-radius: var(--radius-xl);
    padding: 1.5rem;
    border: 1px solid var(--border-color);
}
.testimonial .stars { color: var(--warm); margin-bottom: 0.5rem; }
.testimonial p { font-size: 0.95rem; color: var(--text-primary); margin-bottom: 1rem; line-height: 1.55; }
.testimonial .author {
    display: flex; align-items: center; gap: 0.75rem;
}
.testimonial .author .avatar {
    width: 40px; height: 40px;
    border-radius: 50%;
    background: var(--primary-bg);
    color: var(--primary);
    display: inline-flex; align-items: center; justify-content: center;
    font-weight: 700;
}
.testimonial .author .meta {
    font-size: 0.85rem;
}
.testimonial .author .name { font-weight: 700; }
.testimonial .author .city { color: var(--text-secondary); font-size: 0.8rem; }

/* =====================================================
   FOOTER
   ===================================================== */
.app-footer {
    background: #0F172A;
    color: #CBD5E1;
    padding: 3rem 1.5rem 1.5rem;
    margin-top: 3rem;
}
.footer-inner {
    max-width: 1280px; margin: 0 auto;
    display: grid;
    gap: 2rem;
    grid-template-columns: 1.4fr repeat(3, 1fr);
}
@media (max-width: 800px) {
    .footer-inner { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 480px) {
    .footer-inner { grid-template-columns: 1fr; }
}
.footer-brand p { color: #94A3B8; font-size: 0.9rem; margin-top: 0.5rem; max-width: 280px; }
.footer-col h5 {
    color: white;
    font-weight: 700;
    margin-bottom: 0.85rem;
    font-size: 0.95rem;
}
.footer-col a {
    display: block;
    color: #94A3B8;
    padding: 0.3rem 0;
    text-decoration: none;
    font-size: 0.9rem;
    transition: color 0.15s;
}
.footer-col a:hover { color: white; }
.footer-bottom {
    border-top: 1px solid #1E293B;
    margin-top: 2rem;
    padding-top: 1rem;
    text-align: center;
    color: #64748B;
    font-size: 0.85rem;
}

/* =====================================================
   FORMS
   ===================================================== */
.form-group { margin-bottom: 1rem; }
.form-label {
    display: block;
    font-size: 0.85rem;
    font-weight: 600;
    margin-bottom: 0.4rem;
    color: var(--text-primary);
}
.form-input,
.form-select,
.form-textarea {
    width: 100%;
    padding: 0.7rem 0.9rem;
    border: 1.5px solid var(--border-color);
    border-radius: var(--radius-lg);
    font-size: 0.95rem;
    font-family: inherit;
    background: white;
    color: var(--text-primary);
    transition: all 0.15s;
}
.form-input:focus,
.form-select:focus,
.form-textarea:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 4px rgba(13, 148, 136, 0.12);
}
.form-textarea { resize: vertical; min-height: 110px; }
.form-help { color: var(--text-muted); font-size: 0.8rem; margin-top: 0.3rem; }
.form-error { color: var(--danger); font-size: 0.85rem; margin-top: 0.3rem; }

.form-check {
    display: flex; align-items: center; gap: 0.6rem;
    padding: 0.65rem 0.9rem;
    border: 1.5px solid var(--border-color);
    border-radius: var(--radius-lg);
    cursor: pointer;
    transition: all 0.15s;
    background: white;
}
.form-check:hover { border-color: var(--primary-light); }
.form-check.active { border-color: var(--primary); background: var(--primary-bg); }
.form-check input { accent-color: var(--primary); }

/* =====================================================
   FILTER BAR
   ===================================================== */
.filter-bar {
    background: white;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-xl);
    padding: 1rem;
    display: grid;
    gap: 0.75rem;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    align-items: end;
    margin-bottom: 1.5rem;
}
@media (max-width: 900px) {
    .filter-bar { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 600px) {
    .filter-bar { grid-template-columns: 1fr; }
}

/* =====================================================
   DETAILS - Helper profile
   ===================================================== */
.helper-hero {
    background: linear-gradient(135deg, var(--primary-bg), white);
    border-radius: var(--radius-2xl);
    padding: 2rem;
    display: grid;
    gap: 1.5rem;
    grid-template-columns: 200px 1fr;
    align-items: center;
    border: 1px solid var(--border-color);
    margin-bottom: 2rem;
}
@media (max-width: 700px) {
    .helper-hero { grid-template-columns: 1fr; text-align: center; }
}
.helper-hero-photo {
    width: 200px; height: 200px;
    border-radius: 24px;
    object-fit: cover;
    background: var(--primary-bg);
    border: 4px solid white;
    box-shadow: var(--shadow-md);
}
.helper-hero h1 {
    font-size: 1.75rem;
    font-weight: 800;
    margin-bottom: 0.25rem;
    letter-spacing: -0.01em;
}
.helper-hero .headline {
    color: var(--text-secondary);
    font-size: 1.05rem;
    margin-bottom: 0.85rem;
}
.helper-hero .meta-row {
    display: flex; flex-wrap: wrap; gap: 0.6rem;
    margin-bottom: 1rem;
}
.helper-hero .meta-pill {
    background: white;
    border: 1px solid var(--border-color);
    padding: 0.4rem 0.8rem;
    border-radius: 999px;
    font-size: 0.85rem;
    color: var(--text-secondary);
    display: inline-flex; align-items: center; gap: 0.4rem;
}
.helper-hero .meta-pill i { color: var(--primary); }

.review-card {
    background: white;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-xl);
    padding: 1rem 1.25rem;
    margin-bottom: 0.75rem;
}
.review-card .head {
    display: flex; align-items: center; justify-content: space-between;
    margin-bottom: 0.5rem;
}
.review-card .who { display: flex; align-items: center; gap: 0.6rem; font-weight: 600; }
.review-card .who .avatar {
    width: 36px; height: 36px; border-radius: 50%;
    background: var(--primary-bg); color: var(--primary);
    display: flex; align-items: center; justify-content: center; font-weight: 700;
}
.review-card .stars { color: var(--warm); font-size: 0.9rem; }
.review-card .reply {
    margin-top: 0.75rem; padding: 0.7rem 0.9rem;
    background: var(--primary-bg);
    border-radius: var(--radius-lg);
    font-size: 0.9rem;
    color: var(--text-secondary);
    border-left: 3px solid var(--primary);
}

/* =====================================================
   MODAL
   ===================================================== */
.modal-overlay {
    position: fixed; inset: 0;
    background: rgba(15, 23, 42, 0.55);
    z-index: 100;
    display: flex; align-items: center; justify-content: center;
    padding: 1rem;
    animation: fadeIn 0.18s ease-out;
}
.modal {
    background: white;
    border-radius: var(--radius-2xl);
    width: 100%;
    max-width: 480px;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: var(--shadow-xl);
    animation: slideUp 0.2s ease-out;
}
.modal-lg { max-width: 720px; }
.modal-header {
    padding: 1.25rem 1.5rem;
    border-bottom: 1px solid var(--border-color);
    display: flex; align-items: center; justify-content: space-between;
}
.modal-header h3 { font-weight: 700; font-size: 1.1rem; }
.modal-body { padding: 1.5rem; }
.modal-footer {
    padding: 1rem 1.5rem;
    border-top: 1px solid var(--border-color);
    display: flex; gap: 0.5rem; justify-content: flex-end;
}
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}
@keyframes slideUp {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

/* =====================================================
   TOAST
   ===================================================== */
.toast {
    position: fixed;
    bottom: 1.5rem;
    left: 50%;
    transform: translateX(-50%);
    background: #0F172A;
    color: white;
    padding: 0.75rem 1.25rem;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-xl);
    z-index: 200;
    font-size: 0.9rem;
    animation: slideUp 0.2s ease-out;
    display: inline-flex; align-items: center; gap: 0.5rem;
    max-width: calc(100vw - 2rem);
}
.toast.success { background: #064E3B; }
.toast.error { background: #7F1D1D; }

/* =====================================================
   BADGES & MISC
   ===================================================== */
.badge {
    display: inline-flex; align-items: center; gap: 0.3rem;
    padding: 0.2rem 0.6rem;
    border-radius: 999px;
    font-size: 0.75rem;
    font-weight: 600;
}
.badge-success { background: #DCFCE7; color: #166534; }
.badge-warning { background: #FEF3C7; color: #92400E; }
.badge-danger { background: #FEE2E2; color: #991B1B; }
.badge-info { background: #DBEAFE; color: #1E40AF; }
.badge-primary { background: var(--primary-bg); color: var(--primary-dark); }
.badge-muted { background: #F3F4F6; color: var(--text-secondary); }

.divider {
    height: 1px; background: var(--border-color);
    margin: 1.25rem 0;
}

.empty-state {
    text-align: center;
    padding: 3rem 1rem;
    color: var(--text-secondary);
}
.empty-state .icon {
    font-size: 3rem;
    margin-bottom: 1rem;
    opacity: 0.4;
}
.empty-state h3 { font-size: 1.1rem; font-weight: 700; color: var(--text-primary); margin-bottom: 0.4rem; }

/* =====================================================
   LOCAL CITY PAGES
   ===================================================== */
.city-hero {
    background: linear-gradient(135deg, var(--primary-bg) 0%, white 100%);
    border-radius: var(--radius-2xl);
    padding: 2.5rem 2rem;
    text-align: center;
    margin-bottom: 2rem;
    border: 1px solid var(--border-color);
}
.city-hero h1 {
    font-size: 2rem;
    font-weight: 800;
    letter-spacing: -0.02em;
    margin-bottom: 0.5rem;
}
@media (min-width: 768px) {
    .city-hero h1 { font-size: 2.75rem; }
}
.city-hero .subtitle {
    color: var(--text-secondary);
    font-size: 1.05rem;
    max-width: 620px;
    margin: 0 auto 1.5rem;
}
.live-strip {
    background: white;
    border: 1px solid var(--border-color);
    border-radius: 999px;
    padding: 0.65rem 1.1rem;
    display: inline-flex;
    align-items: center;
    gap: 1.5rem;
    font-size: 0.85rem;
    box-shadow: var(--shadow-sm);
    flex-wrap: wrap;
    justify-content: center;
}
.live-strip .item { display: inline-flex; align-items: center; gap: 0.4rem; color: var(--text-secondary); }
.live-strip .item strong { color: var(--text-primary); }
.live-strip .live-dot {
    width: 8px; height: 8px;
    border-radius: 50%;
    background: var(--success);
    animation: pulse 1.6s infinite;
}

/* =====================================================
   APPLY (Devenir intervenant)
   ===================================================== */
.apply-hero {
    background:
        radial-gradient(circle at 80% 20%, rgba(251, 113, 133, 0.10), transparent 40%),
        linear-gradient(135deg, #FEF7ED 0%, var(--primary-bg) 100%);
    border-radius: var(--radius-2xl);
    padding: 2.5rem 2rem;
    margin-bottom: 2rem;
    border: 1px solid var(--border-color);
    text-align: center;
}
.apply-hero h1 {
    font-size: 2rem; font-weight: 800;
    letter-spacing: -0.02em; margin-bottom: 0.5rem;
}
@media (min-width: 768px) { .apply-hero h1 { font-size: 2.5rem; } }
.apply-bullets {
    display: grid; gap: 0.85rem;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    margin-top: 2rem;
    max-width: 920px; margin-left: auto; margin-right: auto;
}
.apply-bullet {
    background: white;
    border-radius: var(--radius-xl);
    padding: 1rem 1.25rem;
    border: 1px solid var(--border-color);
    display: flex; gap: 0.75rem; align-items: flex-start;
    text-align: left;
}
.apply-bullet .ic {
    width: 36px; height: 36px;
    border-radius: 50%;
    background: var(--primary-bg);
    color: var(--primary);
    display: inline-flex; align-items: center; justify-content: center;
    flex-shrink: 0;
}
.apply-bullet h4 { font-weight: 700; font-size: 0.95rem; margin-bottom: 0.2rem; }
.apply-bullet p { font-size: 0.85rem; color: var(--text-secondary); line-height: 1.4; }

.apply-services-strip {
    display: flex; flex-wrap: wrap; justify-content: center;
    gap: 0.5rem; margin: 1.25rem auto 0; max-width: 720px;
}
.apply-service-chip {
    display: inline-flex; align-items: center; gap: 0.45rem;
    padding: 0.45rem 0.85rem;
    background: white;
    border: 1px solid var(--border-color);
    border-radius: 999px;
    font-size: 0.875rem; font-weight: 600;
    color: var(--text-primary);
    box-shadow: 0 1px 2px rgba(15, 118, 110, 0.04);
}
.apply-service-chip i:first-child { font-size: 0.9rem; }

.helper-services-card {
    background: linear-gradient(180deg, var(--primary-bg) 0%, white 100%);
    border: 1px solid var(--primary-light, #99F6E4);
    border-radius: var(--radius-xl);
    padding: 1.25rem;
}
.helper-services-header {
    display: flex; gap: 0.85rem; align-items: flex-start;
    margin-bottom: 1rem;
}
.helper-services-icon {
    width: 44px; height: 44px;
    border-radius: 50%;
    background: var(--primary);
    color: white;
    display: inline-flex; align-items: center; justify-content: center;
    flex-shrink: 0;
    font-size: 1.1rem;
}
.helper-services-title {
    font-weight: 700; font-size: 1rem;
    color: var(--text-primary);
    margin-bottom: 0.25rem;
}
.helper-services-desc {
    font-size: 0.875rem; line-height: 1.5;
    color: var(--text-secondary);
    margin: 0;
}
.helper-services-list {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
    gap: 0.5rem;
}
.helper-service-chip {
    display: inline-flex; align-items: center; gap: 0.5rem;
    padding: 0.6rem 0.85rem;
    background: white;
    border: 1px solid var(--border-color);
    border-radius: 0.75rem;
    font-size: 0.9rem; font-weight: 600;
    color: var(--text-primary);
}
.helper-service-chip .chip-check {
    color: var(--primary);
    font-size: 0.95rem;
}

/* =====================================================
   UTIL
   ===================================================== */
.text-primary-c { color: var(--primary); }
.text-coral { color: var(--coral-dark); }
.bg-primary-bg { background: var(--primary-bg); }
.text-muted { color: var(--text-muted); }
.text-secondary-c { color: var(--text-secondary); }

.line-clamp-2 {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.line-clamp-3 {
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Mobile bottom safe area */
@supports (padding: max(0px)) {
    .app-footer { padding-bottom: max(1.5rem, env(safe-area-inset-bottom)); }
}

/* =====================================================
     Login : sélecteur de rôle Parent / HomeHelper
     ===================================================== */
.role-grid {
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 0.75rem;
}

.role-card {
        position: relative;
        background: #fff;
        border: 2px solid var(--border-color);
        border-radius: var(--radius-lg);
        padding: 1rem 0.85rem 0.95rem;
        text-align: center;
        cursor: pointer;
        transition: all 0.18s ease;
        font-family: inherit;
        outline: none;
        overflow: hidden;
}
.role-card:hover {
        border-color: var(--primary-light);
        background: var(--primary-bg);
        transform: translateY(-1px);
}
.role-card.is-selected[data-role="parent"] {
        border-color: var(--primary);
        background: linear-gradient(180deg, #F0FDFA 0%, #fff 100%);
        box-shadow: 0 6px 18px rgba(13, 148, 136, 0.18);
}
.role-card.is-selected[data-role="helper"] {
        border-color: var(--coral);
        background: linear-gradient(180deg, #FFF1F2 0%, #fff 100%);
        box-shadow: 0 6px 18px rgba(225, 29, 72, 0.18);
}

.role-card-icon {
        width: 48px; height: 48px;
        border-radius: 14px;
        margin: 0 auto 0.6rem;
        display: flex; align-items: center; justify-content: center;
        font-size: 1.3rem;
        background: #F3F4F6;
        color: var(--text-secondary);
        transition: all 0.18s ease;
}
.role-card[data-role="parent"]:hover .role-card-icon,
.role-card.is-selected[data-role="parent"] .role-card-icon {
        background: linear-gradient(135deg, var(--primary), var(--primary-dark));
        color: white;
}
.role-card[data-role="helper"]:hover .role-card-icon,
.role-card.is-selected[data-role="helper"] .role-card-icon {
        background: linear-gradient(135deg, var(--coral), var(--coral-dark));
        color: white;
}

.role-card-title {
        font-weight: 700;
        font-size: 1rem;
        color: var(--text-primary);
        margin-bottom: 0.15rem;
}
.role-card-subtitle {
        font-size: 0.78rem;
        font-weight: 600;
        color: var(--text-secondary);
        margin-bottom: 0.4rem;
}
.role-card.is-selected[data-role="parent"] .role-card-subtitle { color: var(--primary-dark); }
.role-card.is-selected[data-role="helper"] .role-card-subtitle { color: var(--coral-dark); }
.role-card-desc {
        font-size: 0.78rem;
        color: var(--text-muted);
        line-height: 1.35;
}
.role-card-check {
        position: absolute;
        top: 0.55rem; right: 0.55rem;
        width: 22px; height: 22px;
        border-radius: 50%;
        display: flex; align-items: center; justify-content: center;
        color: white;
        font-size: 0.7rem;
        font-weight: bold;
}
.role-card.is-selected[data-role="parent"] .role-card-check { background: var(--primary); }
.role-card.is-selected[data-role="helper"] .role-card-check { background: var(--coral-dark); }

@media (max-width: 360px) {
        .role-grid { grid-template-columns: 1fr; }
}

.form-input-lg {
        padding: 0.95rem 1.1rem;
        font-size: 1.05rem;
}
