/* ==========================================================================
   Kit Pro Cabinetry — site styles
   Plain CSS, no build step. Edit colours in :root below.
   ========================================================================== */

:root {
  --ink: #1c1a17;          /* primary text (warm near-black) */
  --ink-soft: #4a453f;
  --muted: #726b62;        /* secondary text */
  --bg: #ffffff;
  --bg-warm: #f7f2ec;      /* warm off-white section background */
  --bg-deep: #211d19;      /* dark footer / accents */
  --accent: #9a6a43;       /* wood / caramel accent */
  --accent-dark: #7d5334;
  --line: #e7ded3;         /* hairline borders */
  --shadow: 0 10px 30px rgba(28, 26, 23, 0.10);
  --radius: 10px;
  --container: 1200px;
  --font: 'Poppins', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Arial, sans-serif;
}

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

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  font-family: var(--font);
  color: var(--ink);
  background: var(--bg);
  line-height: 1.65;
  font-size: 17px;
  -webkit-font-smoothing: antialiased;
}

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

a { color: var(--accent-dark); text-decoration: none; }
a:hover { color: var(--accent); }

h1, h2, h3, h4 {
  font-weight: 600;
  line-height: 1.2;
  color: var(--ink);
  margin: 0 0 0.5em;
  letter-spacing: -0.01em;
}
h1 { font-size: clamp(2rem, 5vw, 3.25rem); }
h2 { font-size: clamp(1.6rem, 3.5vw, 2.4rem); }
h3 { font-size: 1.25rem; }
p { margin: 0 0 1.1em; }

.container { width: 100%; max-width: var(--container); margin: 0 auto; padding: 0 24px; }
.section { padding: 84px 0; }
.section--warm { background: var(--bg-warm); }
.narrow { max-width: 820px; }
.center { text-align: center; }
.eyebrow {
  text-transform: uppercase; letter-spacing: 0.18em; font-size: 0.78rem;
  font-weight: 600; color: var(--accent); margin: 0 0 14px;
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-block; cursor: pointer; border: 1.5px solid transparent;
  padding: 14px 30px; border-radius: 40px; font-weight: 600; font-size: 0.95rem;
  font-family: inherit; transition: all 0.2s ease; text-align: center;
}
.btn--primary { background: var(--accent); color: #fff; }
.btn--primary:hover { background: var(--accent-dark); color: #fff; transform: translateY(-2px); }
.btn--ghost { background: transparent; color: var(--ink); border-color: var(--ink); }
.btn--ghost:hover { background: var(--ink); color: #fff; }
.btn--light { background: #fff; color: var(--ink); }
.btn--light:hover { background: var(--accent); color: #fff; }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 100; background: rgba(255,255,255,0.96);
  backdrop-filter: saturate(180%) blur(8px); border-bottom: 1px solid var(--line);
}
.header-inner { display: flex; align-items: center; justify-content: space-between; height: 76px; }
.brand { font-weight: 700; font-size: 1.15rem; letter-spacing: 0.02em; color: var(--ink); line-height: 1.1; }
.brand span { color: var(--accent); }
.nav { display: flex; align-items: center; gap: 30px; }
.nav a { color: var(--ink); font-weight: 500; font-size: 0.96rem; position: relative; }
.nav a:hover, .nav a.active { color: var(--accent); }
.nav a.active::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: -6px; height: 2px; background: var(--accent);
}
.nav .btn { padding: 10px 22px; }
.nav-toggle { display: none; background: none; border: 0; cursor: pointer; padding: 8px; }
.nav-toggle span { display: block; width: 24px; height: 2px; background: var(--ink); margin: 5px 0; transition: 0.2s; }

/* Products dropdown */
.has-sub { position: relative; }
.subnav {
  position: absolute; top: calc(100% + 14px); left: 50%; transform: translateX(-50%) translateY(6px);
  background: #fff; border: 1px solid var(--line); border-radius: 10px; box-shadow: var(--shadow);
  padding: 8px; min-width: 210px; opacity: 0; visibility: hidden; transition: all 0.18s ease; z-index: 120;
}
.has-sub:hover .subnav, .has-sub:focus-within .subnav { opacity: 1; visibility: visible; transform: translateX(-50%) translateY(0); }
.subnav a { display: block; padding: 10px 14px; border-radius: 6px; font-size: 0.92rem; white-space: nowrap; }
.subnav a:hover { background: var(--bg-warm); color: var(--accent); }

/* ---------- Hero ---------- */
.hero {
  position: relative; min-height: 74vh; display: flex; align-items: center;
  color: #fff; text-align: left; overflow: hidden;
}
.hero::before {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(90deg, rgba(24,20,16,0.72) 0%, rgba(24,20,16,0.35) 60%, rgba(24,20,16,0.15) 100%);
  z-index: 1;
}
.hero-bg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: 0; }
.hero .container { position: relative; z-index: 2; }
.hero h1 { color: #fff; max-width: 16ch; }
.hero p { color: rgba(255,255,255,0.92); font-size: 1.15rem; max-width: 52ch; margin-bottom: 1.8em; }
.hero .eyebrow { color: #e9c9a8; }
.hero-actions { display: flex; gap: 14px; flex-wrap: wrap; }

/* Compact hero for interior pages */
.page-hero { min-height: 44vh; }
.page-hero h1 { max-width: none; }

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

.card {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  overflow: hidden; transition: transform 0.2s ease, box-shadow 0.2s ease;
  display: flex; flex-direction: column;
}
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow); }
.card img { aspect-ratio: 4/3; object-fit: cover; width: 100%; }
.card-body { padding: 22px 24px 26px; }
.card-body h3 { margin-bottom: 6px; }
.card-body p { color: var(--muted); font-size: 0.95rem; margin-bottom: 14px; }
.card-link { font-weight: 600; color: var(--accent); font-size: 0.9rem; }
.card:hover .card-link { color: var(--accent-dark); }

/* ---------- Split content (image + text) ---------- */
.split { display: grid; grid-template-columns: 1fr 1fr; gap: 56px; align-items: center; }
.split img { border-radius: var(--radius); box-shadow: var(--shadow); }
.split--reverse .split-media { order: 2; }

/* ---------- Rich content lists ---------- */
.content ul { list-style: none; padding: 0; margin: 0 0 1.4em; }
.content li { position: relative; padding: 8px 0 8px 30px; border-bottom: 1px solid var(--line); }
.content li::before {
  content: ""; position: absolute; left: 4px; top: 17px; width: 8px; height: 8px;
  border-radius: 50%; background: var(--accent);
}
.steps { counter-reset: step; list-style: none; padding: 0; }
.steps li { position: relative; padding: 6px 0 22px 56px; }
.steps li::before {
  counter-increment: step; content: counter(step);
  position: absolute; left: 0; top: 2px; width: 38px; height: 38px; border-radius: 50%;
  background: var(--accent); color: #fff; font-weight: 600; display: flex; align-items: center; justify-content: center;
}

/* ---------- Gallery ---------- */
.gallery { columns: 3; column-gap: 18px; }
.gallery img {
  width: 100%; margin-bottom: 18px; border-radius: 8px; break-inside: avoid;
  transition: transform 0.25s ease, filter 0.25s ease; cursor: zoom-in;
}
.gallery img:hover { transform: scale(1.02); filter: brightness(1.05); }

/* ---------- Contact ---------- */
.contact-grid { display: grid; grid-template-columns: 1fr 1.1fr; gap: 56px; }
.info-item { display: flex; gap: 16px; margin-bottom: 26px; align-items: flex-start; }
.info-item .ic {
  flex: 0 0 44px; height: 44px; border-radius: 50%; background: var(--bg-warm);
  display: flex; align-items: center; justify-content: center; font-size: 1.2rem;
}
.info-item h4 { margin: 0 0 2px; font-size: 1rem; }
.info-item p, .info-item a { margin: 0; color: var(--muted); }
.contact-actions { display: flex; flex-wrap: wrap; gap: 12px; margin: 30px 0 20px; }
.contact-actions .btn { padding: 14px 24px; }
.contact-details { margin-top: 26px; border-top: 1px solid var(--line); padding-top: 26px; }
.map-embed { min-height: 440px; }
.map-embed iframe { width: 100%; height: 100%; min-height: 440px; border: 0; border-radius: var(--radius); box-shadow: var(--shadow); }
@media (max-width: 900px) { .map-embed, .map-embed iframe { min-height: 340px; } }

form label { display: block; font-weight: 500; font-size: 0.9rem; margin: 0 0 6px; }
form .field { margin-bottom: 18px; }
form input, form textarea {
  width: 100%; padding: 13px 15px; border: 1px solid var(--line); border-radius: 8px;
  font-family: inherit; font-size: 1rem; background: #fff; color: var(--ink);
}
form input:focus, form textarea:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px rgba(154,106,67,0.15); }
form textarea { min-height: 140px; resize: vertical; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }

/* ---------- CTA band ---------- */
.cta {
  background: var(--bg-deep); color: #fff; text-align: center; padding: 80px 0;
}
.cta h2 { color: #fff; }
.cta p { color: rgba(255,255,255,0.8); max-width: 46ch; margin: 0 auto 1.8em; }

/* ---------- Footer ---------- */
.site-footer { background: var(--bg-deep); color: rgba(255,255,255,0.72); padding: 64px 0 28px; font-size: 0.94rem; }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 40px; margin-bottom: 44px; }
.site-footer h4 { color: #fff; font-size: 0.95rem; text-transform: uppercase; letter-spacing: 0.12em; margin-bottom: 18px; }
.site-footer a { color: rgba(255,255,255,0.72); }
.site-footer a:hover { color: #fff; }
.site-footer ul { list-style: none; padding: 0; margin: 0; }
.site-footer li { margin-bottom: 10px; }
.footer-brand { font-weight: 700; font-size: 1.2rem; color: #fff; margin-bottom: 12px; }
.footer-brand span { color: var(--accent); }
.footer-bottom { border-top: 1px solid rgba(255,255,255,0.12); padding-top: 24px; display: flex; justify-content: space-between; flex-wrap: wrap; gap: 10px; font-size: 0.85rem; }

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .grid-4 { grid-template-columns: repeat(2, 1fr); }
  .grid-3 { grid-template-columns: repeat(2, 1fr); }
  .split, .contact-grid { grid-template-columns: 1fr; gap: 34px; }
  .split--reverse .split-media { order: 0; }
  .gallery { columns: 2; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .nav { position: fixed; inset: 76px 0 auto 0; background: #fff; flex-direction: column;
    align-items: stretch; gap: 0; padding: 10px 24px 24px; border-bottom: 1px solid var(--line);
    box-shadow: var(--shadow); transform: translateY(-140%); transition: transform 0.25s ease; }
  .nav.open { transform: translateY(0); }
  .nav a { padding: 14px 0; border-bottom: 1px solid var(--line); }
  .nav a.active::after { display: none; }
  .nav .btn { margin-top: 14px; text-align: center; }
  .nav-toggle { display: block; }
  /* dropdown becomes inline indented list on mobile */
  .subnav { position: static; transform: none; opacity: 1; visibility: visible;
    box-shadow: none; border: 0; border-radius: 0; padding: 0 0 0 16px; min-width: 0; }
  .subnav a { padding: 12px 0; border-bottom: 1px solid var(--line); }
  .has-sub > a::after { content: " ▾"; color: var(--accent); }
  .section { padding: 60px 0; }
}
@media (max-width: 560px) {
  .grid-4, .grid-3, .grid-2 { grid-template-columns: 1fr; }
  .gallery { columns: 1; }
  .footer-grid { grid-template-columns: 1fr; }
  .form-row { grid-template-columns: 1fr; }
  .hero { min-height: 66vh; }
}

/* Lightbox */
.lightbox { position: fixed; inset: 0; background: rgba(15,12,9,0.92); z-index: 200;
  display: none; align-items: center; justify-content: center; padding: 30px; cursor: zoom-out; }
.lightbox.open { display: flex; }
.lightbox img { max-width: 92vw; max-height: 90vh; border-radius: 6px; box-shadow: 0 20px 60px rgba(0,0,0,0.5); }
