/* ============================================================
   GINGERBREAD AESTHETIC — treatments.css
   Styles for treatments/index.html and all individual
   treatment sub-pages. Requires foundation.css + style.css.
   ============================================================ */


/* ============================================================
   TREATMENT CARD GRID — overview page
   ============================================================ */

.treatments-overview {
  background-color: var(--ivory);
}

/* 3-column grid, wraps automatically */
.tx-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-6);
}

/* Each card is an <a> tag — whole card is clickable */
.tx-card {
  display: flex;
  flex-direction: column;
  background-color: #fff;
  border: 1px solid var(--color-border-subtle);
  border-radius: var(--radius-lg);
  overflow: hidden;
  text-decoration: none;
  color: inherit;
  transition: transform var(--transition-base),
              box-shadow var(--transition-base),
              border-color var(--transition-base);
}

.tx-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
  border-color: var(--color-border);
}

/* Image area — photo or placeholder */
.tx-card-image {
  position: relative;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  background-color: var(--champagne);
}

.tx-card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
  transition: transform var(--transition-slow);
}

.tx-card:hover .tx-card-image img {
  transform: scale(1.04);
}

/* Placeholder shown until photos are added */
.tx-card-image-placeholder {
  width: 100%;
  height: 100%;
  background: linear-gradient(
    135deg,
    var(--champagne) 0%,
    var(--marble-lt) 100%
  );
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Large treatment number in placeholder */
.tx-card-num {
  font-family: var(--font-heading);
  font-size: 4rem;
  font-weight: var(--weight-bold);
  color: rgba(201, 168, 76, 0.25);
  line-height: 1;
  user-select: none;
}

/* Gold bar that appears at the bottom of image on hover */
.tx-card-image::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 3px;
  background-color: var(--gold);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform var(--transition-base);
}

.tx-card:hover .tx-card-image::after {
  transform: scaleX(1);
}

/* Card body */
.tx-card-body {
  padding: var(--space-6);
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
  flex: 1;
}

/* Title + price row */
.tx-card-header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: var(--space-3);
}

.tx-card-title {
  font-family: var(--font-heading);
  font-size: var(--text-lg);
  font-weight: var(--weight-heading);
  color: var(--espresso);
  line-height: var(--leading-snug);
  margin: 0;
}

.tx-card-price {
  font-family: var(--font-heading);
  font-size: var(--text-base);
  font-weight: var(--weight-bold);
  color: var(--gold);
  white-space: nowrap;
  flex-shrink: 0;
}

.tx-card-desc {
  font-size: var(--text-sm);
  color: var(--text-mid);
  line-height: var(--leading-normal);
  flex: 1;
  max-width: 100%;
}

/* Treatment tags */
.tx-card-tags {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2);
}

.tx-tag {
  font-family: var(--font-body);
  font-size: 0.7rem;
  font-weight: var(--weight-medium);
  letter-spacing: var(--tracking-wide);
  color: var(--gold-dark);
  background-color: var(--champagne);
  padding: 3px var(--space-3);
  border-radius: var(--radius-xl);
  white-space: nowrap;
}

/* "View treatment →" link at bottom of card */
.tx-card-link {
  font-size: var(--text-sm);
  font-weight: var(--weight-medium);
  color: var(--gold);
  letter-spacing: var(--tracking-wide);
  display: inline-block;
  transition: transform var(--transition-fast),
              color var(--transition-fast);
  margin-top: auto;
  padding-top: var(--space-2);
}

.tx-card:hover .tx-card-link {
  transform: translateX(5px);
  color: var(--gold-dark);
}


/* ============================================================
   "NOT SURE?" CTA SECTION — overview page
   ============================================================ */

.tx-help-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-10);
  flex-wrap: wrap;
}

.tx-help-text {
  max-width: 560px;
}

.tx-help-text h2 {
  margin-top: var(--space-2);
}

.tx-help-text p {
  margin-top: var(--space-4);
  color: var(--text-mid);
  font-size: var(--text-sm);
  line-height: var(--leading-normal);
  max-width: 100%;
}

.tx-help-actions {
  display: flex;
  gap: var(--space-4);
  flex-shrink: 0;
  flex-wrap: wrap;
}


/* ============================================================
   INDIVIDUAL TREATMENT PAGE STYLES
   Used by rf-microneedling.html, anti-wrinkle.html etc.
   ============================================================ */

/* Treatment intro — photo left, content right */
.tx-intro-inner {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-16);
  align-items: start;
}

.tx-intro-image {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  aspect-ratio: 3 / 4;
  background: linear-gradient(135deg, var(--champagne), var(--marble-lt));
}

.tx-intro-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* Placeholder image */
.tx-intro-image-placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: var(--space-3);
}

.tx-intro-image-placeholder span {
  font-family: var(--font-heading);
  font-size: var(--text-sm);
  color: var(--marble);
}

.tx-intro-content {
  display: flex;
  flex-direction: column;
  gap: var(--space-5);
  padding-top: var(--space-4);
}

.tx-intro-content h2 {
  margin-top: var(--space-2);
}

.tx-intro-content p {
  color: var(--text-mid);
  line-height: var(--leading-normal);
  max-width: 100%;
}


/* ============================================================
   PRICE TABLE
   Used on individual treatment pages
   ============================================================ */

.tx-price-table {
  width: 100%;
  border-collapse: collapse;
}

.tx-price-table caption {
  font-family: var(--font-body);
  font-size: var(--text-xs);
  font-weight: var(--weight-semibold);
  letter-spacing: var(--tracking-widest);
  text-transform: uppercase;
  color: var(--gold);
  text-align: left;
  padding-bottom: var(--space-4);
}

.tx-price-table th {
  font-family: var(--font-body);
  font-size: var(--text-xs);
  font-weight: var(--weight-semibold);
  letter-spacing: var(--tracking-wider);
  text-transform: uppercase;
  color: var(--text-light);
  text-align: left;
  padding: var(--space-2) var(--space-4) var(--space-3);
  border-bottom: 1px solid var(--color-border);
}

.tx-price-table th:last-child {
  text-align: right;
}

.tx-price-table td {
  padding: var(--space-4);
  border-bottom: 1px solid var(--color-border-subtle);
  vertical-align: top;
}

.tx-price-table tr:last-child td {
  border-bottom: none;
}

.tx-price-table tr:hover td {
  background-color: var(--off-white);
}

.tx-price-name {
  font-family: var(--font-body);
  font-size: var(--text-sm);
  font-weight: var(--weight-medium);
  color: var(--espresso);
}

.tx-price-note {
  font-size: var(--text-xs);
  color: var(--text-light);
  margin-top: var(--space-1);
}

.tx-price-amount {
  font-family: var(--font-heading);
  font-size: var(--text-base);
  font-weight: var(--weight-bold);
  color: var(--gold);
  text-align: right;
  white-space: nowrap;
}


/* ============================================================
   WHAT TO EXPECT — on individual treatment pages
   ============================================================ */

.tx-expect-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-8);
}

.tx-expect-item {
  position: relative;
  padding-top: var(--space-4);
}

.tx-expect-item::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 28px;
  height: 2px;
  background-color: var(--gold);
}

.tx-expect-num {
  font-family: var(--font-heading);
  font-size: 2rem;
  font-weight: var(--weight-bold);
  color: var(--champagne);
  line-height: 1;
  margin-bottom: var(--space-3);
}

.tx-expect-title {
  font-family: var(--font-heading);
  font-size: var(--text-base);
  font-weight: var(--weight-heading);
  color: var(--espresso);
  margin-bottom: var(--space-3);
}

.tx-expect-desc {
  font-size: var(--text-sm);
  color: var(--text-mid);
  line-height: var(--leading-normal);
  max-width: 100%;
}


/* ============================================================
   TREATMENT BREADCRUMB NAV
   e.g. Home > Treatments > RF Microneedling
   ============================================================ */

.tx-breadcrumb {
  padding: var(--space-4) 0 0;
  font-size: var(--text-xs);
  color: var(--text-light);
  display: flex;
  align-items: center;
  gap: var(--space-2);
  flex-wrap: wrap;
}

.tx-breadcrumb a {
  color: var(--text-light);
  text-decoration: none;
  transition: color var(--transition-fast);
}

.tx-breadcrumb a:hover {
  color: var(--gold);
}

.tx-breadcrumb-sep {
  color: var(--color-border);
}

.tx-breadcrumb-current {
  color: var(--gold);
}


/* ============================================================
   RELATED TREATMENTS — bottom of sub-pages
   ============================================================ -->
   ============================================================ */

.tx-related-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-4);
}

.tx-related-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-4);
  padding: var(--space-5);
  background-color: #fff;
  border: 1px solid var(--color-border-subtle);
  border-radius: var(--radius-md);
  text-decoration: none;
  color: inherit;
  transition: background-color var(--transition-fast),
              border-color var(--transition-fast),
              transform var(--transition-fast);
}

.tx-related-item:hover {
  background-color: var(--champagne);
  border-color: var(--color-border);
  transform: translateX(3px);
}

.tx-related-name {
  font-family: var(--font-body);
  font-size: var(--text-sm);
  font-weight: var(--weight-medium);
  color: var(--espresso);
}

.tx-related-price {
  font-family: var(--font-heading);
  font-size: var(--text-sm);
  font-weight: var(--weight-bold);
  color: var(--gold);
  white-space: nowrap;
  flex-shrink: 0;
}


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

@media (max-width: 1024px) {

  /* 2-column grid on tablet */
  .tx-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  /* Treatment intro stacks */
  .tx-intro-inner {
    grid-template-columns: 1fr;
    gap: var(--space-10);
  }

  .tx-intro-image {
    aspect-ratio: 16 / 9;
    max-height: 400px;
  }

  /* Expect: 2 columns on tablet */
  .tx-expect-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  /* Related: 2 columns */
  .tx-related-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  /* Help CTA stacks */
  .tx-help-inner {
    flex-direction: column;
  }

  .tx-help-actions {
    width: 100%;
  }

}

@media (max-width: 640px) {

  /* 1-column grid on mobile */
  .tx-grid {
    grid-template-columns: 1fr;
  }

  /* Expect: 1 column */
  .tx-expect-grid {
    grid-template-columns: 1fr;
  }

  /* Related: 1 column */
  .tx-related-grid {
    grid-template-columns: 1fr;
  }

  /* Card image shorter on mobile */
  .tx-card-image {
    aspect-ratio: 16 / 9;
  }

  .tx-help-actions {
    flex-direction: column;
  }

  .tx-help-actions .btn {
    width: 100%;
    justify-content: center;
  }

}
