/* ==========================================================================
   HNG GLOBAL DESIGN SYSTEM
   File: template-parts/hng-global.css
   
   Centralized design tokens, typography, utilities, and component primitives
   shared across ALL custom blocks and template parts.

   Load order: this file MUST be enqueued BEFORE any block-specific CSS.

   Contents:
     1. Design Tokens (CSS custom properties)
     2. Typography System
     3. Global Button Component
     4. Outer Box Utility
     5. Block Spacing Utility
     6. Responsive Overrides
   ========================================================================== */

/* ══════════════════════════════════════════════════════════════
   1. DESIGN TOKENS
   ══════════════════════════════════════════════════════════════ */

:root {
  --color-brand-orange: #f58220;

  /* ── Brand Colors ─────────────────────────────────────────── */
  --hng-orange: var(--color-brand-orange); /* primary brand orange */
  --hng-orange-hover: #d96e18; /* darker on hover         */
  --hng-orange-light: #f9a55a; /* lighter tint / links    */
  --hng-white: #ffffff;
  --hng-muted: rgba(255, 255, 255, 0.72);
  --hng-muted-heavy: rgba(255, 255, 255, 0.55);

  /* ── Outer Box (dark transparent container) ───────────────── */
  --hng-outer-bg: rgb(0 0 0 / 10%);
  --hng-outer-blur: blur(10px);

  /* ── Border Radius ────────────────────────────────────────── */
  --radius-section: 60px; /* outer box / dark containers     */
  --radius-image: 40px; /* all images / media              */
  --radius-card: 1.25rem; /* content cards                   */
  --radius-btn: 100px; /* buttons — pill shape            */

  /* ── Typography ───────────────────────────────────────────── */
  --hng-serif: "Georgia", serif;
  --hng-sans: "DM Sans", system-ui, sans-serif;

  /* Target: 58px  */
  --hng-h1-size: clamp(2.25rem, 4.5vw, 3.625rem);
  /* Target: 40px  */
  --hng-caption-size: clamp(1.75rem, 3.2vw, 2.5rem);
  /* Target: 50px */
  --hng-h2-size: clamp(2rem, 4.2vw, 3.125rem);
  /* Target: 30px */
  --hng-h3-size: clamp(1.5rem, 2.5vw, 1.875rem);
  /* Target: 18px  */
  --hng-body-size: clamp(1rem, 1.5vw, 1.125rem);
  --hng-small-size: clamp(0.8rem, 1.2vw, 0.9rem);

  /* ── Spacing ──────────────────────────────────────────────── */
  --hng-block-gap: 8%; /* margin-bottom each block      */
  --hng-section-pad: 35px clamp(1.5rem, 6vw, 6rem); /* inner padding     */
  --hng-col-gap: clamp(1.25rem, 3vw, 2.5rem);
  --hng-row-gap: clamp(1rem, 2.5vw, 2rem);
  --hng-text-gap: 1rem; /* gap inside text columns       */

  /* ── Transitions ──────────────────────────────────────────── */
  --hng-transition: 0.25s ease;
  --hng-transition-slow: 0.45s ease;

  /* ── Shadows ──────────────────────────────────────────────── */
  --hng-btn-shadow: 0 4px 16px rgba(245, 130, 32, 0.35);
  --hng-img-shadow: 0 8px 32px rgba(0, 0, 0, 0.25);
}

/* ══════════════════════════════════════════════════════════════
   2. TYPOGRAPHY SYSTEM
   ══════════════════════════════════════════════════════════════ */

/* @font-face declarations are loaded via itc-avant-garde-fonts.css,
   enqueued in functions.php before this file. */

.ag-ce-demi {
  font-family: "ITCAvantGarde", sans-serif;
  font-weight: 600;
  font-style: normal;
  font-stretch: normal;
}

/* ── Body copy ────────────────────────────────────────────── */
.hng-body {
  font-family: var(--hng-sans);
  font-size: var(--hng-body-size);
  line-height: 1.7;
  color: var(--hng-muted);
}

.hng-body p {
  margin: 0 0 0.85em;
}
.hng-body p:last-child {
  margin-bottom: 0;
}

/* ══════════════════════════════════════════════════════════════
   3. GLOBAL BUTTON COMPONENT
   ══════════════════════════════════════════════════════════════ */

/* ── Base button ──────────────────────────────────────────── */
.hng-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.7em 1.5em;
  background: var(--hng-orange);
  color: var(--hng-white);
  border: 2px solid transparent;
  border-radius: var(--radius-btn);
  font-size: clamp(14px, 1.4vw, 15px);
  font-family: "ITCAvantGarde", sans-serif;
  font-weight: 600;
  font-style: normal;
  font-stretch: normal;
  text-decoration: none;
  font-style: normal;
  line-height: 1.2;
  cursor: pointer;
  white-space: nowrap;
  transition:
    background var(--hng-transition),
    transform var(--hng-transition),
    box-shadow var(--hng-transition),
    border-color var(--hng-transition);
  text-wrap: auto !important;
}

.hng-btn:hover,
.hng-btn:focus-visible {
  background: var(--hng-orange-hover);
  transform: translateY(-2px);
  box-shadow: var(--hng-btn-shadow);
  text-decoration: none;
  outline: none;
}

.hng-btn:focus-visible {
  outline: 2px solid var(--hng-orange-light);
  outline-offset: 2px;
}

.hng-btn svg {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
}

/* ── Outline variant ──────────────────────────────────────── */
.hng-btn--outline {
  background: transparent;
  border-color: var(--hng-orange);
  color: var(--hng-orange);
}

.hng-btn--outline:hover,
.hng-btn--outline:focus-visible {
  background: var(--hng-orange);
  color: var(--hng-white);
}

/* ── Ghost variant (white border, transparent bg) ─────────── */
.hng-btn--ghost {
  background: transparent;
  border-color: rgba(255, 255, 255, 0.45);
  color: var(--hng-white);
}

.hng-btn--ghost:hover,
.hng-btn--ghost:focus-visible {
  background: rgba(255, 255, 255, 0.12);
  border-color: var(--hng-white);
  box-shadow: none;
}

/* ── Button group (wrapping row of multiple buttons) ─────── */
.hng-btn-group {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1rem;
  margin-top: 0.5rem;
}

/* ══════════════════════════════════════════════════════════════
   4. OUTER BOX UTILITY
   Dark transparent rounded container shared by all blocks.
   Apply to the block's __inner element when outer_box = true.
   ══════════════════════════════════════════════════════════════ */

.hng-outer-box {
  background: rgb(0 0 0 / 28%);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  padding: var(--hng-section-pad);
  box-sizing: border-box;
  overflow: hidden;
  border-radius: 60px;
}

/* ══════════════════════════════════════════════════════════════
   5. BLOCK SPACING UTILITY
   ══════════════════════════════════════════════════════════════ */

/* All top-level block sections */
.hng-block {
  width: 100%;
  box-sizing: border-box;
  margin-bottom: var(--hng-block-gap);
}

/* ══════════════════════════════════════════════════════════════
   6. RESPONSIVE OVERRIDES
   ══════════════════════════════════════════════════════════════ */

/* ── Tablet ───────────────────────────────────────────────── */
@media (max-width: 900px) {
  :root {
    --hng-section-pad: 2.5rem;
    --hng-h2-size: 2.5rem; /* 40px */
    --hng-h3-size: 1.5625rem; /* 25px */
  }
}

/* ── Mobile ───────────────────────────────────────────────── */
@media (max-width: 600px) {
  :root {
    --hng-section-pad: 1.5rem;
    --radius-section: 40px; /* slightly smaller on mobile */
    --radius-image: 24px; /* slightly smaller on mobile */
    --hng-h2-size: 2.5rem; /* 40px */
    --hng-h3-size: 1.5625rem; /* 25px */
    --hng-body-size: 1rem; /* 16px */
  }

  .hng-btn-group {
    flex-direction: column;
    align-items: flex-start;
  }
}

/* ── Reduced motion ───────────────────────────────────────── */
@media (prefers-reduced-motion: reduce) {
  .hng-btn {
    transition: none;
  }

  .hng-img-wrap img {
    transition: none;
  }
}

/* ==========================================================================
   HNG Footer — Layout 01

   Structure:
     .hng-footer               — full-width footer shell
     .hng-footer__main         — dark section: logo left, social right
     .hng-footer__bottom       — orange bar: copyright left, legal links right
   ========================================================================== */

.hng-footer {
  --hf-bg-main: #2b2b2b;
  --hf-bg-bottom: var(--hng-orange, #f58220);
  --hf-text: #ffffff;
  --hf-muted: rgba(255, 255, 255, 0.7);
  --hf-pad-x: var(--hng-section-pad, clamp(1.5rem, 6vw, 6rem));
  --hf-body-size: var(--hng-small-size, clamp(0.8rem, 1.2vw, 0.9rem));
  --hf-accent-h: 6px;

  width: 100%;
  font-family: var(--hng-sans, "DM Sans", system-ui, sans-serif);
}

/* ── Top accent line ────────────────────────────────────────────── */
.hng-footer::before {
  content: "";
  display: block;
  width: 100%;
  height: var(--hf-accent-h);
  background: var(--hng-orange, #f58220);
}

/* ── Main bar (dark) ────────────────────────────────────────────── */
.hng-footer__main {
  background: var(--hf-bg-main);
  display: flex;
  align-items: center;
  justify-content: space-between;
  /* padding: clamp(1.25rem, 3vh, 2rem) var(--hf-pad-x); */
  padding: 40px 10rem 50px 10rem;
  gap: 2rem;
  box-sizing: border-box;
}

/* Logo */
.hng-footer__logo {
  display: flex;
  align-items: center;
  /* flex-shrink: 0; */
  width: 230px;
}

.hng-footer__logo img {
  /* display: block;
	height: clamp(40px, 6vh, 60px);
	width: auto;
	object-fit: contain; */

  height: 100%;
  width: 100%;
}

.hng-footer__logo-text {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--hf-text);
}

/* Social block */
.hng-footer__social {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex-shrink: 0;
  flex-direction: column;
}

.hng-footer__social-label {
  font-size: 22px;
  font-family: "ITCAvantGarde", sans-serif;
  font-weight: 400;
  font-style: normal;
  font-stretch: normal;
  color: var(----color-brand-orange, #f58220);
  white-space: nowrap;
}

.hng-footer__social-link {
  text-align: center;
  align-items: center;
  display: block;
  text-decoration: none;
  transition: opacity 0.2s ease;
}

.hng-footer__social-link:hover,
.hng-footer__social-link:focus-visible {
  opacity: 0.8;
}

.hng-footer__social-link svg {
  display: block;
}

/* ── Bottom bar (orange) ────────────────────────────────────────── */
.hng-footer__bottom {
  background: var(--hf-bg-main);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 10rem 20px 10rem;
  gap: 1.5rem;
  box-sizing: border-box;
}

.hng-footer__copyright {
  margin: 0;
  font-size: var(--hf-body-size);
  color: var(--hf-text);
  font-family: "ITCAvantGarde", sans-serif;
  font-weight: 400;
  font-style: normal;
  font-stretch: normal;
  line-height: 1.4;
}

/* Legal nav */
.hng-footer__legal {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-shrink: 0;
  white-space: nowrap;
}

.hng-footer__legal-link {
  font-size: var(--hf-body-size);
  color: var(--hf-text);
  font-family: "ITCAvantGarde", sans-serif;
  font-weight: 400;
  font-style: normal;
  font-stretch: normal;
  text-decoration: none;
  transition: opacity 0.2s ease;
}

.hng-footer__legal-link:hover,
.hng-footer__legal-link:focus-visible {
  opacity: 0.75;
  text-decoration: underline;
}

.hng-footer__legal-sep {
  font-size: var(--hf-body-size);
  font-family: "ITCAvantGarde", sans-serif;
  font-weight: 400;
  font-style: normal;
  font-stretch: normal;
  color: var(--hf-text);
  opacity: 0.6;
}

@media (min-width: 1800px) {
  .approach-block__step-body {
    font-size: 22px;
  }

}

@media (min-width: 1300px) {
  .pillars-block__section-intro,
  .pillars-block__group-intro {
    width: 45%;
  }
}

/* ── Mobile (≤ 640px) ───────────────────────────────────────────── */
@media (max-width: 640px) {
  :root {
    --hng-body-size: 0.875rem; /* 14px */
    --hng-h2-size: 1.75rem; /* 28px */
  }

  .hng-footer__main {
    flex-direction: column;
    padding: 40px 0 50px 0;
    justify-content: center;
    align-items: center;
    gap: 4rem;
  }

  .hng-footer__bottom {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.5rem;
    padding-top: 1rem;
    padding-bottom: 1rem;
  }

  .hng-footer__bottom {
    padding: 20px;
  }
}

