﻿/* ==========================================================================
   polish.css - our layer, loaded after site.css and brand.css.
   Kept deliberately small: this file starts with the type system and the hero
   scrim only. Anything else gets added section by section.
   ========================================================================== */

:root {
  /* next/font exposes these on <html> (see app/src/app/layout.tsx). */
  --font-display: var(--font-lora), "Noto Serif Ethiopic", Georgia, "Times New Roman", serif;
  --font-body: var(--font-inter), "Noto Sans Ethiopic", system-ui, -apple-system, "Segoe UI", Arial, sans-serif;
}

/* ---------------------------------------------------------------- type ---- */
/* body: the template asked for a webfont it never shipped, so this was Arial. */
body {
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.6;
  letter-spacing: 0;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

h1, h2, h3, h4, h5, h6,
.heading,
.heading-custom-h1,
.heading-custom-h2,
.heading-custom-h3,
.heading-custom-h4,
.heading-custom-h5,
.heading-custom-h6,
.hero-text-split {
  font-family: var(--font-display);
  font-weight: 500;
  letter-spacing: -0.01em;
  text-wrap: balance;
}

/* H1 - hero and page titles */
h1,
.heading-custom-h1,
.hero-text-split {
  font-size: clamp(40px, 4.6vw, 64px);
  line-height: 1.05;
  letter-spacing: -0.01em;
}

/* H2 - section titles */
h2,
.heading-custom-h2 {
  font-size: clamp(32px, 3.3vw, 44px);
  line-height: 1.1;
  letter-spacing: -0.01em;
}

/* H3 - card titles stay sans for contrast with the serif headlines */
h3,
.heading-custom-h3 {
  font-family: var(--font-body);
  font-size: clamp(18px, 1.5vw, 20px);
  font-weight: 600;
  line-height: 1.3;
  letter-spacing: 0;
}

h4, .heading-custom-h4 { font-size: clamp(20px, 1.9vw, 26px); line-height: 1.2; }
h5, .heading-custom-h5 { font-size: 20px; line-height: 1.3; }
h6, .heading-custom-h6 { font-size: 18px; line-height: 1.3; }

/* ----------------------------------------------------------- hero scrim ---- */
/* The imported wash runs at 157deg and turns fully opaque teal towards the
   bottom, so the headline sat on a bright window and the copy below was on a
   flat slab. This is the same idea, but light: dark where the text is, clear
   across the photo. */
.hero_overlay.is-gradient {
  background-image:
    linear-gradient(90deg, rgba(6, 48, 47, .82) 0%, rgba(6, 48, 47, .58) 38%, rgba(6, 48, 47, .18) 66%, rgba(6, 48, 47, 0) 88%),
    linear-gradient(180deg, rgba(6, 48, 47, .34) 0%, rgba(6, 48, 47, 0) 38%);
}

@media screen and (max-width: 991px) {
  /* Phones: the copy sits across the whole width, so the scrim is vertical. */
  .hero_overlay.is-gradient {
    background-image: linear-gradient(
      180deg,
      rgba(6, 48, 47, .82) 0%,
      rgba(6, 48, 47, .66) 26%,
      rgba(6, 48, 47, .34) 52%,
      rgba(6, 48, 47, .55) 78%,
      rgba(6, 48, 47, .82) 100%
    );
  }
}
/* -------------------------------------------------------- transformations ---- */
/* Three comparison cards per row (two on tablets, one on phones). Each card is
   a drag comparison; the row snap-scrolls in pages when there are more cases
   than fit. Cards stay at the template's 4:3 so they never dominate the page. */
.section_transform {
  background: linear-gradient(180deg, #ffffff 0%, var(--neutral-25) 100%);
}

.section_transform > .section-padding {
  padding-top: clamp(56px, 6vw, 88px);
  padding-bottom: clamp(56px, 6vw, 88px);
}

.ba_header {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: clamp(20px, 3vw, 48px);
  margin-bottom: clamp(24px, 3vw, 40px);
}

.ba_header-content {
  max-width: 680px;
}

.ba_lead {
  margin-top: 12px;
  max-width: 58ch;
  color: var(--neutral-600);
  font-size: 16px;
  line-height: 1.6;
}

.ba_row {
  --ba-gap: 24px;
  position: relative;
}

.ba_track {
  display: flex;
  gap: var(--ba-gap);
  overflow-x: auto;
  overscroll-behavior-x: contain;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  scrollbar-width: none;
  -ms-overflow-style: none;
}

.ba_track::-webkit-scrollbar {
  display: none;
}

.ba_card {
  flex: 0 0 calc((100% - 2 * var(--ba-gap)) / 3);
  min-width: 0;
  scroll-snap-align: start;
}

/* --- comparison frame ----------------------------------------------------- */
.ba_frame {
  --ba-pos: 50%;
  position: relative;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  border-radius: 18px;
  background: var(--teal-900);
  box-shadow: 0 18px 40px rgba(6, 48, 47, .14);
  cursor: ew-resize;
  touch-action: pan-y;
  user-select: none;
  -webkit-user-select: none;
}

.ba_frame.is-dragging {
  cursor: grabbing;
}

.ba_photo {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* The after photo is the same frame, revealed from the handle rightwards. */
.ba_after {
  position: absolute;
  inset: 0;
  clip-path: inset(0 0 0 var(--ba-pos));
  will-change: clip-path;
}

.ba_label {
  position: absolute;
  bottom: 12px;
  z-index: 3;
  padding: 5px 11px;
  border-radius: 999px;
  font-family: var(--font-body);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  pointer-events: none;
}

.ba_label-before {
  left: 12px;
  color: #fff;
  background: rgba(6, 48, 47, .62);
}

.ba_label-after {
  right: 12px;
  color: var(--teal-900);
  background: rgba(255, 255, 255, .92);
}

.ba_handle {
  position: absolute;
  top: 0;
  bottom: 0;
  left: var(--ba-pos);
  z-index: 4;
  width: 56px;
  margin-left: -28px;
  padding: 0;
  border: 0;
  background: none;
  color: var(--teal-700);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: ew-resize;
  touch-action: none;
}

.ba_handle-rail {
  position: absolute;
  top: 0;
  bottom: 0;
  left: 50%;
  width: 2px;
  margin-left: -1px;
  background: linear-gradient(180deg, rgba(255, 255, 255, .2), #fff 14%, #fff 86%, rgba(255, 255, 255, .2));
  box-shadow: 0 0 18px rgba(6, 48, 47, .45);
}

.ba_handle-grip {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 999px;
  border: 1px solid rgba(12, 108, 108, .16);
  background: #fff;
  color: var(--teal-700);
  box-shadow: 0 10px 24px rgba(6, 48, 47, .32);
  transition: transform .2s ease, box-shadow .2s ease;
}

.ba_handle-grip svg {
  width: 20px;
  height: 14px;
}

.ba_frame:hover .ba_handle-grip {
  transform: scale(1.06);
  box-shadow: 0 14px 30px rgba(6, 48, 47, .4);
}

.ba_handle:focus-visible {
  outline: none;
}

.ba_handle:focus-visible .ba_handle-grip {
  outline: 2px solid var(--magenta-500);
  outline-offset: 3px;
}

/* --- case meta ------------------------------------------------------------ */
.ba_meta {
  padding-top: 14px;
}

.ba_meta-top {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px 10px;
}

.ba_title {
  margin: 0;
  color: var(--teal-900);
  font-family: var(--font-display);
  font-size: clamp(17px, 1.3vw, 20px);
  font-weight: 500;
  letter-spacing: -0.01em;
  line-height: 1.25;
}

.ba_treatment {
  padding: 4px 10px;
  border-radius: 999px;
  background: var(--magenta-50);
  color: var(--magenta-600);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  white-space: nowrap;
}

.ba_para {
  margin-top: 6px;
  color: var(--neutral-600);
  font-size: 14px;
  line-height: 1.55;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* --- paging --------------------------------------------------------------- */
/* Only shown when the row actually has more cases than fit. */
.ba_nav {
  display: none;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 18px;
}

.ba_row.is-scrollable .ba_nav {
  display: flex;
}

.ba_nav-arrow {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  padding: 0;
  border: 1px solid var(--neutral-200);
  border-radius: 999px;
  background: #fff;
  color: var(--teal-700);
  cursor: pointer;
  transition: background-color .2s ease, border-color .2s ease, color .2s ease,
    opacity .2s ease, transform .2s ease;
}

.ba_nav-arrow svg {
  width: 18px;
  height: 12px;
}

.ba_nav-arrow:hover:not(:disabled) {
  border-color: var(--teal-600);
  background: var(--teal-600);
  color: #fff;
  transform: translateY(-1px);
}

.ba_nav-arrow:disabled {
  opacity: .35;
  cursor: default;
}

@media screen and (max-width: 991px) {
  .ba_card {
    flex-basis: calc((100% - var(--ba-gap)) / 2);
  }
}

@media screen and (max-width: 640px) {
  .ba_header {
    flex-direction: column;
    align-items: flex-start;
  }

  .ba_card {
    flex-basis: 86%;
  }
}


@media screen and (max-width: 640px) {
  .ba_header {
    flex-direction: column;
    align-items: flex-start;
  }

  .ba_card {
    flex-basis: 86%;
  }
}

/* --- soft corners --------------------------------------------------------- */
/* The comparison cards are content, not floating widgets, but they still sit
   inside the same 16-20px geometry as the rest of the site: rounded media, a
   hairline and a soft tinted panel. The home row and /transformations match. */
.ba_frame {
  border-radius: 16px;
  box-shadow: 0 22px 44px -38px rgba(6, 48, 47, .4);
  border: 1px solid var(--neutral-100);
}

.ba_label {
  border-radius: 999px;
  padding: 5px 11px;
  letter-spacing: 0.1em;
}

.ba_treatment {
  border-radius: 999px;
  padding: 4px 10px;
}

/* Bigger cards on the dedicated page - the grid reads as a gallery, not a strip. */
.ba_track.is-grid {
  --ba-gap: 24px;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  overflow: visible;
}

.ba_track.is-grid .ba_frame {
  aspect-ratio: 3 / 2;
}

/* The page grid gets full panels, like the service and blog cards. */
.ba_track.is-grid .ba_card {
  padding: 12px 12px 16px;
  border: 1px solid var(--color-border);
  border-radius: 20px;
  background: var(--neutral-0);
  box-shadow: 0 22px 44px -40px rgba(6, 48, 47, .35);
  transition: border-color .18s ease, box-shadow .18s ease, transform .18s ease;
}

.ba_track.is-grid .ba_card:hover {
  border-color: var(--teal-100);
  box-shadow: 0 26px 50px -38px rgba(6, 48, 47, .45);
  transform: translateY(-2px);
}

.ba_track.is-grid .ba_meta {
  padding: 14px 6px 0;
}

.ba_treatment {
  max-width: 100%;
  white-space: normal;
  overflow-wrap: anywhere;
}

@media screen and (max-width: 991px) {
  .ba_track.is-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media screen and (max-width: 640px) {
  .ba_track.is-grid {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* Keep contact details readable when staff enter longer addresses or hours. */
.our-info_item {
  flex-wrap: wrap;
  row-gap: 12px;
}

.our-info_row {
  max-width: 100%;
}

.our-info_item-para {
  white-space: normal;
  overflow: visible;
  overflow-wrap: anywhere;
}

.home-hero_content {
  width: 100%;
}

.hero-text-split {
  overflow-wrap: anywhere;
}

/* Visible focus on glass, white and tinted surfaces, without changing hover. */
a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible,
[tabindex]:focus-visible {
  outline: 3px solid var(--magenta-600, #ba1878);
  outline-offset: 4px;
}

.navbar_wrap a:focus-visible,
.our-info_wrap a:focus-visible {
  outline-color: #fff;
}

@media screen and (max-width: 767px) {
  /* iOS zooms focused form fields when their text is smaller than 16px. */
  input,
  select,
  textarea,
  .ed_form .ed_field input,
  .ed_form .ed_field select,
  .ed_form .ed_field textarea {
    font-size: 16px;
  }

  .button_primary,
  .navbar_link,
  .ba_nav-arrow {
    min-height: 44px;
  }

  .section_hero.is-home-hero {
    min-height: 100svh;
  }

  .home-hero_content {
    margin-bottom: clamp(48px, 8svh, 88px);
  }
}

