/* Shared styles for the public pages (home, services, about, gallery,
   policies, and the header/footer on the booking page). */

:root {
  /* Pulled straight from Traci's logo */
  --pink: #f0048c;        /* logo pink: accents on dark, the dog tag */
  --pink-strong: #d6007c; /* buttons with white text (passes contrast) */
  --pink-dark: #c20070;   /* links on light backgrounds, hovers */
  --ink: #141a1a;         /* logo's green-black */
  --khaki: #dddbab;       /* logo's rings and paw prints */
  --khaki-soft: #ebe9c9;
  --paper: #f7f6e9;       /* page background, a pale version of the khaki */
  --gray: #5d6360;
  --rule: #e3e1c6;
  --display: 'DM Serif Display', Georgia, 'Times New Roman', serif;
  --font: 'Bricolage Grotesque', 'Segoe UI', system-ui, -apple-system, sans-serif;
}

html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
@media (min-width: 1600px) { html { font-size: 17px; } }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font);
  font-size: 1.0625rem;
  line-height: 1.55;
}

a { color: var(--pink-dark); }
a:focus-visible, button:focus-visible {
  outline: 3px solid var(--pink);
  outline-offset: 3px;
  border-radius: 4px;
}

.skip-link {
  position: absolute; left: -999px; top: 8px;
  background: var(--pink-strong); color: #fff; padding: 8px 14px; border-radius: 8px;
}
.skip-link:focus { left: 8px; z-index: 10; }

/* ---- Header ---- */
.site-header {
  background: var(--ink);
  color: var(--khaki);
}
.site-header .inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 14px 20px;
  display: flex;
  align-items: center;
  gap: 24px;
}
.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  font-size: 1.35rem;
  letter-spacing: -0.02em;
  color: var(--pink);
  text-decoration: none;
  white-space: nowrap;
}
.site-nav {
  display: flex;
  gap: 4px;
  margin-left: auto;
  align-items: center;
}
.site-nav a {
  color: var(--khaki);
  text-decoration: none;
  padding: 6px 10px;
  border-radius: 6px;
  font-weight: 500;
}
.site-nav a:hover { color: #fff; background: rgba(255,255,255,0.08); }
.site-nav a[aria-current="page"] { color: var(--pink); }
.site-nav a.nav-book {
  background: var(--pink-strong);
  color: #fff;
  font-weight: 700;
  padding: 8px 16px;
  border-radius: 999px;
  margin-left: 8px;
}
.site-nav a.nav-book:hover { background: var(--pink-dark); }
.site-nav a.nav-book[aria-current="page"] { color: #fff; }

@media (max-width: 960px) {
  .site-header .inner { flex-wrap: wrap; gap: 8px; padding: 12px 16px; }
  .site-nav {
    margin-left: -10px;
    width: 100%;
    flex-wrap: wrap;
    gap: 0 2px;
  }
  .site-nav a { white-space: nowrap; padding: 10px; }
  .site-nav a.nav-book { margin-left: auto; }
}

/* ---- Page body ---- */
.page {
  max-width: 1200px;
  margin: 0 auto;
  padding: 48px 20px 72px;
}
.measure { max-width: 64ch; }

.page-title {
  font-family: var(--display);
  font-size: clamp(2.4rem, 5.5vw, 3.8rem);
  font-weight: 400;
  line-height: 1.05;
  letter-spacing: -0.01em;
  margin: 0 0 16px;
}
.lede { font-size: 1.2rem; color: var(--gray); margin: 0 0 40px; max-width: 56ch; }

h2 {
  font-size: 1.6rem;
  font-weight: 750;
  letter-spacing: -0.02em;
  line-height: 1.15;
  margin: 56px 0 16px;
}
h3 { font-size: 1.15rem; font-weight: 700; margin: 0 0 4px; }

.btn {
  display: inline-block;
  font: inherit;
  font-weight: 700;
  text-decoration: none;
  padding: 13px 26px;
  border-radius: 999px;
  border: 2px solid transparent;
  cursor: pointer;
}
.btn-pink { background: var(--pink-strong); color: #fff; }
.btn-pink:hover { background: var(--pink-dark); }
.btn-line { border-color: currentColor; color: inherit; }
.btn-line:hover { background: rgba(236,31,127,0.08); }

/* Placeholder text Traci still needs to supply. Deliberately loud so it
   can't be missed; delete the class once real text is in. */
.todo {
  background: #fff3c4;
  outline: 2px dashed var(--pink);
  outline-offset: 2px;
  padding: 0 4px;
}

/* ---- Home hero ---- */
.hero {
  background: var(--ink);
  color: var(--khaki);
}
.hero .inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 56px 20px 88px;
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 48px;
  align-items: center;
}
.hero h1 {
  font-family: var(--display);
  font-size: clamp(2.9rem, 7.5vw, 5.6rem);
  font-weight: 400;
  line-height: 1;
  letter-spacing: -0.01em;
  margin: 0 0 20px;
  color: var(--khaki);
}
.hero p { font-size: 1.2rem; max-width: 44ch; margin: 0 0 28px; color: var(--khaki); }
.hero .actions { display: flex; flex-wrap: wrap; gap: 12px; }

/* The dog tag: shows the live next opening. The one bold element. */
.logo img { width: 44px; height: 44px; display: block; }

/* Hero art: Traci's logo, with the live "next opening" tag hanging off it */
.brand-stack {
  position: relative;
  width: min(380px, 78vw);
  margin: 0 auto 30%; /* room for the tag hanging below */
}
.brand-stack > img { width: 100%; height: auto; display: block; }
.dog-tag-wrap {
  position: absolute;
  left: 50%;
  top: 96%;
  width: 40%;
  margin-left: -20%;
}
/* the little ring linking the tag to the logo's rim */
.dog-tag-wrap::before {
  content: '';
  position: absolute;
  top: -5%;
  left: 50%;
  width: 16%;
  aspect-ratio: 1;
  margin-left: -8%;
  border-radius: 50%;
  border: 3px solid var(--khaki);
  z-index: 1;
}
.dog-tag {
  position: relative;
  width: 100%;
  aspect-ratio: 1;
  border-radius: 50%;
  background: var(--pink);
  color: #fff;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 22% 12% 12%;
  text-decoration: none;
  box-shadow: inset 0 0 0 6px rgba(255,255,255,0.18), 0 0 0 5px var(--ink);
  transform: rotate(-6deg);
  transform-origin: 50% 0;
}
.dog-tag::before { /* the ring hole */
  content: '';
  position: absolute;
  top: 7%;
  left: 50%;
  width: 11%; height: 11%;
  margin-left: -5.5%;
  border-radius: 50%;
  background: var(--ink);
  box-shadow: 0 0 0 5px rgba(255,255,255,0.35);
}
.dog-tag .tag-label { font-size: clamp(0.75rem, 2.4vw, 0.95rem); font-weight: 600; opacity: 0.9; }
.dog-tag .tag-day { font-size: clamp(1.05rem, 3.8vw, 1.45rem); font-weight: 800; line-height: 1.05; letter-spacing: -0.02em; margin: 6px 0 2px; }
.dog-tag .tag-time { font-size: clamp(0.95rem, 3.2vw, 1.2rem); font-weight: 700; }
.dog-tag .tag-cta { margin-top: 6px; font-size: clamp(0.75rem, 2.4vw, 0.9rem); font-weight: 600; text-decoration: underline; text-underline-offset: 3px; }
.dog-tag:hover { background: var(--pink-dark); }

@media (prefers-reduced-motion: no-preference) {
  .dog-tag.ready { animation: swing 1.6s ease-out 1; }
  @keyframes swing {
    0% { transform: rotate(12deg); }
    35% { transform: rotate(-12deg); }
    65% { transform: rotate(-2deg); }
    100% { transform: rotate(-6deg); }
  }
}

@media (max-width: 900px) {
  .hero .inner { grid-template-columns: 1fr; padding: 40px 20px 56px; gap: 40px; }
  .brand-stack { width: min(340px, 74vw); }
}

/* ---- Lists of rows (services, included items, policies) ---- */
.rows { list-style: none; margin: 0; padding: 0; border-top: 2px solid var(--ink); }
.rows > li {
  padding: 18px 0;
  border-bottom: 1px solid var(--rule);
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 4px 24px;
  align-items: baseline;
}
.rows .meta { color: var(--gray); font-size: 0.95rem; }
.rows .right { font-weight: 700; text-align: right; white-space: nowrap; }
@media (max-width: 560px) {
  .rows > li { grid-template-columns: 1fr; }
  .rows .right { text-align: left; }
}

.steps { counter-reset: step; list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 32px; }
.steps li { counter-increment: step; }
.steps li::before {
  content: counter(step);
  display: block;
  font-size: 2.6rem;
  font-weight: 800;
  color: var(--pink);
  line-height: 1;
  margin-bottom: 8px;
}
.steps p { margin: 0; color: var(--gray); }
@media (max-width: 760px) { .steps { grid-template-columns: 1fr; gap: 24px; } }

.two-col { display: grid; grid-template-columns: 1.3fr 1fr; gap: 56px; }
@media (max-width: 760px) { .two-col { grid-template-columns: 1fr; gap: 8px; } }

.hours-table { width: 100%; border-collapse: collapse; }
.hours-table th, .hours-table td { text-align: left; padding: 10px 0; border-bottom: 1px solid var(--rule); }
.hours-table th { font-weight: 600; }
.hours-table td { text-align: right; }
.hours-table tr.closed td { color: var(--gray); }

.callout {
  background: var(--khaki-soft);
  padding: 28px;
  border-radius: 4px 28px 4px 28px;
  margin-top: 56px;
  display: flex;
  flex-wrap: wrap;
  gap: 16px 32px;
  align-items: center;
  justify-content: space-between;
}
.callout p { margin: 0; font-size: 1.2rem; font-weight: 600; max-width: 40ch; }

/* ---- Gallery ---- */
.gallery-grid { columns: 3 260px; column-gap: 12px; }
.photo-btn {
  display: block;
  width: 100%;
  padding: 0;
  margin: 0 0 12px;
  border: 0;
  background: none;
  cursor: zoom-in;
  break-inside: avoid;
}
.gallery-grid img {
  width: 100%;
  height: auto;
  display: block;
  border-radius: 6px;
  background: var(--khaki);
}
.viewer {
  border: 0;
  padding: 0;
  background: transparent;
  max-width: 94vw;
  max-height: 94vh;
}
.viewer::backdrop { background: rgba(20, 26, 26, 0.88); }
.viewer img { max-width: 94vw; max-height: 90vh; display: block; border-radius: 6px; }
.viewer-close {
  position: fixed;
  top: 12px; right: 16px;
  width: 44px; height: 44px;
  border-radius: 50%;
  border: 0;
  background: var(--pink-strong);
  color: #fff;
  font-size: 1.8rem;
  line-height: 1;
  cursor: pointer;
}

/* Home page strip of recent grooms */
.recent { margin-bottom: 56px; }
.recent-head { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; }
.recent-head h2 { margin-top: 0; }
.photo-strip { columns: 3 220px; column-gap: 10px; }
.photo-strip a { display: block; margin-bottom: 10px; break-inside: avoid; }
.photo-strip img { width: 100%; height: auto; display: block; border-radius: 6px; background: var(--khaki); }
@media (max-width: 560px) { .photo-strip { columns: 2; column-gap: 8px; } .photo-strip a { margin-bottom: 8px; } }

/* Belt and braces: no image can ever be wider than the screen */
img { max-width: 100%; }
html, body { overflow-x: hidden; }

.about-photo { width: 100%; height: auto; display: block; border-radius: 4px 28px 4px 28px; margin-bottom: 8px; }
.empty {
  border: 2px dashed var(--rule);
  border-radius: 6px;
  padding: 48px 24px;
  text-align: center;
  color: var(--gray);
}

/* ---- Footer ---- */
.site-footer-main {
  border-top: 1px solid var(--rule);
  color: var(--gray);
  font-size: 0.95rem;
}
.site-footer-main .inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 28px 20px 40px;
  display: flex;
  flex-wrap: wrap;
  gap: 8px 24px;
  justify-content: space-between;
}
.site-footer-main a { color: var(--ink); font-weight: 600; }
.site-footer-main p { margin: 0; }

/* ---- Fixes ---- */
[hidden] { display: none !important; }
.hero { overflow: hidden; }

/* Booking page: keep long service names from pushing the page sideways */
.field-row label { min-width: 0; }
.field-row select, .field-row input { width: 100%; max-width: 100%; }
@media (max-width: 560px) {
  .field-row { flex-direction: column; gap: 0; }
}

/* Mobile: keep "Book now" beside the logo instead of scrolled off-screen */
.header-book { display: none; }
@media (max-width: 960px) {
  .header-book {
    display: inline-block;
    margin-left: auto;
    background: var(--pink-strong);
    color: #fff;
    font-weight: 700;
    text-decoration: none;
    padding: 7px 16px;
    border-radius: 999px;
  }
  .site-nav a.nav-book { display: none; }
}
#serviceNote { margin: -4px 0 8px; }
@media (max-width: 560px) {
  .gallery-grid { columns: 2; column-gap: 8px; }
  .photo-btn { margin-bottom: 8px; }
}

/* Booking page title matches the other page titles */
.wrap > h1 { font-family: var(--display); font-weight: 400; font-size: clamp(2.2rem, 6vw, 3rem); line-height: 1.05; }

/* ---- All-device polish ---- */
.recent-head a { white-space: nowrap; }

/* Very small phones (iPhone SE 1st gen and similar) */
@media (max-width: 360px) {
  .logo { font-size: 1.1rem; gap: 8px; }
  .logo img { width: 34px; height: 34px; }
  .header-book { padding: 6px 12px; font-size: 0.95rem; }
  .page { padding-left: 16px; padding-right: 16px; }
  .hero .inner { padding-left: 16px; padding-right: 16px; }
  .btn { padding: 12px 20px; }
}

/* Phones turned sideways: keep the hero from taking several screens */
@media (max-height: 500px) and (orientation: landscape) {
  .hero .inner { grid-template-columns: 1.4fr 1fr; padding-top: 28px; padding-bottom: 64px; }
  .brand-stack { width: min(240px, 34vw); }
  .hero h1 { font-size: clamp(2rem, 5.5vw, 3rem); }
}

/* Respect iPhone notches/rounded corners in landscape */
@supports (padding: max(0px)) {
  .site-header .inner, .page, .hero .inner, .site-footer-main .inner {
    padding-left: max(16px, env(safe-area-inset-left));
    padding-right: max(16px, env(safe-area-inset-right));
  }
}
@media (min-width: 761px) {
  .site-header .inner, .page, .hero .inner, .site-footer-main .inner { padding-left: 20px; padding-right: 20px; }
}
