/* =====================================================================
   Aerious — Typography standardization layer (2026-08)
   Loaded AFTER the theme's style.css/responsive.css so it wins the cascade.
   Goals: one modern, sober typeface; a comfortable base size (no more
   "too small" text); a consistent, harmonized type scale. Structure and
   COLORS are intentionally left to the theme — this file only touches
   font-family, size, weight, line-height and letter-spacing.
   Reversible: remove the <link> in web/common/meta.blade.php to revert.
   ===================================================================== */

:root {
    /* Modern, sober sans. Inter is loaded via Google Fonts in <head>. */
    --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;

    /* Fluid, harmonized type scale (min .. max) — clamps for responsiveness. */
    --fs-xs:   0.8125rem;                       /* 13px — smallest allowed */
    --fs-sm:   0.9375rem;                        /* 15px */
    --fs-base: 1.0625rem;                        /* 17px — comfortable body */
    --fs-lg:   1.1875rem;                         /* 19px */
    --fs-xl:   clamp(1.35rem, 1.1rem + 1vw, 1.6rem);
    --fs-h4:   clamp(1.35rem, 1.15rem + 0.9vw, 1.75rem);
    --fs-h3:   clamp(1.6rem, 1.25rem + 1.4vw, 2.15rem);
    --fs-h2:   clamp(2rem, 1.5rem + 2.2vw, 2.9rem);
    --fs-h1:   clamp(2.4rem, 1.7rem + 3.2vw, 3.8rem);

    --lh-tight: 1.2;
    --lh-snug:  1.35;
    --lh-body:  1.65;
}

/* --- Base ------------------------------------------------------------- */
html {
    /* The theme shrinks the root below 16px, which is the root cause of the
       "everything feels small" complaint. Reset to a comfortable 16px base so
       the whole rem-based scale lands at its intended sizes. */
    font-size: 100% !important;             /* 16px */
    -webkit-text-size-adjust: 100%;
    text-size-adjust: 100%;
}

body {
    font-family: var(--font-sans);
    font-size: var(--fs-base) !important;
    line-height: var(--lh-body);
    font-weight: 400;
    letter-spacing: -0.006em;               /* subtle, modern tightening */
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Inherit the family everywhere the theme hard-set a different font,
   but never override icon fonts (FontAwesome / themify / et-line). */
body :not(i):not(span[class*="icon"]):not([class*="ti-"]):not([class*="fa"]):not([class*="et-"]):not([class^="icon"]) {
    font-family: var(--font-sans);
}

/* --- Headings: consistent, sober hierarchy --------------------------- */
h1, .h1, h2, .h2, h3, .h3, h4, .h4, h5, .h5, h6, .h6 {
    font-family: var(--font-sans);
    font-weight: 700;
    line-height: var(--lh-tight);
    letter-spacing: -0.02em;
    color: inherit;                          /* keep theme colors */
}

h1, .h1 { font-size: var(--fs-h1); }
h2, .h2 { font-size: var(--fs-h2); }
h3, .h3 { font-size: var(--fs-h3); line-height: var(--lh-snug); }
h4, .h4 { font-size: var(--fs-h4); line-height: var(--lh-snug); font-weight: 600; }
h5, .h5 { font-size: var(--fs-xl); line-height: var(--lh-snug); font-weight: 600; }
h6, .h6 { font-size: var(--fs-lg); line-height: var(--lh-snug); font-weight: 600; }

/* --- Body copy ------------------------------------------------------- */
p, li, dd, dt, blockquote, label, td, th, input, textarea, select, button {
    font-family: var(--font-sans);
}
p, li, dd { font-size: var(--fs-base) !important; line-height: var(--lh-body); }
.lead, p.lead { font-size: var(--fs-lg) !important; line-height: 1.55; }

/* --- Fix "too small" text: raise anything below the floor ------------ */
small, .small, .text-small, .font-small, .text-xs, figcaption, .caption {
    font-size: var(--fs-sm) !important;
    line-height: 1.5;
}
.text-extra-small, .font-size-11, .font-size-12, .font-size-13 {
    font-size: var(--fs-xs) !important;
}

/* Common theme utility sizes → remap onto the scale (keeps rhythm) */
.font-size-14, .font-size-15 { font-size: var(--fs-sm) !important; }
.font-size-16, .font-size-17 { font-size: var(--fs-base) !important; }
.font-size-18, .font-size-19, .font-size-20 { font-size: var(--fs-lg) !important; }

/* Navigation + footer often read too small on this theme */
.navbar-nav > li > a { font-size: var(--fs-sm); letter-spacing: 0; }
footer, footer p, footer li, footer a { font-size: var(--fs-sm); }

/* Buttons: consistent, legible */
.btn, button, .button { font-family: var(--font-sans); font-weight: 600; letter-spacing: 0; }
