/* =============================================================
   BASE STYLES — PepShop
   Modern minimal reset + document defaults.
   No component or section rules here — only global foundations.
   ============================================================= */

/* -----------------------------------------------------------
   BOX MODEL RESET
   ----------------------------------------------------------- */
*,
*::before,
*::after {
  box-sizing: border-box;
}

/* -----------------------------------------------------------
   MARGIN / PADDING RESET
   ----------------------------------------------------------- */
html,
body,
h1, h2, h3, h4, h5, h6,
p,
ul, ol, li,
figure, figcaption,
blockquote,
dl, dd,
fieldset, legend {
  margin: 0;
  padding: 0;
}

/* -----------------------------------------------------------
   LIST RESET (applied per component where needed)
   ----------------------------------------------------------- */
ul, ol {
  list-style: none;
}

/* -----------------------------------------------------------
   MEDIA
   ----------------------------------------------------------- */
img,
video,
svg {
  display: block;
  max-width: 100%;
}

/* -----------------------------------------------------------
   INHERIT FONTS IN FORM ELEMENTS
   ----------------------------------------------------------- */
button,
input,
select,
textarea {
  font: inherit;
}

/* -----------------------------------------------------------
   DOCUMENT ROOT
   ----------------------------------------------------------- */
html {
  font-size: 100%; /* 16px base; do not change — preserves user preferences */
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

/* -----------------------------------------------------------
   BODY DEFAULTS
   ----------------------------------------------------------- */
body {
  background-color: var(--color-surface);
  color: var(--color-text-primary);
  font-family: var(--font-sans);
  font-size: var(--fs-body);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* -----------------------------------------------------------
   HEADINGS
   Sentence case enforced in brand voice; weight/line-height here.
   ----------------------------------------------------------- */
h1 {
  font-size: var(--fs-h1);
  font-weight: 700;
  line-height: 1.15;
}

h2 {
  font-size: var(--fs-h2);
  font-weight: 700;
  line-height: 1.2;
}

h3 {
  font-size: var(--fs-h3);
  font-weight: 600;
  line-height: 1.3;
}

h4, h5, h6 {
  font-weight: 600;
  line-height: 1.4;
}

/* Mobile heading scale */
@media (max-width: 767px) {
  h1 { font-size: var(--fs-h1-mobile); }
  h2 { font-size: var(--fs-h2-mobile); }
  h3 { font-size: var(--fs-h3-mobile); }
}

/* -----------------------------------------------------------
   BODY COPY VARIANTS
   ----------------------------------------------------------- */
p {
  line-height: 1.5;
}

small {
  font-size: var(--fs-body-sm);
}

/* -----------------------------------------------------------
   MONOSPACE / NUMERICAL DATA CLASS
   Use on purity %, lot numbers, COA codes, prices.
   ----------------------------------------------------------- */
.mono {
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
}

/* -----------------------------------------------------------
   LINKS — base style
   Section agents may override for their context.
   ----------------------------------------------------------- */
a {
  color: inherit;
  text-decoration: underline;
  text-underline-offset: 2px;
}

a:hover {
  text-decoration-color: var(--color-accent);
}

/* -----------------------------------------------------------
   FOCUS VISIBLE — accessible keyboard navigation
   ----------------------------------------------------------- */
:focus-visible {
  outline: 2px solid var(--color-accent);
  outline-offset: 2px;
}

/* Remove default focus ring for mouse users */
:focus:not(:focus-visible) {
  outline: none;
}

/* -----------------------------------------------------------
   CONTAINER UTILITY
   Centered, max-width content wrapper.
   ----------------------------------------------------------- */
.container {
  max-width: var(--max-content);
  margin-inline: auto;
  padding-inline: var(--space-6); /* 24px */
}

/* -----------------------------------------------------------
   SECTION PADDING UTILITY
   Applied to every top-level section element.
   ----------------------------------------------------------- */
.section {
  padding-block: var(--space-20); /* 80px desktop */
}

@media (max-width: 767px) {
  .section {
    padding-block: var(--space-14); /* 56px mobile */
  }
}

@media (max-width: 399px) {
  .section {
    padding-block: var(--space-10); /* 40px on very small phones */
  }
}

/* -----------------------------------------------------------
   SCREEN READER ONLY
   Visually hidden but accessible to assistive technology.
   ----------------------------------------------------------- */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border-width: 0;
}

/* -----------------------------------------------------------
   TEXT WIDTH UTILITIES
   Enforce readable line lengths (60–75 characters).
   ----------------------------------------------------------- */
.text-narrow {
  max-width: var(--max-text);   /* 680px */
}

.text-narrower {
  max-width: var(--max-narrow); /* 580px */
}

/* -----------------------------------------------------------
   HORIZONTAL RULE
   ----------------------------------------------------------- */
hr {
  border: none;
  border-top: 1px solid var(--color-border);
}
