/* Equine Symbiosis – shared styles
   Sizes are in rem, so the whole site scales with the root font size below. */

:root {
  /* Colours from Vendula's swatches */
  --bg: #bcc6be;        /* light sage – all backgrounds */
  --ink: #373c40;       /* dark – all text, lines and buttons */
  --ink-hover: #24282b;
  --field: #d2d9d3;     /* form fields, a touch lighter than --bg */
  --error: #7d1d1d;

  --font-body: "Montserrat", system-ui, sans-serif;
  /* Swap for the business card's heading font once we know its name */
  --font-display: "Montserrat", system-ui, sans-serif;

  --header-h: 3.25rem;
  --content: 45rem;
  --gutter: 1.25rem;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  /* Bigger on large screens: 100 % up to ~1000 px wide, growing smoothly
     to 150 % at ~1900 px (like browser zoom 150 % on a full-HD monitor) */
  font-size: clamp(100%, calc(44.44% + 0.889vw), 150%);
  scroll-padding-top: var(--header-h);
  -webkit-text-size-adjust: 100%;
}

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

img {
  display: block;
  max-width: 100%;
}

a {
  color: inherit;
  text-underline-offset: 0.2em;
}

:focus-visible {
  outline: 2px solid var(--ink);
  outline-offset: 3px;
}

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0.5rem;
  z-index: 100;
  padding: 0.5rem 1rem;
  background: var(--ink);
  color: var(--bg);
}

.skip-link:focus {
  left: 1rem;
}

/* ---------- Header (stays on top while scrolling) ---------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  height: var(--header-h);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  padding: 0 0.625rem 0 var(--gutter);
  background: var(--bg);
  border-bottom: 1px solid var(--ink);
}

/* Home: the tagline; every other page: its own name */
.site-header__title {
  min-width: 0;
  margin: 0;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  font-family: var(--font-body);
  font-size: clamp(1rem, 2.4vw, 1.125rem);
  font-weight: 500;
  line-height: 1.3;
  letter-spacing: 0.02em;
  text-decoration: none;
}

.site-header__actions {
  flex: none;
  display: flex;
  align-items: center;
}

.home-link {
  width: 2.75rem;
  height: 2.75rem;
  display: grid;
  place-items: center;
  color: var(--ink);
}

.home-link svg {
  width: 1.5rem;
  height: 1.5rem;
}

.menu-toggle {
  flex: none;
  width: 2.75rem;
  height: 2.75rem;
  display: grid;
  place-content: center;
  gap: 0.375rem;
  padding: 0;
  background: none;
  border: 0;
  color: var(--ink);
  cursor: pointer;
}

.menu-toggle span {
  display: block;
  width: 1.625rem;
  height: 0.125rem;
  border-radius: 0.125rem;
  background: currentColor;
  transition: transform 0.25s ease, opacity 0.2s ease;
}

/* Bars are 0.125rem tall with 0.375rem gaps, so the outer ones move 0.5rem */
.menu-toggle[aria-expanded="true"] span:nth-child(1) {
  transform: translateY(0.5rem) rotate(45deg);
}

.menu-toggle[aria-expanded="true"] span:nth-child(2) {
  opacity: 0;
}

.menu-toggle[aria-expanded="true"] span:nth-child(3) {
  transform: translateY(-0.5rem) rotate(-45deg);
}

/* ---------- Slide-out menu ----------
   Opens on the right, as in the sketch. For the left side, change
   `right: 0` to `left: 0`, `border-left` to `border-right` and
   `translateX(100%)` to `translateX(-100%)`. */

.site-menu {
  position: fixed;
  top: var(--header-h);
  right: 0;
  bottom: 0;
  z-index: 19;
  width: min(15rem, 75vw);
  overflow-y: auto;
  background: var(--bg);
  border-left: 1px solid var(--ink);
  transform: translateX(100%);
  visibility: hidden;
  box-shadow: none;
  transition: transform 0.3s ease, box-shadow 0.3s ease, visibility 0s linear 0.3s;
}

/* Open: the panel lifts off the page with a layered shadow */
.site-menu.is-open {
  transform: none;
  visibility: visible;
  box-shadow:
    -1px 0 2px rgba(36, 40, 43, 0.25),
    -0.5rem 0 1.125rem rgba(36, 40, 43, 0.3),
    -1.75rem 0 4rem rgba(36, 40, 43, 0.45);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

/* ...and the rest of the page steps back: dimmed and slightly blurred */
.menu-backdrop {
  position: fixed;
  top: var(--header-h);
  right: 0;
  bottom: 0;
  left: 0;
  z-index: 18;
  background: rgba(55, 60, 64, 0.32);
  -webkit-backdrop-filter: blur(2px);
  backdrop-filter: blur(2px);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0s linear 0.3s;
}

.menu-open .menu-backdrop {
  opacity: 1;
  visibility: visible;
  transition: opacity 0.3s ease;
}

.site-menu ul {
  margin: 0;
  padding: 0;
  list-style: none;
}

.site-menu a {
  display: block;
  padding: 0.875rem 1.125rem;
  border-bottom: 1px solid var(--ink);
  font-size: 1rem;
  font-weight: 500;
  line-height: 1.3;
  text-decoration: none;
  transition: background-color 0.15s ease, color 0.15s ease;
}

.site-menu a:hover,
.site-menu a[aria-current="page"] {
  background: var(--ink);
  color: var(--bg);
}

/* ---------- Page structure ---------- */

main {
  padding-bottom: 4.5rem;
}

.container {
  max-width: var(--content);
  margin: 0 auto;
  padding: 2.25rem var(--gutter) 0;
}

h2 {
  margin: 1.6em 0 0.5em;
  font-family: var(--font-display);
  font-size: 1.35rem;
  font-weight: 600;
  line-height: 1.3;
}

.container > h2:first-child {
  margin-top: 0;
}

p {
  margin: 0 0 1.1em;
}

ul {
  padding-left: 1.3em;
}

li {
  margin-bottom: 0.4em;
}

/* Solid round bullets, as on the business card */
.container ul:not(.story-grid, .review-list) {
  padding-left: 0;
  list-style: none;
}

.container ul:not(.story-grid, .review-list) > li {
  position: relative;
  padding-left: 1.25em;
}

.container ul:not(.story-grid, .review-list) > li::before {
  content: "";
  position: absolute;
  top: 0.66em;
  left: 0.1em;
  width: 0.38em;
  height: 0.38em;
  border-radius: 50%;
  background: currentColor;
}

.photo-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(13.75rem, 1fr));
  gap: 1rem;
  margin-top: 2rem;
}

.photo-grid img {
  width: 100%;
  height: auto;
}

/* ---------- Buttons ---------- */

.button {
  display: inline-block;
  padding: 0.875rem 2.125rem;
  border: 0;
  border-radius: 0.25rem;
  background: var(--ink);
  color: var(--bg);
  font: 600 1rem/1.3 var(--font-body);
  letter-spacing: 0.04em;
  text-decoration: none;
  cursor: pointer;
  transition: background-color 0.15s ease, transform 0.15s ease;
}

.button:hover {
  background: var(--ink-hover);
}

.button:active {
  transform: translateY(1px);
}

.button[disabled] {
  opacity: 0.7;
  cursor: wait;
}

.button-row {
  margin-top: 2.5rem;
  text-align: center;
}

/* ---------- Home ---------- */

.hero {
  margin: 0;
  border-bottom: 1px solid var(--ink);
}

/* Landscape band, edge to edge on every screen size */
.hero img {
  width: 100%;
  height: clamp(16.25rem, 58vh, 45rem);
  object-fit: cover;
  object-position: 50% 35%;
}

.intro {
  font-size: 1.125rem;
}

.intro__name {
  margin: 0 0 0.15em;
  font-family: var(--font-display);
  font-size: clamp(1.75rem, 5vw, 3.25rem);
  font-weight: 700;
  letter-spacing: 0.04em;
  line-height: 1.1;
  text-transform: uppercase;
}

.intro__sub {
  margin-bottom: 1.4em;
  font-weight: 600;
}

/* Home page button in capitals, like the heading above it */
.home .button {
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

@media (min-width: 900px) {
  .intro {
    font-size: 1.25rem;
  }
}

/* ---------- Services and rates: plain text, grouped by category ---------- */

.service-group + .service-group {
  margin-top: 3rem;
}

.service-group__title {
  margin: 0 0 0.25rem;
  padding-bottom: 0.625rem;
  border-bottom: 1px solid var(--ink);
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: 0.08em;
}

.service {
  padding: 1.375rem 0;
}

.service + .service {
  border-top: 1px solid rgba(55, 60, 64, 0.25);
}

.service__name {
  margin: 0 0 0.375rem;
  font-family: var(--font-display);
  font-size: 1.2rem;
  font-weight: 600;
  line-height: 1.35;
}

.service__details p {
  margin-bottom: 0.6em;
}

.service__price p {
  margin: 0;
  font-weight: 700;
}

/* ---------- My Experience (horse stories) ---------- */

.story-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: clamp(1rem, 5vw, 3rem);
  margin: 0;
  padding: 0;
  list-style: none;
}

.story-grid li {
  margin: 0;
}

.story-tile {
  display: grid;
  place-items: center;
  aspect-ratio: 1;
  border: 1px solid var(--ink);
  font-size: clamp(1.5rem, 5vw, 2.25rem);
  font-weight: 500;
  text-decoration: none;
  transition: background-color 0.15s ease, color 0.15s ease;
}

.story-tile:hover {
  background: var(--ink);
  color: var(--bg);
}

/* Tile with a photo: the photo fills the square, the horse's name sits underneath */
.story-tile--photo {
  position: relative;
  display: block;
  margin-bottom: 2.2em;
}

.story-tile--photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: opacity 0.15s ease;
}

.story-tile--photo:hover {
  background: none;
  color: inherit;
}

.story-tile--photo:hover img {
  opacity: 0.85;
}

.story-name {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  padding-top: 0.375rem;
  font-size: 1rem;
  font-weight: 600;
  line-height: 1.3;
  text-align: center;
}

.story-heading {
  margin-top: 0;
  font-size: clamp(1.4rem, 3.5vw, 1.75rem);
}

.back-link {
  display: inline-block;
  margin-top: 2rem;
  font-weight: 600;
}

/* ---------- Reviews ---------- */

.stars {
  margin: 0;
  color: var(--ink);
  font-size: 1.15rem;
  letter-spacing: 0.1em;
  line-height: 1;
}

.stars__off {
  opacity: 0.25;
}

.reviews-cta {
  margin: 1.25rem 0 0;
}

.review-form {
  margin-top: 0;
}

.reviews-summary {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem 0.75rem;
  margin: 1.5rem 0 0.5rem;
  font-weight: 600;
}

.review-list {
  margin: 0;
  padding: 0;
  list-style: none;
}

.review-list > li {
  margin: 0;
  padding: 1.5rem 0;
  border-top: 1px solid var(--ink);
}

.review__text {
  margin-top: 0.75rem;
}

.review__text p {
  margin-bottom: 0.6em;
}

.review__author {
  margin: 0;
  font-weight: 600;
}

.review__date {
  display: block;
  font-size: 0.875rem;
  font-weight: 400;
}

.review-empty {
  margin-top: 1.5rem;
  font-style: italic;
}

/* Star picker: five radio buttons shown as stars (reversed so hover fills to the left) */
.rating {
  margin: 0;
  padding: 0;
  border: 0;
}

.rating legend {
  margin-bottom: 0.25rem;
  padding: 0;
  font-weight: 600;
}

.rating__stars {
  display: inline-flex;
  flex-direction: row-reverse;
}

.rating__stars input {
  position: absolute;
  opacity: 0;
  width: 1px;
  height: 1px;
}

.rating__stars label {
  padding: 0 0.15rem;
  color: rgba(55, 60, 64, 0.25);
  font-size: 2rem;
  line-height: 1;
  cursor: pointer;
  transition: color 0.1s ease;
}

.rating__stars input:checked ~ label,
.rating__stars label:hover,
.rating__stars label:hover ~ label {
  color: var(--ink);
}

.rating__stars input:focus-visible + label {
  outline: 2px solid var(--ink);
  outline-offset: 2px;
}

.field__optional {
  font-weight: 400;
}

.form-note {
  margin: 0;
  font-size: 0.9375rem;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

/* ---------- Contact ---------- */

.contact-list {
  margin: 0;
}

.contact-list div {
  padding: 0.875rem 0;
  border-bottom: 1px solid var(--ink);
}

.contact-list div:first-child {
  border-top: 1px solid var(--ink);
}

.contact-list dt {
  font-size: 0.875rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.contact-list dd {
  margin: 0;
  font-size: 1.125rem;
}

.contact-text {
  margin-top: 2rem;
}

/* ---------- Map ---------- */

.map-figure {
  margin: 0 0 2rem;
}

.map-figure img {
  width: 100%;
  border: 1px solid var(--ink);
}

.zoomable {
  display: block;
  cursor: zoom-in;
}

/* Enlarged picture on top of a dimmed, blurred page */
.lightbox {
  max-width: none;
  max-height: none;
  padding: 0;
  border: 0;
  background: none;
  overflow: visible;
  cursor: zoom-out;
}

.lightbox::backdrop {
  background: rgba(36, 40, 43, 0.55);
  -webkit-backdrop-filter: blur(6px);
  backdrop-filter: blur(6px);
}

.lightbox img {
  display: block;
  width: auto;
  height: auto;
  max-width: 94vw;
  max-height: 90vh;
  box-shadow: 0 1.5rem 4rem rgba(0, 0, 0, 0.4);
  animation: lightbox-in 0.25s ease;
}

@keyframes lightbox-in {
  from {
    opacity: 0;
    transform: scale(0.96);
  }
}

.lightbox__close {
  position: fixed;
  top: 1rem;
  right: 1rem;
  width: 2.75rem;
  height: 2.75rem;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: var(--bg);
  color: var(--ink);
  font-size: 1.75rem;
  line-height: 1;
  cursor: pointer;
}

html.lightbox-open {
  overflow: hidden;
}

.map-placeholder {
  display: grid;
  place-items: center;
  aspect-ratio: 4 / 3;
  padding: 1.5rem;
  border: 1px solid var(--ink);
  font-style: italic;
  text-align: center;
}

/* ---------- Get in touch form ---------- */

.contact-form {
  display: grid;
  gap: 1.25rem;
  margin-top: 2rem;
}

.field label {
  display: block;
  margin-bottom: 0.375rem;
  font-weight: 600;
}

.field input,
.field textarea {
  width: 100%;
  padding: 0.75rem 0.875rem;
  border: 1px solid var(--ink);
  border-radius: 0.25rem;
  background: var(--field);
  color: var(--ink);
  font: inherit;
}

.field textarea {
  min-height: 11.25rem;
  resize: vertical;
}

.field ::placeholder {
  color: #545b60;
  opacity: 1;
}

.field input[aria-invalid="true"],
.field textarea[aria-invalid="true"] {
  border-width: 2px;
  border-color: var(--error);
}

.field-error,
.form-error {
  margin: 0.375rem 0 0;
  color: var(--error);
  font-weight: 600;
}

.contact-form .button-row {
  margin-top: 0.75rem;
}

/* Hidden trap field for spam bots */
.hp {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.notice {
  margin-top: 2rem;
  padding: 1.25rem 1.5rem;
  border: 1px solid var(--ink);
  border-radius: 0.25rem;
  font-weight: 600;
  text-align: center;
}

/* ---------- Hidden website ---------- */

/* Shown only to the admin while the whole site is hidden */
.hidden-site-note {
  margin: 0;
  padding: 0.5rem var(--gutter);
  background: var(--ink);
  color: var(--bg);
  font-size: 0.875rem;
  font-weight: 600;
  text-align: center;
}

/* What visitors see instead of the site */
.soon {
  min-height: 100vh;
  display: grid;
  place-content: center;
  padding: 2rem var(--gutter);
  text-align: center;
}

.soon__tagline {
  margin: 0 0 0.5rem;
  font-weight: 500;
  letter-spacing: 0.02em;
}

.soon__name {
  margin: 0 0 1rem;
  font-size: clamp(2rem, 6vw, 3.25rem);
  font-weight: 700;
  letter-spacing: 0.04em;
  line-height: 1.1;
  text-transform: uppercase;
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    transition: none !important;
    animation: none !important;
  }
}
