/* ╔══════════════════════════════════════════════════════════════════════════════╗
   ║                                                                              ║
   ║   LOCATIONS.CSS — GEOGRAPHIC AUTHORITY ARCHITECTURE                          ║
   ║   Version: 1.0 (Tesla DNA Edition)                                           ║
   ║   Target: Local SEO Dominance, Trust, & Clarity                              ║
   ║   Scope: Hub Page + All 15+ Individual Location Pages                        ║
   ║                                                                              ║
   ╚══════════════════════════════════════════════════════════════════════════════╝ */

/* ═══════════════════════════════════════════════════════════════════════════════
   1. GLOBAL PAGE CONFIGURATION
   ═══════════════════════════════════════════════════════════════════════════════ */
.page-locations {
    /* Premium background gradient */
    background: linear-gradient(to bottom, var(--color-neutral-50) 0%, var(--color-brand-white) 100%);
    color: var(--color-neutral-700);
    line-height: 1.6;
    overflow-x: hidden;
}

/* "Scroll Up" Animation Physics */
@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(30px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Staggered Animation Entry */
.section-hero, 
.section-neighborhoods, 
.section-areas,
.section-damage, 
.section-services,
.section-cost {
    animation: fadeInUp 0.8s cubic-bezier(0.2, 0.8, 0.2, 1) forwards;
}

/* Delays for "Waterfall" effect */
.section-neighborhoods { opacity: 0; animation-delay: 0.15s; animation-fill-mode: forwards; }
.section-damage        { opacity: 0; animation-delay: 0.3s; animation-fill-mode: forwards; }
.section-services      { opacity: 0; animation-delay: 0.45s; animation-fill-mode: forwards; }

/* ═══════════════════════════════════════════════════════════════════════════════
   2. BREADCRUMBS (The "Clean Pill")
   ═══════════════════════════════════════════════════════════════════════════════ */
.breadcrumb {
    display: flex;
    justify-content: center;
    padding: var(--space-4) 0;
    background: transparent;
}

.breadcrumb ol {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    gap: var(--space-2);
    list-style: none !important;
    margin: 0;
    padding: var(--space-2) 16px;
    background: white;
    border-radius: var(--radius-full);
    border: 1px solid rgba(0,0,0,0.06);
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-muted);
}

.breadcrumb li { list-style: none !important; }
.breadcrumb li:not(:last-child)::after { content: "›"; margin-left: var(--space-2); opacity: 0.4; }
.breadcrumb a { color: var(--color-brand-blue); text-decoration: none; }
.breadcrumb a:hover { color: var(--color-brand-red); }

/* ═══════════════════════════════════════════════════════════════════════════════
   3. HERO SECTION (Location Authority)
   ═══════════════════════════════════════════════════════════════════════════════ */
.section-hero {
    text-align: center;
    padding: clamp(30px, 4vw, 50px) 0; 
    background: linear-gradient(160deg, #1a2a4e 0%, var(--color-brand-blue) 100%);
    color: white;
    margin-bottom: var(--space-10);
    box-shadow: 0 10px 25px -5px rgba(24, 48, 117, 0.25);
    position: relative;
    border-radius: 0 0 var(--radius-lg) var(--radius-lg);
}

.section-hero::before {
    content: "";
    position: absolute;
    inset: 0;
    background-image: 
        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: 30px 30px;
    pointer-events: none;
}

.section-hero h1 {
    font-size: clamp(1.75rem, 3.5vw, 2.5rem);
    font-weight: 800;
    line-height: 1.2;
    color: white;
    margin: 0 auto var(--space-4);
    max-width: 900px;
    text-shadow: 0 2px 8px rgba(0,0,0,0.15);
}

.hero-lead {
    font-size: 1.05rem;
    color: rgba(255, 255, 255, 0.95);
    max-width: 70ch;
    margin: 0 auto var(--space-6);
    line-height: 1.6;
}

.hero-proof, .operational-proof {
    display: inline-block;
    background: rgba(255,255,255,0.1);
    padding: var(--space-3) 16px;
    border-radius: var(--radius-md);
    font-size: 0.9rem;
    margin-bottom: var(--space-6);
    border: 1px solid rgba(255,255,255,0.15);
}

.hero-cta, .hero-cta-soft {
    display: flex;
    justify-content: center;
    gap: var(--space-4);
    flex-wrap: wrap;
}

/* ═══════════════════════════════════════════════════════════════════════════════
   4. LOCATION GRIDS (Neighborhoods & Areas)
   The "Property Listing" look — clean, boxed, high-value.
   ═══════════════════════════════════════════════════════════════════════════════ */
.section-neighborhoods, .section-areas, .section-county {
    padding: var(--space-10) 0;
}

.section-neighborhoods h2, .section-areas h2, .section-county h2 {
    text-align: center;
    font-size: 1.8rem;
    color: var(--color-brand-blue-dark);
    margin-bottom: var(--space-4);
}

/* Center intro paragraphs below section headings */
.section-neighborhoods > .container > p,
.section-areas > .container > p,
.section-county > .container > p,
.county-intro {
    text-align: center !important;
    max-width: 70ch;
    margin: 0 auto var(--space-8) !important;
}

/* The Grid Container */
.neighborhood-grid, .location-grid, .area-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: var(--space-5);
}

/* The Card Item */
.neighborhood-item, .location-card, .area-item {
    background: white;
    border-radius: var(--radius-lg);
    padding: var(--space-6);
    
    /* Permanent Border */
    border: 1px solid var(--color-neutral-300);
    box-shadow: 0 2px 4px rgba(0,0,0,0.02);
    
    display: flex;
    flex-direction: column;
    transition: all 0.2s ease;
    text-decoration: none; /* For linked cards */
    color: inherit;
}

/* Hover State */
/* No hover effects - keep cards stable */
.neighborhood-item:hover, .location-card:hover, .area-item:hover {
    /* Cards stay the same on hover for clean appearance */
}

/* ═══════════════════════════════════════════════════════════════════════════════
   HEADING HIERARCHY - Make headings stand out from body text
   ═══════════════════════════════════════════════════════════════════════════════ */
.page-locations h2,
.page-location h2 {
    color: var(--color-brand-blue-dark, #0f1e4a) !important;
    font-weight: 800;
    margin-bottom: var(--space-6);
}

.page-locations h3,
.page-location h3 {
    color: var(--color-brand-blue, #183075) !important;
    font-weight: 700;
    font-size: 1.35rem;
    margin-top: var(--space-6);
    margin-bottom: var(--space-3);
    border-left: 4px solid var(--color-brand-red, #EC1C24);
    padding-left: 12px;
}

/* Body text stays grey for contrast */
.page-locations p,
.page-location p {
    color: var(--color-neutral-600, #4b5563);
}

/* Strong text gets emphasis */
.page-locations p strong,
.page-location p strong {
    color: var(--color-brand-blue-dark, #0f1e4a);
}

/* Card Typography */
.neighborhood-item h3, .location-name, .area-item h3 {
    font-size: 1.25rem;
    color: var(--color-brand-blue-dark);
    margin-bottom: var(--space-2);
    font-weight: 700;
}

.location-type {
    display: block;
    font-size: 0.85rem;
    color: var(--color-brand-gold, #D4A019);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: var(--space-4);
    font-weight: 600;
}

.neighborhood-item p, .location-description, .area-item p {
    font-size: 0.95rem;
    color: var(--color-neutral-600);
    margin-bottom: var(--space-4);
    flex-grow: 1;
}

/* Nested Lists in Cards */
.location-neighborhoods {
    list-style: none;
    padding: 0;
    margin: 0;
    border-top: 1px solid var(--color-neutral-100);
    padding-top: var(--space-3);
}

.location-neighborhoods li {
    font-size: 0.85rem;
    color: var(--text-muted);
    margin-bottom: 2px;
    padding-left: var(--space-4);
    position: relative;
}

.location-neighborhoods li::before {
    content: "•";
    position: absolute;
    left: 0;
    color: var(--color-brand-blue);
}

/* Card Footer (Response Time) */
.card-footer {
    margin-top: var(--space-4);
    padding-top: var(--space-3);
    border-top: 1px solid var(--color-neutral-100);
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--color-success);
}

/* ═══════════════════════════════════════════════════════════════════════════════
   5. DAMAGE & SERVICES SECTIONS
   ═══════════════════════════════════════════════════════════════════════════════ */
.section-damage, .section-services {
    padding: var(--space-12) 0;
    background-color: white;
    border-top: 1px solid var(--border);
}

.section-damage h2, .section-services h2 {
    text-align: center;
    font-size: 1.8rem;
    color: var(--color-brand-blue-dark);
    margin-bottom: var(--space-8);
}

.damage-grid, .services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: var(--space-6);
}

/* Damage/Service Items */
.damage-item, .service-item {
    background: #F8FAFC;
    padding: var(--space-6);
    border-radius: var(--radius-md);
    border: 1px solid var(--border);
}

.damage-item h3, .service-item h3 {
    font-size: 1.1rem;
    color: var(--color-brand-blue);
    margin-bottom: var(--space-3);
}

/* Service Item Links */
.service-item a {
    text-decoration: none;
    color: inherit;
}
.service-item a:hover {
    color: var(--color-brand-red);
    text-decoration: underline;
}

/* ═══════════════════════════════════════════════════════════════════════════════
   6. UNIQUE MODULES (Gate, Military, Luxury)
   Handling the specific content found in specialized location pages.
   ═══════════════════════════════════════════════════════════════════════════════ */

/* GATE ACCESS (Kiawah / Seabrook / Wild Dunes) */
.section-gate { background-color: var(--color-neutral-50); padding: var(--space-10) 0; }
.gate-process {
    background: white;
    padding: var(--space-8);
    border-radius: var(--radius-lg);
    border: 1px solid var(--border);
    max-width: 800px;
    margin: 0 auto;
    box-shadow: var(--shadow-sm);
    counter-reset: gate-counter;
    list-style: none;
}
.gate-process li {
    position: relative;
    padding-left: 50px;
    margin-bottom: var(--space-4);
}
.gate-process li::before {
    counter-increment: gate-counter;
    content: counter(gate-counter);
    position: absolute;
    left: 0;
    top: 0;
    width: 32px;
    height: 32px;
    background: var(--color-brand-blue);
    color: white;
    border-radius: 50%;
    text-align: center;
    line-height: 32px;
    font-weight: 700;
}
.gate-note { text-align: center; font-style: italic; margin-top: var(--space-6); color: var(--text-muted); }

/* MILITARY (Goose Creek) */
.section-military { background: white; border-top: 1px solid var(--border); }
.military-list {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: var(--space-4);
    list-style: none;
    padding: 0;
    margin-top: var(--space-6);
}
.military-list li {
    background: #F8FAFC;
    padding: var(--space-5);
    border-radius: var(--radius-md);
    border-left: 4px solid var(--color-brand-blue);
}

/* LUXURY (Kiawah) & VEHICLES */
.section-luxury, .section-vehicles { background: white; }
.luxury-grid, .vehicle-list-columns {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: var(--space-4);
    margin-top: var(--space-6);
}
.luxury-item {
    padding: var(--space-5);
    border: 1px solid var(--color-neutral-300);
    border-radius: var(--radius-md);
}

/* WHY MOBILE / ADVANTAGE (Charleston Specific) */
.section-advantage {
    text-align: center;
    padding: var(--space-12) 0;
}

.section-advantage h2 {
    text-align: center !important;
    margin-bottom: var(--space-4);
}

.section-advantage > .container > p {
    text-align: center !important;
    max-width: 70ch;
    margin: 0 auto var(--space-8);
}

/* Remove left border from h3s and center them in advantage section */
.section-advantage h3 {
    text-align: center !important;
    border-left: none !important;
    padding-left: 0 !important;
    margin-top: var(--space-8);
    margin-bottom: var(--space-3);
}

.section-advantage .container h3 + p,
.section-advantage .advantage-grid p {
    text-align: center !important;
    max-width: 65ch;
    margin: 0 auto var(--space-6);
}

/* Advantage grid for mobile reasons */
.advantage-grid {
    max-width: 800px;
    margin: 0 auto;
}

.advantage-grid h3 {
    color: var(--color-brand-blue);
}

.mobile-reasons {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: var(--space-4);
    list-style: none;
    padding: 0;
    max-width: 900px;
    margin: 0 auto;
}
.mobile-reasons li {
    background: white;
    padding: var(--space-5);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-sm);
    text-align: left;
}

/* ═══════════════════════════════════════════════════════════════════════════════
   7. COST & INSURANCE (The Money Box)
   ═══════════════════════════════════════════════════════════════════════════════ */
.section-cost { text-align: center; background: white; padding: var(--space-12) 0; }

.cost-factors-list {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: var(--space-4);
    list-style: none;
    padding: 0;
    margin-bottom: var(--space-8);
}
.cost-factors-list li {
    background: #F8FAFC;
    padding: var(--space-4) 20px;
    border-radius: var(--radius-full);
    border: 1px solid var(--border);
    font-size: 0.9rem;
    font-weight: 500;
}

.insurance-highlight {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: white;
    padding: var(--space-8);
    border-radius: var(--radius-lg);
    text-align: center;
    max-width: 800px;
    margin: 0 auto;
    box-shadow: 0 10px 20px -5px rgba(16, 185, 129, 0.3);
}
.insurance-highlight h3 { color: white; margin-bottom: var(--space-1); font-size: 1.5rem; }
.insurance-highlight a { color: white; text-decoration: underline; font-weight: 700; }

/* ═══════════════════════════════════════════════════════════════════════════════
   INSURANCE CARRIERS - Make company names pop with pill styling
   ═══════════════════════════════════════════════════════════════════════════════ */
.insurance-carriers {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: var(--space-3);
    list-style: none;
    padding: 0;
    margin: var(--space-6) 0;
}

.insurance-carriers li {
    display: inline-flex;
    align-items: center;
    padding: var(--space-3) var(--space-5);
    background: linear-gradient(135deg, var(--color-brand-blue) 0%, #1a3a8f 100%);
    color: white;
    font-weight: 700;
    font-size: 0.95rem;
    border-radius: var(--radius-full);
    box-shadow: 0 4px 12px rgba(24, 48, 117, 0.25);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.insurance-carriers li:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(24, 48, 117, 0.35);
}

/* ═══════════════════════════════════════════════════════════════════════════════
   INSURANCE LOGO CAROUSEL - Smooth auto-scrolling logos
   ═══════════════════════════════════════════════════════════════════════════════ */
.insurance-logo-carousel {
    position: relative;
    overflow: hidden;
    margin: var(--space-8) auto;
    max-width: 100%;
    padding: var(--space-4) 0;
    background: var(--color-neutral-50);
    border-radius: var(--radius-lg);
    border: 1px solid var(--color-neutral-200);
}

.insurance-logo-carousel::before,
.insurance-logo-carousel::after {
    content: "";
    position: absolute;
    top: 0;
    bottom: 0;
    width: 80px;
    z-index: 2;
    pointer-events: none;
}

.insurance-logo-carousel::before {
    left: 0;
    background: linear-gradient(to right, var(--color-neutral-50) 0%, transparent 100%);
}

.insurance-logo-carousel::after {
    right: 0;
    background: linear-gradient(to left, var(--color-neutral-50) 0%, transparent 100%);
}

.carousel-track {
    display: flex;
    gap: var(--space-8);
    animation: scroll-logos 25s linear infinite;
    width: fit-content;
}

.carousel-track:hover {
    animation-play-state: paused;
}

@keyframes scroll-logos {
    0% { transform: translateX(0); }
    100% { transform: translateX(-50%); }
}

.insurance-logo {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: var(--space-4) var(--space-6);
    background: white;
    border-radius: var(--radius-md);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    min-width: 140px;
    height: 70px;
    transition: transform 0.2s ease;
}

.insurance-logo:hover {
    transform: scale(1.05);
}

.insurance-logo img {
    max-height: 45px;
    max-width: 120px;
    width: auto;
    height: auto;
    object-fit: contain;
    filter: grayscale(20%);
    transition: filter 0.2s ease;
}

.insurance-logo:hover img {
    filter: grayscale(0%);
}

/* Text fallback for logos (before images are added) */
.insurance-logo-text {
    font-weight: 700;
    font-size: 0.9rem;
    color: var(--color-brand-blue-dark);
    text-align: center;
    white-space: nowrap;
}

/* Responsive carousel */
@media (max-width: 768px) {
    .insurance-logo-carousel::before,
    .insurance-logo-carousel::after {
        width: 40px;
    }

    .carousel-track {
        gap: var(--space-4);
    }

    .insurance-logo {
        min-width: 100px;
        height: 50px;
        padding: var(--space-2) var(--space-4);
    }

    .insurance-logo img {
        max-height: 30px;
        max-width: 80px;
    }
}

/* ═══════════════════════════════════════════════════════════════════════════════
   8. FOOTER & CTA
   ═══════════════════════════════════════════════════════════════════════════════ */
.section-nearby {
    background-color: var(--color-neutral-50);
    padding: var(--space-12) 0;
    text-align: center;
    border-top: 1px solid var(--border);
}

.nearby-areas-list {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: var(--space-3);
    list-style: none;
    padding: 0;
    max-width: 900px;
    margin: 0 auto var(--space-6);
}

.nearby-areas-list a {
    display: inline-block;
    padding: var(--space-3) 16px;
    background: white;
    border: 1px solid var(--color-neutral-300);
    border-radius: 4px;
    color: var(--color-brand-blue);
    text-decoration: none;
    font-weight: 600;
    transition: all 0.2s;
}
.nearby-areas-list a:hover {
    background: var(--color-brand-blue);
    color: white;
    border-color: var(--color-brand-blue);
}

.section-cta { text-align: center; background: white; border-top: 1px solid var(--border); padding: var(--space-16) 0; }
.cta-buttons { display: flex; justify-content: center; gap: var(--space-4); margin-top: var(--space-6); flex-wrap: wrap; }
.cta-note { font-size: 0.85rem; color: var(--text-muted); margin-top: var(--space-4); font-style: italic; }

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: var(--space-4) 24px;
    border-radius: 999px;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.2s;
    min-width: 200px;
}
.btn-primary { background: var(--color-brand-red); color: white; }
.btn-secondary { background: white; border: 2px solid var(--color-brand-blue); color: var(--color-brand-blue); }
.btn-phone { background: rgba(255,255,255,0.1); border: 1px solid white; color: white; }

/* ═══════════════════════════════════════════════════════════════════════════════
   9. RESPONSIVE REFLOW
   ═══════════════════════════════════════════════════════════════════════════════ */
@media (max-width: 768px) {
    .section-hero h1 { font-size: 1.75rem; }
    .neighborhood-grid, .location-grid, .damage-grid, .services-grid, .mobile-reasons, .military-list { 
        grid-template-columns: 1fr; 
    }
    .cta-buttons { flex-direction: column; width: 100%; max-width: 350px; margin: 0 auto; }
    .btn { width: 100%; }
    .gate-process { padding: var(--space-5); }
    .location-neighborhoods { display: none; } /* Hide detailed lists on mobile to save scroll space */
}