/* ============================================================
   UTILITIES.CSS — Golfakademi
   Hjälpklasser för snabb styling
   Mobile first
   ============================================================ */

/* ============================================================
   DISPLAY
   ============================================================ */

.d-none     { display: none; }
.d-block    { display: block; }
.d-flex     { display: flex; }
.d-grid     { display: grid; }
.d-inline   { display: inline; }

@media (min-width: 600px) {
  .d-tablet-none  { display: none; }
  .d-tablet-block { display: block; }
  .d-tablet-flex  { display: flex; }
}

@media (min-width: 1024px) {
  .d-desktop-none  { display: none; }
  .d-desktop-block { display: block; }
  .d-desktop-flex  { display: flex; }
}

/* ============================================================
   FLEXBOX
   ============================================================ */

.flex-row     { flex-direction: row; }
.flex-col     { flex-direction: column; }
.flex-wrap    { flex-wrap: wrap; }
.flex-nowrap  { flex-wrap: nowrap; }
.flex-1       { flex: 1; }

.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-end      { justify-content: flex-end; }
.justify-between  { justify-content: space-between; }

/* 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-6  { gap: var(--space-6); }
.gap-8  { gap: var(--space-8); }

/* ============================================================
   TEXT
   ============================================================ */

.text-left    { text-align: left; }
.text-center  { text-align: center; }
.text-right   { text-align: right; }

.text-xs    { font-size: var(--text-xs); }
.text-sm    { font-size: var(--text-sm); }
.text-base  { font-size: var(--text-base); }
.text-md    { font-size: var(--text-md); }
.text-lg    { font-size: var(--text-lg); }
.text-xl    { font-size: var(--text-xl); }
.text-2xl   { font-size: var(--text-2xl); }

.font-light    { font-weight: 300; }
.font-normal   { font-weight: 400; }
.font-medium   { font-weight: 500; }
.font-semibold { font-weight: 600; }
.font-bold     { font-weight: 700; }

.font-display { font-family: var(--font-display); }
.font-body    { font-family: var(--font-body); }

.uppercase  { text-transform: uppercase; }
.lowercase  { text-transform: lowercase; }
.capitalize { text-transform: capitalize; }

.tracking-wide  { letter-spacing: 0.05em; }
.tracking-wider { letter-spacing: 0.1em; }

/* ============================================================
   FÄRGER
   ============================================================ */

.text-primary   { color: var(--text-primary); }
.text-secondary { color: var(--text-secondary); }
.text-inverted  { color: var(--text-inverted); }
.text-gold      { color: var(--color-gold); }
.text-green     { color: var(--color-green); }
.text-white     { color: var(--color-white); }

.bg-dark       { background-color: var(--color-dark); }
.bg-white      { background-color: var(--color-white); }
.bg-off-white  { background-color: var(--color-off-white); }
.bg-gold       { background-color: var(--color-gold); }
.bg-green      { background-color: var(--color-green); }

/* ============================================================
   SPACING — MARGIN
   ============================================================ */

.m-0  { margin: 0; }
.m-auto { margin: auto; }

.mt-1  { margin-top: var(--space-1); }
.mt-2  { margin-top: var(--space-2); }
.mt-3  { margin-top: var(--space-3); }
.mt-4  { margin-top: var(--space-4); }
.mt-6  { margin-top: var(--space-6); }
.mt-8  { margin-top: var(--space-8); }
.mt-12 { margin-top: var(--space-12); }

.mb-1  { margin-bottom: var(--space-1); }
.mb-2  { margin-bottom: var(--space-2); }
.mb-3  { margin-bottom: var(--space-3); }
.mb-4  { margin-bottom: var(--space-4); }
.mb-6  { margin-bottom: var(--space-6); }
.mb-8  { margin-bottom: var(--space-8); }
.mb-12 { margin-bottom: var(--space-12); }

.ml-auto { margin-left: auto; }
.mr-auto { margin-right: auto; }
.mx-auto { margin-left: auto; margin-right: auto; }

/* ============================================================
   SPACING — PADDING
   ============================================================ */

.p-0  { padding: 0; }
.p-2  { padding: var(--space-2); }
.p-4  { padding: var(--space-4); }
.p-6  { padding: var(--space-6); }
.p-8  { padding: var(--space-8); }

.pt-4  { padding-top: var(--space-4); }
.pb-4  { padding-bottom: var(--space-4); }
.px-4  { padding-left: var(--space-4); padding-right: var(--space-4); }
.py-4  { padding-top: var(--space-4); padding-bottom: var(--space-4); }

.px-6  { padding-left: var(--space-6); padding-right: var(--space-6); }
.py-6  { padding-top: var(--space-6); padding-bottom: var(--space-6); }

/* ============================================================
   BORDER & RADIUS
   ============================================================ */

.rounded-sm   { border-radius: var(--radius-sm); }
.rounded-md   { border-radius: var(--radius-md); }
.rounded-lg   { border-radius: var(--radius-lg); }
.rounded-xl   { border-radius: var(--radius-xl); }
.rounded-pill { border-radius: var(--radius-pill); }
.rounded-full { border-radius: 50%; }

.border       { border: 1px solid rgba(30,26,20,0.1); }
.border-gold  { border: 1px solid var(--color-gold); }

/* ============================================================
   SKUGGOR
   ============================================================ */

.shadow-sm { box-shadow: var(--shadow-sm); }
.shadow-md { box-shadow: var(--shadow-md); }
.shadow-lg { box-shadow: var(--shadow-lg); }
.shadow-xl { box-shadow: var(--shadow-xl); }

/* ============================================================
   BILDER
   ============================================================ */

.img-cover {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.img-contain {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.img-round {
  border-radius: 50%;
}

/* ============================================================
   TILLGÄNGLIGHET
   ============================================================ */

.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;
}

/* ============================================================
   ÖVRIGT
   ============================================================ */

.w-full  { width: 100%; }
.h-full  { height: 100%; }
.min-h-screen { min-height: 100vh; }

.overflow-hidden { overflow: hidden; }
.overflow-auto   { overflow: auto; }

.cursor-pointer { cursor: pointer; }

.transition { transition: all var(--transition-base); }

.truncate {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}