/* C Spray — minimal site, matching original brand */

:root {
  --cs-primary: #2471a2;
  --cs-primary-dark: #0e2d41;
  --cs-hero: #0a87c4;
  --cs-orange: #ff7a00;
  --cs-orange-dark: #e06b00;
  --cs-sky-soft: #e3f0f5;
  --cs-text: #222;
  --cs-muted: #6c757d;
  --cs-border: #c3c3c3;
  --cs-bg-soft: #f8f9fa;
}

html, body { height: 100%; }

body {
  font-family: "Poppins", system-ui, -apple-system, BlinkMacSystemFont,
    "Segoe UI", "Helvetica Neue", Arial, sans-serif;
  color: var(--cs-text);
  background: #fff;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

/* Round logo badge — matches original (gradient mark in a white circle) */
.logo {
  background: #fff;
  border-radius: 50%;
  padding: 6px;
  width: auto;
  display: block;
}

/* Header — matches original: round logo left, white navigation right, on blue */
#header {
  background: var(--cs-primary);
}

#header .logo { height: 60px; }
#header a:hover .logo { opacity: 0.85; }

#header .main-nav a {
  padding: 8px 14px;
  color: #fff;
  font-weight: 500;
  font-size: 1.05rem;
  text-decoration: none;
}

#header .main-nav a:hover,
#header .main-nav a.active {
  color: var(--cs-primary-dark);
}

#header .btn-outline-light {
  border-color: #fff;
  color: #fff;
}

#header .btn-outline-light:hover {
  background: #fff;
  color: var(--cs-primary);
}

/* Bootstrap primary override to use the brand's orange CTA colour */
.btn-primary {
  background-color: var(--cs-orange);
  border-color: var(--cs-orange);
  font-weight: 600;
}

.btn-primary:hover,
.btn-primary:focus,
.btn-primary:active {
  background-color: var(--cs-orange-dark) !important;
  border-color: var(--cs-orange-dark) !important;
}

.btn-primary.disabled,
.btn-primary:disabled {
  background-color: rgba(255, 255, 255, 0.2);
  border-color: rgba(255, 255, 255, 0.35);
  color: #fff;
  opacity: 1;
}

a { color: var(--cs-primary); }
a:hover { color: var(--cs-primary-dark); }

/* Page header — blue banner used on inner pages */
.page-header {
  background: var(--cs-sky-soft);
  border-bottom: 1px solid #83b0cb;
  color: var(--cs-primary-dark);
  padding: 48px 0 56px;
  margin-bottom: 32px;
  text-align: center;
}

.page-header h1 {
  font-weight: 700;
  margin: 0;
  font-size: clamp(2.25rem, 5vw, 3.5rem);
}

/* Content area */
.content {
  padding: 16px 0 64px;
}

.content h2 {
  font-weight: 700;
  margin: 32px 0 12px;
  font-size: 1.5rem;
  color: var(--cs-primary-dark);
}

/* Language switcher — segmented pill control */
.lang-switch {
  display: inline-flex;
  align-items: stretch;
  background: rgba(255, 255, 255, 0.15);
  border: 1px solid rgba(255, 255, 255, 0.35);
  border-radius: 999px;
  padding: 3px;
  gap: 2px;
  font-size: 0.78rem;
  line-height: 1;
}

.lang-switch a {
  display: inline-flex;
  align-items: center;
  padding: 6px 10px;
  border-radius: 999px;
  color: rgba(255, 255, 255, 0.85);
  text-decoration: none !important;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  transition: background 0.15s ease, color 0.15s ease;
}

.lang-switch a:hover {
  color: #fff;
  background: rgba(255, 255, 255, 0.12);
}

.lang-switch a.active,
.lang-switch a.active:hover {
  background: #fff;
  color: var(--cs-primary);
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.08);
}

.mobile-nav .lang-switch {
  margin: 24px 0 0;
  background: var(--cs-bg-soft);
  border-color: var(--cs-border);
  flex-wrap: wrap;
}

.mobile-nav .lang-switch a { color: #555; }
.mobile-nav .lang-switch a:hover { color: var(--cs-text); background: rgba(0, 0, 0, 0.04); }
.mobile-nav .lang-switch a.active { background: var(--cs-primary); color: #fff; }

/* Mobile offcanvas-style nav (pure CSS) */
#mobile-nav-toggle { display: none; }

.mobile-nav {
  position: fixed;
  inset: 0 0 0 auto;
  width: 280px;
  max-width: 85vw;
  background: #fff;
  border-left: 1px solid var(--cs-border);
  transform: translateX(100%);
  transition: transform 0.25s ease;
  z-index: 1050;
  padding: 24px 20px;
  box-shadow: -4px 0 24px rgba(0, 0, 0, 0.08);
}

.mobile-nav-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.45);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease;
  z-index: 1040;
}

#mobile-nav-toggle:checked ~ .mobile-nav { transform: translateX(0); }
#mobile-nav-toggle:checked ~ .mobile-nav-backdrop {
  opacity: 1;
  pointer-events: auto;
}

.mobile-nav ul {
  list-style: none;
  padding: 0;
  margin: 24px 0 0;
}

.mobile-nav li { margin: 0; }

.mobile-nav ul a {
  display: block;
  padding: 12px 8px;
  color: var(--cs-text);
  text-decoration: none;
  font-weight: 500;
  border-bottom: 1px solid #f0f0f0;
}

.mobile-nav ul a:hover {
  color: var(--cs-primary);
}

.mobile-nav-close {
  background: none;
  border: 0;
  font-size: 24px;
  line-height: 1;
  color: var(--cs-text);
  cursor: pointer;
  float: right;
  padding: 0;
}

.mobile-nav .logo { height: 44px; padding: 0; }

/* Sold-out hero — original hero photo, text on the empty blue side */
.soldout-hero {
  display: flex;
  align-items: center;
  min-height: 520px;
  padding: 64px 0 80px;
  color: #fff;
  background: var(--cs-hero) url("/hero.jpg") no-repeat right center / cover;
}

.soldout-hero .hero-copy { max-width: 560px; }

.soldout-hero .badge-soldout {
  display: inline-block;
  background: #fff;
  color: var(--cs-primary);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding: 6px 14px;
  border-radius: 4px;
  margin-bottom: 24px;
}

.soldout-hero h1 {
  font-weight: 700;
  margin: 0 0 16px;
  font-size: clamp(2rem, 4vw, 3rem);
  line-height: 1.2;
}

.soldout-hero p.lead {
  color: rgba(255, 255, 255, 0.92);
  font-size: 1.15rem;
  margin: 0 0 32px;
}

.soldout-hero .btn-outline-light:hover {
  color: var(--cs-primary);
}

/* Ingredients table — matches original (blue header, ruled rows) */
.product-table table {
  width: 100%;
  border-collapse: collapse;
  margin-bottom: 16px;
  font-size: 0.95rem;
}

.product-table th,
.product-table td {
  padding: 8px 4px;
  border-bottom: 1px solid #000;
  vertical-align: middle;
}

.product-table th:last-child,
.product-table td:last-child { text-align: right; }

.product-table td:nth-child(2) { white-space: nowrap; text-align: right; padding-right: 16px; }

.product-table thead th {
  color: var(--cs-primary);
  font-weight: 700;
}

.text-uppercase { text-transform: uppercase; letter-spacing: 0.04em; }

.product-photo {
  border-radius: 12px;
  max-width: 340px;
  width: 100%;
}

/* Contact info cards */
.contact-card {
  border: 1px solid var(--cs-border);
  border-radius: 6px;
  padding: 24px;
  height: 100%;
  background: #fff;
  transition: box-shadow 0.15s;
}

.contact-card:hover {
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.06);
}

.contact-card h3 {
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--cs-muted);
  margin: 0 0 10px;
  font-weight: 700;
}

.contact-card p { margin: 0; font-size: 1rem; }
.contact-card p.note { margin-top: 8px; font-size: 0.8rem; color: var(--cs-muted); }

.contact-card a { font-weight: 500; text-decoration: none; }
.contact-card a:hover { text-decoration: underline; }

/* Footer — dark, centered round logo + disclaimer */
#footer {
  padding: 48px 0 32px;
  margin-top: auto;
  background: #222;
  color: #fff;
}

#footer .logo {
  height: 56px;
  margin: 0 auto 20px;
}

#footer p {
  font-size: 0.8rem;
  color: #fff;
  max-width: 900px;
  margin: 0 auto;
  text-align: center;
  line-height: 1.6;
}

#footer .footer-links {
  text-align: center;
  margin-top: 20px;
  font-size: 0.9rem;
  color: rgba(255, 255, 255, 0.5);
}

#footer .footer-links a {
  color: rgba(255, 255, 255, 0.8);
  text-decoration: none;
  margin: 0 8px;
}

#footer .footer-links a:hover {
  color: #fff;
  text-decoration: underline;
}

#footer p.copyright {
  margin-top: 16px;
  color: rgba(255, 255, 255, 0.6);
}

/* Make body a flex column so footer can stick to bottom on short pages */
body.d-flex.flex-column { min-height: 100vh; }
main.flex-shrink-0 {
  flex: 1 0 auto;
  display: flex;
  flex-direction: column;
}

/* Let the hero fill the space above the footer on tall screens */
.soldout-hero { flex: 1 0 auto; }

@media (max-width: 991px) {
  /* Portrait photo: copy sits in the empty blue sky above the product */
  .soldout-hero {
    align-items: flex-start;
    min-height: 0;
    padding: 40px 0 0;
    background-image: url("/hero-mobile.jpg");
    background-position: center bottom;
    background-size: cover;
  }
  .soldout-hero .container { padding-bottom: min(110vw, 760px); }
  .soldout-hero .hero-copy { max-width: 600px; }
}

@media (max-width: 767px) {
  #header .logo { height: 48px; }
  .page-header { padding: 32px 0 40px; }
  .product-table table { font-size: 0.85rem; }
}

/* 404 — plain blue hero without the product photo */
.soldout-hero.soldout-hero--plain,
.soldout-hero.soldout-hero--plain .container { background-image: none; padding-bottom: 0; }
.soldout-hero.soldout-hero--plain { padding: 64px 0 80px; align-items: center; }
