/* ===========================================================
   Pet Adoption Website — Shared Stylesheet
   Theme: warm orange, cream, dark cocoa
   =========================================================== */

:root {
  --orange:        #FF8C42;
  --orange-deep:   #E55934;
  --orange-soft:   #FFB07A;
  --cream:         #FFF8F0;
  --peach:         #FFE4CC;
  --peach-strong:  #FFCFA8;
  --dark:          #2D1810;
  --dark-soft:     #5C3A28;
  --muted:         #8B7164;
  --white:         #FFFFFF;
  --gold:          #FFC107;
  --green:         #4CAF50;
  --red:           #E53935;

  --shadow-sm: 0 2px 6px rgba(45, 24, 16, 0.06);
  --shadow-md: 0 6px 20px rgba(45, 24, 16, 0.08);
  --shadow-lg: 0 14px 40px rgba(45, 24, 16, 0.12);
  --radius-sm: 10px;
  --radius:    16px;
  --radius-lg: 24px;
  --radius-pill: 999px;

  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
          "Helvetica Neue", Arial, "Noto Sans", sans-serif,
          "Apple Color Emoji", "Segoe UI Emoji";
}

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  font-family: var(--font);
  color: var(--dark);
  background: var(--cream);
  line-height: 1.55;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
button { font-family: inherit; cursor: pointer; border: none; background: none; }
a { color: var(--orange-deep); text-decoration: none; }
a:hover { text-decoration: underline; }
h1, h2, h3, h4 { margin: 0 0 0.5em; line-height: 1.2; color: var(--dark); }
p { margin: 0 0 1em; }

/* ---------- Layout ---------- */
.container {
  width: min(1180px, 92%);
  margin: 0 auto;
}
.section { padding: 64px 0; }
.section-tight { padding: 40px 0; }
.section-title {
  font-size: 32px;
  font-weight: 800;
  text-align: center;
  margin-bottom: 8px;
}
.section-sub {
  text-align: center;
  color: var(--muted);
  margin-bottom: 40px;
  font-size: 17px;
}

/* ---------- Navbar ---------- */
.nav {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255, 248, 240, 0.92);
  backdrop-filter: saturate(180%) blur(12px);
  -webkit-backdrop-filter: saturate(180%) blur(12px);
  border-bottom: 1px solid var(--peach);
}
.nav-inner {
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px 0;
}
.logo {
  display: flex; align-items: center; gap: 10px;
  font-weight: 800; font-size: 20px; color: var(--dark);
  text-decoration: none;
}
.logo-mark {
  width: 38px; height: 38px; border-radius: 12px;
  background: linear-gradient(135deg, var(--orange) 0%, var(--orange-deep) 100%);
  display: grid; place-items: center;
  color: white; font-size: 20px;
  box-shadow: var(--shadow-sm);
}
.logo-text { letter-spacing: -0.5px; }
.logo-text span { color: var(--orange-deep); }

.nav-links {
  display: flex; gap: 4px; align-items: center;
  list-style: none; margin: 0; padding: 0;
}
.nav-links a {
  color: var(--dark);
  padding: 9px 16px;
  border-radius: var(--radius-pill);
  font-weight: 600; font-size: 15px;
  text-decoration: none;
  transition: background .18s, color .18s;
}
.nav-links a:hover { background: var(--peach); }
.nav-links a.active {
  background: var(--dark);
  color: white;
}

.nav-cart {
  display: inline-flex; align-items: center; gap: 6px;
  background: var(--orange);
  color: white;
  padding: 9px 16px;
  border-radius: var(--radius-pill);
  font-weight: 700; font-size: 14px;
  text-decoration: none;
  box-shadow: var(--shadow-sm);
  transition: transform .15s, background .15s;
}
.nav-cart:hover { background: var(--orange-deep); text-decoration: none; transform: translateY(-1px); }
.nav-cart-count {
  background: white; color: var(--orange-deep);
  border-radius: var(--radius-pill);
  min-width: 22px; height: 22px;
  display: inline-grid; place-items: center;
  font-size: 12px; font-weight: 800;
  padding: 0 6px;
}

.nav-burger {
  display: none;
  width: 40px; height: 40px; border-radius: 10px;
  align-items: center; justify-content: center;
  background: var(--peach);
  color: var(--dark-soft);
  font-size: 20px;
}

/* ---------- Hero ---------- */
.hero {
  position: relative; overflow: hidden;
  padding: 70px 0 60px;
}
.hero-grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 48px;
  align-items: center;
}
.hero-eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 6px 14px; border-radius: var(--radius-pill);
  background: var(--peach); color: var(--orange-deep);
  font-weight: 700; font-size: 13px;
  letter-spacing: 0.4px; text-transform: uppercase;
  margin-bottom: 18px;
}
.hero h1 {
  font-size: clamp(36px, 5.2vw, 56px);
  letter-spacing: -1.5px;
  font-weight: 800;
  margin-bottom: 18px;
}
.hero h1 em {
  font-style: normal;
  background: linear-gradient(120deg, var(--orange) 0%, var(--orange-deep) 100%);
  -webkit-background-clip: text; background-clip: text;
  color: transparent;
}
.hero-lead {
  font-size: 19px; color: var(--dark-soft);
  max-width: 520px; margin-bottom: 28px;
}
.hero-cta { display: flex; gap: 12px; flex-wrap: wrap; }

.hero-illustration {
  aspect-ratio: 1 / 1;
  border-radius: 48% 52% 38% 62% / 56% 42% 58% 44%;
  background:
    radial-gradient(circle at 30% 28%, rgba(255,255,255,0.6), transparent 50%),
    linear-gradient(135deg, var(--orange) 0%, var(--orange-deep) 100%);
  display: grid; place-items: center;
  box-shadow: var(--shadow-lg);
  position: relative;
  animation: blob 16s ease-in-out infinite;
}
.hero-illustration .emoji {
  font-size: clamp(120px, 18vw, 200px);
  filter: drop-shadow(0 10px 16px rgba(0,0,0,0.15));
}
@keyframes blob {
  0%, 100% { border-radius: 48% 52% 38% 62% / 56% 42% 58% 44%; }
  50%      { border-radius: 38% 62% 52% 48% / 44% 56% 44% 56%; }
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 13px 24px;
  border-radius: var(--radius-pill);
  font-weight: 700; font-size: 15px;
  background: var(--orange); color: white;
  box-shadow: var(--shadow-sm);
  transition: transform .15s, background .15s, box-shadow .15s;
  text-decoration: none;
}
.btn:hover {
  background: var(--orange-deep);
  transform: translateY(-1px);
  box-shadow: var(--shadow-md);
  text-decoration: none;
  color: white;
}
.btn-ghost {
  background: transparent;
  color: var(--dark);
  border: 2px solid var(--dark);
  padding: 11px 22px;
  box-shadow: none;
}
.btn-ghost:hover { background: var(--dark); color: white; }
.btn-light {
  background: white; color: var(--orange-deep);
  border: 2px solid var(--peach-strong);
}
.btn-light:hover { background: var(--peach); color: var(--orange-deep); }
.btn-sm { padding: 8px 14px; font-size: 13px; }
.btn-block { width: 100%; justify-content: center; }
.btn-danger { background: var(--red); }
.btn-danger:hover { background: #B71C1C; }

/* ---------- Search bar ---------- */
.search {
  display: flex; align-items: center;
  background: white;
  border-radius: var(--radius-pill);
  padding: 6px 6px 6px 22px;
  box-shadow: var(--shadow-md);
  border: 2px solid var(--peach);
  max-width: 560px; margin: 0 auto;
}
.search input {
  flex: 1; border: none; outline: none;
  font-size: 16px; padding: 12px 8px;
  background: transparent; color: var(--dark);
  font-family: inherit;
}
.search button { padding: 12px 22px; }

/* ---------- Card grid ---------- */
.grid {
  display: grid;
  gap: 24px;
}
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }
.grid-2 { grid-template-columns: repeat(2, 1fr); }

/* ---------- Pet card ---------- */
.pet-card {
  background: white;
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: transform .2s, box-shadow .2s;
  display: flex; flex-direction: column;
  border: 1px solid rgba(255, 228, 204, 0.6);
}
.pet-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}
.pet-photo {
  aspect-ratio: 4 / 3;
  display: grid; place-items: center;
  font-size: 90px;
  position: relative;
}
.pet-tag {
  position: absolute; top: 12px; right: 12px;
  background: rgba(255,255,255,0.92);
  color: var(--orange-deep);
  padding: 4px 12px; border-radius: var(--radius-pill);
  font-weight: 700; font-size: 12px;
  text-transform: uppercase; letter-spacing: 0.3px;
}
.pet-body { padding: 18px 20px 22px; }
.pet-name { font-size: 19px; font-weight: 800; margin: 0 0 4px; }
.pet-meta { color: var(--muted); font-size: 14px; margin-bottom: 14px; }
.pet-meta span + span::before { content: " · "; }
.pet-actions { display: flex; gap: 8px; }

/* ---------- Featured / Generic card ---------- */
.card {
  background: white;
  border-radius: var(--radius);
  padding: 24px;
  box-shadow: var(--shadow-sm);
  border: 1px solid rgba(255, 228, 204, 0.6);
}
.card-pad-lg { padding: 32px; }

/* ---------- Testimonials ---------- */
.testimonial {
  background: white;
  border-radius: var(--radius);
  padding: 26px;
  box-shadow: var(--shadow-sm);
  border-left: 5px solid var(--orange);
  display: flex; flex-direction: column; gap: 14px;
}
.testimonial-text { color: var(--dark-soft); font-size: 15.5px; font-style: italic; margin: 0; }
.testimonial-author { display: flex; align-items: center; gap: 12px; }
.testimonial-avatar {
  width: 44px; height: 44px; border-radius: 50%;
  display: grid; place-items: center;
  background: var(--peach); color: var(--orange-deep);
  font-weight: 800; font-size: 16px;
}
.testimonial-name { font-weight: 700; font-size: 15px; line-height: 1.2; }
.testimonial-role { color: var(--muted); font-size: 13px; }
.stars { color: var(--gold); font-size: 14px; letter-spacing: 1px; }

/* ---------- Filters ---------- */
.filters {
  display: flex; flex-wrap: wrap;
  gap: 8px; align-items: center; justify-content: center;
  margin-bottom: 32px;
}
.filter-group {
  display: inline-flex;
  background: white;
  padding: 6px;
  border-radius: var(--radius-pill);
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--peach);
}
.chip {
  padding: 8px 18px;
  border-radius: var(--radius-pill);
  font-weight: 600; font-size: 14px;
  color: var(--dark-soft);
  background: transparent;
  transition: all .15s;
}
.chip:hover { background: var(--peach); }
.chip.active {
  background: var(--orange);
  color: white;
  box-shadow: var(--shadow-sm);
}

/* ---------- Forms ---------- */
.field { margin-bottom: 16px; }
.field label {
  display: block; font-weight: 700; font-size: 13px;
  color: var(--dark-soft); margin-bottom: 6px;
  letter-spacing: 0.2px; text-transform: uppercase;
}
.input, .select, .textarea {
  width: 100%;
  padding: 12px 14px;
  border: 2px solid var(--peach);
  border-radius: var(--radius-sm);
  font-size: 15px;
  background: var(--cream);
  color: var(--dark);
  font-family: inherit;
  outline: none;
  transition: border-color .15s, background .15s;
}
.input:focus, .select:focus, .textarea:focus {
  border-color: var(--orange);
  background: white;
}
.textarea { resize: vertical; min-height: 90px; }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }

/* ---------- Modal ---------- */
.modal-backdrop {
  position: fixed; inset: 0;
  background: rgba(45, 24, 16, 0.55);
  display: none;
  align-items: center; justify-content: center;
  padding: 20px; z-index: 200;
  animation: fadeIn .18s ease;
}
.modal-backdrop.open { display: flex; }
.modal {
  background: white;
  border-radius: var(--radius-lg);
  padding: 30px;
  width: min(520px, 100%);
  max-height: 90vh; overflow: auto;
  box-shadow: var(--shadow-lg);
  animation: pop .2s ease;
}
.modal h3 {
  font-size: 22px; margin: 0 0 6px;
  display: flex; align-items: center; gap: 10px;
}
.modal-sub { color: var(--muted); margin-bottom: 22px; }
.modal-actions { display: flex; gap: 10px; justify-content: flex-end; margin-top: 14px; }
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
@keyframes pop {
  from { opacity: 0; transform: translateY(8px) scale(.97); }
  to   { opacity: 1; transform: translateY(0) scale(1); }
}

/* ---------- Cart drawer ---------- */
.drawer-backdrop {
  position: fixed; inset: 0;
  background: rgba(45, 24, 16, 0.45);
  display: none; z-index: 150;
}
.drawer-backdrop.open { display: block; }
.drawer {
  position: fixed; top: 0; right: 0;
  width: min(420px, 100%); height: 100%;
  background: white;
  box-shadow: var(--shadow-lg);
  transform: translateX(100%);
  transition: transform .25s ease;
  z-index: 151;
  display: flex; flex-direction: column;
}
.drawer.open { transform: translateX(0); }
.drawer-head {
  padding: 20px 24px; border-bottom: 1px solid var(--peach);
  display: flex; align-items: center; justify-content: space-between;
}
.drawer-body { flex: 1; overflow: auto; padding: 16px 24px; }
.drawer-foot {
  padding: 18px 24px; border-top: 1px solid var(--peach);
  background: var(--cream);
}
.cart-row {
  display: flex; gap: 12px; align-items: center;
  padding: 12px 0; border-bottom: 1px dashed var(--peach);
}
.cart-row:last-child { border-bottom: none; }
.cart-emoji {
  width: 50px; height: 50px; border-radius: 12px;
  background: var(--peach); display: grid; place-items: center;
  font-size: 26px; flex-shrink: 0;
}
.cart-info { flex: 1; min-width: 0; }
.cart-name { font-weight: 700; font-size: 14px; }
.cart-price { color: var(--orange-deep); font-weight: 700; font-size: 13px; }
.qty {
  display: inline-flex; align-items: center; gap: 6px;
  background: var(--cream); border-radius: var(--radius-pill);
  padding: 3px;
}
.qty button {
  width: 26px; height: 26px; border-radius: 50%;
  background: white; color: var(--orange-deep);
  font-weight: 800; font-size: 14px;
  display: grid; place-items: center;
  box-shadow: var(--shadow-sm);
}
.qty span { min-width: 20px; text-align: center; font-weight: 700; font-size: 14px; }

/* ---------- Product card ---------- */
.product-card {
  background: white;
  border-radius: var(--radius);
  padding: 20px;
  box-shadow: var(--shadow-sm);
  border: 1px solid rgba(255, 228, 204, 0.6);
  display: flex; flex-direction: column;
  text-align: center;
  transition: transform .2s, box-shadow .2s;
}
.product-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
}
.product-emoji {
  font-size: 72px; margin: 8px 0 12px;
}
.product-name { font-weight: 700; font-size: 16px; margin-bottom: 4px; }
.product-cat { color: var(--muted); font-size: 12px; text-transform: uppercase; letter-spacing: 0.5px; margin-bottom: 8px; }
.product-price { font-size: 20px; font-weight: 800; color: var(--orange-deep); margin-bottom: 14px; }

/* ---------- Subscription ---------- */
.sub-card {
  background: linear-gradient(135deg, var(--orange) 0%, var(--orange-deep) 100%);
  color: white;
  border-radius: var(--radius-lg);
  padding: 36px;
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 24px;
  align-items: center;
  box-shadow: var(--shadow-lg);
}
.sub-card h2 { color: white; font-size: 28px; }
.sub-card p { color: rgba(255,255,255,0.9); margin-bottom: 18px; }
.sub-card .btn { background: white; color: var(--orange-deep); }
.sub-card .btn:hover { background: var(--cream); color: var(--orange-deep); }
.sub-control {
  background: rgba(255,255,255,0.18);
  backdrop-filter: blur(6px);
  border-radius: var(--radius);
  padding: 22px;
}
.sub-control label { color: white; }
.sub-control .input, .sub-control .select { background: rgba(255,255,255,0.95); border-color: transparent; }
.sub-price-display {
  font-size: 36px; font-weight: 800; margin-top: 10px;
}

/* ---------- Reorder ---------- */
.reorder-row {
  display: flex; gap: 14px; align-items: center;
  padding: 12px 16px;
  background: white;
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--peach);
  margin-bottom: 10px;
}
.reorder-row .product-emoji { font-size: 32px; margin: 0; }
.reorder-info { flex: 1; }
.reorder-info .name { font-weight: 700; font-size: 15px; }
.reorder-info .meta { color: var(--muted); font-size: 13px; }

/* ---------- Dashboard ---------- */
.dash-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
}
.dash-grid .full { grid-column: 1 / -1; }
.dash-card {
  background: white;
  border-radius: var(--radius-lg);
  padding: 26px;
  box-shadow: var(--shadow-sm);
  border: 1px solid rgba(255,228,204,0.6);
}
.dash-card h3 {
  font-size: 18px; margin: 0 0 18px;
  display: flex; align-items: center; gap: 10px;
}
.dash-card h3 .pill {
  margin-left: auto;
  background: var(--peach); color: var(--orange-deep);
  font-size: 12px; padding: 3px 10px; border-radius: var(--radius-pill);
  font-weight: 700;
}
.record-row {
  display: flex; gap: 12px; align-items: center;
  padding: 12px 0; border-bottom: 1px dashed var(--peach);
}
.record-row:last-child { border-bottom: none; }
.record-icon {
  width: 38px; height: 38px; border-radius: 50%;
  background: var(--peach); color: var(--orange-deep);
  display: grid; place-items: center;
  font-size: 18px; flex-shrink: 0;
}
.record-icon.ok { background: #DFF5E1; color: var(--green); }
.record-icon.warn { background: #FFEAA8; color: #B07900; }
.record-icon.alert { background: #FEDCDC; color: var(--red); }
.record-body { flex: 1; min-width: 0; }
.record-title { font-weight: 700; font-size: 14.5px; }
.record-meta { color: var(--muted); font-size: 13px; }
.record-action button {
  background: var(--cream); color: var(--dark-soft);
  padding: 6px 10px; border-radius: 8px; font-size: 12px; font-weight: 700;
}
.record-action button:hover { background: var(--peach); }

.task-row {
  display: flex; gap: 12px; align-items: center;
  padding: 10px 12px;
  background: var(--cream);
  border-radius: 12px;
  margin-bottom: 8px;
  cursor: pointer;
  transition: background .15s;
  user-select: none;
}
.task-row:hover { background: var(--peach); }
.task-row.done { opacity: 0.55; }
.task-row.done .task-title { text-decoration: line-through; }
.task-check {
  width: 22px; height: 22px; border-radius: 50%;
  border: 2px solid var(--orange);
  display: grid; place-items: center;
  flex-shrink: 0;
  background: white;
}
.task-row.done .task-check {
  background: var(--orange); color: white;
}
.task-title { font-weight: 600; font-size: 14.5px; }

.pet-pick {
  display: flex; gap: 8px; flex-wrap: wrap;
  margin-bottom: 22px;
}
.pet-pick button {
  display: flex; align-items: center; gap: 8px;
  padding: 8px 14px;
  background: white;
  border: 2px solid var(--peach);
  border-radius: var(--radius-pill);
  font-weight: 600; font-size: 14px;
  color: var(--dark);
}
.pet-pick button.active {
  background: var(--dark); color: white; border-color: var(--dark);
}
.pet-pick .pp-emoji { font-size: 18px; }

.alert-banner {
  display: flex; align-items: center; gap: 12px;
  background: #FFF1E6;
  border: 1px solid var(--peach-strong);
  color: var(--dark);
  padding: 14px 18px;
  border-radius: var(--radius);
  margin-bottom: 20px;
  font-size: 14.5px;
}
.alert-banner.urgent {
  background: #FEEAEA;
  border-color: #F5BCBC;
  color: #8B2A2A;
}

/* ---------- Empty state ---------- */
.empty {
  text-align: center; padding: 28px 16px;
  color: var(--muted);
}
.empty .em { font-size: 42px; display: block; margin-bottom: 8px; }

/* ---------- Footer ---------- */
.footer {
  background: var(--dark);
  color: var(--peach);
  padding: 56px 0 24px;
  margin-top: 80px;
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: 36px;
  margin-bottom: 36px;
}
.footer h4 {
  color: white; font-size: 14px; text-transform: uppercase;
  letter-spacing: 1px; margin-bottom: 14px;
}
.footer ul { list-style: none; padding: 0; margin: 0; }
.footer li { margin-bottom: 8px; }
.footer a { color: var(--peach); font-size: 14px; }
.footer a:hover { color: var(--orange); text-decoration: none; }
.footer .logo-text, .footer .logo { color: white; }
.footer-about { font-size: 14px; max-width: 320px; line-height: 1.7; opacity: 0.85; }
.footer-bottom {
  border-top: 1px solid rgba(255, 228, 204, 0.15);
  padding-top: 18px;
  display: flex; justify-content: space-between; flex-wrap: wrap; gap: 12px;
  font-size: 13px; opacity: 0.75;
}
.footer-bottom a { font-weight: 600; }

/* ---------- Toast ---------- */
.toast {
  position: fixed; bottom: 28px; left: 50%;
  transform: translateX(-50%) translateY(20px);
  background: var(--dark); color: white;
  padding: 12px 20px; border-radius: var(--radius-pill);
  font-weight: 600; font-size: 14px;
  box-shadow: var(--shadow-lg);
  opacity: 0; pointer-events: none;
  transition: opacity .2s, transform .2s;
  z-index: 300;
}
.toast.show {
  opacity: 1; transform: translateX(-50%) translateY(0);
}

/* ---------- Page header (non-home pages) ---------- */
.page-head {
  padding: 56px 0 36px;
  text-align: center;
  background:
    radial-gradient(circle at 20% 0%, var(--peach), transparent 50%),
    radial-gradient(circle at 80% 100%, var(--peach), transparent 50%);
}
.page-head h1 {
  font-size: clamp(30px, 4vw, 44px);
  letter-spacing: -1px;
  margin-bottom: 8px;
}
.page-head p {
  color: var(--dark-soft); font-size: 17px; max-width: 620px; margin: 0 auto;
}

/* ---------- Responsive ---------- */

/* Tablet & smaller phones — switch to mobile nav, stack hero/dash/sub */
@media (max-width: 860px) {
  /* Layout */
  .grid-4 { grid-template-columns: repeat(2, 1fr); }
  .grid-3 { grid-template-columns: repeat(2, 1fr); }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .hero-grid { grid-template-columns: 1fr; gap: 28px; }
  .hero-illustration { max-width: 320px; margin: 0 auto; }
  .dash-grid { grid-template-columns: 1fr; gap: 16px; }
  .sub-card { grid-template-columns: 1fr; padding: 28px; }

  /* Nav — show burger, hide horizontal links */
  .nav-burger { display: inline-flex; }
  .nav-cart {
    padding: 8px 12px;
    font-size: 13px;
    gap: 6px;
  }
  .nav-cart .nav-cart-label { display: none; }   /* keep emoji + badge */

  /* Mobile dropdown menu */
  .nav-links {
    display: none;
    position: absolute;
    top: 100%;
    left: 4%; right: 4%;
    background: white;
    flex-direction: column;
    padding: 8px;
    margin-top: 6px;
    gap: 2px;
    border-radius: var(--radius);
    box-shadow: var(--shadow-lg);
    border: 1px solid var(--peach);
    animation: menuDrop .18s ease;
  }
  .nav-links.show { display: flex; }
  .nav-links a {
    width: 100%;
    padding: 13px 16px;
    border-radius: 12px;
    font-size: 15.5px;
    color: var(--dark);
  }
  .nav-links a:hover { background: var(--peach); }
  .nav-links a.active {
    background: var(--orange);
    color: white;
  }

  /* Backdrop while menu is open (clickable to close) */
  .menu-backdrop {
    position: fixed; inset: 0;
    background: rgba(45, 24, 16, 0.25);
    z-index: 40;
    display: none;
    animation: fadeIn .15s ease;
  }
  .menu-backdrop.show { display: block; }

  /* Tighter section spacing */
  .section { padding: 48px 0; }
  .hero { padding: 40px 0 30px; }

  /* Filter rows scroll horizontally if they overflow */
  .filters {
    flex-wrap: nowrap;
    overflow-x: auto;
    justify-content: flex-start;
    padding: 4px 4px 14px;
    margin-left: -4px; margin-right: -4px;
    scrollbar-width: none;
  }
  .filters::-webkit-scrollbar { display: none; }
  .filter-group { flex-shrink: 0; }
}

/* Phone — single columns, tighter type, hide cart label entirely */
@media (max-width: 640px) {
  .grid-4, .grid-3, .grid-2 { grid-template-columns: 1fr; }
  .field-row { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; }
  .footer { padding: 44px 0 20px; margin-top: 56px; }
  .footer-bottom { flex-direction: column; gap: 8px; text-align: center; }

  .section { padding: 40px 0; }
  .section-tight { padding: 28px 0; }
  .section-title { font-size: 26px; }
  .section-sub  { font-size: 15px; margin-bottom: 28px; }

  .hero { padding: 30px 0 16px; }
  .hero h1 { font-size: 34px; letter-spacing: -1px; }
  .hero-lead { font-size: 16px; }
  .hero-cta .btn { flex: 1; justify-content: center; }
  .hero-illustration { max-width: 240px; }
  .hero-illustration .emoji { font-size: 110px; }

  .page-head { padding: 36px 0 24px; }
  .page-head h1 { font-size: 28px; }
  .page-head p  { font-size: 15px; }

  /* Card paddings */
  .dash-card { padding: 18px; }
  .card-pad-lg { padding: 22px; }
  .modal { padding: 22px; border-radius: 18px; }
  .modal h3 { font-size: 19px; }

  /* Search bar */
  .search { padding: 5px 5px 5px 16px; }
  .search input { font-size: 15px; padding: 11px 6px; }
  .search button { padding: 11px 16px; }

  /* Nav inner padding */
  .nav-inner { padding: 12px 0; gap: 8px; }
  .logo-text { font-size: 18px; }
  .logo-mark { width: 34px; height: 34px; font-size: 18px; }

  /* Sub card heading */
  .sub-card h2 { font-size: 22px; }
  .sub-price-display { font-size: 30px; }

  /* Drawer full width */
  .drawer { width: 100%; }
}

/* Very small — 380px and under */
@media (max-width: 380px) {
  .container { width: 94%; }
  .hero h1 { font-size: 30px; }
  .section-title { font-size: 22px; }
  .nav-cart { padding: 7px 10px; }
  .pet-pick button { font-size: 13px; padding: 7px 11px; }
}

@keyframes menuDrop {
  from { opacity: 0; transform: translateY(-6px); }
  to   { opacity: 1; transform: translateY(0); }
}
