/* ============================================
   HOPE PAWS RESCUE — Animal Rescue Nonprofit
   Custom Palette: Warm cream, forest green, coral
   Fonts: Boska (display) + Work Sans (body)
   ============================================ */

/* --- Design Tokens --- */
:root,
[data-theme='light'] {
  /* Surfaces — warm cream */
  --color-bg: #FAF6F0;
  --color-surface: #FFFDF9;
  --color-surface-2: #F5F0E8;
  --color-surface-offset: #F0EBE2;
  --color-surface-offset-2: #E8E2D6;
  --color-surface-dynamic: #DDD6C8;
  --color-divider: #E5DFD5;
  --color-border: #D8D0C2;

  /* Text — warm charcoal */
  --color-text: #2A2520;
  --color-text-muted: #6B6358;
  --color-text-faint: #A8A095;
  --color-text-inverse: #FAF6F0;

  /* Primary — forest green */
  --color-primary: #2D5A3D;
  --color-primary-hover: #244730;
  --color-primary-active: #1B3524;
  --color-primary-highlight: #D4E5DA;

  /* Coral CTA */
  --color-coral: #E8755B;
  --color-coral-hover: #D5634A;
  --color-coral-active: #C0533D;
  --color-coral-highlight: #FAE0D8;

  /* Accent — soft sage */
  --color-accent: #8BAE9E;
  --color-accent-highlight: #DDEAE4;

  /* Warm gold (for highlights) */
  --color-gold: #D4A04C;
  --color-gold-highlight: #F5E8D0;

  /* Radius */
  --radius-sm: 0.375rem;
  --radius-md: 0.75rem;
  --radius-lg: 1rem;
  --radius-xl: 1.5rem;
  --radius-2xl: 2rem;
  --radius-full: 9999px;

  /* Transitions */
  --transition-interactive: 180ms cubic-bezier(0.16, 1, 0.3, 1);

  /* Shadows — warm-toned */
  --shadow-sm: 0 1px 3px oklch(0.25 0.03 80 / 0.06);
  --shadow-md: 0 4px 16px oklch(0.25 0.03 80 / 0.08);
  --shadow-lg: 0 16px 40px oklch(0.25 0.03 80 / 0.14);

  /* Content widths */
  --content-narrow: 640px;
  --content-default: 1080px;
  --content-wide: 1200px;

  /* Fonts */
  --font-display: 'Boska', Georgia, serif;
  --font-body: 'Work Sans', 'Helvetica Neue', sans-serif;

  /* Type scale */
  --text-xs: clamp(0.75rem, 0.7rem + 0.25vw, 0.875rem);
  --text-sm: clamp(0.875rem, 0.8rem + 0.35vw, 1rem);
  --text-base: clamp(1rem, 0.95rem + 0.25vw, 1.125rem);
  --text-lg: clamp(1.125rem, 1rem + 0.75vw, 1.5rem);
  --text-xl: clamp(1.5rem, 1.2rem + 1.25vw, 2.25rem);
  --text-2xl: clamp(2rem, 1.2rem + 2.5vw, 3.5rem);
  --text-3xl: clamp(2.5rem, 1rem + 4vw, 4.5rem);
  --text-hero: clamp(2.75rem, 0.5rem + 6vw, 6rem);

  /* Spacing */
  --space-1: 0.25rem;
  --space-2: 0.5rem;
  --space-3: 0.75rem;
  --space-4: 1rem;
  --space-5: 1.25rem;
  --space-6: 1.5rem;
  --space-8: 2rem;
  --space-10: 2.5rem;
  --space-12: 3rem;
  --space-16: 4rem;
  --space-20: 5rem;
  --space-24: 6rem;
  --space-32: 8rem;
}

[data-theme='dark'] {
  --color-bg: #1A1814;
  --color-surface: #221F1A;
  --color-surface-2: #28241E;
  --color-surface-offset: #1E1B16;
  --color-surface-offset-2: #2A2620;
  --color-surface-dynamic: #34302A;
  --color-divider: #2E2A24;
  --color-border: #3D3830;

  --color-text: #E5DFD5;
  --color-text-muted: #9A9285;
  --color-text-faint: #6A6358;
  --color-text-inverse: #1A1814;

  --color-primary: #7BAE8E;
  --color-primary-hover: #6A9E7D;
  --color-primary-active: #5A8E6D;
  --color-primary-highlight: #2A3A30;

  --color-coral: #F09080;
  --color-coral-hover: #E88070;
  --color-coral-active: #D87060;
  --color-coral-highlight: #3D2E2A;

  --color-accent: #8BAE9E;
  --color-accent-highlight: #2A3530;

  --color-gold: #E8C070;
  --color-gold-highlight: #3D3520;

  --shadow-sm: 0 1px 3px oklch(0 0 0 / 0.2);
  --shadow-md: 0 4px 16px oklch(0 0 0 / 0.3);
  --shadow-lg: 0 16px 40px oklch(0 0 0 / 0.4);
}

/* --- Base Reset --- */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  -webkit-text-size-adjust: none;
  -moz-text-size-adjust: none;
  text-size-adjust: none;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  scroll-behavior: smooth;
  scroll-padding-top: var(--space-20);
}

body {
  min-height: 100dvh;
  line-height: 1.6;
  font-family: var(--font-body);
  font-size: var(--text-base);
  color: var(--color-text);
  background-color: var(--color-bg);
}

img, picture, video, canvas, svg {
  display: block;
  max-width: 100%;
  height: auto;
}

ul[role='list'], ol[role='list'] {
  list-style: none;
}

input, button, textarea, select {
  font: inherit;
  color: inherit;
}

h1, h2, h3, h4, h5, h6 {
  text-wrap: balance;
  line-height: 1.15;
  font-family: var(--font-display);
  font-weight: 500;
}

p, li, figcaption {
  text-wrap: pretty;
  max-width: 72ch;
}

::selection {
  background: var(--color-coral-highlight);
  color: var(--color-text);
}

:focus-visible {
  outline: 2px solid var(--color-primary);
  outline-offset: 3px;
  border-radius: var(--radius-sm);
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

button {
  cursor: pointer;
  background: none;
  border: none;
}

a, button, [role='button'], input, textarea, select {
  transition: color var(--transition-interactive),
              background var(--transition-interactive),
              border-color var(--transition-interactive),
              box-shadow var(--transition-interactive),
              transform var(--transition-interactive);
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border-width: 0;
}

/* --- Layout --- */
.container {
  width: 100%;
  max-width: var(--content-default);
  margin: 0 auto;
  padding-inline: clamp(var(--space-4), 5vw, var(--space-10));
}

/* --- Buttons --- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  font-family: var(--font-body);
  font-weight: 600;
  font-size: var(--text-sm);
  line-height: 1;
  padding: var(--space-3) var(--space-5);
  border-radius: var(--radius-full);
  text-decoration: none;
  border: 2px solid transparent;
  white-space: nowrap;
  cursor: pointer;
}

.btn--sm { padding: var(--space-2) var(--space-4); font-size: var(--text-xs); }
.btn--lg { padding: var(--space-4) var(--space-8); font-size: var(--text-base); }
.btn--block { width: 100%; }

.btn--primary {
  background: var(--color-primary);
  color: var(--color-text-inverse);
  border-color: var(--color-primary);
}
.btn--primary:hover {
  background: var(--color-primary-hover);
  border-color: var(--color-primary-hover);
  transform: translateY(-1px);
  box-shadow: var(--shadow-md);
}

.btn--coral {
  background: var(--color-coral);
  color: #fff;
  border-color: var(--color-coral);
}
.btn--coral:hover {
  background: var(--color-coral-hover);
  border-color: var(--color-coral-hover);
  transform: translateY(-1px);
  box-shadow: var(--shadow-md);
}

.btn--ghost {
  background: transparent;
  color: var(--color-primary);
  border-color: var(--color-primary);
}
.btn--ghost:hover {
  background: var(--color-primary);
  color: var(--color-text-inverse);
}

.btn--outline {
  background: transparent;
  color: var(--color-primary);
  border-color: var(--color-border);
}
.btn--outline:hover {
  border-color: var(--color-primary);
  background: var(--color-primary-highlight);
}

/* --- Badge / Eyebrow --- */
.badge {
  display: inline-block;
  font-size: var(--text-xs);
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--color-primary);
  background: var(--color-primary-highlight);
  padding: var(--space-2) var(--space-4);
  border-radius: var(--radius-full);
}

.eyebrow {
  display: inline-block;
  font-size: var(--text-xs);
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--color-coral);
  margin-bottom: var(--space-3);
}

.eyebrow--light {
  color: var(--color-coral);
}

.section-title {
  font-size: var(--text-xl);
  font-weight: 500;
  margin-bottom: var(--space-4);
  max-width: 20ch;
}

.section-title--light {
  color: var(--color-text-inverse);
}

.section-subtitle {
  font-size: var(--text-base);
  color: var(--color-text-muted);
  max-width: 55ch;
}

.section-header {
  text-align: center;
  max-width: 60ch;
  margin: 0 auto var(--space-12);
}

.section-header .section-title {
  margin-inline: auto;
}

.section-header .section-subtitle {
  margin-inline: auto;
}

/* --- Header --- */
.header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: oklch(from var(--color-bg) l c h / 0.92);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--color-divider);
  transition: box-shadow var(--transition-interactive);
}

.header--scrolled {
  box-shadow: var(--shadow-sm);
}

.header__inner {
  max-width: var(--content-wide);
  margin: 0 auto;
  padding: var(--space-4) clamp(var(--space-4), 5vw, var(--space-10));
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-6);
}

.logo {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  text-decoration: none;
  color: var(--color-primary);
  font-family: var(--font-display);
  font-size: var(--text-base);
  font-weight: 700;
  white-space: nowrap;
}

.logo__img {
  height: 56px;
  width: auto;
  max-width: 180px;
  object-fit: contain;
  flex-shrink: 0;
}

.logo--light .logo__img {
  height: 64px;
  max-width: 200px;
}

.logo--light {
  color: var(--color-primary);
}

.logo__icon {
  flex-shrink: 0;
}

.nav__list {
  display: flex;
  align-items: center;
  gap: var(--space-8);
}

.nav__link {
  font-size: var(--text-sm);
  font-weight: 500;
  text-decoration: none;
  color: var(--color-text-muted);
}

.nav__link:hover {
  color: var(--color-primary);
}

.header__actions {
  display: flex;
  align-items: center;
  gap: var(--space-3);
}

.theme-toggle {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: var(--radius-full);
  color: var(--color-text-muted);
  border: 1px solid var(--color-border);
}

.theme-toggle:hover {
  color: var(--color-primary);
  border-color: var(--color-primary);
}

.nav-toggle {
  display: none;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: var(--radius-md);
  color: var(--color-text);
}

.mobile-nav {
  display: none;
  padding: var(--space-4);
  border-top: 1px solid var(--color-divider);
  background: var(--color-bg);
}

.mobile-nav.open {
  display: block;
}

.mobile-nav ul {
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
}

.mobile-nav__link {
  display: block;
  padding: var(--space-3) var(--space-4);
  font-size: var(--text-base);
  font-weight: 500;
  text-decoration: none;
  color: var(--color-text);
  border-radius: var(--radius-md);
}

.mobile-nav__link:hover {
  background: var(--color-surface-offset);
}

/* --- Hero --- */
.hero {
  position: relative;
  min-height: 90vh;
  display: flex;
  align-items: center;
  overflow: hidden;
}

.hero__image-wrap {
  position: absolute;
  inset: 0;
  z-index: 0;
}

.hero__image {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero__overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(105deg,
    oklch(from var(--color-bg) l c h / 0.93) 0%,
    oklch(from var(--color-bg) l c h / 0.8) 38%,
    oklch(from var(--color-bg) l c h / 0.25) 68%,
    transparent 100%
  );
}

[data-theme='dark'] .hero__overlay {
  background: linear-gradient(105deg,
    oklch(from var(--color-bg) l c h / 0.95) 0%,
    oklch(from var(--color-bg) l c h / 0.82) 35%,
    oklch(from var(--color-bg) l c h / 0.3) 65%,
    oklch(from var(--color-bg) l c h / 0.1) 100%
  );
}

.hero__content {
  position: relative;
  z-index: 1;
  max-width: 640px;
  padding: var(--space-32) clamp(var(--space-4), 5vw, var(--space-10));
  margin-left: auto;
  margin-right: auto;
  max-width: var(--content-default);
  width: 100%;
}

.hero__logo {
  width: 480px;
  max-width: 480px;
  height: auto;
  margin-left: -110px;
  margin-bottom: var(--space-6);
  border-radius: var(--radius-lg);
}

.hero__title {
  font-size: var(--text-2xl);
  font-weight: 500;
  line-height: 1.1;
  margin-bottom: var(--space-5);
  color: var(--color-text);
  font-weight: 550;
  text-shadow: 0 0 8px oklch(from var(--color-bg) l c h / 0.8), 0 0 20px oklch(from var(--color-bg) l c h / 0.6);
}

.hero__subtitle {
  font-size: var(--text-lg);
  font-weight: 450;
  color: color-mix(in oklab, var(--color-text) 60%, var(--color-text-muted));
  text-shadow: 0 0 6px oklch(from var(--color-bg) l c h / 0.8), 0 0 16px oklch(from var(--color-bg) l c h / 0.6);
  margin-bottom: var(--space-8);
  max-width: 52ch;
}

.hero__cta {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-4);
}

/* --- Stats --- */
.stats {
  background: var(--color-primary);
  padding: var(--space-16) 0;
}

.stats__grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--space-8);
  text-align: center;
}

.stat__number {
  display: block;
  font-family: var(--font-display);
  font-size: var(--text-2xl);
  font-weight: 700;
  color: #fff;
  margin-bottom: var(--space-2);
}

.stat__label {
  font-size: var(--text-sm);
  color: oklch(from #fff l c h / 0.8);
  letter-spacing: 0.04em;
}

/* --- About --- */
.about {
  padding: clamp(var(--space-16), 8vw, var(--space-32)) 0;
}

.about__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(var(--space-8), 6vw, var(--space-20));
  align-items: center;
}

.about__image-wrap {
  border-radius: var(--radius-2xl);
  overflow: hidden;
  box-shadow: var(--shadow-lg);
  aspect-ratio: 4/5;
}

.about__image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 85%;
}
.about__figure { margin: 0; }
.about__caption {
  margin-top: var(--space-3);
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  border-left: 3px solid var(--color-primary);
  padding-left: var(--space-3);
}
.about__caption strong { color: var(--color-text); font-weight: 600; }

.about__content p {
  margin-bottom: var(--space-4);
  color: var(--color-text-muted);
}

.about__values {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-6);
  margin-top: var(--space-8);
}

.value {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  color: var(--color-primary);
}

.value__icon {
  flex-shrink: 0;
}

.value__text {
  font-size: var(--text-sm);
  font-weight: 600;
}

/* --- Adoptable Pets --- */
.adopt {
  background: var(--color-surface-2);
  padding: clamp(var(--space-16), 8vw, var(--space-32)) 0;
}

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

.pet-card {
  background: var(--color-surface);
  border-radius: var(--radius-xl);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: transform var(--transition-interactive), box-shadow var(--transition-interactive);
}

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

.pet-card__image-wrap {
  position: relative;
  aspect-ratio: 4/3;
  overflow: hidden;
}

.pet-card__image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 400ms cubic-bezier(0.16, 1, 0.3, 1);
}

.pet-card:hover .pet-card__image {
  transform: scale(1.05);
}

.pet-card__badge {
  position: absolute;
  top: var(--space-3);
  left: var(--space-3);
  font-size: var(--text-xs);
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: #fff;
  background: var(--color-coral);
  padding: var(--space-1) var(--space-3);
  border-radius: var(--radius-full);
}

.pet-card__body {
  padding: var(--space-5);
}

.pet-card__name {
  font-size: var(--text-lg);
  font-weight: 700;
  margin-bottom: var(--space-2);
}

.pet-card__meta {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  font-size: var(--text-xs);
  color: var(--color-text-muted);
  margin-bottom: var(--space-3);
}

.dot {
  color: var(--color-text-faint);
}

.pet-card__desc {
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  margin-bottom: var(--space-4);
}

.adopt__cta {
  text-align: center;
  margin-top: var(--space-10);
}

/* --- How It Works --- */
.how-it-works {
  padding: clamp(var(--space-16), 8vw, var(--space-32)) 0;
}

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

.step {
  position: relative;
  text-align: center;
  padding: var(--space-6);
  background: var(--color-surface);
  border-radius: var(--radius-xl);
  border: 1px solid var(--color-divider);
}

.step__number {
  position: absolute;
  top: var(--space-4);
  right: var(--space-5);
  font-family: var(--font-display);
  font-size: var(--text-xl);
  font-weight: 700;
  color: var(--color-primary-highlight);
  opacity: 0.6;
}

.step__icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 56px;
  height: 56px;
  margin: 0 auto var(--space-4);
  border-radius: var(--radius-full);
  background: var(--color-primary-highlight);
  color: var(--color-primary);
}

.step__title {
  font-size: var(--text-base);
  font-weight: 700;
  margin-bottom: var(--space-2);
}

.step__desc {
  font-size: var(--text-sm);
  color: var(--color-text-muted);
}

/* --- Success Story --- */
.success-story {
  background: var(--color-surface-offset);
  padding: clamp(var(--space-16), 8vw, var(--space-32)) 0;
}

.success-story__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(var(--space-8), 6vw, var(--space-20));
  align-items: center;
}

.success-story__image-wrap {
  border-radius: var(--radius-2xl);
  overflow: hidden;
  box-shadow: var(--shadow-lg);
  aspect-ratio: 4/3;
}

.success-story__image {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.success-story__quote p {
  font-family: var(--font-display);
  font-size: var(--text-xl);
  font-weight: 400;
  line-height: 1.4;
  color: var(--color-text);
  margin-bottom: var(--space-6);
}

.success-story__author {
  display: flex;
  align-items: center;
  gap: var(--space-3);
}

.success-story__avatar {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  border-radius: var(--radius-full);
  background: var(--color-coral);
  color: #fff;
  font-size: var(--text-sm);
  font-weight: 700;
}

.success-story__name {
  font-weight: 600;
  font-size: var(--text-sm);
}

.success-story__role {
  font-size: var(--text-xs);
  color: var(--color-text-muted);
}

/* --- Animal Stories --- */
.stories {
  background: var(--color-surface);
  padding: clamp(var(--space-16), 8vw, var(--space-32)) 0;
}

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

.story-card {
  background: var(--color-bg);
  border-radius: var(--radius-xl);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: transform var(--transition-interactive), box-shadow var(--transition-interactive);
  display: flex;
  flex-direction: column;
}

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

.story-card__image-wrap {
  position: relative;
  aspect-ratio: 4/3;
  overflow: hidden;
}

.story-card__image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 400ms cubic-bezier(0.16, 1, 0.3, 1);
}

.story-card:hover .story-card__image {
  transform: scale(1.05);
}

.story-card__badge {
  position: absolute;
  top: var(--space-3);
  right: var(--space-3);
  font-size: var(--text-xs);
  font-weight: 600;
  letter-spacing: 0.04em;
  color: #fff;
  background: var(--color-primary);
  padding: var(--space-1) var(--space-3);
  border-radius: var(--radius-full);
}

.story-card__body {
  padding: var(--space-5);
  flex-grow: 1;
}

.story-card__name {
  font-size: var(--text-lg);
  font-weight: 700;
  margin-bottom: var(--space-2);
}

.story-card__story {
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  line-height: 1.7;
}

.stories__cta {
  text-align: center;
  margin-top: var(--space-10);
}

/* --- Image Divider --- */
.image-divider {
  position: relative;
  height: clamp(280px, 45vw, 520px);
  overflow: hidden;
}
.image-divider img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.image-divider::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, oklch(0.2 0.02 60 / 0.65), transparent 60%);
}
.image-divider__caption {
  position: absolute;
  left: 50%;
  bottom: var(--space-10);
  transform: translateX(-50%);
  z-index: 1;
  width: min(90%, 720px);
  text-align: center;
  color: #fff;
  font-family: var(--font-display);
  font-size: var(--text-xl);
  line-height: 1.3;
}

/* --- Gallery --- */
.gallery {
  padding: clamp(var(--space-16), 8vw, var(--space-32)) 0;
}
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  grid-auto-rows: 220px;
  grid-auto-flow: dense;
  gap: var(--space-4);
}
.gallery-item {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  margin: 0;
}
.gallery-item--wide { grid-column: span 2; }
.gallery-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.gallery-item figcaption {
  position: absolute;
  left: var(--space-3);
  bottom: var(--space-3);
  font-size: var(--text-xs);
  font-weight: 600;
  color: #fff;
  background: oklch(0.2 0.02 60 / 0.6);
  padding: var(--space-1) var(--space-3);
  border-radius: var(--radius-full);
}

/* --- Ways to Help --- */
.help {
  padding: clamp(var(--space-16), 8vw, var(--space-32)) 0;
}

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

.help-card {
  background: var(--color-surface);
  border: 1px solid var(--color-divider);
  border-radius: var(--radius-xl);
  padding: var(--space-6);
  display: flex;
  flex-direction: column;
  transition: transform var(--transition-interactive), box-shadow var(--transition-interactive);
}

.help-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
}

.help-card--featured {
  background: var(--color-primary);
  border-color: var(--color-primary);
  color: var(--color-text-inverse);
}

.help-card--featured .help-card__desc {
  color: oklch(from #fff l c h / 0.85);
}

.help-card--featured .help-card__icon {
  background: oklch(from #fff l c h / 0.15);
  color: #fff;
}

.help-card__icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 56px;
  height: 56px;
  border-radius: var(--radius-md);
  background: var(--color-primary-highlight);
  color: var(--color-primary);
  margin-bottom: var(--space-4);
}

.help-card__title {
  font-size: var(--text-lg);
  font-weight: 700;
  margin-bottom: var(--space-3);
}

.help-card__desc {
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  margin-bottom: var(--space-5);
  flex-grow: 1;
}

/* --- Donate --- */
.donate {
  background: var(--color-surface-2);
  padding: clamp(var(--space-16), 8vw, var(--space-32)) 0;
}
.donate__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(var(--space-8), 6vw, var(--space-16));
  align-items: start;
}
.donate__content > p { color: var(--color-text-muted); margin-bottom: var(--space-6); }
.donate__uses { display: flex; flex-direction: column; gap: var(--space-4); margin-bottom: var(--space-8); }
.donate__uses li { display: flex; gap: var(--space-3); align-items: flex-start; font-size: var(--text-sm); }
.donate__uses svg { flex-shrink: 0; color: var(--color-primary); margin-top: 2px; }
.donate__tax {
  font-size: var(--text-xs) !important;
  color: var(--color-text-muted);
  border-left: 3px solid var(--color-gold);
  padding-left: var(--space-3);
}
.donate__form-wrap {
  background: var(--color-surface);
  border: 1px solid var(--color-divider);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-md);
  padding: var(--space-6);
}
.donate__embed iframe { width: 100%; min-height: 720px; border: 0; display: block; }
.donate__placeholder { text-align: center; padding: var(--space-8) var(--space-4); }
.donate__placeholder svg { margin: 0 auto var(--space-4); color: var(--color-coral); }
.donate__placeholder h3 { font-size: var(--text-lg); margin-bottom: var(--space-3); }
.donate__placeholder p { font-size: var(--text-sm); color: var(--color-text-muted); margin: 0 auto var(--space-6); }
.donate__alt { font-size: var(--text-xs); color: var(--color-text-muted); text-align: center; margin-top: var(--space-3); }
.donate__alt a { color: var(--color-primary); }

/* --- Contact / Newsletter --- */
.contact {
  padding: clamp(var(--space-12), 6vw, var(--space-20)) 0;
}

.contact__card {
  background: var(--color-primary);
  border-radius: var(--radius-2xl);
  padding: clamp(var(--space-8), 5vw, var(--space-16));
  color: var(--color-text-inverse);
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(var(--space-8), 4vw, var(--space-16));
  align-items: center;
}

.contact__desc {
  font-size: var(--text-sm);
  color: oklch(from #fff l c h / 0.8);
  margin-top: var(--space-3);
}

.newsletter {
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
}

.newsletter__field {
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
}

.newsletter__input {
  width: 100%;
  padding: var(--space-4) var(--space-5);
  font-size: var(--text-base);
  border-radius: var(--radius-md);
  border: 2px solid oklch(from #fff l c h / 0.25);
  background: oklch(from #fff l c h / 0.1);
  color: #fff;
}

.newsletter__input::placeholder {
  color: oklch(from #fff l c h / 0.5);
}

.newsletter__input:focus {
  outline: none;
  border-color: #fff;
  background: oklch(from #fff l c h / 0.15);
}

.newsletter__note {
  font-size: var(--text-xs);
  color: oklch(from #fff l c h / 0.7);
  min-height: var(--space-5);
}

.contact__info {
  margin-top: var(--space-8);
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
}

.contact__item {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  font-size: var(--text-sm);
  color: oklch(from #fff l c h / 0.85);
}

/* --- Footer --- */
.footer {
  background: var(--color-surface-offset);
  padding: clamp(var(--space-12), 6vw, var(--space-20)) 0 var(--space-8);
  border-top: 1px solid var(--color-divider);
}

.footer__grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: var(--space-8);
  margin-bottom: var(--space-10);
}

.footer__tagline {
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  margin-top: var(--space-3);
  max-width: 35ch;
}

.footer__ein {
  font-size: var(--text-xs);
  color: var(--color-text-faint);
  margin-top: var(--space-2);
}

.footer__heading {
  font-family: var(--font-body);
  font-size: var(--text-sm);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: var(--space-4);
}

.footer__list {
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
}

.footer__list a {
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  text-decoration: none;
}

.footer__list a:hover {
  color: var(--color-primary);
}

.footer__social {
  display: flex;
  gap: var(--space-3);
  margin-bottom: var(--space-4);
}

.footer__social-link {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: var(--radius-full);
  background: var(--color-surface);
  color: var(--color-text-muted);
  border: 1px solid var(--color-border);
}

.footer__social-link:hover {
  background: var(--color-primary);
  color: #fff;
  border-color: var(--color-primary);
}

.footer__hours {
  font-size: var(--text-xs);
  color: var(--color-text-muted);
  line-height: 1.6;
}

.footer__bottom {
  padding-top: var(--space-8);
  border-top: 1px solid var(--color-divider);
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: var(--space-2);
}

.footer__bottom p {
  font-size: var(--text-xs);
  color: var(--color-text-faint);
}

/* --- Responsive --- */
@media (max-width: 1024px) {
  .stats__grid { grid-template-columns: repeat(2, 1fr); gap: var(--space-10); }
  .stories-grid { grid-template-columns: repeat(2, 1fr); }
  .gallery-grid { grid-template-columns: repeat(2, 1fr); grid-auto-rows: 200px; }
  .help-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 860px) {
  .nav { display: none; }
  .nav-toggle { display: flex; }
  .header__actions .btn--sm { display: none; }
  .logo__img { height: 44px; max-width: 140px; }
  .hero__logo { width: 390px; max-width: 100%; margin-left: 0; }
  .about__grid { grid-template-columns: 1fr; }
  .about__image-wrap { aspect-ratio: 16/10; max-height: 400px; }
  .success-story__grid { grid-template-columns: 1fr; }
  .contact__card { grid-template-columns: 1fr; }
  .donate__grid { grid-template-columns: 1fr; }
  .steps { grid-template-columns: 1fr; }
  .footer__grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 640px) {
  .pets-grid { grid-template-columns: 1fr; }
  .stories-grid { grid-template-columns: 1fr; }
  .gallery-grid { grid-template-columns: 1fr 1fr; grid-auto-rows: 150px; gap: var(--space-2); }
  .image-divider__caption { font-size: var(--text-lg); bottom: var(--space-6); }
  .steps { grid-template-columns: 1fr; }
  .help-grid { grid-template-columns: 1fr; }
  .footer__grid { grid-template-columns: 1fr; }
  .footer__bottom { flex-direction: column; text-align: center; }
  .hero__cta { flex-direction: column; align-items: stretch; }
  .hero__cta .btn { text-align: center; }
  .stats__grid { grid-template-columns: 1fr 1fr; gap: var(--space-6); }
}

@media (max-width: 400px) {
  .stats__grid { grid-template-columns: 1fr; }
}


/* --- Animal Stories: flexible grid for any number of residents --- */
.stories-grid {
  display: flex !important;
  flex-wrap: wrap;
  justify-content: center;
  gap: var(--space-6);
}
.stories-grid > .story-card { flex: 0 1 calc((100% - 3 * var(--space-6)) / 4); min-width: 230px; }
.story-card__story--soon { font-style: italic; color: var(--color-text-faint, var(--color-text-muted)); }
@media (max-width: 1024px) { .stories-grid > .story-card { flex-basis: calc((100% - var(--space-6)) / 2); } }
@media (max-width: 560px) { .stories-grid > .story-card { flex-basis: 100%; } }

/* --- In Loving Memory --- */
.memorial {
  background: var(--color-surface-2);
  padding: clamp(var(--space-16), 8vw, var(--space-24)) 0;
}
.memorial .eyebrow { color: var(--color-text-muted); }
.memorial__empty {
  max-width: 560px;
  margin: 0 auto;
  text-align: center;
  padding: var(--space-8) var(--space-6);
  border: 1px dashed var(--color-divider);
  border-radius: var(--radius-xl);
  color: var(--color-text-muted);
}
.memorial__empty svg { margin: 0 auto var(--space-3); color: var(--color-coral); opacity: .8; }

.story-card__photo-soon {
  width: 100%; height: 100%;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: var(--space-2);
  background: var(--color-surface-2);
  color: var(--color-text-faint);
  font-size: var(--text-sm);
}

.story-card--memorial .story-card__image { filter: saturate(0.85); }
.story-card--memorial .story-card__badge { background: var(--color-text-muted); }

.story-card__story a { color: var(--color-primary); text-decoration: underline; text-underline-offset: 2px; }

/* ============================================
   Animal tiles (index) + Animal bio pages
   ============================================ */
.animal-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--space-5, 1.25rem);
}
.animal-tile {
  position: relative;
  display: block;
  border-radius: var(--radius-xl);
  overflow: hidden;
  aspect-ratio: 1 / 1;
  background: var(--color-surface-2);
  box-shadow: var(--shadow-sm);
  text-decoration: none;
  color: #fff;
  transition: transform 300ms cubic-bezier(0.16, 1, 0.3, 1), box-shadow 300ms;
}
.animal-tile:hover, .animal-tile:focus-visible { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.animal-tile:focus-visible { outline: 3px solid var(--color-primary); outline-offset: 3px; }
.animal-tile__media, .animal-tile__img { width: 100%; height: 100%; }
.animal-tile__img { object-fit: cover; display: block; transition: transform 600ms cubic-bezier(0.16, 1, 0.3, 1); }
.animal-tile:hover .animal-tile__img { transform: scale(1.05); }
.animal-tile__label {
  position: absolute; inset: auto 0 0 0;
  padding: var(--space-10, 2.5rem) var(--space-4) var(--space-4);
  background: linear-gradient(to top, rgba(20, 16, 10, 0.78), rgba(20, 16, 10, 0));
  display: flex; flex-direction: column; gap: 2px;
}
.animal-tile__name {
  font-family: var(--font-display);
  font-size: var(--text-lg);
  font-weight: 600;
  line-height: 1.15;
  color: #fff;
}
.animal-tile__species { font-size: var(--text-xs); letter-spacing: .04em; text-transform: uppercase; color: rgba(255,255,255,.85); }
.animal-photo-soon {
  width: 100%; height: 100%;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: var(--space-2);
  background: var(--color-surface-2);
  color: var(--color-text-faint);
  font-size: var(--text-sm);
  padding-bottom: var(--space-12, 3rem);
}
.animal-tile--memorial .animal-tile__img { filter: saturate(0.8); }
.animal-grid--memorial .animal-photo-soon { background: var(--color-surface); }
@media (max-width: 1024px) { .animal-grid { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 640px) {
  .animal-grid { grid-template-columns: repeat(2, 1fr); gap: var(--space-3); }
  .animal-tile__label { padding: var(--space-8) var(--space-3) var(--space-3); }
  .animal-tile__name { font-size: var(--text-base); }
}

/* --- Animal bio page --- */
.animal-page { padding: var(--space-8) 0 var(--space-20, 5rem); }
.animal-page__container { max-width: 1100px; }
.animal-page__back {
  display: inline-flex; align-items: center; gap: var(--space-1);
  color: var(--color-primary); font-weight: 600; font-size: var(--text-sm);
  text-decoration: none; margin-bottom: var(--space-6);
}
.animal-page__back:hover { text-decoration: underline; }
.animal-page__article {
  display: grid; grid-template-columns: 1.1fr 1fr;
  gap: clamp(var(--space-6), 5vw, var(--space-12));
  align-items: start;
}
.animal-page__cover {
  border-radius: var(--radius-2xl);
  overflow: hidden;
  box-shadow: var(--shadow-lg);
  aspect-ratio: 4 / 5;
  background: var(--color-surface-2);
}
.animal-page__cover-img { width: 100%; height: 100%; object-fit: cover; display: block; }
.animal-page__body { padding-top: var(--space-4); }
.animal-page__name {
  font-family: var(--font-display);
  font-size: clamp(2.25rem, 5vw, 3.5rem);
  line-height: 1.05;
  margin: var(--space-2) 0 var(--space-3);
}
.animal-page__species {
  display: inline-block;
  background: var(--color-primary); color: #fff;
  font-size: var(--text-xs); font-weight: 600; letter-spacing: .04em; text-transform: uppercase;
  padding: 4px 12px; border-radius: 999px;
  margin-bottom: var(--space-6);
}
.animal-page--memorial .animal-page__species { background: var(--color-text-muted); }
.animal-page--memorial .animal-page__cover-img { filter: saturate(0.85); }
.animal-page__bio p { font-size: var(--text-base); line-height: 1.75; color: var(--color-text-muted); margin-bottom: var(--space-4); max-width: 60ch; }
.animal-page__bio a { color: var(--color-primary); text-decoration: underline; text-underline-offset: 2px; }
.animal-page__soon { font-style: italic; color: var(--color-text-faint) !important; }
.animal-page__more { margin-top: var(--space-16, 4rem); }
.animal-page__more-title { font-family: var(--font-display); font-size: var(--text-xl); margin-bottom: var(--space-5); }
.animal-page__photos { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--space-4); }
.animal-page__photo { margin: 0; border-radius: var(--radius-xl); overflow: hidden; aspect-ratio: 1/1; }
.animal-page__photo img { width: 100%; height: 100%; object-fit: cover; display: block; }
.animal-page__pager {
  display: flex; justify-content: space-between; gap: var(--space-4);
  margin-top: var(--space-16, 4rem); padding-top: var(--space-6);
  border-top: 1px solid var(--color-divider);
}
.animal-page__pager-link {
  display: inline-flex; align-items: center; gap: var(--space-2);
  color: var(--color-text); font-weight: 600; text-decoration: none;
}
.animal-page__pager-link:hover { color: var(--color-primary); }
.animal-page__cta {
  margin-top: var(--space-12, 3rem);
  text-align: center;
  background: var(--color-surface-2);
  border-radius: var(--radius-2xl);
  padding: var(--space-10, 2.5rem) var(--space-6);
}
.animal-page__cta p { font-family: var(--font-display); font-size: var(--text-lg); margin-bottom: var(--space-5); }
.animal-page__cta-buttons { display: flex; gap: var(--space-3); justify-content: center; flex-wrap: wrap; }
@media (max-width: 860px) {
  .animal-page__article { grid-template-columns: 1fr; }
  .animal-page__cover { aspect-ratio: 4 / 3; }
  .animal-page__body { padding-top: 0; }
  .animal-page__photos { grid-template-columns: repeat(2, 1fr); }
}
.animal-photo-soon { display: flex !important; }
.contact__link { color: inherit; text-decoration: underline; text-underline-offset: 3px; }

.contact__emails { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.contact__email-note { font-size: var(--text-sm); opacity: .9; overflow-wrap: anywhere; }
.contact__link { overflow-wrap: anywhere; }
.contact__item:has(.contact__emails) { align-items: flex-start; }
.contact__email-note { display: flex; flex-direction: column; }
.contact__link { overflow-wrap: normal; word-break: normal; }
@media (max-width: 640px) {
  .contact__emails, .contact__email-note { font-size: var(--text-xs); }
}
/* Show cover photos at their natural shape (no side cropping) */
.animal-page__cover { aspect-ratio: auto !important; }
.animal-page__cover-img { height: auto; max-height: 78vh; }
.animal-page__cover .animal-photo-soon { aspect-ratio: 4 / 3; height: auto; }

/* Fit the whole landing section on one computer screen (no scrolling) */
@media (min-width: 901px) {
  .hero {
    min-height: 0;
    height: calc(100svh - var(--hero-offset, 120px));
    max-height: 1000px;
  }
  .hero__content {
    padding-top: clamp(var(--space-4), 3vh, var(--space-12));
    padding-bottom: clamp(var(--space-4), 3vh, var(--space-12));
  }
  .hero__logo {
    --logo-w: clamp(200px, 36vh, 480px);
    width: var(--logo-w);
    max-width: var(--logo-w);
    margin-left: calc(var(--logo-w) * -0.23);
    margin-bottom: clamp(var(--space-2), 1.2vh, var(--space-6));
  }
  .hero__content .badge, .hero__content > span { margin-bottom: clamp(var(--space-2), 1vh, var(--space-4)); }
  .hero__title {
    font-size: clamp(1.9rem, 5.2vh, 3.6rem);
    margin-bottom: clamp(var(--space-2), 1.6vh, var(--space-5));
  }
  .hero__subtitle {
    font-size: clamp(0.95rem, 2.1vh, 1.25rem);
    line-height: 1.5;
    margin-bottom: clamp(var(--space-4), 2.6vh, var(--space-8));
  }
}

/* Landing photo: keep full top-to-bottom (rainbow + animals); trim sides only */
@media (min-width: 901px) {
  .hero { background: var(--color-bg); }
  .hero__image-wrap {
    left: auto;
    right: 0;
    height: 100%;
    width: auto;
    aspect-ratio: 4 / 3;
    max-width: 100%;
    -webkit-mask-image: linear-gradient(to right, transparent 0, #000 22%);
            mask-image: linear-gradient(to right, transparent 0, #000 22%);
  }
  .hero__image { object-fit: cover; object-position: center; }
}
@media (min-width: 901px) {
  .hero__overlay {
    background: linear-gradient(100deg,
      oklch(from var(--color-bg) l c h / 0.85) 0%,
      oklch(from var(--color-bg) l c h / 0.5) 30%,
      oklch(from var(--color-bg) l c h / 0.12) 55%,
      transparent 75%);
  }
}
@media (min-width: 901px) and (max-width: 1199px) {
  .hero__logo { margin-left: 0; }
}

/* --- Kind Words (testimonials) --- */
.kind-words { padding: var(--space-24) 0; background: var(--color-surface-2, var(--color-bg)); }
.kw-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--space-6); }
.kw-grid:has(> .kw-empty) { grid-template-columns: 1fr; max-width: 640px; margin-inline: auto; }
.kw-card {
  position: relative; margin: 0;
  display: flex; flex-direction: column; gap: var(--space-4);
  padding: var(--space-8) var(--space-6) var(--space-6);
  background: var(--color-surface, #fff);
  border: 1px solid var(--color-border, oklch(0.9 0.01 90));
  border-radius: var(--radius-lg, 16px);
  box-shadow: 0 1px 2px oklch(0 0 0 / 0.04), 0 8px 24px oklch(0 0 0 / 0.05);
}
.kw-card__mark { color: var(--color-accent, var(--color-primary)); opacity: 0.55; }
.kw-card__quote { margin: 0; flex: 1; }
.kw-card__quote p { font-size: var(--text-base); line-height: 1.65; color: var(--color-text); }
.kw-card__by { display: flex; flex-direction: column; gap: 2px; padding-top: var(--space-4); border-top: 1px solid var(--color-border, oklch(0.9 0.01 90)); }
.kw-card__name { font-weight: 600; color: var(--color-text); }
.kw-card__role { font-size: var(--text-sm); color: var(--color-text-muted); }
.kw-empty {
  text-align: center; padding: var(--space-10) var(--space-8);
  border: 1.5px dashed var(--color-border, oklch(0.85 0.02 90));
  border-radius: var(--radius-lg, 16px);
  color: var(--color-text-muted);
}
.kw-empty__title { font-family: var(--font-display, inherit); font-size: var(--text-lg); color: var(--color-text); margin-bottom: var(--space-2); }
.kw-actions { display: flex; flex-wrap: wrap; justify-content: center; gap: var(--space-4); margin-top: var(--space-10); }
.kw-page { padding: var(--space-10) 0 var(--space-24); }
.kw-page__header { margin-top: var(--space-8); }
.kw-page h1.section-title { font-size: var(--text-2xl); }
.kw-share {
  max-width: 720px; margin: var(--space-16) auto 0; text-align: center;
  padding: var(--space-10) var(--space-8);
  background: var(--color-surface-2, oklch(0.96 0.01 90));
  border-radius: var(--radius-xl, 24px);
}
.kw-share__title { font-family: var(--font-display, inherit); font-size: var(--text-xl); margin-bottom: var(--space-3); }
.kw-share p { color: var(--color-text-muted); max-width: 56ch; margin: 0 auto; }
.kw-share__buttons { display: flex; flex-wrap: wrap; justify-content: center; gap: var(--space-4); margin-top: var(--space-6); }
@media (max-width: 1024px) { .kw-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 640px) {
  .kw-grid { grid-template-columns: 1fr; }
  .kw-actions .btn, .kw-share__buttons .btn { width: 100%; text-align: center; }
}
/* Seven menu links: tighten spacing on mid-size screens */
@media (min-width: 861px) and (max-width: 1279px) {
  .nav__list { gap: var(--space-5); }
}
@media (min-width: 861px) and (max-width: 1099px) {
  .nav__list { gap: var(--space-3); }
  .nav__link { font-size: var(--text-xs); white-space: nowrap; }
}
.nav__link { white-space: nowrap; }
@media (min-width: 861px) and (max-width: 1399px) { .nav__list { gap: var(--space-5); } }
@media (min-width: 1100px) and (max-width: 1279px) { .nav__list { gap: var(--space-4); } }

/* --- Private feedback ("Help us improve") --- */
.improve {
  display: grid; grid-template-columns: 1fr 1.4fr; gap: var(--space-12);
  margin-top: var(--space-20); padding: var(--space-12);
  background: var(--color-surface); border: 1px solid var(--color-border);
  border-radius: var(--radius-xl); scroll-margin-top: 100px;
}
.improve__title { font-family: var(--font-display); font-size: var(--text-xl); margin: var(--space-2) 0 var(--space-4); }
.improve__intro p { color: var(--color-text-muted); }
.improve__points { margin-top: var(--space-6); display: grid; gap: var(--space-2); padding: 0; list-style: none; }
.improve__points li { position: relative; padding-left: var(--space-6); font-size: var(--text-sm); color: var(--color-text); }
.improve__points li::before {
  content: ""; position: absolute; left: 0; top: 0.45em; width: 10px; height: 10px; border-radius: 50%;
  background: var(--color-primary);
}
.improve__form { display: grid; gap: var(--space-5); }
.improve__row { display: grid; grid-template-columns: 1fr 1fr; gap: var(--space-5); }
.improve__field { display: grid; gap: var(--space-2); font-size: var(--text-sm); font-weight: 500; color: var(--color-text); }
.improve__field em { font-style: normal; font-weight: 400; color: var(--color-text-muted); }
.improve__field input, .improve__field select, .improve__field textarea {
  width: 100%; font: inherit; font-weight: 400; font-size: var(--text-base); color: var(--color-text);
  padding: 0.7rem 0.9rem; background: var(--color-bg); border: 1px solid var(--color-border); border-radius: var(--radius-md, 10px);
}
.improve__field textarea { resize: vertical; min-height: 120px; }
.improve__field input:focus, .improve__field select:focus, .improve__field textarea:focus {
  outline: 2px solid var(--color-primary); outline-offset: 1px; border-color: transparent;
}
.improve__error { color: #b3261e; font-weight: 500; }
[data-theme='dark'] .improve__error { color: #ff8a80; }
.improve__form .btn { justify-self: start; }
.improve__note { font-size: var(--text-xs); color: var(--color-text-muted); }
.kw-improve-link { text-align: center; margin-top: var(--space-6); font-size: var(--text-sm); color: var(--color-text-muted); }
.kw-improve-link a { color: var(--color-primary); font-weight: 600; }
@media (max-width: 860px) {
  .improve { grid-template-columns: 1fr; gap: var(--space-8); padding: var(--space-8) var(--space-6); }
}
@media (max-width: 640px) {
  .improve__row { grid-template-columns: 1fr; }
  .improve__form .btn { justify-self: stretch; text-align: center; }
}
.improve__row { align-items: end; }

/* --- Share your photos (permission + email) --- */
.photos-share {
  display: grid; grid-template-columns: 1fr 1.4fr; gap: var(--space-12);
  margin-top: var(--space-16); padding: var(--space-12);
  background: var(--color-surface); border: 1px solid var(--color-border);
  border-radius: var(--radius-xl); scroll-margin-top: 100px;
}
.photos-share__intro p { color: var(--color-text-muted); }
.photos-share__steps { margin: var(--space-6) 0; padding-left: 1.25rem; display: grid; gap: var(--space-2); font-size: var(--text-sm); color: var(--color-text); }
.photos-share__fine { font-size: var(--text-sm); }
.photos-share__consent { border: 1px solid var(--color-border); border-radius: var(--radius-md, 10px); padding: var(--space-4) var(--space-5); margin: 0; display: grid; gap: var(--space-3); background: var(--color-bg); }
.photos-share__consent legend { font-size: var(--text-sm); font-weight: 600; padding: 0 var(--space-2); }
.photos-share__consent label { display: grid; grid-template-columns: auto 1fr; gap: var(--space-3); align-items: start; font-size: var(--text-sm); line-height: 1.5; cursor: pointer; }
.photos-share__consent input { width: 18px; height: 18px; margin-top: 2px; accent-color: var(--color-primary); }
@media (max-width: 860px) { .photos-share { grid-template-columns: 1fr; gap: var(--space-8); padding: var(--space-8) var(--space-6); } }
.kw-improve-link { max-width: none; margin-left: auto; margin-right: auto; }
.contact__address { font-style: normal; line-height: 1.5; }
.contact__item:has(.contact__address) { align-items: flex-start; }
.contact__item:has(.contact__address) svg { margin-top: 2px; }

/* Lighter peace sign in light mode (dark mode keeps its own color) */
.logo__icon { color: #6FA383; }
[data-theme='dark'] .logo__icon { color: var(--color-primary); }

/* Email helper window */
.mail-dialog {
  position: fixed; inset: 0; margin: auto; height: fit-content;
  width: min(92vw, 520px); max-height: 90dvh; overflow: auto;
  border: 1px solid var(--color-border); border-radius: var(--radius-xl);
  background: var(--color-surface); color: var(--color-text);
  padding: var(--space-6); box-shadow: var(--shadow-lg);
}
.mail-dialog::backdrop { background: oklch(0.2 0.02 60 / 0.55); }
.mail-dialog__close {
  position: absolute; top: var(--space-3); right: var(--space-3);
  width: 40px; height: 40px; border: 0; border-radius: 50%; background: transparent;
  color: var(--color-text-muted); font-size: 1.75rem; line-height: 1; cursor: pointer;
}
.mail-dialog__close:hover { background: var(--color-surface-offset); }
.mail-dialog__title { font-family: var(--font-display); font-size: var(--text-xl); margin: 0 0 var(--space-1); padding-right: 40px; }
.mail-dialog__lead { color: var(--color-text-muted); margin: 0 0 var(--space-4); }
.mail-dialog__row {
  display: flex; align-items: center; justify-content: space-between; gap: var(--space-3); flex-wrap: wrap;
  padding: var(--space-3) var(--space-4); border-radius: var(--radius-lg); background: var(--color-surface-offset);
}
.mail-dialog__label { display: block; font-size: var(--text-xs); color: var(--color-text-muted); margin-bottom: 2px; }
.mail-dialog__addr { overflow-wrap: anywhere; font-size: var(--text-base); }
.mail-dialog__msg { margin-top: var(--space-4); display: flex; flex-direction: column; gap: var(--space-1); }
.mail-dialog__msg[hidden] { display: none; }
.mail-dialog__subject { margin: 0 0 var(--space-2); font-weight: 600; overflow-wrap: anywhere; }
.mail-dialog__msg textarea {
  width: 100%; font: inherit; font-size: var(--text-sm); color: inherit; resize: vertical;
  background: var(--color-bg); border: 1px solid var(--color-border); border-radius: var(--radius-md, 8px); padding: var(--space-2) var(--space-3);
}
.mail-dialog__msg .mail-dialog__copy { align-self: flex-start; margin-top: var(--space-2); }
.mail-dialog__attach { margin: var(--space-3) 0 0; font-weight: 600; color: var(--color-primary); }
.mail-dialog__actions { display: flex; flex-direction: column; gap: var(--space-2); margin-top: var(--space-5); }
.mail-dialog__actions .btn { width: 100%; justify-content: center; text-align: center; }
.mail-dialog__note { margin: var(--space-4) 0 0; font-size: var(--text-sm); color: var(--color-text-muted); }
.mail-dialog [hidden] { display: none !important; }

/* Visit cards: keep buttons lined up at the bottom */
.pet-card { display: flex; flex-direction: column; }
.pet-card__body { flex: 1; display: flex; flex-direction: column; }
.pet-card__body > .btn { margin-top: auto; }
.pet-card__desc { margin-bottom: var(--space-4); }

/* Tall photos take two rows so heads and feet are not cut off */
.gallery-item--tall { grid-row: span 2; }

/* Visitor photos on the Kind Words page */
.visitor-photos { margin-top: var(--space-16); }
.visitor-photos .section-header { margin-bottom: var(--space-8); }

/* Show more photos */
.gallery-grid > [hidden] { display: none !important; }
.gallery-more { display: flex; flex-direction: column; align-items: center; gap: var(--space-3); margin-top: var(--space-8); }
.gallery-more__count { margin: 0; font-size: var(--text-sm); color: var(--color-text-muted); }
.gallery-more .btn[hidden] { display: none; }
.gallery-item:focus { outline: none; }

/* Contact card without newsletter form */
@media (min-width: 861px) { .contact__card > .contact__info { margin-top: 0; } }

/* Photo viewer */
img.zoomable { cursor: zoom-in; }
img.zoomable:focus-visible { outline: 3px solid var(--color-primary); outline-offset: 3px; }
html.lightbox-open, html.lightbox-open body { overflow: hidden; }
.lightbox { position: fixed; inset: 0; z-index: 1000; background: oklch(0.12 0.01 60 / 0.92); display: flex; align-items: center; justify-content: center; padding: 56px 72px 64px; }
.lightbox[hidden] { display: none; }
.lightbox__figure { margin: 0; max-width: 100%; max-height: 100%; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 12px; width: 100%; height: 100%; }
.lightbox__img { max-width: 100%; max-height: calc(100% - 44px); width: auto; height: auto; object-fit: contain; border-radius: 10px; box-shadow: 0 10px 40px rgb(0 0 0 / 0.4); background: #222; }
.lightbox__caption { color: #fff; font-size: var(--text-base); text-align: center; max-width: 60ch; line-height: 1.4; }
.lightbox__caption[hidden] { display: none; }
.lightbox__count { position: absolute; top: 16px; left: 50%; transform: translateX(-50%); margin: 0; color: rgb(255 255 255 / 0.75); font-size: var(--text-sm); }
.lightbox__close, .lightbox__nav { position: absolute; border: 0; background: rgb(255 255 255 / 0.14); color: #fff; border-radius: 999px; cursor: pointer; display: flex; align-items: center; justify-content: center; line-height: 1; transition: background 0.15s; }
.lightbox__close:hover, .lightbox__nav:hover { background: rgb(255 255 255 / 0.28); }
.lightbox__close:focus-visible, .lightbox__nav:focus-visible { outline: 3px solid #fff; outline-offset: 2px; }
.lightbox__close { top: 12px; right: 12px; width: 44px; height: 44px; font-size: 30px; }
.lightbox__nav { top: 50%; transform: translateY(-50%); width: 52px; height: 52px; font-size: 40px; padding-bottom: 4px; }
.lightbox__nav[hidden] { display: none; }
.lightbox__nav--prev { left: 12px; }
.lightbox__nav--next { right: 12px; }
@media (max-width: 640px) {
  .lightbox { padding: 60px 8px 72px; }
  .lightbox__nav { top: auto; bottom: 12px; transform: none; width: 48px; height: 48px; }
  .lightbox__nav--prev { left: calc(50% - 60px); }
  .lightbox__nav--next { right: calc(50% - 60px); }
  .lightbox__caption { font-size: var(--text-sm); padding: 0 8px; }
}
.gallery-item figcaption { pointer-events: none; }

/* Gallery link buttons */
.gallery-links { display: flex; flex-wrap: wrap; justify-content: center; gap: var(--space-3); margin-top: var(--space-6); }
@media (max-width: 480px) { .gallery-links .btn { width: 100%; max-width: 320px; } }

.pet-card__note{margin-top:calc(-1*var(--space-2,0.5rem));margin-bottom:var(--space-4,1rem);padding:0.5rem 0.75rem;border-radius:0.5rem;background:color-mix(in srgb,var(--color-primary,#2d5a3d) 10%,transparent);font-size:0.9rem;line-height:1.45;}

.about__image--ron{object-position:55% center;}
@media (max-width: 1024px){.about__figure:has(.about__image--ron) .about__image-wrap{aspect-ratio:1/1;max-height:none;max-width:520px;}.about__figure:has(.about__image--ron) .about__caption{max-width:520px;}}
