/* =============================================
   TARUGITOS — Layout
   Phase 1
   ============================================= */

/* === BASE PAGE STRUCTURE === */
body {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

main {
  flex: 1;
}

/* === CONTAINER === */
.container {
  width: 100%;
  max-width: var(--container-max);
  margin-inline: auto;
  padding-inline: var(--section-pad-x);
}

.container--wide {
  max-width: var(--container-wide);
}

/* === SECTION BASE === */
.section {
  padding-block: var(--section-pad-y);
}

.section--sm {
  padding-block: var(--space-10);
}

.section--lg {
  padding-block: calc(var(--section-pad-y) * 1.5);
}

/* Background variants */
.section--cream  { background-color: var(--cream); }
.section--white  { background-color: var(--white); }
.section--black  { background-color: var(--black); }
.section--dark   { background-color: var(--black-soft); }

/* === GRID UTILITIES === */
.grid {
  display: grid;
  gap: var(--space-4);
}

.grid--2 { grid-template-columns: repeat(2, 1fr); }
.grid--3 { grid-template-columns: repeat(3, 1fr); }
.grid--4 { grid-template-columns: repeat(4, 1fr); }

@media (min-width: 768px) {
  .grid--2-md { grid-template-columns: repeat(2, 1fr); }
  .grid--3-md { grid-template-columns: repeat(3, 1fr); }
  .grid--4-md { grid-template-columns: repeat(4, 1fr); }
}

/* === FLEX UTILITIES === */
.flex         { display: flex; }
.flex-col     { flex-direction: column; }
.flex-wrap    { flex-wrap: wrap; }
.items-center { align-items: center; }
.items-start  { align-items: flex-start; }
.justify-center   { justify-content: center; }
.justify-between  { justify-content: space-between; }
.justify-end      { justify-content: flex-end; }
.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 UTILITIES === */
.text-center { text-align: center; }
.text-left   { text-align: left; }
.text-right  { text-align: right; }

.text-pink   { color: var(--pink); }
.text-yellow { color: var(--yellow); }
.text-white  { color: var(--white); }
.text-black  { color: var(--black); }
.text-gray   { color: var(--gray-text); }

/* === SECTION HEADER === */
.section-header {
  text-align: center;
  margin-bottom: var(--space-10);
}

.section-title {
  font-family: var(--font-display);
  font-size: clamp(var(--text-3xl), 6vw, var(--text-5xl));
  color: var(--black);
  letter-spacing: 0.03em;
  line-height: 1;
}

.section-title .accent {
  color: var(--pink);
}

.section-subtitle {
  font-family: var(--font-body);
  font-size: var(--text-base);
  color: var(--gray-text);
  margin-top: var(--space-2);
  font-weight: 400;
}

/* === DECORATIVE DIVIDERS === */
.wavy-divider {
  width: 100%;
  overflow: hidden;
  line-height: 0;
}

.wavy-divider svg {
  display: block;
  width: 100%;
  height: 48px;
}

/* === SCROLL HELPERS === */
.scroll-x {
  overflow-x: auto;
  scrollbar-width: none;
  -ms-overflow-style: none;
  -webkit-overflow-scrolling: touch;
}

.scroll-x::-webkit-scrollbar {
  display: none;
}

/* === VISIBILITY === */
.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;
}

@media (min-width: 768px) {
  .hide-md { display: none; }
}

@media (max-width: 767px) {
  .show-md { display: none; }
}
