/*
Theme Name: LegalHai
Theme URI: https://legalhai.com/
Author: LegalHai
Author URI: https://legalhai.com/
Description: Companion theme for the LegalHai Core plugin — global multi-country legal services platform with country routing (/in/, /us/, /uk/, /uae/), package marketplace and SEO-grade schema. Yellow + black + white brand. Accessible, fast, mobile-first.
Version: 1.0.0
Requires at least: 6.0
Requires PHP: 7.4
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: legalhai
Tags: business, legal, seo, multi-country, custom-colors, custom-menu, threaded-comments, translation-ready, wide-blocks
*/

/* =========================================================================
   Brand tokens
   ========================================================================= */
:root {
    --lh-yellow: #FFD60A;
    --lh-yellow-dark: #E6C009;
    --lh-yellow-soft: #FFF5BF;
    --lh-black: #0A0A0A;
    --lh-graphite: #1F2937;
    --lh-mute: #6B7280;
    --lh-line: #E5E7EB;
    --lh-bg: #FFFFFF;
    --lh-bg-alt: #FAFAFA;
    --lh-radius: 14px;
    --lh-shadow: 0 1px 2px rgba(0,0,0,.04), 0 8px 32px -12px rgba(0,0,0,.08);
    --lh-font: ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    --lh-mono: ui-monospace, SFMono-Regular, Menlo, monospace;
    --lh-container: 1180px;
}

/* =========================================================================
   Base reset & typography
   ========================================================================= */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
    margin: 0;
    background: var(--lh-bg);
    color: var(--lh-black);
    font: 16px/1.6 var(--lh-font);
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
}
img, svg, video { max-width: 100%; height: auto; }
a { color: var(--lh-black); text-decoration-color: var(--lh-yellow); text-decoration-thickness: 2px; text-underline-offset: 3px; }
a:hover { color: var(--lh-graphite); }
h1, h2, h3, h4 { color: var(--lh-black); line-height: 1.25; margin: 0 0 .6em; }
h1 { font-size: clamp(28px, 4.5vw, 44px); font-weight: 800; letter-spacing: -.02em; }
h2 { font-size: clamp(22px, 3.2vw, 32px); font-weight: 800; letter-spacing: -.01em; }
h3 { font-size: 20px; font-weight: 700; }
p { margin: 0 0 1em; }
hr { border: 0; border-top: 1px solid var(--lh-line); margin: 28px 0; }
blockquote { margin: 1.2em 0; padding: 12px 18px; border-left: 4px solid var(--lh-yellow); background: var(--lh-bg-alt); border-radius: 6px; }
code { font-family: var(--lh-mono); background: var(--lh-bg-alt); padding: 1px 6px; border-radius: 4px; font-size: .92em; }

.lh-container { max-width: var(--lh-container); margin: 0 auto; padding: 0 20px; }

/* Skip link for accessibility */
.skip-link {
    position: absolute; left: -9999px; top: 0;
    background: var(--lh-yellow); color: var(--lh-black);
    padding: 8px 12px; z-index: 100;
}
.skip-link:focus { left: 8px; top: 8px; }

/* =========================================================================
   Header
   ========================================================================= */
.lh-header {
    position: sticky; top: 0; z-index: 50;
    background: var(--lh-bg);
    border-bottom: 1px solid var(--lh-line);
    backdrop-filter: saturate(180%) blur(8px);
}
.lh-header__inner {
    display: flex; align-items: center; justify-content: space-between;
    gap: 24px; padding: 8px 0;
    min-height: 70px;
}
.lh-header__cta { display: flex; align-items: center; gap: 10px; flex-shrink: 0; }
.lh-brand { flex-shrink: 0; }
.lh-brand {
    display: inline-flex; align-items: center; gap: 8px;
    text-decoration: none; color: var(--lh-black); font-weight: 800; font-size: 20px;
}
.lh-brand .custom-logo-link { display: inline-flex; align-items: center; }
.lh-brand .custom-logo { max-height: 44px; width: auto; height: auto; display: block; }
.lh-brand__mark {
    width: 32px; height: 32px; border-radius: 8px;
    background: var(--lh-yellow); color: var(--lh-black);
    display: inline-flex; align-items: center; justify-content: center;
    font-weight: 900;
}
.lh-nav {
    display: flex; align-items: center; gap: 18px;
}
.lh-nav a {
    text-decoration: none; color: var(--lh-graphite);
    font-weight: 600; font-size: 15px;
}
.lh-nav a:hover { color: var(--lh-black); }

/* Top-level menu — horizontal */
.lh-nav .menu {
    display: flex;
    gap: 22px;
    list-style: none;
    padding: 0;
    margin: 0;
    align-items: center;
}
.lh-nav .menu > li {
    position: relative;
    list-style: none;
}
.lh-nav .menu > li > a {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 22px 0;
    color: var(--lh-graphite);
    white-space: nowrap;
}
.lh-nav .menu > li > a:hover,
.lh-nav .menu > li.current-menu-item > a {
    color: var(--lh-black);
}
.lh-nav .menu > li.current-menu-item > a {
    box-shadow: inset 0 -2px 0 var(--lh-yellow);
}

/* Caret on parents with children */
.lh-nav .menu-item-has-children > a::after {
    content: "▾";
    font-size: 10px;
    margin-left: 2px;
    color: var(--lh-mute);
}

/* Submenus — hidden by default, dropdown on hover/focus */
.lh-nav .sub-menu {
    position: absolute;
    top: 100%;
    left: -14px;
    min-width: 240px;
    background: var(--lh-bg);
    border: 1px solid var(--lh-line);
    border-radius: var(--lh-radius);
    box-shadow: var(--lh-shadow);
    list-style: none;
    padding: 8px;
    margin: 0;
    display: none;
    z-index: 60;
}
.lh-nav .menu-item-has-children:hover > .sub-menu,
.lh-nav .menu-item-has-children:focus-within > .sub-menu,
.lh-nav .menu-item-has-children.is-open > .sub-menu {
    display: block;
}
.lh-nav .sub-menu li { list-style: none; }
.lh-nav .sub-menu a {
    display: block;
    padding: 8px 12px;
    border-radius: 8px;
    color: var(--lh-graphite);
    font-weight: 500;
    font-size: 14px;
    white-space: nowrap;
}
.lh-nav .sub-menu a:hover { background: var(--lh-yellow-soft); color: var(--lh-black); }

/* 3rd-level submenus */
.lh-nav .sub-menu .sub-menu {
    top: 0;
    left: 100%;
}
.lh-header__cta { display: flex; align-items: center; gap: 10px; }
.lh-cc-toggle__pos { position: relative; }
.lh-mobile-toggle { display: none; }

@media (max-width: 1024px) {
    .lh-nav { display: none; }
    .lh-nav.is-open {
        display: flex; flex-direction: column; align-items: stretch;
        position: absolute; top: 100%; left: 0; right: 0;
        background: var(--lh-bg); border-bottom: 1px solid var(--lh-line);
        padding: 14px 20px;
        max-height: calc(100vh - 70px);
        overflow-y: auto;
    }
    .lh-nav.is-open .menu { flex-direction: column; gap: 0; align-items: stretch; }
    .lh-nav.is-open .menu > li { width: 100%; }
    .lh-nav.is-open .menu > li > a { padding: 12px 0; display: flex; justify-content: space-between; }
    .lh-nav.is-open .sub-menu {
        position: static;
        display: block;
        border: 0;
        box-shadow: none;
        padding: 4px 0 8px 12px;
        background: transparent;
        min-width: 0;
    }
    .lh-nav.is-open .menu-item-has-children > a::after { content: "+"; font-size: 16px; }
    .lh-mobile-toggle {
        display: inline-flex; align-items: center; justify-content: center;
        width: 40px; height: 40px; border-radius: 10px;
        border: 1px solid var(--lh-line); background: var(--lh-bg);
    }
}

/* =========================================================================
   Hero
   ========================================================================= */
.lh-hero {
    background: radial-gradient(60% 80% at 80% 0%, var(--lh-yellow-soft), transparent 60%), var(--lh-bg);
    padding: 64px 0 40px;
    border-bottom: 1px solid var(--lh-line);
}
.lh-hero__grid {
    display: grid; grid-template-columns: 1.2fr .8fr; gap: 40px; align-items: center;
}
@media (max-width: 880px) { .lh-hero__grid { grid-template-columns: 1fr; } }
.lh-hero__eyebrow {
    display: inline-block;
    background: var(--lh-black); color: var(--lh-yellow);
    padding: 4px 10px; border-radius: 999px;
    font-size: 12px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase;
}
.lh-hero h1 { margin-top: 14px; }
.lh-hero p.lh-lede { font-size: 18px; color: var(--lh-graphite); max-width: 56ch; }
.lh-hero__actions { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 18px; }
.lh-hero__trust { margin-top: 20px; display: flex; gap: 24px; flex-wrap: wrap; color: var(--lh-mute); font-size: 14px; }

/* Buttons inherit plugin styles, but provide fallback */
.lh-btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 12px 20px; border-radius: 10px; font: 600 15px/1 var(--lh-font); border: 1px solid transparent; cursor: pointer; text-decoration: none; }
.lh-btn--primary { background: var(--lh-yellow); color: var(--lh-black); border-color: var(--lh-yellow-dark); }
.lh-btn--primary:hover { background: var(--lh-yellow-dark); }
.lh-btn--ghost { background: transparent; color: var(--lh-black); border-color: var(--lh-black); }
.lh-btn--ghost:hover { background: var(--lh-black); color: var(--lh-yellow); }

/* =========================================================================
   Sections
   ========================================================================= */
.lh-section { padding: 56px 0; }
.lh-section--alt { background: var(--lh-bg-alt); }
.lh-section__head { display: flex; justify-content: space-between; align-items: end; margin-bottom: 22px; gap: 16px; flex-wrap: wrap; }
.lh-section__title { margin: 0; }
.lh-section__sub { color: var(--lh-mute); margin: 0; }

/* =========================================================================
   Single content
   ========================================================================= */
.lh-single { padding: 36px 0 48px; }
.lh-single__layout { display: grid; grid-template-columns: 1fr 360px; gap: 36px; }
@media (max-width: 980px) { .lh-single__layout { grid-template-columns: 1fr; } }
.lh-single__meta { display: flex; gap: 12px; color: var(--lh-mute); font-size: 14px; flex-wrap: wrap; }
.lh-prose { font-size: 17px; }
.lh-prose h2, .lh-prose h3 { margin-top: 1.6em; }
.lh-prose ul, .lh-prose ol { padding-left: 1.4em; }
.lh-aside {
    position: sticky; top: 92px;
    background: var(--lh-bg);
    border: 1px solid var(--lh-line);
    border-radius: var(--lh-radius);
    padding: 18px;
    box-shadow: var(--lh-shadow);
}
.lh-pricetag { display: inline-flex; align-items: baseline; gap: 4px; background: var(--lh-yellow-soft); color: var(--lh-black); padding: 6px 10px; border-radius: 999px; font-weight: 700; }
.lh-feature-list { list-style: none; padding: 0; margin: 12px 0; }
.lh-feature-list li {
    padding: 6px 0 6px 26px;
    background: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%23FFD60A'><path d='M9 16.2 4.8 12l-1.4 1.4L9 19l12-12-1.4-1.4z'/></svg>") no-repeat 0 8px / 18px;
    color: var(--lh-graphite);
}

/* Breadcrumbs */
.lh-crumbs { font-size: 13px; color: var(--lh-mute); padding: 14px 0; }
.lh-crumbs a { color: var(--lh-graphite); text-decoration: none; }
.lh-crumbs a:hover { color: var(--lh-black); text-decoration: underline; }
.lh-crumbs span[aria-current="page"] { color: var(--lh-black); font-weight: 600; }

/* =========================================================================
   FAQ
   ========================================================================= */
.lh-faq { display: grid; gap: 10px; }
.lh-faq details {
    border: 1px solid var(--lh-line);
    border-radius: 12px;
    background: var(--lh-bg);
    padding: 14px 16px;
}
.lh-faq details[open] { border-color: var(--lh-yellow); background: var(--lh-yellow-soft); }
.lh-faq summary { font-weight: 700; cursor: pointer; }

/* =========================================================================
   Footer
   ========================================================================= */
.lh-footer {
    background: var(--lh-black);
    color: #E5E7EB;
    padding: 48px 0 24px;
    margin-top: 56px;
}
.lh-footer h4 { color: #FFFFFF; margin: 0 0 12px; }
.lh-footer a { color: #E5E7EB; text-decoration: none; }
.lh-footer a:hover { color: var(--lh-yellow); }
.lh-footer__cols { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: 28px; }
@media (max-width: 760px) { .lh-footer__cols { grid-template-columns: 1fr 1fr; } }
.lh-footer__bottom {
    margin-top: 28px; border-top: 1px solid #1F2937;
    padding-top: 16px; display: flex; justify-content: space-between; flex-wrap: wrap; gap: 8px;
    font-size: 13px; color: #9CA3AF;
}

/* =========================================================================
   Cards (used outside the plugin shortcode too)
   ========================================================================= */
.lh-grid { display: grid; gap: 16px; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); padding: 16px 0; }
.lh-card, .lh-pkg { background: var(--lh-bg); border: 1px solid var(--lh-line); border-radius: var(--lh-radius); padding: 22px; text-decoration: none; color: var(--lh-black); display: flex; flex-direction: column; gap: 10px; }
.lh-card:hover, .lh-pkg:hover { border-color: var(--lh-black); transform: translateY(-2px); box-shadow: var(--lh-shadow); }
.lh-card__title, .lh-pkg__title { margin: 0; font: 700 18px/1.3 var(--lh-font); }
.lh-card__excerpt, .lh-pkg__excerpt { color: var(--lh-mute); font-size: 14px; margin: 0; }

/* =========================================================================
   404 + search
   ========================================================================= */
.lh-404, .lh-search { padding: 80px 0; text-align: center; }
.lh-search input[type="search"] {
    width: 100%; max-width: 480px; padding: 12px 14px;
    border: 1px solid var(--lh-line); border-radius: 10px; font-size: 16px;
}

/* Static front page wrapper — fully transparent so Elementor / Gutenberg layouts render at full width */
.lh-front-static { all: unset; display: block; }

/* ============================================================
   Homepage — multi-section landing
   ============================================================ */

/* Eyebrow chip used across sections */
.lh-eyebrow {
    display: inline-block;
    font-size: 12px; letter-spacing: .14em; text-transform: uppercase;
    font-weight: 700;
    background: var(--lh-yellow-soft);
    color: var(--lh-black);
    padding: 6px 12px; border-radius: 999px;
    margin-bottom: 12px;
}

/* Big hero variant */
.lh-hero--big { padding: 80px 0 64px; position: relative; overflow: hidden; }
.lh-hero--big::before {
    content: ""; position: absolute; inset: 0;
    background:
        radial-gradient(40% 60% at 90% 10%, var(--lh-yellow-soft), transparent 70%),
        radial-gradient(35% 50% at 0% 90%, #FFF9CC, transparent 70%);
    z-index: -1;
}
.lh-hero--big h1 { font-size: clamp(34px, 5.6vw, 60px); line-height: 1.05; }
.lh-hero--big .lh-lede { font-size: clamp(16px, 1.6vw, 19px); }

/* Hero search box */
.lh-search-cta {
    display: flex; gap: 8px; margin-top: 22px;
    background: #fff; border: 1px solid var(--lh-line);
    border-radius: 14px; padding: 6px;
    box-shadow: var(--lh-shadow); max-width: 580px;
}
.lh-search-cta input {
    flex: 1; border: 0; padding: 10px 12px;
    font: 15px var(--lh-font); background: transparent; outline: 0;
    color: var(--lh-black);
}
.lh-search-cta .lh-btn { padding: 10px 18px; }

/* Hero card stack */
.lh-hero__cards { perspective: 1200px; }
.lh-stack { position: relative; height: 380px; }
.lh-stack__card {
    position: absolute; left: 0; right: 0;
    background: #fff; border: 1px solid var(--lh-line);
    border-radius: 18px; padding: 22px;
    box-shadow: var(--lh-shadow);
}
.lh-stack__card h3 { margin: 8px 0 4px; font-size: 18px; }
.lh-stack__card p { color: var(--lh-mute); font-size: 14px; margin: 0; }
.lh-stack__pill {
    display: inline-block; font-size: 11px; font-weight: 700;
    letter-spacing: .08em; text-transform: uppercase;
    background: var(--lh-yellow); color: var(--lh-black);
    padding: 4px 10px; border-radius: 999px;
}
.lh-stack__card--1 { top:   0; transform: rotate(-3deg) translateY(0); z-index: 1; }
.lh-stack__card--2 { top:  90px; transform: rotate(2deg);  z-index: 2; background: var(--lh-yellow-soft); border-color: var(--lh-yellow); }
.lh-stack__card--3 { top: 180px; transform: rotate(-1deg); z-index: 3; }
@media (max-width: 880px) {
    .lh-hero__cards { display: none; }
}

/* Trust strip */
.lh-strip {
    border-block: 1px solid var(--lh-line);
    background: #fff;
    padding: 18px 0;
}
.lh-strip__label {
    text-align: center; color: var(--lh-mute);
    font-size: 13px; letter-spacing: .04em; text-transform: uppercase;
    margin: 0 0 10px;
}
.lh-strip__logos {
    display: flex; gap: 28px; justify-content: center; align-items: center;
    flex-wrap: wrap;
}
.lh-strip__logo {
    color: var(--lh-graphite); opacity: .7;
    font-weight: 800; font-size: 18px; letter-spacing: -.02em;
    filter: grayscale(1);
}

/* Three pillars */
.lh-pillars {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 18px; margin-top: 18px;
}
@media (max-width: 920px) { .lh-pillars { grid-template-columns: 1fr; } }
.lh-pillar {
    background: #fff;
    border: 1px solid var(--lh-line);
    border-radius: 18px;
    padding: 28px;
    display: flex; flex-direction: column; gap: 10px;
    transition: transform .15s, border-color .15s, box-shadow .15s;
}
.lh-pillar:hover { transform: translateY(-3px); border-color: var(--lh-black); box-shadow: var(--lh-shadow); }
.lh-pillar--accent { background: var(--lh-yellow-soft); border-color: var(--lh-yellow); }
.lh-pillar__icon { font-size: 32px; }
.lh-pillar h3 { margin: 0; font-size: 22px; }
.lh-pillar p { color: var(--lh-graphite); margin: 0; }
.lh-pillar__list { list-style: none; padding: 0; margin: 4px 0; display: grid; gap: 6px; }
.lh-pillar__list li {
    padding: 6px 0 6px 26px; color: var(--lh-graphite); font-size: 14px;
    background: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%230A0A0A'><path d='M9 16.2 4.8 12l-1.4 1.4L9 19l12-12-1.4-1.4z'/></svg>") no-repeat 0 8px / 18px;
}
.lh-pillar__cta {
    margin-top: auto; align-self: flex-start;
    color: var(--lh-black); font-weight: 700; text-decoration: none;
    border-bottom: 2px solid var(--lh-yellow); padding-bottom: 2px;
}
.lh-pillar__cta:hover { color: var(--lh-graphite); }

/* Stats band */
.lh-stats {
    background: var(--lh-black);
    color: #fff;
    padding: 56px 0;
}
.lh-stats__grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 24px;
    text-align: center;
}
@media (max-width: 760px) { .lh-stats__grid { grid-template-columns: 1fr 1fr; } }
.lh-stats__num {
    display: block; font-weight: 800;
    font-size: clamp(34px, 4.8vw, 56px);
    line-height: 1;
    color: var(--lh-yellow);
    letter-spacing: -.02em;
}
.lh-stats__num small { font-size: .55em; color: #FFF9CC; }
.lh-stats__label {
    display: block; margin-top: 8px;
    color: #D1D5DB; font-size: 14px;
    text-transform: uppercase; letter-spacing: .08em;
}

/* Service categories grid */
.lh-cat-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 12px; margin-top: 18px;
}
@media (max-width: 980px) { .lh-cat-grid { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 680px) { .lh-cat-grid { grid-template-columns: repeat(2, 1fr); } }
.lh-cat {
    display: flex; flex-direction: column; gap: 6px;
    background: #fff;
    border: 1px solid var(--lh-line);
    border-radius: 14px;
    padding: 18px;
    text-decoration: none;
    color: var(--lh-black);
    transition: border-color .15s, transform .15s, box-shadow .15s;
}
.lh-cat:hover { border-color: var(--lh-yellow); transform: translateY(-2px); box-shadow: var(--lh-shadow); }
.lh-cat__icon { font-size: 28px; line-height: 1; }
.lh-cat__title { font-weight: 700; font-size: 15px; }
.lh-cat__country { color: var(--lh-mute); font-size: 12px; text-transform: uppercase; letter-spacing: .06em; }

/* Steps */
.lh-steps {
    display: grid; grid-template-columns: repeat(3, 1fr);
    gap: 20px; padding: 0; margin: 24px 0 0; list-style: none;
    counter-reset: lh-step;
}
@media (max-width: 880px) { .lh-steps { grid-template-columns: 1fr; } }
.lh-steps li {
    background: #fff; border: 1px solid var(--lh-line);
    border-radius: 18px; padding: 28px;
    position: relative;
}
.lh-steps__num {
    display: inline-flex; width: 40px; height: 40px;
    align-items: center; justify-content: center;
    background: var(--lh-yellow); color: var(--lh-black);
    font-weight: 800; font-size: 18px;
    border-radius: 12px; margin-bottom: 12px;
}
.lh-steps li h3 { margin: 0 0 6px; font-size: 19px; }
.lh-steps li p { color: var(--lh-graphite); margin: 0; }

/* Testimonials */
.lh-tests {
    display: grid; grid-template-columns: repeat(3, 1fr);
    gap: 16px; margin-top: 18px;
}
@media (max-width: 980px) { .lh-tests { grid-template-columns: 1fr; } }
.lh-test {
    background: #fff; border: 1px solid var(--lh-line);
    border-radius: 18px; padding: 26px;
    margin: 0;
    display: flex; flex-direction: column; gap: 14px;
}
.lh-test--accent { background: var(--lh-yellow-soft); border-color: var(--lh-yellow); }
.lh-test blockquote {
    margin: 0; padding: 0; border: 0; background: transparent;
    color: var(--lh-black); font-size: 16px; line-height: 1.55;
}
.lh-test figcaption strong { display: block; color: var(--lh-black); }
.lh-test figcaption span { color: var(--lh-mute); font-size: 13px; }

/* CTA panel */
.lh-cta { padding: 64px 0; }
.lh-cta__panel {
    background: linear-gradient(135deg, var(--lh-black) 0%, #1F2937 100%);
    color: #fff;
    border-radius: 24px;
    padding: 56px 40px;
    text-align: center;
    position: relative; overflow: hidden;
}
.lh-cta__panel::before {
    content: ""; position: absolute; right: -60px; top: -60px;
    width: 240px; height: 240px;
    background: var(--lh-yellow); opacity: .2;
    border-radius: 50%;
}
.lh-cta__panel h2 { color: #fff; margin: 0 0 8px; font-size: clamp(28px, 3.4vw, 40px); }
.lh-cta__panel p { color: #D1D5DB; margin: 0 0 22px; max-width: 600px; margin-left: auto; margin-right: auto; }
.lh-cta__actions { display: inline-flex; gap: 10px; flex-wrap: wrap; justify-content: center; }
.lh-btn--lg { padding: 14px 26px; font-size: 16px; }
.lh-cta__panel .lh-btn--ghost {
    border-color: #fff; color: #fff;
}
.lh-cta__panel .lh-btn--ghost:hover {
    background: var(--lh-yellow); color: var(--lh-black); border-color: var(--lh-yellow);
}

/* ============================================================
   Service detail page (single-legalhai_service.php)
   ============================================================ */

.lh-svc-hero {
    padding: 56px 0 40px;
    background: radial-gradient(60% 90% at 90% 10%, var(--lh-yellow-soft), transparent 70%), #fff;
    border-bottom: 1px solid var(--lh-line);
}
.lh-svc-hero__grid {
    display: grid; grid-template-columns: 1.4fr 1fr;
    gap: 40px; align-items: start;
}
@media (max-width: 980px) { .lh-svc-hero__grid { grid-template-columns: 1fr; } }
.lh-svc-hero h1 { margin: 12px 0 12px; font-size: clamp(28px, 4.4vw, 48px); line-height: 1.1; }
.lh-svc-hero .lh-lede { font-size: 17px; max-width: 56ch; }
.lh-svc-hero__pills {
    list-style: none; padding: 0; margin: 18px 0;
    display: flex; flex-wrap: wrap; gap: 8px;
}
.lh-svc-hero__pills li {
    background: #fff; border: 1px solid var(--lh-line);
    padding: 6px 12px; border-radius: 999px;
    font-size: 13px; color: var(--lh-graphite); font-weight: 500;
}
.lh-svc-hero__cta { display: flex; gap: 10px; flex-wrap: wrap; }

.lh-svc-card {
    background: #fff;
    border: 1px solid var(--lh-line);
    border-radius: 18px;
    padding: 22px;
    box-shadow: var(--lh-shadow);
    position: sticky; top: 90px;
}
.lh-svc-card__price { display: flex; align-items: baseline; gap: 4px; margin-bottom: 4px; }
.lh-svc-card__currency { font-size: 22px; color: var(--lh-mute); }
.lh-svc-card__price strong { font-size: 40px; font-weight: 800; line-height: 1; }
.lh-svc-card__suffix { color: var(--lh-mute); font-size: 14px; margin-left: 6px; }
.lh-svc-card__note { color: var(--lh-mute); font-size: 13px; margin: 0 0 16px; }

@media (max-width: 980px) {
    .lh-svc-card { position: static; }
}

/* "At a glance" stats band — sits between hero and benefits */
.lh-glance {
    background: var(--lh-yellow-soft);
    border-bottom: 1px solid var(--lh-yellow);
    padding: 28px 0;
}
.lh-glance__grid {
    display: grid; grid-template-columns: repeat(4, 1fr);
    gap: 16px; text-align: center;
}
@media (max-width: 760px) { .lh-glance__grid { grid-template-columns: 1fr 1fr; } }
.lh-glance__num {
    display: block;
    font-weight: 800; font-size: clamp(26px, 3.4vw, 38px);
    color: var(--lh-black); line-height: 1;
    letter-spacing: -.02em;
}
.lh-glance__label {
    display: block; margin-top: 4px;
    color: var(--lh-graphite); font-size: 13px;
    text-transform: uppercase; letter-spacing: .06em;
}

/* Benefits grid */
.lh-benefits {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px; margin-top: 18px;
}
@media (max-width: 980px) { .lh-benefits { grid-template-columns: 1fr 1fr; } }
@media (max-width: 600px) { .lh-benefits { grid-template-columns: 1fr; } }
.lh-benefit {
    background: #fff; border: 1px solid var(--lh-line);
    border-radius: 16px; padding: 24px;
    transition: transform .15s, border-color .15s, box-shadow .15s;
}
.lh-benefit:hover { transform: translateY(-3px); border-color: var(--lh-yellow); box-shadow: var(--lh-shadow); }
.lh-benefit__icon {
    display: inline-flex; align-items: center; justify-content: center;
    width: 48px; height: 48px; border-radius: 14px;
    background: var(--lh-yellow-soft); font-size: 24px;
    margin-bottom: 12px;
}
.lh-benefit h3 { margin: 0 0 6px; font-size: 18px; }
.lh-benefit p { color: var(--lh-graphite); margin: 0; font-size: 14px; }

/* Two-column split (used by Documents / Eligibility sections) */
.lh-svc-split {
    display: grid; grid-template-columns: 1fr 1.2fr;
    gap: 36px; align-items: start;
}
@media (max-width: 880px) { .lh-svc-split { grid-template-columns: 1fr; } }

.lh-doclist {
    list-style: none; padding: 0; margin: 0;
    display: grid; grid-template-columns: 1fr 1fr; gap: 8px 14px;
    background: #fff; border: 1px solid var(--lh-line);
    border-radius: 16px; padding: 22px;
}
@media (max-width: 540px) { .lh-doclist { grid-template-columns: 1fr; } }
.lh-doclist li {
    padding: 6px 0 6px 28px;
    background: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%23FFD60A' stroke='%230A0A0A' stroke-width='1.6'><path d='M9 16.2 4.8 12l-1.4 1.4L9 19l12-12-1.4-1.4z'/></svg>") no-repeat 0 8px / 20px;
    color: var(--lh-graphite); font-size: 15px;
}
.lh-doclist--bullets li {
    background: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%23FFD60A'><circle cx='12' cy='12' r='6'/></svg>") no-repeat 0 8px / 20px;
}

/* Process timeline */
.lh-timeline {
    list-style: none; padding: 0; margin: 24px 0 0;
    display: grid; gap: 14px;
    counter-reset: lh-tl;
}
.lh-timeline li {
    position: relative; padding-left: 64px;
    background: #fff; border: 1px solid var(--lh-line);
    border-radius: 16px; padding-top: 18px; padding-right: 22px; padding-bottom: 18px;
}
.lh-timeline__num {
    position: absolute; left: 16px; top: 18px;
    width: 36px; height: 36px;
    display: inline-flex; align-items: center; justify-content: center;
    background: var(--lh-yellow); color: var(--lh-black);
    font-weight: 800; border-radius: 10px;
}
.lh-timeline li h3 { margin: 0 0 4px; font-size: 17px; }
.lh-timeline li p { margin: 0; color: var(--lh-graphite); font-size: 14px; }

/* Why-us comparison table */
.lh-compare {
    margin-top: 18px;
    overflow-x: auto;
    border-radius: 16px;
    border: 1px solid var(--lh-line);
    background: #fff;
}
.lh-compare table {
    width: 100%; border-collapse: collapse;
    font-size: 14px;
}
.lh-compare th,
.lh-compare td {
    padding: 14px 16px;
    text-align: center;
    border-bottom: 1px solid var(--lh-line);
}
.lh-compare th { background: var(--lh-bg-alt); font-weight: 700; color: var(--lh-black); }
.lh-compare th.is-us { background: var(--lh-yellow); color: var(--lh-black); }
.lh-compare tbody tr:last-child td { border-bottom: 0; }
.lh-compare td:first-child,
.lh-compare th:first-child { text-align: left; font-weight: 600; }
.lh-compare td.is-us { background: rgba(255, 214, 10, 0.08); font-weight: 700; }
.lh-compare td.is-yes { color: #047857; font-weight: 800; font-size: 18px; }
.lh-compare td.is-no { color: #B91C1C; font-weight: 800; font-size: 18px; }
.lh-compare td.is-maybe { color: #B45309; font-weight: 800; font-size: 18px; }
.lh-compare td.is-na { color: var(--lh-mute); }

/* WordPress-required widget alignment helpers */
.alignleft { float: left; margin-right: 1em; }
.alignright { float: right; margin-left: 1em; }
.aligncenter { display: block; margin-left: auto; margin-right: auto; }
.screen-reader-text { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.wp-caption { max-width: 100%; }

/* ============================================================
   MOBILE OPTIMISATION (≤ 1024px → ≤ 720px → ≤ 480px → ≤ 360px)
   Defensive overflow guards + tighter spacing on every page.
   ============================================================ */

/* Hard overflow guard — nothing should ever cause horizontal scroll */
html, body { overflow-x: hidden; max-width: 100%; }

/* Allow long words / URLs to break instead of pushing layout */
body, h1, h2, h3, h4, p, li, td, th { word-wrap: break-word; overflow-wrap: anywhere; }

/* All images and SVGs respect viewport — overrides WP-injected width attrs */
img, svg, video, iframe, embed, object {
    max-width: 100% !important;
    height: auto;
}
.wp-caption img, .wp-block-image img, figure img { max-width: 100% !important; height: auto; }

/* Logo never blows out the header on any viewport */
.lh-brand .custom-logo {
    max-height: 44px !important;
    max-width: 180px !important;
    width: auto !important;
    height: auto !important;
    object-fit: contain;
}
.lh-brand { flex-shrink: 1; min-width: 0; max-width: 60%; }

/* ---------- Tablets and below (≤ 1024px) ---------- */
@media (max-width: 1024px) {
    .lh-container { padding: 0 16px; }
    .lh-section { padding: 44px 0; }
    .lh-cta { padding: 44px 0; }
}

/* ---------- Phones (≤ 720px) ---------- */
@media (max-width: 720px) {
    .lh-container { padding: 0 14px; }
    .lh-section { padding: 36px 0; }

    /* Hero — smaller padding, single column */
    .lh-hero, .lh-hero--big { padding: 40px 0 28px; }
    .lh-hero--big h1 { font-size: clamp(26px, 7vw, 36px); }
    .lh-hero--big .lh-lede { font-size: 15px; }
    .lh-hero__cards { display: none; }
    .lh-hero__trust { gap: 12px; font-size: 13px; }

    /* Search-CTA stacks vertically when cramped */
    .lh-search-cta { flex-direction: column; gap: 6px; padding: 8px; }
    .lh-search-cta input { width: 100%; padding: 12px; }
    .lh-search-cta .lh-btn { width: 100%; padding: 12px; }

    /* Eyebrow chips — softer letter-spacing, allow wrap */
    .lh-eyebrow, .lh-hero__eyebrow {
        letter-spacing: .08em;
        white-space: normal;
        max-width: 100%;
        line-height: 1.3;
    }

    /* Section heads center cleanly */
    .lh-section__head {
        flex-direction: column;
        align-items: stretch !important;
        text-align: center;
    }
    .lh-section__head .lh-btn { align-self: center; }

    /* CTA panel less aggressive padding */
    .lh-cta__panel { padding: 36px 22px; border-radius: 18px; }
    .lh-cta__panel h2 { font-size: clamp(22px, 5vw, 30px); }
    .lh-cta__actions .lh-btn { width: 100%; }

    /* Stats: tighter */
    .lh-stats { padding: 36px 0; }
    .lh-stats__num { font-size: clamp(28px, 8vw, 42px); }
    .lh-stats__label { font-size: 11px; }

    /* Service detail hero */
    .lh-svc-hero { padding: 32px 0 24px; }
    .lh-svc-hero h1 { font-size: clamp(24px, 6vw, 34px); }
    .lh-svc-hero__pills { gap: 6px; }
    .lh-svc-hero__pills li { font-size: 12px; padding: 4px 10px; }
    .lh-svc-card { padding: 18px; }
    .lh-svc-card__price strong { font-size: 32px; }

    /* Glance band — 2x2 */
    .lh-glance__num { font-size: clamp(22px, 6vw, 30px); }
    .lh-glance__label { font-size: 11px; letter-spacing: .04em; }

    /* Benefits / pillars / cards: 1-column when really tight */
    .lh-benefits, .lh-pillars { gap: 12px; }
    .lh-benefit, .lh-pillar { padding: 20px; }
    .lh-pillar h3, .lh-benefit h3 { font-size: 17px; }

    /* Timeline */
    .lh-timeline li { padding: 16px 16px 16px 60px; }
    .lh-timeline__num { left: 12px; top: 16px; width: 32px; height: 32px; }

    /* Compare table — make it scrollable horizontally if needed */
    .lh-compare table { font-size: 13px; }
    .lh-compare th, .lh-compare td { padding: 10px 8px; }

    /* Country picker — tighter cards */
    .lh-picker__card { padding: 18px; }
    .lh-picker__name { font-size: 16px; }
    .lh-picker__tag { font-size: 13px; }

    /* Modal panel doesn't push edges */
    .lh-modal__panel { padding: 22px 18px; }
    .lh-modal__title { font-size: 19px; }
    .lh-modal__grid { grid-template-columns: 1fr; gap: 8px; }

    /* Inquiry form */
    .lh-form { padding: 18px; }
    .lh-form__row { grid-template-columns: 1fr; gap: 10px; }

    /* Footer 2-col on phones */
    .lh-footer { padding: 32px 0 16px; }
    .lh-footer__cols { gap: 20px; grid-template-columns: 1fr 1fr; }
    .lh-footer__bottom { flex-direction: column; align-items: flex-start; gap: 6px; font-size: 12px; }

    /* Floating WhatsApp doesn't sit on top of CTA */
    .lh-fab-whatsapp { right: 12px; bottom: 12px; width: 48px; height: 48px; }
    .lh-fab-whatsapp svg { width: 22px; height: 22px; }
}

/* ---------- Small phones (≤ 480px) ---------- */
@media (max-width: 480px) {
    /* Header collapses aggressively */
    .lh-header__inner { gap: 8px; padding: 6px 0; min-height: 60px; }
    .lh-brand .custom-logo { max-height: 36px !important; max-width: 130px !important; }
    .lh-brand__mark { width: 28px; height: 28px; }
    .lh-brand { font-size: 17px; max-width: 50%; }

    .lh-cc-toggle { padding: 6px 8px; font-size: 13px; gap: 4px; }

    /* "Talk to a lawyer" — hide text, keep as iconified yellow circle */
    .lh-header__cta .lh-btn--primary {
        padding: 8px 12px;
        font-size: 0;
        gap: 0;
    }
    .lh-header__cta .lh-btn--primary::before {
        content: "💬";
        font-size: 16px;
    }

    .lh-mobile-toggle { width: 36px; height: 36px; }

    /* Footer goes single-col on tiny screens */
    .lh-footer__cols { grid-template-columns: 1fr; }

    /* Hero further tightens */
    .lh-hero--big { padding: 28px 0 20px; }
    .lh-hero--big h1 { font-size: clamp(22px, 8vw, 30px); line-height: 1.15; }
    .lh-hero__trust { gap: 8px; font-size: 12px; flex-direction: column; }
    .lh-hero__trust span { width: 100%; }

    /* Stats 1x1 (single column) for max readability */
    .lh-stats__grid { grid-template-columns: 1fr 1fr; gap: 16px; }

    /* Glance band single col on smallest screens */
    .lh-glance__grid { grid-template-columns: 1fr 1fr; gap: 12px; }

    /* Benefits 1 col */
    .lh-benefits { grid-template-columns: 1fr; }

    /* Cat-grid 2 cols */
    .lh-cat-grid { grid-template-columns: 1fr 1fr; gap: 8px; }
    .lh-cat { padding: 14px; }
    .lh-cat__icon { font-size: 22px; }
    .lh-cat__title { font-size: 13px; }
    .lh-cat__country { font-size: 10px; }

    /* Doclist single col */
    .lh-doclist { grid-template-columns: 1fr; padding: 16px; }

    /* Strip logos wrap nicely */
    .lh-strip__logos { gap: 14px; }
    .lh-strip__logo { font-size: 14px; }

    /* CTA actions stack */
    .lh-cta__actions { flex-direction: column; }
    .lh-cta__actions .lh-btn { width: 100%; }

    /* Service hero pricing card price */
    .lh-svc-card__price strong { font-size: 28px; }
    .lh-svc-card__currency { font-size: 18px; }
}

/* ---------- Ultra-small (≤ 360px) — last-resort tightening ---------- */
@media (max-width: 360px) {
    .lh-container { padding: 0 12px; }
    .lh-section { padding: 28px 0; }
    .lh-hero--big h1 { font-size: 22px; }
    .lh-hero--big .lh-lede { font-size: 14px; }
    .lh-svc-hero h1 { font-size: 22px; }
    .lh-glance__num { font-size: 22px; }
    .lh-stats__num { font-size: 26px; }
    .lh-pillar { padding: 16px; }
    .lh-test { padding: 18px; }
    .lh-cta__panel { padding: 26px 16px; }
}

/* Comparison table — horizontal scroll instead of overflow */
.lh-compare { -webkit-overflow-scrolling: touch; }
.lh-compare table { min-width: 480px; }
@media (max-width: 540px) { .lh-compare table { min-width: 420px; font-size: 12px; } }

/* ============================================================
   ABOUT US — team grid
   ============================================================ */
.lh-team {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 18px; margin-top: 18px;
}
@media (max-width: 880px) { .lh-team { grid-template-columns: 1fr 1fr; } }
@media (max-width: 540px) { .lh-team { grid-template-columns: 1fr; } }

.lh-member {
    background: #fff;
    border: 1px solid var(--lh-line);
    border-radius: 18px;
    padding: 24px;
    margin: 0;
    display: flex; flex-direction: column; gap: 6px;
    text-align: left;
    transition: transform .15s, border-color .15s, box-shadow .15s;
}
.lh-member:hover { transform: translateY(-3px); border-color: var(--lh-yellow); box-shadow: var(--lh-shadow); }
.lh-member__avatar {
    width: 72px; height: 72px; border-radius: 50%;
    background: var(--lh-yellow);
    color: var(--lh-black);
    display: inline-flex; align-items: center; justify-content: center;
    font: 800 28px var(--lh-font);
    margin-bottom: 6px;
}
.lh-member strong { color: var(--lh-black); font-size: 17px; }
.lh-member span { color: var(--lh-mute); font-size: 13px; text-transform: uppercase; letter-spacing: .06em; }
.lh-member p { color: var(--lh-graphite); font-size: 14px; margin: 6px 0 0; }

/* ============================================================
   CONTACT US — country office cards
   ============================================================ */
.lh-offices {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 14px; margin-top: 18px;
}
@media (max-width: 980px) { .lh-offices { grid-template-columns: 1fr 1fr; } }
@media (max-width: 540px) { .lh-offices { grid-template-columns: 1fr; } }

.lh-office {
    background: #fff;
    border: 1px solid var(--lh-line);
    border-radius: 16px;
    padding: 22px;
    margin: 0;
}
.lh-office__flag { font-size: 30px; line-height: 1; }
.lh-office h3 { margin: 6px 0 4px; font-size: 17px; }
.lh-office__addr { color: var(--lh-mute); font-size: 13px; margin: 0 0 10px; line-height: 1.5; min-height: 60px; }
.lh-office__list { list-style: none; padding: 0; margin: 0; display: grid; gap: 4px; font-size: 14px; }
.lh-office__list a { color: var(--lh-black); text-decoration: none; }
.lh-office__list a:hover { color: var(--lh-graphite); text-decoration: underline; }
.lh-office__hours { color: var(--lh-mute); font-size: 12px; margin: 12px 0 0; padding-top: 12px; border-top: 1px solid var(--lh-line); }

/* ============================================================
   HOMEPAGE — Hire-a-pro section
   ============================================================ */
.lh-hire {
    padding: 64px 0;
    background: linear-gradient(180deg, #fff 0%, var(--lh-yellow-soft) 100%);
}
.lh-hire__grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    align-items: center;
}
@media (max-width: 980px) { .lh-hire__grid { grid-template-columns: 1fr; gap: 24px; } }

.lh-hire__list {
    list-style: none; padding: 0; margin: 16px 0 0;
    display: grid; gap: 8px;
}
.lh-hire__list li {
    color: var(--lh-graphite); font-size: 15px; line-height: 1.5;
}

.lh-hire__cards {
    display: flex; flex-direction: column; gap: 12px;
}
.lh-hire-card {
    display: grid;
    grid-template-columns: 56px 1fr auto;
    align-items: center;
    gap: 14px;
    background: #fff;
    border: 1px solid var(--lh-line);
    border-radius: 16px;
    padding: 16px 18px;
    box-shadow: var(--lh-shadow);
}
.lh-hire-card--accent { background: var(--lh-yellow); border-color: var(--lh-yellow-dark); transform: translateX(20px); }
@media (max-width: 540px) { .lh-hire-card--accent { transform: none; } }
.lh-hire-card__avatar {
    width: 48px; height: 48px;
    background: var(--lh-black); color: var(--lh-yellow);
    display: inline-flex; align-items: center; justify-content: center;
    border-radius: 50%;
    font: 800 14px var(--lh-font);
    letter-spacing: -.02em;
}
.lh-hire-card strong { color: var(--lh-black); display: block; font-size: 15px; }
.lh-hire-card p { color: var(--lh-graphite); margin: 2px 0 0; font-size: 13px; }
.lh-hire-card__price {
    font-weight: 800; color: var(--lh-black); font-size: 17px;
    white-space: nowrap;
}
.lh-hire-card__price small { color: var(--lh-mute); font-weight: 500; font-size: 12px; }

@media (max-width: 720px) {
    .lh-hire { padding: 40px 0; }
    .lh-hire-card { grid-template-columns: 44px 1fr; padding: 14px; }
    .lh-hire-card__avatar { width: 40px; height: 40px; font-size: 12px; }
    .lh-hire-card__price { grid-column: 1 / -1; text-align: right; }
}
