/* ==============================================
   BASE — CSS Variables, Reset, Typography
   ============================================== */

:root {
  /* ── Brand palette — Modern Editorial ── */
  --iw-navy:       #1e1b4b;   /* deep indigo */
  --iw-orange:     #ea580c;   /* vivid orange */
  --iw-yellow:     #f59e0b;   /* amber gold */
  --iw-purple:     #7c3aed;   /* vivid violet */
  --iw-blue:       #3b82f6;   /* cobalt blue */
  --iw-cats-bg:    #f97316;   /* category pill bg */
  --iw-green:      #10b981;   /* emerald */
  --iw-teal:       #06b6d4;   /* cyan  — new */
  --iw-rose:       #f43f5e;   /* rose  — new */
  --iw-dark-tag:   #1e293b;

  /* ── Neutrals (slate-based — cooler, editorial) ── */
  --iw-white:      #ffffff;
  --iw-bg:         #fafaf8;   /* warm white */
  --iw-gray-50:    #f8fafc;
  --iw-gray-100:   #f1f5f9;
  --iw-gray-200:   #e2e8f0;
  --iw-gray-300:   #cbd5e1;
  --iw-gray-400:   #94a3b8;
  --iw-gray-500:   #64748b;
  --iw-gray-700:   #334155;
  --iw-gray-900:   #0f172a;
  --iw-text:       #0f172a;
  --iw-muted:      #64748b;

  /* ── Component colours ── */
  --iw-peach:      #fff7ed;
  --iw-border:     #e2e8f0;

  /* Typography */
  --iw-font:       'Poppins', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;

  /* Layout */
  --iw-max-width:  1280px;
  --iw-gap:        12px;
  --iw-pad:        24px;

  /* Radii */
  --iw-radius:     16px;
  --iw-radius-sm:  10px;
  --iw-radius-xs:  6px;

  /* ── Shadows ── */
  --iw-shadow-sm:  0 1px 4px rgba(0,0,0,0.07);
  --iw-shadow:     0 4px 20px rgba(0,0,0,0.09);
  --iw-shadow-lg:  0 8px 36px rgba(0,0,0,0.12);

  /* Transitions */
  --iw-t:          0.22s ease;
  --iw-t-slow:     0.4s ease;
}

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

html { scroll-behavior: smooth; }

body {
  font-family: var(--iw-font);
  font-size: 15px;
  line-height: 1.6;
  color: var(--iw-text);
  background: var(--iw-bg);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

a {
  text-decoration: none;
  color: inherit;
  transition: color var(--iw-t);
}

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

button, input, select, textarea {
  font-family: var(--iw-font);
}

ul, ol { list-style: none; }

/* ── Base Typography ── */
h1, h2, h3, h4, h5, h6 {
  font-weight: 700;
  line-height: 1.25;
  color: var(--iw-text);
}

h1 { font-size: clamp(24px, 4vw, 36px); }
h2 { font-size: clamp(20px, 3vw, 28px); }
h3 { font-size: clamp(17px, 2.5vw, 22px); }
h4 { font-size: 18px; }

p { margin-bottom: 1em; }
p:last-child { margin-bottom: 0; }

/* ── Accessible focus ── */
:focus-visible {
  outline: 2px solid var(--iw-blue);
  outline-offset: 3px;
}

/* ── Screen reader only ── */
.sr-only {
  position: absolute;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0,0,0,0);
  white-space: nowrap; border: 0;
}

/* ── Embed wrapper for responsive video ── */
.iw-embed-wrap {
  position: relative;
  padding-bottom: 56.25%;
  height: 0;
  overflow: hidden;
  border-radius: var(--iw-radius-sm);
}
.iw-embed-wrap iframe,
.iw-embed-wrap object,
.iw-embed-wrap embed {
  position: absolute;
  inset: 0;
  width: 100%; height: 100%;
}

/* ── WordPress alignment classes ── */
.alignleft  { float: left;  margin: 0 1.5em 1em 0; }
.alignright { float: right; margin: 0 0 1em 1.5em; }
.aligncenter { display: block; margin: 1.5em auto; }
.alignwide  { width: 100%; }
.alignfull  { width: 100vw; margin-left: calc(50% - 50vw); }

/* ── WordPress caption ── */
.wp-caption { max-width: 100%; }
.wp-caption-text { font-size: 13px; color: var(--iw-muted); text-align: center; margin-top: 6px; }

/* ── Gallery ── */
.gallery { display: grid; gap: 8px; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); }
.gallery-item img { width: 100%; border-radius: var(--iw-radius-xs); }

/* ── Skip link ── */
.skip-link {
  position: absolute;
  top: -9999px;
  left: 0;
  padding: 8px 16px;
  background: var(--iw-navy);
  color: #fff;
  font-size: 14px;
  font-weight: 600;
  z-index: 9999;
}
.skip-link:focus { top: 0; }
