:root {
    --primary: #0284c7;
    --primary-hover: #0369a1;
    --primary-light: #e0f2fe;
    --secondary-accent: #0f172a;
    --background-light: #ffffff;
    --background-subtle: #f8fafc;
    --background-card: #f1f5f9;
    --border-color: #e2e8f0;
    --text-primary: #0f172a;
    --text-secondary: #475569;
    --text-muted: #64748b;
    --text-inverse: #ffffff;
    --accent-alert: #ef4444;
    --font-heading: 'Plus Jakarta Sans', sans-serif;
    --font-body: 'Inter', sans-serif;
}

*,
*::before,
*::after {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%;
}

html,
body {
    overflow-x: hidden;
}

@supports (overflow: clip) {
    html,
    body {
        overflow-x: clip;
    }
}

body {
    margin: 0;
    padding: 0;
    font-family: var(--font-body);
    color: var(--text-secondary);
    background-color: var(--background-light);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: var(--font-heading);
    color: inherit;
    font-weight: 700;
    margin-top: 0;
    margin-bottom: 0.5rem;
    line-height: 1.25;
}

a {
    text-decoration: none;
    color: inherit;
    transition: color 0.2s ease, opacity 0.2s ease;
}

button {
    cursor: pointer;
    border: none;
    background: none;
    font-family: inherit;
    transition: all 0.2s ease;
}

ul,
ol {
    list-style: none;
    margin: 0;
    padding: 0;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
    outline: 2px solid var(--primary);
    outline-offset: 2px;
}

@media (max-width: 768px) {
    h1 {
        font-size: clamp(1.75rem, 5vw, 2.25rem);
        line-height: 1.2;
    }

    h2 {
        font-size: clamp(1.5rem, 4vw, 1.875rem);
        line-height: 1.25;
    }

    h3 {
        font-size: clamp(1.25rem, 3.5vw, 1.5rem);
    }

    h4 {
        font-size: 1.125rem;
    }

    h5,
    h6 {
        font-size: 1rem;
    }

    p,
    span,
    a,
    li {
        overflow-wrap: break-word;
        word-break: break-word;
    }
}

/* ===== header_block ===== */
#header {
    overflow: hidden;
}

#mobile-nav-overlay.open {
    display: flex !important;
}

/* ===== hero_editorial_block ===== */
#hero-intro {
    overflow: hidden;
    hyphens: auto;
}

#hero-intro img {
    width: 100%;
    object-fit: cover;
}

/* ===== hidden_plumbing_issues_block ===== */
#hidden-issues {
    overflow: hidden;
}

#hidden-issues h2,
#hidden-issues h3 {
    hyphens: auto;
}

#hidden-issues .js-issue-card {
    min-height: 100%;
}

/* ===== daily_habits_block ===== */
#daily-habits {
    overflow: hidden;
}

#daily-habits .js-habit-card {
    transition: transform 0.2s ease;
}

/* ===== early_warning_signs_block ===== */
#early-warning-signs {
    overflow: hidden;
}

#early-warning-signs .js-symptom-card.is-active {
    border-color: #0284c7;
    background-color: #f0f9ff;
}

/* ===== case_scenarios_block ===== */
#case-scenarios {
    width: 100%;
    hyphens: auto;
}

/* ===== diy_vs_pro_block ===== */
#diy-vs-pro {
    hyphens: auto;
}

#diy-vs-pro h2,
#diy-vs-pro h3,
#diy-vs-pro h4 {
    line-height: 1.25;
}

/* ===== seasonal_risks_block ===== */
#seasonal-risks {
    position: relative;
    width: 100%;
    box-sizing: border-box;
}

#seasonal-risks h2,
#seasonal-risks h3 {
    hyphens: auto;
}

/* ===== maintenance_checklist_block ===== */
#maintenance-checklist {
    overflow: hidden;
    hyphens: auto;
}

#maintenance-checklist table {
    min-width: 600px;
}

/* ===== equipment_overview_block ===== */
#equipment-overview {
    overflow: hidden;
}

#equipment-overview img {
    width: 100%;
    object-fit: cover;
}

/* ===== emergency_readiness_block ===== */
#emergency-readiness {
    overflow: hidden;
}

#emergency-readiness h2,
#emergency-readiness h3 {
    hyphens: auto;
    line-height: 1.2;
}

/* ===== repair_options_block ===== */
#repair-options {
    overflow: hidden;
    width: 100%;
}

#repair-options * {
    box-sizing: border-box;
}

/* ===== contact_form_block ===== */
#consultation-form {
    overflow: hidden;
}

#consultation-form input::placeholder {
    color: #475569;
    opacity: 0.8;
}

/* ===== footer_block ===== */
#footer {
    position: relative;
    background-color: #0f172a;
    color: #94a3b8;
    overflow: hidden;
    width: 100%;
}

#footer a {
    transition: color 0.2s ease;
}

#footer h3 {
    color: #ffffff;
    line-height: 1.2;
    hyphens: auto;
}
/* ===== article modal ===== */
.article-body h3 {
    font-size: 18px;
    font-weight: 700;
    color: #0f172a;
    line-height: 1.3;
    margin: 22px 0 10px;
}
.article-body > h3:first-child {
    margin-top: 0;
}
.article-body p {
    font-size: 15px;
    line-height: 1.75;
    color: #475569;
    margin-bottom: 14px;
}
.article-body ul,
.article-body ol {
    margin: 0 0 16px 6px;
    padding-left: 18px;
}
.article-body li {
    font-size: 15px;
    line-height: 1.7;
    color: #475569;
    margin-bottom: 8px;
}
.article-body ul li {
    list-style: disc;
}
.article-body ol li {
    list-style: decimal;
}
.article-body strong {
    color: #0f172a;
    font-weight: 600;
}
.article-body table {
    display: block;
    width: 100%;
    font-size: 14px;
    border-collapse: collapse;
    margin: 18px 0 22px;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}
.article-body th {
    text-align: left;
    padding: 10px 12px;
    background: #f1f5f9;
    color: #0f172a;
    font-weight: 600;
    border: 1px solid #e2e8f0;
}
.article-body td {
    padding: 10px 12px;
    border: 1px solid #e2e8f0;
    color: #475569;
    vertical-align: top;
    line-height: 1.5;
}
