/* ============================================================
   _modules/modules.css — Sajūtu Terapija
   Reusable layout + component primitives
   ============================================================ */

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

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

body {
  background-color: var(--color-bg);
  color: var(--color-text);
  font-family: var(--font-body);
  font-size: var(--fs-16);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

img, video { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { cursor: pointer; border: none; background: none; font: inherit; }

/* --- Container -------------------------------------------- */
.container {
  width: 100%;
  max-width: var(--max-w);
  margin-inline: auto;
  padding-inline: clamp(1.25rem, 5vw, 4rem);
}

.container--narrow {
  max-width: var(--max-w-narrow);
  margin-inline: auto;
  padding-inline: clamp(1.25rem, 5vw, 4rem);
}

/* --- Section rhythm --------------------------------------- */
.section {
  padding-block: var(--s-24);
}

.section--alt {
  background-color: var(--color-bg-alt);
}

/* --- Eyebrow label --------------------------------------- */
.eyebrow {
  display: inline-block;
  font-family: var(--font-body);
  font-size: var(--fs-12);
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--color-accent);
  margin-bottom: var(--s-3);
}

/* --- Divider line ---------------------------------------- */
.divider {
  width: 2.5rem;
  height: 1px;
  background-color: var(--color-accent);
  margin-block: var(--s-6);
  opacity: 0.5;
}

.divider--center {
  margin-inline: auto;
}

/* --- Button primitives ----------------------------------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.85rem 2rem;
  border-radius: 2px;
  font-family: var(--font-body);
  font-size: var(--fs-14);
  font-weight: 500;
  letter-spacing: 0.04em;
  transition: all 0.25s ease;
  white-space: nowrap;
}

.btn--primary {
  background-color: var(--color-accent);
  color: #F5EFE6;
}

.btn--primary:hover {
  background-color: #2e5540;
  transform: translateY(-1px);
  box-shadow: 0 4px 16px rgba(59, 107, 78, 0.25);
}

.btn--ghost {
  background-color: transparent;
  color: var(--color-text);
  border: 1px solid var(--color-border);
}

.btn--ghost:hover {
  border-color: var(--color-accent);
  color: var(--color-accent);
}

/* --- Card ------------------------------------------------ */
.card {
  background-color: var(--color-card);
  border: 1px solid var(--color-border);
  border-radius: 3px;
  padding: clamp(1.5rem, 3vw, 2.5rem);
}

/* --- Grid helpers ---------------------------------------- */
.grid-2 {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: clamp(1.5rem, 3vw, 3rem);
}

.grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: clamp(1.5rem, 3vw, 2.5rem);
}

@media (max-width: 900px) {
  .grid-2 { grid-template-columns: 1fr; }
  .grid-3 { grid-template-columns: 1fr; }
}

@media (min-width: 640px) and (max-width: 900px) {
  .grid-3 { grid-template-columns: repeat(2, 1fr); }
}

/* --- Text helpers ---------------------------------------- */
.text-center { text-align: center; }
.text-muted { color: var(--color-muted); }

/* --- Overflow hidden for clip animations ----------------- */
.overflow-hidden { overflow: hidden; }

/* --- Reveal animation base (JS-driven) ------------------- */
.reveal {
  opacity: 0;
  transform: translateY(24px);
}

/* --- Horizontal rule ------------------------------------- */
hr.section-rule {
  border: none;
  border-top: var(--line);
  margin-block: 0;
}

/* --- Accessible focus ------------------------------------ */
:focus-visible {
  outline: 2px solid var(--color-accent);
  outline-offset: 3px;
  border-radius: 2px;
}
