/**
 * Mac Angelo — Services Hub Page Styles
 * Covers: page-services.php (S1 hero, sticky tab nav, category sections, service cards)
 *
 * @package mac-angelo-child
 * @version 1.0.0
 */

/* ============================================================
   S1 — HERO
   ============================================================ */

.ma-sh-hero {
  background: var(--ma-offwhite, #F9F9F6);
  padding: clamp(52px, 7vw, 80px) 0 clamp(40px, 5vw, 60px);
  position: relative;
  overflow: hidden;
}

.ma-sh-hero__geo-tl,
.ma-sh-hero__geo-br {
  position: absolute;
  pointer-events: none;
}
.ma-sh-hero__geo-tl {
  top: 0; left: 0;
  width: clamp(180px, 22vw, 360px);
  height: clamp(120px, 15vw, 240px);
  background: linear-gradient(135deg, rgba(201,168,76,0.08) 0%, transparent 70%);
  clip-path: polygon(0 0, 100% 0, 0 100%);
}
.ma-sh-hero__geo-br {
  bottom: 0; right: 0;
  width: clamp(160px, 18vw, 280px);
  height: clamp(100px, 12vw, 200px);
  background: linear-gradient(315deg, rgba(107,63,160,0.06) 0%, transparent 70%);
  clip-path: polygon(100% 0, 100% 100%, 0 100%);
}

.ma-sh-hero__inner {
  max-width: var(--ma-max-w, 1280px);
  margin-inline: auto;
  padding-inline: var(--ma-pad-x, clamp(24px, 5vw, 80px));
  position: relative;
  z-index: 1;
}

.ma-sh-hero__headline {
  font-family: 'Space Grotesk', sans-serif;
  font-size: clamp(32px, 5vw, 56px);
  font-weight: 800;
  line-height: 1.1;
  letter-spacing: -0.02em;
  color: var(--ma-text, #0A0A0A);
  margin: 0 0 20px;
}

.ma-sh-hero__sub {
  font-family: 'DM Sans', sans-serif;
  font-size: clamp(16px, 2vw, 18px);
  line-height: 1.65;
  color: var(--ma-muted, #4A4A4A);
  margin: 0 0 36px;
  max-width: 640px;
}

.ma-sh-hero__meta {
  display: flex;
  align-items: center;
  gap: 20px;
  flex-wrap: wrap;
}

.ma-sh-hero__stat {
  font-family: 'DM Sans', sans-serif;
  font-size: 14px;
  color: var(--ma-muted, #4A4A4A);
}
.ma-sh-hero__stat strong {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 20px;
  font-weight: 800;
  color: var(--ma-gold, #C9A84C);
  margin-right: 4px;
}

.ma-sh-hero__divider {
  display: inline-block;
  width: 1px;
  height: 20px;
  background: var(--ma-border-light, rgba(0,0,0,0.10));
}


/* ============================================================
   STICKY CATEGORY TAB NAV
   ============================================================ */

.ma-sh-tabs {
  position: sticky;
  top: var(--ma-header-h, 68px);
  z-index: 490;
  background: #FFFFFF;
  border-bottom: 1px solid var(--ma-border-light, rgba(0,0,0,0.07));
  box-shadow: 0 2px 16px rgba(0,0,0,0.04);
}

.ma-sh-tabs__inner {
  max-width: var(--ma-max-w, 1280px);
  margin-inline: auto;
  padding-inline: var(--ma-pad-x, clamp(24px, 5vw, 80px));
  display: flex;
  align-items: stretch;
  gap: 0;
  overflow-x: auto;
  scrollbar-width: none;
  -ms-overflow-style: none;
}
.ma-sh-tabs__inner::-webkit-scrollbar { display: none; }

.ma-sh-tab {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: 'DM Sans', sans-serif;
  font-size: 14px;
  font-weight: 600;
  color: var(--ma-muted, #4A4A4A);
  background: transparent;
  border: none;
  border-bottom: 2px solid transparent;
  padding: 16px 20px;
  cursor: pointer;
  white-space: nowrap;
  transition: color 0.2s ease, border-color 0.2s ease;
  flex-shrink: 0;
}

.ma-sh-tab:hover {
  color: var(--ma-text, #0A0A0A);
}

.ma-sh-tab--active {
  color: var(--ma-text, #0A0A0A);
  border-bottom-color: var(--tab-color, #C9A84C);
}

.ma-sh-tab__count {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 20px;
  height: 20px;
  padding: 0 6px;
  border-radius: 10px;
  background: var(--ma-offwhite, #F9F9F6);
  font-size: 11px;
  font-weight: 700;
  color: var(--ma-subtle, #A8A8A0);
  transition: background 0.2s, color 0.2s;
}

.ma-sh-tab--active .ma-sh-tab__count {
  background: var(--tab-color, #C9A84C);
  color: #FFFFFF;
}


/* ============================================================
   S2 — CATEGORY SECTIONS
   ============================================================ */

.ma-sh-sections {
  background: #FFFFFF;
}

.ma-sh-section {
  padding: clamp(48px, 6vw, 72px) 0;
  border-bottom: 1px solid var(--ma-border-light, rgba(0,0,0,0.06));
}

.ma-sh-section:last-child { border-bottom: none; }

/* Alternate section backgrounds for visual rhythm */
.ma-sh-section:nth-child(even) {
  background: var(--ma-offwhite, #F9F9F6);
}

.ma-sh-section__inner {
  max-width: var(--ma-max-w, 1280px);
  margin-inline: auto;
  padding-inline: var(--ma-pad-x, clamp(24px, 5vw, 80px));
}

/* Category header row */
.ma-sh-section__header {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 32px;
  padding-bottom: 24px;
  border-bottom: 1px solid var(--ma-border-light, rgba(0,0,0,0.06));
}

.ma-sh-section__header-left {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.ma-sh-cat-badge {
  display: inline-flex;
  align-items: center;
  font-family: 'DM Sans', sans-serif;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.10em;
  text-transform: uppercase;
  padding: 4px 12px;
  border-radius: 4px;
  width: fit-content;
}

.ma-sh-section__heading {
  font-family: 'Space Grotesk', sans-serif;
  font-size: clamp(22px, 3vw, 30px);
  font-weight: 700;
  color: var(--ma-text, #0A0A0A);
  margin: 0;
  line-height: 1.2;
}

.ma-sh-section__count {
  font-family: 'DM Sans', sans-serif;
  font-size: 13px;
  font-weight: 500;
  color: var(--ma-subtle, #A8A8A0);
  white-space: nowrap;
  padding-bottom: 4px;
}


/* ============================================================
   SERVICE CARDS
   ============================================================ */

.ma-sh-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

.ma-sh-card {
  background: #FFFFFF;
  border: 1px solid var(--ma-border-light, rgba(0,0,0,0.07));
  border-radius: 14px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: box-shadow 0.22s ease, transform 0.22s ease, border-color 0.22s ease;
}

/* Even sections have offwhite bg, so invert card bg */
.ma-sh-section:nth-child(even) .ma-sh-card {
  background: #FFFFFF;
}

.ma-sh-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 32px rgba(0,0,0,0.09);
  border-color: var(--card-accent, rgba(201,168,76,0.30));
}

/* Top accent line */
.ma-sh-card__accent {
  height: 3px;
  width: 100%;
  flex-shrink: 0;
  opacity: 0.75;
}

.ma-sh-card__body {
  padding: 24px 24px 16px;
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.ma-sh-card__title {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 17px;
  font-weight: 700;
  color: var(--ma-text, #0A0A0A);
  margin: 0;
  line-height: 1.3;
}

.ma-sh-card__title-link {
  color: inherit;
  text-decoration: none;
  transition: color 0.2s;
}
.ma-sh-card__title-link:hover {
  color: var(--card-accent, #C9A84C);
}

.ma-sh-card__tagline {
  font-family: 'Inter', sans-serif;
  font-size: 13.5px;
  line-height: 1.6;
  color: var(--ma-muted, #4A4A4A);
  margin: 0;
}

.ma-sh-card__tagline--placeholder {
  color: var(--ma-subtle, #A8A8A0);
  font-style: italic;
}

.ma-sh-card__footer {
  padding: 14px 24px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-top: 1px solid var(--ma-border-light, rgba(0,0,0,0.06));
  margin-top: auto;
}

.ma-sh-card__pricing {
  font-family: 'DM Sans', sans-serif;
  font-size: 12px;
  font-weight: 500;
  color: var(--ma-subtle, #A8A8A0);
}

.ma-sh-card__link {
  font-family: 'DM Sans', sans-serif;
  font-size: 13px;
  font-weight: 700;
  text-decoration: none;
  transition: opacity 0.2s;
}
.ma-sh-card__link:hover { opacity: 0.75; }


/* ============================================================
   RESPONSIVE
   ============================================================ */

@media (max-width: 1024px) {
  .ma-sh-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 768px) {
  .ma-sh-grid { grid-template-columns: 1fr; }

  .ma-sh-section__header {
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
  }

  .ma-sh-hero__inner {
    max-width: 100%;
  }

  .ma-sh-hero__headline br { display: none; }
}

@media (max-width: 480px) {
  .ma-sh-tab { padding: 14px 14px; font-size: 13px; }
  .ma-sh-tab__count { display: none; }
}
