/* ==========================================================
   Timberidge Ltd - shared styles
   Mobile-first: the base styles are for phones, and the
   @media (min-width: ...) section at the bottom widens
   the layout for tablets and desktops.
   ========================================================== */

/* ---------- 0. Font ----------
   Inter is hosted on this site (fonts/ folder) rather than loaded from Google,
   so visitors' details are not sent to a third party. One file covers weights 400-700. */
@font-face {
  font-family: "Inter";
  src: url("../fonts/inter-latin.woff2") format("woff2");
  font-weight: 400 700;
  font-style: normal;
  font-display: swap;
}

/* ---------- 1. Colours and sizes (change them here once) ---------- */
:root {
  --charcoal: #232323;     /* header, footer, dark sections */
  --gold: #c9a24b;         /* logo colour, accents */
  --gold-dark: #a8832f;
  --oak: #8b5a2b;          /* warm wood tone */
  --oak-dark: #6e4521;
  --cream: #faf6ef;        /* soft background for alternate sections */
  --text: #2e2a26;
  --muted: #6b645c;
  --white: #ffffff;
  --radius: 16px;          /* rounded corners on cards and images */
  --pill: 999px;           /* fully rounded buttons */
  --shadow: 0 10px 30px rgba(35, 35, 35, 0.08);
  --shadow-lift: 0 16px 40px rgba(35, 35, 35, 0.16);
  --max-width: 1120px;
  --font: "Inter", "Segoe UI", system-ui, -apple-system, Arial, sans-serif;
}

/* ---------- 2. Basic reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font);
  font-size: 1.05rem;
  line-height: 1.7;
  color: var(--text);
  background: var(--white);
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; height: auto; display: block; }
a { color: var(--oak); }

h1, h2, h3 {
  font-family: var(--font);
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: -0.02em;
  margin: 0 0 0.6em;
}
h1 { font-size: 2.4rem; }
h2 { font-size: 1.9rem; }
h3 { font-size: 1.15rem; letter-spacing: -0.01em; }
p  { margin: 0 0 1em; }

/* A centred, padded box that holds each section's content */
.container {
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 1.25rem;
}

.section { padding: 4.5rem 0; }
.section--cream { background: var(--cream); }
.section--warm { background: linear-gradient(180deg, #ecdcc2 0%, #e2cba6 100%); }   /* warm oak/sand tone */
.section-title { text-align: center; }
.section-intro {
  text-align: center;
  max-width: 560px;
  margin: 0 auto 3rem;
  color: var(--muted);
}

/* Small gold label above a heading */
.eyebrow {
  display: block;
  text-align: center;
  color: var(--gold-dark);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  margin-bottom: 0.75rem;
}

/* ---------- 3. Buttons ---------- */
.btn {
  display: inline-block;
  padding: 0.95rem 2rem;
  border-radius: var(--pill);
  background: var(--gold);
  color: var(--charcoal);
  font-weight: 600;
  text-decoration: none;
  text-align: center;
  border: 2px solid var(--gold);
  cursor: pointer;
  font-size: 1rem;
  font-family: inherit;
  transition: transform 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
}
.btn:hover {
  background: var(--gold-dark);
  border-color: var(--gold-dark);
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(201, 162, 75, 0.35);
}
.btn--outline { background: transparent; color: var(--white); border-color: rgba(255, 255, 255, 0.7); }
.btn--outline:hover { background: var(--white); color: var(--charcoal); border-color: var(--white); box-shadow: none; }

/* ---------- 4. Header and navigation ---------- */
.site-header {
  background: rgba(35, 35, 35, 0.92);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);       /* frosted-glass effect over the page behind it */
  position: sticky;
  top: 0;
  z-index: 10;
  border-bottom: 1px solid rgba(201, 162, 75, 0.45);
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 72px;
}

/* Logo: shows just the tradesman emblem cropped from the logo image,
   with the company name as text next to it */
.logo {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  text-decoration: none;
  color: var(--gold);
  font-size: 1.2rem;
  font-weight: 700;
  letter-spacing: -0.01em;
}
.logo-mark {
  width: 46px;
  height: 46px;
  background: url("../images/logo.jpg") no-repeat;
  background-size: 192px auto;          /* scales the whole logo image down */
  background-position: -73px -24px;     /* slides it so only the emblem shows */
  border-radius: 10px;
}

/* The "hamburger" button - phones only */
.nav-toggle {
  background: none;
  border: 1px solid rgba(201, 162, 75, 0.7);
  color: var(--gold);
  font-size: 1.4rem;
  line-height: 1;
  padding: 0.35rem 0.7rem;
  border-radius: 12px;
  cursor: pointer;
}

/* On phones the menu is hidden until the button adds the "open" class */
.nav-links {
  display: none;
  list-style: none;
  margin: 0;
  padding: 0.25rem 0;
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  background: rgba(35, 35, 35, 0.98);
  border-bottom: 1px solid rgba(201, 162, 75, 0.45);
}
.nav-links.open { display: block; }
.nav-links a {
  display: block;
  padding: 1rem 1.25rem;
  color: var(--white);
  text-decoration: none;
  font-weight: 500;
}
.nav-links a:hover,
.nav-links a[aria-current="page"] { color: var(--gold); }

/* ---------- 5. Home page hero ---------- */
.hero {
  /* A dark layer sits on top of the photo so the white text is easy to read. */
  background:
    linear-gradient(180deg, rgba(25, 20, 15, 0.55) 0%, rgba(25, 20, 15, 0.8) 100%),
    url("../images/service-design.jpg") center / cover no-repeat,
    var(--charcoal);                             /* fallback colour if the photo is missing */
  color: var(--white);
  text-align: center;
  padding: 5rem 0 7rem;                          /* extra bottom space for the traits card to overlap */
}
.hero h1 { color: var(--white); max-width: 760px; margin-left: auto; margin-right: auto; }
.hero .tagline {
  display: inline-block;
  color: var(--gold);
  border: 1px solid rgba(201, 162, 75, 0.6);
  border-radius: var(--pill);
  padding: 0.35rem 1rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  font-size: 0.72rem;
  font-weight: 600;
  margin-bottom: 1.5rem;
}
.hero p.lead { max-width: 640px; margin: 0 auto 2.25rem; color: #f1ece3; font-size: 1.1rem; }

/* On phones the two buttons are stacked and full width, so they're easy to tap */
.hero-actions { display: flex; flex-direction: column; gap: 0.9rem; max-width: 380px; margin: 0 auto; }

/* ---------- Traits card (30+ years, luxury, etc.) ---------- */
.traits { margin-top: -3.5rem; position: relative; z-index: 2; }   /* pulls the card up over the hero */
.traits-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem 1rem;
  text-align: center;
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: var(--shadow-lift);
  padding: 1.75rem 1rem;
  width: calc(100% - 2.5rem);
}
.trait strong { display: block; color: var(--charcoal); font-size: 1.35rem; font-weight: 700; letter-spacing: -0.01em; }
.trait span { font-size: 0.85rem; color: var(--muted); }
.trait-link { text-decoration: none; display: block; }
.trait-link strong { color: var(--gold); }
.trait-link:hover strong { color: var(--gold-dark); }

/* ---------- Service cards ---------- */
.service-grid { display: grid; gap: 1rem; grid-template-columns: 1fr 1fr; }
.service-card {
  background: var(--white);
  border-radius: var(--radius);
  overflow: hidden;            /* keeps the photo's corners rounded */
  box-shadow: var(--shadow);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}
.service-card:hover { transform: translateY(-6px); box-shadow: var(--shadow-lift); }
.service-card h3 {
  margin: 0;
  padding: 1rem 0.75rem 1.15rem;
  font-size: 0.95rem;
  text-align: center;
  color: var(--charcoal);
}
/* The photo slot: real photos are cropped to fit, not stretched */
.service-photo {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  transition: transform 0.4s ease;
}
.service-card:hover .service-photo { transform: scale(1.04); }
.service-card { isolation: isolate; }

/* Big logo at the top of the home page */
.hero-logo {
  width: min(1040px, 100%);
  height: auto;
  margin: 0 auto 2.25rem;
  border-radius: var(--radius);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.5);
  border: 1px solid rgba(201, 162, 75, 0.45);
}

/* Gallery teaser on the home page */
.teaser-strip { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0.6rem; margin-bottom: 2rem; }
.teaser-strip img { width: 100%; aspect-ratio: 3 / 4; object-fit: cover; border-radius: var(--radius); box-shadow: var(--shadow); }
.teaser-cta { text-align: center; }

/* Customer reviews (home page) */
/* Reviews slide sideways: one card at a time on phones, three on desktop */
.review-grid {
  display: flex;
  gap: 1.25rem;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scrollbar-width: none;
  padding: 0.5rem 0.25rem 1.5rem;
  margin: 0 -0.25rem;
}
.review-grid::-webkit-scrollbar { display: none; }
.review-card { flex: 0 0 100%; scroll-snap-align: start; }
.review-controls { display: flex; align-items: center; justify-content: center; gap: 1rem; margin-bottom: 2rem; }
.review-controls[hidden] { display: none; }
.review-btn { width: 40px; height: 40px; border-radius: 50%; border: 1px solid var(--oak-dark); background: transparent; color: var(--oak-dark); font-size: 1.5rem; line-height: 1; cursor: pointer; }
.review-btn:hover { background: var(--oak-dark); color: var(--white); }
.review-dots { display: flex; gap: 0.5rem; }
.review-dot { width: 10px; height: 10px; padding: 0; border-radius: 50%; border: 0; background: rgba(110, 69, 33, 0.3); cursor: pointer; }
.review-dot[aria-current="true"] { background: var(--oak-dark); }
.review-card { margin: 0; background: var(--white); border-radius: var(--radius); box-shadow: var(--shadow); padding: 1.6rem 1.5rem; display: flex; flex-direction: column; gap: 0.6rem; }
.review-stars { color: var(--gold); letter-spacing: 0.15em; font-size: 1.1rem; }
.review-tag { align-self: flex-start; font-size: 0.75rem; font-weight: 600; color: var(--oak-dark); background: var(--cream); border: 1px solid rgba(201, 162, 75, 0.5); border-radius: var(--pill); padding: 0.1rem 0.7rem; }
.review-card blockquote { margin: 0; flex: 1; font-size: 0.97rem; }
.review-card figcaption { font-weight: 700; color: var(--charcoal); }

/* About page */
.about-grid { display: grid; gap: 2rem; justify-items: center; grid-template-columns: minmax(0, 1fr); max-width: 860px; }
.about-grid .video-box { width: 100%; }
.about-photo { width: 100%; aspect-ratio: 3 / 4; object-fit: cover; border-radius: var(--radius); box-shadow: var(--shadow-lift); max-height: 520px; }
.values-grid { display: grid; gap: 1rem; grid-template-columns: 1fr; margin-bottom: 2.5rem; }
.value-card { background: var(--white); border-radius: var(--radius); box-shadow: var(--shadow); padding: 1.5rem; text-align: center; }
.value-card h3 { color: var(--oak-dark); }
.value-card p { color: var(--muted); font-size: 0.95rem; margin: 0; }

.video-box { background: linear-gradient(180deg, rgba(20, 16, 12, 0.55) 0%, rgba(20, 16, 12, 0.85) 100%), url("../images/video-poster.jpg") center / cover no-repeat, var(--charcoal); aspect-ratio: 16 / 9; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 1rem; padding: 1.5rem 1.25rem; text-align: center; min-height: 0; min-width: 0; max-width: 100%; color: #fff; border-radius: var(--radius); box-shadow: var(--shadow-lift); }
.video-note { font-size: 0.8rem; color: #e8e2d8; margin: 0; max-width: 460px; }
.video-note a { color: var(--gold); }
.video-box--spc { background: linear-gradient(180deg, rgba(20, 16, 12, 0.55) 0%, rgba(20, 16, 12, 0.85) 100%), url("../images/gallery/spc-floor.jpg") center / cover no-repeat, var(--charcoal); margin-top: 1.5rem; }
.video-section { max-width: 960px; text-align: center; }
.video-grid { display: grid; gap: 1.5rem; grid-template-columns: minmax(0, 1fr); margin: 1.5rem 0 2rem; }
.video-grid .video-box--spc { margin-top: 0; }
@media (min-width: 768px) { .video-grid { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); } .video-box { min-height: 260px; } }
.video-points { margin: 0 auto; }
.video-points h3 { color: var(--oak-dark); }
.video-box--playing { padding: 0; min-height: 0; overflow: hidden; background: #000; }
.video-box--playing iframe { width: 100%; height: 100%; border: 0; }

/* Services page */
.service-list { display: grid; gap: 3.5rem; }
.service-row { display: grid; gap: 1.5rem; align-items: center; }
.service-row img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; border-radius: var(--radius); box-shadow: var(--shadow-lift); }
.service-text h2 { font-size: 1.6rem; }
.service-text p { color: var(--muted); }

/* Gallery page */
.gallery-grid { display: grid; gap: 1rem; grid-template-columns: 1fr 1fr; }
.gallery-item { margin: 0; background: var(--white); border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); }
.gallery-item img { width: 100%; aspect-ratio: 3 / 4; object-fit: cover; }
.gallery-item figcaption { padding: 0.8rem 0.9rem 1rem; font-size: 0.9rem; font-weight: 600; text-align: center; color: var(--charcoal); }

/* ---------- Inner-page banner (Contact, Privacy, etc.) ---------- */
.page-hero {
  background:
    radial-gradient(circle at 50% 0%, rgba(201, 162, 75, 0.2), transparent 60%),
    var(--charcoal);
  color: #e8e2d8;
  text-align: center;
  padding: 4rem 0 4.5rem;
}
.page-hero h1 { color: var(--white); margin-bottom: 0.4em; }
.page-hero .eyebrow { color: var(--gold); }
.page-hero .lead { max-width: 560px; margin: 0 auto; font-size: 1.1rem; }
.page-hero--small { padding: 3rem 0; }
.page-hero--small .lead { font-size: 0.95rem; color: #b9b2a5; }

/* ---------- Readable text pages ---------- */
.prose { max-width: 720px; text-align: center; }
.prose--left { text-align: left; }
.prose h2 { font-size: 1.5rem; margin-top: 2.25rem; }
.prose > h2:first-child { margin-top: 0; }
.prose ul { padding-left: 1.25rem; margin: 0 0 1em; }
.prose li { margin-bottom: 0.4rem; }

/* ---------- Contact page cards ---------- */
.contact-cards { display: grid; gap: 1.25rem; margin: 2.5rem 0 2rem; }
.contact-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.2rem;
  padding: 2rem 1.25rem;
  background: var(--cream);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  text-decoration: none;
  color: var(--charcoal);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}
.contact-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lift); }
.contact-icon {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: var(--charcoal);
  color: var(--gold);
  font-size: 1.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 0.75rem;
}
.contact-label { font-size: 0.78rem; letter-spacing: 0.18em; text-transform: uppercase; color: var(--gold-dark); font-weight: 600; }
.contact-value { font-size: 1.3rem; font-weight: 700; letter-spacing: -0.01em; overflow-wrap: anywhere; }
.contact-hint { font-size: 0.85rem; color: var(--muted); }
.area-note { font-weight: 600; color: var(--oak-dark); }
.privacy-note { font-size: 0.9rem; color: var(--muted); }

/* ---------- 6. Contact / call-to-action band ---------- */
.cta-band {
  background:
    radial-gradient(circle at 50% 0%, rgba(201, 162, 75, 0.18), transparent 60%),
    var(--charcoal);
  color: #e8e2d8;
  text-align: center;
  padding: 5rem 0;
  scroll-margin-top: 70px;     /* stops the sticky header covering the heading when jumping here */
}
.cta-band h2 { color: var(--white); }
.cta-band .eyebrow { color: var(--gold); }
.contact-details { display: flex; flex-direction: column; gap: 0.9rem; max-width: 380px; margin: 1.75rem auto 0; }
.cta-reviews { margin: 1.75rem 0 0; }
.cta-reviews a { color: var(--gold); text-decoration: none; border-bottom: 1px solid rgba(201, 162, 75, 0.5); }
.cta-reviews a:hover { color: var(--white); border-color: var(--white); }

/* ---------- 7. Footer ---------- */
.site-footer {
  background: #1a1a1a;
  color: #b9b2a5;
  padding: 3.5rem 0 1.5rem;
  font-size: 0.95rem;
}
.footer-grid { display: grid; gap: 2rem; }
.site-footer h3 { color: var(--gold); font-size: 0.8rem; letter-spacing: 0.15em; text-transform: uppercase; }
.site-footer a { color: var(--white); text-decoration: none; }
.site-footer a:hover { color: var(--gold); }
.site-footer ul { list-style: none; margin: 0; padding: 0; }
.site-footer li { margin-bottom: 0.4rem; }
.copyright {
  border-top: 1px solid #333;
  margin-top: 2rem;
  padding-top: 1.25rem;
  text-align: center;
  font-size: 0.8rem;
  color: #8a8478;
}

/* ==========================================================
   Wider screens (tablets and desktops)
   ========================================================== */
@media (min-width: 768px) {
  h1 { font-size: 3.6rem; }
  h2 { font-size: 2.4rem; }

  .nav-toggle { display: none; }          /* no hamburger needed */
  .nav-links {
    display: flex;                        /* menu sits in a row */
    position: static;
    background: none;
    border: none;
    padding: 0;
    gap: 0.25rem;
  }
  .nav-links a { padding: 0.5rem 1rem; border-radius: var(--pill); font-size: 0.95rem; }
  .nav-links a:hover { background: rgba(255, 255, 255, 0.08); }

  .hero { padding: 8rem 0 10rem; }
  .hero-actions { flex-direction: row; justify-content: center; gap: 1.25rem; max-width: none; }

  .traits { margin-top: -4.5rem; }
  .traits-grid { grid-template-columns: repeat(4, 1fr); padding: 2.25rem 1.5rem; width: calc(100% - 2.5rem); }
  .trait + .trait { border-left: 1px solid #eee7da; }   /* thin dividers between traits */

  .section { padding: 6rem 0; }
  .service-grid { grid-template-columns: repeat(3, 1fr); gap: 1.75rem; }
  .service-card h3 { font-size: 1.05rem; }

  .gallery-grid { grid-template-columns: repeat(3, 1fr); gap: 1.5rem; }
  .teaser-strip { gap: 1.5rem; max-width: 820px; margin-left: auto; margin-right: auto; }

  .service-row { grid-template-columns: 1fr 1fr; gap: 3.5rem; }
  .service-row--reverse img { order: 2; }
  .service-text h2 { font-size: 2rem; }

  .review-grid { gap: 1.5rem; }
  .review-card { flex-basis: calc((100% - 3rem) / 3); }
  .about-grid { gap: 3rem; }
  .values-grid { grid-template-columns: repeat(4, 1fr); }

  .page-hero { padding: 6rem 0 6.5rem; }
  .page-hero--small { padding: 4rem 0; }
  .contact-cards { grid-template-columns: 1fr 1fr; }
  .contact-details { flex-direction: row; justify-content: center; max-width: none; }
  .footer-grid { grid-template-columns: repeat(3, 1fr); }
}

/* Photos that must be shown whole (not cropped): the small laminated stairs picture */
.service-row img.photo-whole { aspect-ratio: auto; object-fit: contain; max-width: 340px; justify-self: center; }
.service-photo.photo-whole { object-fit: contain; background: var(--cream); }
.gallery-item img.photo-whole { object-fit: contain; background: var(--cream); }
