/*
Theme Name:        Takapuna Heat Pumps
Theme URI:         https://heatpumpstakapuna.nz
Author:            MoreLeads.nz
Author URI:        https://moreleads.nz
Description:       Custom theme for Takapuna Heat Pumps — North Shore's Local Heat Pump Specialists
Version:           1.0.0
Requires at least: 6.0
Requires PHP:      8.0
License:           Proprietary
Text Domain:       takapuna-hp
*/

/* ==========================================================================
   Fonts — Montserrat self-hosted
   ========================================================================== */

@font-face {
  font-family: 'Montserrat';
  src: url('/wp-content/themes/takapuna-hp/fonts/montserrat-400.woff2') format('woff2');
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: 'Montserrat';
  src: url('/wp-content/themes/takapuna-hp/fonts/montserrat-600.woff2') format('woff2');
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: 'Montserrat';
  src: url('/wp-content/themes/takapuna-hp/fonts/montserrat-700.woff2') format('woff2');
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: 'Montserrat';
  src: url('/wp-content/themes/takapuna-hp/fonts/montserrat-800.woff2') format('woff2');
  font-weight: 800;
  font-style: normal;
  font-display: swap;
}

/* ==========================================================================
   Design Tokens — CSS Custom Properties
   ========================================================================== */

:root {

  /* --- Colours: Primary --- */
  --color-primary:        #2B7BB9;   /* Sky Blue — headers, links, primary buttons */
  --color-primary-dark:   #1E5F8E;   /* Hover state for primary */
  --color-primary-light:  #EDF3F9;   /* Light tint — section backgrounds, highlights */

  /* --- Colours: Accent --- */
  --color-accent:         #F07D28;   /* Warm Orange — CTAs, highlights, badges */
  --color-accent-dark:    #D4661A;   /* Hover state for accent */
  --color-accent-light:   #FEF3EB;   /* Light tint — accent backgrounds */

  /* --- Colours: Trust / Success --- */
  --color-trust:          #2E7D52;   /* Fresh Green — trust badges, ticks, guarantees */
  --color-trust-light:    #EAF4EE;   /* Light tint — trust badge backgrounds */

  /* --- Colours: Backgrounds --- */
  --color-bg-white:       #FFFFFF;   /* Page background, cards */
  --color-bg-off-white:   #F8F9FA;   /* Alternate section background */
  --color-bg-light:       #EDF3F9;   /* Light blue-grey sections */
  --color-bg-footer:      #F0F4F8;   /* Footer background */

  /* --- Colours: Text --- */
  --color-text-primary:   #1E1E1E;   /* Body copy, headings */
  --color-text-secondary: #5A6472;   /* Subtext, meta, captions */
  --color-text-light:     #8A94A0;   /* Placeholder, disabled */
  --color-text-inverse:   #FFFFFF;   /* Text on dark/coloured backgrounds */

  /* --- Colours: Borders --- */
  --color-border:         #DDE3EA;   /* Card borders, dividers, inputs */
  --color-border-focus:   #2B7BB9;   /* Input focus state */

  /* --- Shadows --- */
  --shadow-sm:  0 1px 3px rgba(0,0,0,0.08);
  --shadow-md:  0 4px 12px rgba(0,0,0,0.10);
  --shadow-lg:  0 8px 24px rgba(0,0,0,0.12);

  /* --- Typography: Family --- */
  --font-family:      'Montserrat', sans-serif;

  /* --- Typography: Scale --- */
  --text-hero:        clamp(2.2rem, 5vw, 3.5rem);    /* Hero H1 */
  --text-h1:          clamp(1.8rem, 4vw, 2.8rem);    /* Page H1 */
  --text-h2:          clamp(1.5rem, 3vw, 2.1rem);    /* Section headings */
  --text-h3:          clamp(1.2rem, 2.5vw, 1.5rem);  /* Card / subsection headings */
  --text-h4:          1.15rem;                         /* Minor headings */
  --text-lg:          1.125rem;                        /* Lead paragraph */
  --text-base:        1rem;                            /* Body copy */
  --text-sm:          0.875rem;                        /* Meta, captions, labels */
  --text-xs:          0.75rem;                         /* Fine print, badges */

  /* --- Typography: Line Heights --- */
  --leading-tight:    1.2;
  --leading-normal:   1.6;
  --leading-relaxed:  1.75;

  /* --- Typography: Letter Spacing --- */
  --tracking-tight:   -0.02em;
  --tracking-normal:  0;
  --tracking-wide:    0.05em;
  --tracking-wider:   0.1em;

  /* --- Spacing (4px base unit) --- */
  --space-1:    0.25rem;   /*  4px */
  --space-2:    0.5rem;    /*  8px */
  --space-3:    0.75rem;   /* 12px */
  --space-4:    1rem;      /* 16px */
  --space-5:    1.25rem;   /* 20px */
  --space-6:    1.5rem;    /* 24px */
  --space-8:    2rem;      /* 32px */
  --space-10:   2.5rem;    /* 40px */
  --space-12:   3rem;      /* 48px */
  --space-16:   4rem;      /* 64px */
  --space-20:   5rem;      /* 80px */
  --space-24:   6rem;      /* 96px */

  /* --- Spacing: Sections & Container --- */
  --section-py:       clamp(3rem, 6vw, 5rem);
  --section-px:       clamp(1rem, 4vw, 2rem);
  --container-max:    1200px;
  --container-wide:   1440px;
  --container-narrow: 768px;

  /* --- Breakpoints (reference values — use literal px in @media queries) --- */
  --bp-sm:   480px;    /* Large phones */
  --bp-md:   768px;    /* Tablets */
  --bp-lg:   1024px;   /* Small desktop */
  --bp-xl:   1280px;   /* Desktop */
  --bp-2xl:  1440px;   /* Wide desktop */
}

/* ==========================================================================
   Base Reset
   ========================================================================== */

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

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

body {
  font-family: var(--font-family);
  font-size: var(--text-base);
  font-weight: 400;
  line-height: var(--leading-normal);
  color: var(--color-text-primary);
  background-color: var(--color-bg-white);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* --- Headings --- */

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-family);
  color: var(--color-text-primary);
  line-height: var(--leading-tight);
}

h1 {
  font-size: var(--text-h1);
  font-weight: 800;
  letter-spacing: var(--tracking-tight);
}

h2 {
  font-size: var(--text-h2);
  font-weight: 700;
  letter-spacing: -0.01em;
}

h3 {
  font-size: var(--text-h3);
  font-weight: 700;
}

h4 {
  font-size: var(--text-h4);
  font-weight: 600;
}

h5, h6 {
  font-weight: 600;
}

/* --- Body copy --- */

p {
  line-height: var(--leading-normal);
}

p + p {
  margin-top: var(--space-4);
}

/* --- Links --- */

a {
  color: var(--color-primary);
  text-decoration: none;
}

a:hover {
  color: var(--color-primary-dark);
}

/* --- Lists --- */

ul,
ol {
  list-style: none;
}

/* --- Media --- */

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

/* --- Form elements --- */

button,
input,
select,
textarea {
  font-family: inherit;
  font-size: inherit;
  line-height: inherit;
}

button {
  cursor: pointer;
  border: none;
  background: none;
}

/* --- Layout utilities --- */

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

.section {
  padding: var(--section-py) var(--section-px);
}
