:root {
  --color-primary: #009688;
  --color-primary-dark: #00796b;
  --color-accent: #f7980a;
  --color-text: #2d3436;
  --color-muted: #636e72;
  --color-dark: #29323c;
  --font-heading: 'Playfair Display', Georgia, serif;
  --font-body: 'Inter', Arial, sans-serif;
  --radius: 12px;
  --shadow: 0 4px 24px rgba(0, 0, 0, 0.08);
  --header-height: 72px;
}

*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }

html {
  overflow-x: hidden;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: var(--font-body);
  color: var(--color-text);
  background: #f8f9fa;
  padding-top: var(--header-height);
  overflow-x: hidden;
}

body.nav-open {
  overflow: hidden;
}

.nav-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.45);
  z-index: 150;
}

body.nav-open .nav-overlay {
  display: block;
}

.f {
  padding: 0 6px;
  border: 2px solid currentColor;
  color: #e53935;
  font-weight: 700;
  font-size: 1.4em;
}

/* Header */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  height: var(--header-height);
  background: rgba(255, 255, 255, 0.97);
  box-shadow: var(--shadow);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 clamp(16px, 4vw, 24px);
}

.logo-link {
  text-decoration: none;
  color: var(--color-text);
  font-size: clamp(1rem, 3vw, 1.25rem);
  font-weight: 600;
  display: flex;
  align-items: center;
  flex-shrink: 0;
}

.site-logo {
  display: block;
  height: 46px;
  width: auto;
  max-width: min(140px, 30vw);
  object-fit: contain;
  border-radius: 4px;
}

.site-logo--footer {
  height: 52px;
  max-width: 150px;
  margin-bottom: 8px;
}

.main-nav ul { display: flex; list-style: none; gap: 8px; }
.main-nav a {
  text-decoration: none;
  color: var(--color-text);
  font-size: 0.85rem;
  font-weight: 500;
  padding: 8px 14px;
  border-radius: 6px;
}
.main-nav a:hover { background: rgba(0, 150, 136, 0.1); color: var(--color-primary); }

.header-cta {
  background: var(--color-accent);
  color: var(--color-text) !important;
  text-decoration: none;
  padding: 10px 22px;
  border-radius: 8px;
  font-weight: 600;
  font-size: 0.85rem;
  white-space: nowrap;
}

.menu-btn {
  display: none;
  width: 44px;
  height: 44px;
  background: var(--color-primary);
  border: none;
  border-radius: 8px;
  cursor: pointer;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.menu-btn img { width: 22px; height: 22px; }

#sideNav {
  width: min(280px, 85vw);
  height: 100vh;
  height: 100dvh;
  position: fixed;
  right: 0;
  top: 0;
  background: var(--color-primary);
  z-index: 200;
  transition: transform 0.4s ease;
  transform: translateX(100%);
  padding-top: calc(var(--header-height) + 16px);
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}

#sideNav.is-open {
  transform: translateX(0);
}
#sideNav nav ul { list-style: none; }
#sideNav nav ul li a {
  display: block;
  text-decoration: none;
  color: white;
  padding: 16px 24px;
  font-weight: 500;
  font-size: 1rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

/* Breadcrumb */
.pup-breadcrumb {
  max-width: 1200px;
  margin: 0 auto;
  padding: 16px clamp(16px, 4vw, 24px) 0;
  font-size: 0.85rem;
  color: var(--color-muted);
  line-height: 1.5;
  word-break: break-word;
}
.pup-breadcrumb a { color: var(--color-primary); text-decoration: none; }
.pup-breadcrumb a:hover { text-decoration: underline; }

/* Layout */
.pup-detail {
  max-width: 1200px;
  margin: 0 auto;
  padding: 16px clamp(16px, 4vw, 24px) 24px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(20px, 4vw, 40px);
  align-items: start;
}

.pup-gallery {
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  min-width: 0;
}

.swiper-container {
  width: 100%;
  border-radius: var(--radius);
}

.swiper-slide img {
  display: block;
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
}

.swiper-pagination-bullet-active {
  background: var(--color-primary);
}

.pup-info-panel {
  background: white;
  border-radius: var(--radius);
  padding: clamp(20px, 4vw, 32px);
  box-shadow: var(--shadow);
  min-width: 0;
}

.pup-info-panel h1 {
  font-family: var(--font-heading);
  font-size: clamp(1.5rem, 5vw, 2rem);
  margin-bottom: 8px;
  word-break: break-word;
}

.pup-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 20px;
}

.pup-meta span {
  background: #e0f2f1;
  color: var(--color-primary-dark);
  padding: 6px 12px;
  border-radius: 20px;
  font-size: 0.8rem;
  font-weight: 600;
}

.pup-price {
  font-size: clamp(1.4rem, 4vw, 1.75rem);
  font-weight: 700;
  color: var(--color-primary);
  margin-bottom: 20px;
}

.pup-info-panel .info h3 {
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--color-muted);
  margin-bottom: 8px;
  padding-bottom: 8px;
  border-bottom: 1px solid #eee;
}

.paypal-section,
.inquiry-section {
  margin-top: 20px;
  padding-top: 20px;
  border-top: 1px solid #eee;
}

.paypal-section p,
.inquiry-section p {
  font-size: 0.85rem;
  color: var(--color-muted);
  margin-bottom: 12px;
  line-height: 1.5;
}

.paypal-btn,
.inquiry-btn {
  display: block;
  width: 100%;
  background: #009688;
  color: white;
  padding: 16px 24px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: 600;
  font-size: 1rem;
  border: none;
  cursor: pointer;
  transition: background 0.2s, transform 0.2s;
  text-align: center;
  font-family: inherit;
}

.paypal-btn:hover,
.inquiry-btn:hover {
  background: #00796b;
  color: white;
  transform: translateY(-1px);
}

.inquiry-modal {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.inquiry-modal.is-open {
  display: flex;
}

.inquiry-modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.55);
}

.inquiry-modal-dialog {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 480px;
  max-height: 90vh;
  overflow-y: auto;
  background: #fff;
  border-radius: 12px;
  padding: 28px 24px 24px;
  box-shadow: 0 16px 48px rgba(0, 0, 0, 0.2);
}

.inquiry-modal-close {
  position: absolute;
  top: 12px;
  right: 14px;
  width: 36px;
  height: 36px;
  border: none;
  background: #f0f2f5;
  border-radius: 50%;
  font-size: 1.4rem;
  line-height: 1;
  cursor: pointer;
  color: #636e72;
}

.inquiry-modal-close:hover {
  background: #dfe6e9;
}

.inquiry-modal-dialog h2 {
  font-family: 'Playfair Display', Georgia, serif;
  font-size: 1.4rem;
  margin-bottom: 8px;
  padding-right: 36px;
}

.inquiry-modal-note {
  font-size: 0.9rem;
  color: #636e72;
  margin-bottom: 20px;
  line-height: 1.5;
}

.inquiry-field {
  margin-bottom: 16px;
}

.inquiry-field label {
  display: block;
  font-size: 0.85rem;
  font-weight: 600;
  margin-bottom: 6px;
  color: #2d3436;
}

.inquiry-field input,
.inquiry-field textarea {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid #dfe6e9;
  border-radius: 8px;
  font-size: 16px;
  font-family: inherit;
  color: #2d3436;
}

.inquiry-field input:focus,
.inquiry-field textarea:focus {
  outline: none;
  border-color: #009688;
  box-shadow: 0 0 0 3px rgba(0, 150, 136, 0.15);
}

.inquiry-field textarea {
  min-height: 110px;
  resize: vertical;
}

.inquiry-form-footer {
  font-size: 0.8rem;
  color: #636e72;
  line-height: 1.5;
  margin-bottom: 16px;
}

.inquiry-form-footer a {
  color: #009688;
  word-break: break-all;
}

.inquiry-submit {
  width: 100%;
  background: #f7980a;
  color: #2d3436;
  border: none;
  padding: 14px 20px;
  border-radius: 8px;
  font-size: 1rem;
  font-weight: 700;
  cursor: pointer;
  transition: transform 0.2s, box-shadow 0.2s;
}

.inquiry-submit:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 16px rgba(247, 152, 10, 0.4);
}

.back-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--color-primary);
  text-decoration: none;
  font-weight: 500;
  font-size: 0.9rem;
  margin-bottom: 12px;
  min-height: 44px;
}

.back-link:hover { text-decoration: underline; }

/* Content boxes */
.pup-content {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 clamp(16px, 4vw, 24px) clamp(48px, 8vw, 64px);
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(16px, 3vw, 24px);
}

.content-box {
  background: white;
  border-radius: var(--radius);
  padding: clamp(20px, 4vw, 32px);
  box-shadow: var(--shadow);
  min-width: 0;
}

.content-box h2 {
  font-family: var(--font-heading);
  font-size: clamp(1.15rem, 3vw, 1.35rem);
  margin-bottom: 12px;
  color: var(--color-text);
}

.content-box p {
  color: var(--color-muted);
  line-height: 1.7;
  font-size: 0.95rem;
}

.content-box ul {
  color: var(--color-muted);
  padding-left: 20px;
  line-height: 1.8;
  font-size: 0.95rem;
}

/* Footer */
#footer {
  background: linear-gradient(135deg, var(--color-dark), #485563);
  color: white;
  padding: clamp(40px, 6vw, 64px) clamp(16px, 4vw, 24px) clamp(24px, 4vw, 32px);
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: clamp(24px, 4vw, 40px);
  max-width: 1200px;
  margin: 0 auto clamp(24px, 4vw, 40px);
}

.footer-brand .brand h1 {
  color: white;
  font-size: 1.5rem;
}

.footer-brand p {
  color: rgba(255, 255, 255, 0.7);
  font-size: 0.9rem;
  margin-top: 12px;
  max-width: 320px;
  line-height: 1.6;
}

.footer-links h3 {
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 16px;
  color: rgba(255, 255, 255, 0.5);
}

.footer-links ul { list-style: none; }
.footer-links ul li { margin-bottom: 10px; }
.footer-links ul li a {
  color: rgba(255, 255, 255, 0.85);
  text-decoration: none;
  font-size: 0.9rem;
  word-break: break-word;
}
.footer-links ul li a:hover { color: var(--color-accent); }

.social-icon { display: flex; gap: 12px; margin-top: 16px; }
.social-item a {
  display: flex;
  width: 44px;
  height: 44px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 50%;
  align-items: center;
  justify-content: center;
}
.social-item img { width: 20px; filter: brightness(0) invert(1); }

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding-top: 24px;
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
}

.footer-bottom .co-info {
  color: rgba(255, 255, 255, 0.6);
  font-size: 0.85rem;
  word-break: break-word;
}
.footer-bottom .co-info a { color: rgba(255, 255, 255, 0.85); text-decoration: none; }

/* ── Responsive ── */
@media screen and (max-width: 1100px) {
  .main-nav a {
    padding: 8px 10px;
    font-size: 0.8rem;
  }
  .header-cta {
    padding: 10px 16px;
    font-size: 0.8rem;
  }
}

@media screen and (max-width: 900px) {
  :root {
    --header-height: 64px;
  }

  .main-nav,
  .header-cta {
    display: none;
  }

  .menu-btn {
    display: flex;
  }

  .pup-detail,
  .pup-content {
    grid-template-columns: 1fr;
  }

  .footer-grid {
    grid-template-columns: 1fr 1fr;
  }

  .footer-brand {
    grid-column: 1 / -1;
  }
}

@media screen and (max-width: 640px) {
  .footer-grid {
    grid-template-columns: 1fr;
  }

  .footer-bottom {
    flex-direction: column;
    text-align: center;
  }

  .pup-breadcrumb {
    font-size: 0.8rem;
  }

  .pup-meta span {
    font-size: 0.75rem;
    padding: 5px 10px;
  }
}

@media screen and (max-width: 380px) {
  :root {
    --header-height: 58px;
  }

  .menu-btn {
    width: 40px;
    height: 40px;
  }

  .menu-btn img {
    width: 18px;
    height: 18px;
  }
}

@media (hover: none) and (pointer: coarse) {
  #sideNav nav ul li a,
  .menu-btn,
  .paypal-btn,
  .back-link {
    min-height: 44px;
  }
}

@supports (padding: max(0px)) {
  .site-header {
    padding-left: max(0px, env(safe-area-inset-left));
    padding-right: max(0px, env(safe-area-inset-right));
  }

  #footer {
    padding-bottom: max(24px, env(safe-area-inset-bottom));
  }

  #sideNav {
    padding-bottom: env(safe-area-inset-bottom);
  }
}
