/* ==========================================================================
   utilities.css — Helper Classes
   Bankenveld Golf Estate
   Single-purpose utilities: display, flex, grid, spacing, text, containers,
   visibility. Keep atomic — no component-specific rules here.
   ========================================================================== */

/* --------------------------------------------------------------------------
   DISPLAY
   -------------------------------------------------------------------------- */
.block   { display: block; }
.inline  { display: inline; }
.inline-block { display: inline-block; }
.hidden  { display: none !important; }
.contents { display: contents; }

/* --------------------------------------------------------------------------
   FLEX
   -------------------------------------------------------------------------- */
.flex        { display: flex; }
.inline-flex { display: inline-flex; }
.flex-col    { flex-direction: column; }
.flex-wrap   { flex-wrap: wrap; }
.flex-1      { flex: 1 1 0%; }
.items-start   { align-items: flex-start; }
.items-center  { align-items: center; }
.items-end     { align-items: flex-end; }
.justify-start   { justify-content: flex-start; }
.justify-center  { justify-content: center; }
.justify-between { justify-content: space-between; }
.justify-end     { justify-content: flex-end; }

/* --------------------------------------------------------------------------
   GRID
   -------------------------------------------------------------------------- */
.grid       { display: grid; }
.grid-2     { grid-template-columns: repeat(2, 1fr); }
.grid-3     { grid-template-columns: repeat(3, 1fr); }
.grid-4     { grid-template-columns: repeat(4, 1fr); }
.grid-auto  { grid-template-columns: repeat(auto-fit, minmax(min(100%, 16rem), 1fr)); }
.place-center { place-items: center; }
.col-span-full { grid-column: 1 / -1; }

/* --------------------------------------------------------------------------
   GAP
   -------------------------------------------------------------------------- */
.gap-1 { gap: var(--space-1); }
.gap-2 { gap: var(--space-2); }
.gap-3 { gap: var(--space-3); }
.gap-4 { gap: var(--space-4); }
.gap-5 { gap: var(--space-5); }
.gap-6 { gap: var(--space-6); }
.gap-8 { gap: var(--space-8); }

/* --------------------------------------------------------------------------
   SPACING — margin / padding (t r b l + axis)
   -------------------------------------------------------------------------- */
.m-0 { margin: 0; }        .p-0 { padding: 0; }
.mt-2 { margin-top: var(--space-2); }   .mt-4 { margin-top: var(--space-4); }   .mt-6 { margin-top: var(--space-6); }   .mt-8 { margin-top: var(--space-8); }
.mb-2 { margin-bottom: var(--space-2); } .mb-4 { margin-bottom: var(--space-4); } .mb-6 { margin-bottom: var(--space-6); } .mb-8 { margin-bottom: var(--space-8); }
.mx-auto { margin-inline: auto; }
.my-0 { margin-block: 0; }
.pt-4 { padding-top: var(--space-4); }   .pb-4 { padding-bottom: var(--space-4); }
.p-4 { padding: var(--space-4); }        .p-6 { padding: var(--space-6); }       .p-8 { padding: var(--space-8); }

/* --------------------------------------------------------------------------
   CONTAINERS / WIDTH
   -------------------------------------------------------------------------- */
.w-full   { width: 100%; }
.max-w-prose  { max-width: 68ch; }
.max-w-narrow { max-width: var(--container-narrow); }
.mx-auto-narrow { max-width: var(--container-narrow); margin-inline: auto; }

/* --------------------------------------------------------------------------
   TEXT
   -------------------------------------------------------------------------- */
.text-left   { text-align: left; }
.text-center { text-align: center; }
.text-right  { text-align: right; }
.text-balance { text-wrap: balance; }
.text-pretty  { text-wrap: pretty; }
.uppercase   { text-transform: uppercase; letter-spacing: var(--ls-wide); }
.font-heading { font-family: var(--font-heading); }
.font-body    { font-family: var(--font-body); }
.fw-light    { font-weight: var(--fw-light); }
.fw-medium   { font-weight: var(--fw-medium); }
.fw-semibold { font-weight: var(--fw-semibold); }
.fw-bold     { font-weight: var(--fw-bold); }
.text-muted  { color: var(--color-text-muted); }
.text-accent { color: var(--color-accent-dark); }
.text-inverse { color: var(--color-text-inverse); }

/* --------------------------------------------------------------------------
   SURFACE / RADIUS / SHADOW
   -------------------------------------------------------------------------- */
.rounded    { border-radius: var(--radius-md); }
.rounded-lg { border-radius: var(--radius-lg); }
.rounded-pill { border-radius: var(--radius-pill); }
.shadow    { box-shadow: var(--shadow-md); }
.shadow-lg { box-shadow: var(--shadow-lg); }
.bg-surface { background: var(--color-surface); }
.bg-primary { background: var(--color-primary); color: var(--color-text-inverse); }
.glass {
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  -webkit-backdrop-filter: blur(var(--glass-blur)) saturate(var(--glass-saturate));
  backdrop-filter: blur(var(--glass-blur)) saturate(var(--glass-saturate));
}

/* --------------------------------------------------------------------------
   POSITION / OVERFLOW
   -------------------------------------------------------------------------- */
.relative { position: relative; }
.absolute { position: absolute; }
.fixed    { position: fixed; }
.inset-0  { inset: 0; }
.overflow-hidden { overflow: hidden; }
.overflow-x-auto { overflow-x: auto; }
.z-raised { z-index: var(--z-raised); }

/* --------------------------------------------------------------------------
   RESPONSIVE VISIBILITY
   -------------------------------------------------------------------------- */
.show-mobile { display: block; }
.show-desktop { display: none; }
@media (min-width: 1024px) {
  .show-mobile { display: none; }
  .show-desktop { display: block; }
}

/* --------------------------------------------------------------------------
   ACCESSIBILITY
   -------------------------------------------------------------------------- */
.sr-only {
  position: absolute !important;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0);
  white-space: nowrap; border: 0;
}
.no-scroll { overflow: hidden !important; } /* toggled when menu/lightbox open */
