/* ------------------------- CSS RESET & NORMALIZE -------------------------- */
html, body, div, span, applet, object, iframe, h1, h2, h3, h4, h5, h6, p, blockquote, pre, a, abbr, acronym, address, big, cite, code, del, dfn, em, img, ins, kbd, q, s, samp, small, strike, strong, sub, sup, tt, var, b, u, i, center, dl, dt, dd, ol, ul, li, fieldset, form, label, legend, table, caption, tbody, tfoot, thead, tr, th, td, article, aside, canvas, details, embed, figure, figcaption, footer, header, hgroup, menu, nav, output, ruby, section, summary, time, mark, audio, video {
  margin: 0;
  padding: 0;
  border: 0;
  font-size: 100%;
  font: inherit;
  vertical-align: baseline;
  box-sizing: border-box;
}
html { box-sizing: border-box; }
*, *:before, *:after { box-sizing: inherit; }
article, aside, details, figcaption, figure, footer, header, hgroup, main, menu, nav, section { display: block; }
ul, ol { list-style: none; }
a { background: transparent; text-decoration: none; color: inherit; }
img { max-width: 100%; display: block; border: 0; }
button, input, select, textarea { font-family: inherit; font-size: 100%; }
button { cursor: pointer; background: none; border: none; padding: 0; }

/* ------------------------- BRAND VARIABLES & BASE -------------------------- */
:root {
  --color-primary: #24313B;
  --color-secondary: #7699A5;
  --color-accent: #F4EDE1;
  --color-dark: #21282f;
  --color-muted: #e5dfd4;
  --color-bg: #fff;
  --color-text: #212226;
  --color-border: #d6ccc2;
  --shadow-soft: 0 2px 16px 0 rgba(36, 49, 59, 0.08);
  --shadow-touch: 0 8px 16px rgba(36,49,59,0.08);
  --radius-card: 16px;
  --radius-btn: 24px;
  --transition: all 0.26s cubic-bezier(.5,.12,.2,1);
  --font-display: 'Montserrat', serif;
  --font-body: 'Roboto', serif;
}

body {
  font-family: var(--font-body), Georgia, Times, 'Times New Roman', serif;
  font-size: 16px;
  line-height: 1.7;
  color: var(--color-text);
  background: var(--color-accent);
  min-height: 100vh;
}

.container {
  max-width: 1100px;
  width: 100%;
  margin: 0 auto;
  padding: 0 20px;
  display: flex;
  flex-direction: column;
  align-items: stretch;
}

.section {
  margin-bottom: 60px;
  padding: 40px 20px;
  background: var(--color-bg);
  border-radius: var(--radius-card);
  box-shadow: var(--shadow-soft);
}

.content-wrapper {
  display: flex;
  flex-direction: column;
  gap: 24px;
  align-items: flex-start;
  width: 100%;
}

/* ------------------------- TYPOGRAPHY -------------------------- */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-display), Georgia, Times, 'Times New Roman', serif;
  color: var(--color-primary);
  font-weight: 700;
  letter-spacing: 0.01em;
}
h1 {
  font-size: 2.5rem;
  margin-bottom: 20px;
  line-height: 1.1;
}
h2 {
  font-size: 2rem;
  margin-bottom: 16px;
  line-height: 1.17;
}
h3 {
  font-size: 1.35rem;
  margin-bottom: 10px;
  line-height: 1.2;
}
h4 { font-size: 1.07rem;  }
p, ul, ol, li, blockquote, em { font-size: 1rem; color: var(--color-text); }
strong { font-weight: 600; }
em { font-style: italic; }

ul, ol {
  margin-left: 1.1em;
  margin-bottom: 16px;
}
ul li, ol li {
  margin-bottom: 8px;
  line-height: 1.7;
}

blockquote {
  font-style: italic;
  border-left: 3px solid var(--color-secondary);
  padding-left: 18px;
  margin: 18px 0;
  color: var(--color-primary);
}

/* ------------------------- HEADER & NAVIGATION -------------------------- */
header {
  background: var(--color-bg);
  border-bottom: 1px solid var(--color-border);
  position: sticky;
  top: 0;
  z-index: 101;
}
.main-nav {
  max-width: 1100px;
  margin: 0 auto;
  padding: 24px 20px 16px 20px;
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 28px;
  justify-content: flex-start;
}
.main-nav > a {
  font-family: var(--font-display), serif;
  color: var(--color-primary);
  font-weight: 500;
  font-size: 1rem;
  padding: 6px 0;
  transition: var(--transition);
  position: relative;
}
.main-nav > a:not(:first-child)::after {
  content: '';
  display: block;
  height: 2px;
  background: transparent;
  transition: var(--transition);
  width: 0;
  margin-top: 3px;
}
.main-nav > a:hover, .main-nav > a:focus {
  color: var(--color-secondary);
}
.main-nav > a:not(:first-child):hover::after, .main-nav > a:not(:first-child):focus::after {
  width: 100%;
  background: var(--color-secondary);
}
img[alt='Sleek Finish'] {
  width: 130px;
  height: auto;
  margin-right: 18px;
  vertical-align: middle;
}

.cta-btn {
  background: var(--color-primary);
  color: #fff!important;
  font-family: var(--font-display), serif;
  font-size: 1rem;
  font-weight: 700;
  border-radius: var(--radius-btn);
  padding: 10px 30px;
  box-shadow: 0 3px 12px 0 rgba(36,49,59,0.10);
  border: none;
  transition: var(--transition);
  margin-left: auto;
  letter-spacing: 0.03em;
  outline: none;
}
.cta-btn:hover, .cta-btn:focus {
  background: var(--color-secondary);
  color: var(--color-primary);
}

/* ------------------------- MOBILE NAV MENU -------------------------- */
.mobile-menu-toggle {
  position: absolute;
  top: 20px;
  right: 24px;
  display: none;
  z-index: 107;
  width: 46px;
  height: 46px;
  background: var(--color-primary);
  color: #fff;
  font-size: 2.3rem;
  border-radius: 50%;
  border: none;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 10px rgba(36,49,59,0.10);
  transition: background 0.2s;
}
.mobile-menu-toggle:active, .mobile-menu-toggle:focus {
  background: var(--color-secondary);
}

.mobile-menu {
  position: fixed;
  top: 0;
  right: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(36,49,59,0.97);
  color: #fff;
  z-index: 108;
  transform: translateX(100%);
  transition: transform 0.38s cubic-bezier(.43,.13,.39,1);
  display: flex;
  flex-direction: column;
  padding: 0;
}
.mobile-menu.open {
  transform: translateX(0);
}
.mobile-menu-close {
  background: none;
  color: #fff;
  font-size: 2.15rem;
  align-self: flex-end;
  margin: 24px 36px 0 0;
  border: none;
  transition: color 0.19s;
  z-index: 109;
}
.mobile-menu-close:focus, .mobile-menu-close:hover {
  color: var(--color-secondary);
}
.mobile-nav {
  display: flex;
  flex-direction: column;
  gap: 32px;
  align-items: center;
  margin-top: 40px;
}
.mobile-nav a {
  font-family: var(--font-display), serif;
  font-size: 1.28rem;
  color: #fff;
  padding: 8px 32px;
  border-radius: var(--radius-btn);
  transition: background 0.14s;
  text-align: center;
  min-width: 180px;
}
.mobile-nav a:hover, .mobile-nav a:focus {
  color: var(--color-secondary);
  background: rgba(244,237,225,0.08);
}

@media (max-width: 1000px) {
  .main-nav {
    gap: 16px;
    padding-right: 48px;
  }
  img[alt='Sleek Finish'] { width: 110px; }
}
@media (max-width: 900px) {
  .main-nav > a { font-size: 0.98rem; }
  .cta-btn { padding: 8px 20px; font-size: 0.97rem; }
}
@media (max-width: 820px) {
  .main-nav { gap: 10px; padding: 16px 18px 12px 18px; }
}
@media (max-width: 760px) {
  .main-nav {
    display: none;
  }
  .mobile-menu-toggle {
    display: flex;
  }
  header { padding-bottom: 6px; }
}
/* Give slight opacity to background for mobile menu animation */
.mobile-menu {
  /* already styled above */
}

/* ------------------------- FLEXBOX LAYOUTS -------------------------- */
.card-container, .feature-grid, .service-item-grid, .project-grid, .blog-post-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 24px;
  width: 100%;
  justify-content: flex-start;
}
.card, .feature-grid > div, .service-item-grid > div, .project-grid > div, .blog-post-grid > div {
  background: var(--color-accent);
  border-radius: var(--radius-card);
  padding: 24px 24px 20px 24px;
  box-shadow: var(--shadow-soft);
  margin-bottom: 20px;
  position: relative;
  flex: 1 1 260px;
  min-width: 260px;
  max-width: 320px;
  display: flex;
  flex-direction: column;
  gap: 13px;
}
.card img, .feature-grid img, .project-grid img {
  width: 48px;
  height: 48px;
  margin-bottom: 8px;
}

.content-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  justify-content: space-between;
}
.text-image-section {
  display: flex;
  align-items: center;
  gap: 30px;
  flex-wrap: wrap;
}
.testimonial-card {
  display: flex;
  align-items: center;
  gap: 20px;
  padding: 20px 30px;
  background: #fff;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-card);
  box-shadow: 0 2px 10px rgba(36,49,59,0.04);
  margin-bottom: 20px;
  transition: box-shadow 0.18s;
  min-width: 250px; max-width: 700px;
  flex: 1 1 340px;
}
.testimonial-card p {
  font-size: 1.14rem;
  color: var(--color-primary);
}
.testimonial-card span {
  font-size: 1rem;
  font-weight: 500;
  color: var(--color-secondary);
  margin-left: auto;
  font-family: var(--font-display), serif;
}
.feature-item {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 15px;
}

/* Cards/Sections spacing */
.section > .container {
  gap: 20px;
  display: flex;
  flex-direction: column;
}

/* ------------------------- BLOG & FEATURED ARTICLE -------------------------- */
.featured-article {
  background: var(--color-bg);
  border-left: 5px solid var(--color-secondary);
  padding: 22px 26px;
  border-radius: var(--radius-card);
  box-shadow: var(--shadow-soft);
  margin-top: 14px;
  margin-bottom: 24px;
}
.featured-article h3 {
  color: var(--color-secondary); margin-bottom: 8px;
}

/* Blog post cards (similar to others) */
.blog-post-grid > div,
.project-grid > div {
  background: #fff;
}

/* ------------------------- BUTTONS & LINKS -------------------------- */
a, button {
  outline: none;
  transition: var(--transition);
}
a:focus, button:focus {
  box-shadow: 0 0 0 2px var(--color-secondary) inset;
}

/* Secondary action links on footer and filters */
.footer-nav a,
.legal-links a,
nav a {
  color: var(--color-primary);
  font-size: 1rem;
  font-family: var(--font-body), serif;
  padding: 3px 0;
}
.footer-nav a:hover, .legal-links a:hover {
  color: var(--color-secondary);
}

@media (max-width: 600px) {
  .footer-nav {
    flex-direction: column;
    gap: 12px;
  }
}

/* ------------------------- TABLES (Legal, cookies, GDPR) -------------------------- */
table {
  border-collapse: collapse;
  width: 100%;
  background: var(--color-bg);
  margin-bottom: 24px;
}
th, td {
  border: 1px solid var(--color-border);
  padding: 10px 14px;
  text-align: left;
}
th {
  background: var(--color-accent);
  color: var(--color-primary);
}

/* ------------------------- FORMS & NEWSLETTER -------------------------- */
input, textarea, select {
  font-family: var(--font-body), serif;
  padding: 9px 14px;
  border-radius: 11px;
  border: 1px solid var(--color-border);
  background: #fff;
  transition: border 0.16s;
  box-shadow: 0 1px 5px rgba(36,49,59,0.03);
  margin-bottom: 16px;
}
input:focus, textarea:focus, select:focus {
  border: 1px solid var(--color-secondary);
}

/* ------------------------- FOOTER -------------------------- */
footer {
  background: var(--color-accent);
  border-top: 1px solid var(--color-border);
  padding: 32px 0 18px 0;
}
footer .container {
  flex-direction: row;
  align-items: flex-start;
}
.content-wrapper {
  flex-direction: row;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: flex-start;
  gap: 24px;
  width: 100%;
}
.footer-nav {
  display: flex;
  flex-direction: row;
  gap: 24px;
}
.brand-info {
  display: flex;
  flex-direction: column;
  gap: 8px;
  align-items: flex-start;
  flex: 1 1 240px;
}
.brand-info img {
  width: 56px;
  height: auto;
}
.legal-links {
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  gap: 10px;
  min-width: 140px;
  align-self: flex-end;
  font-size: 0.98rem;
  color: var(--color-primary);
}

/* ------------------------- COOKIE CONSENT BANNER -------------------------- */
.cookie-banner {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  width: 100vw;
  background: var(--color-bg);
  color: var(--color-text);
  border-top: 2px solid var(--color-border);
  box-shadow: 0 -14px 32px rgba(36,49,59,0.07);
  padding: 22px 16px 18px 16px;
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 32px;
  z-index: 9999;
  font-size: 1rem;
  transition: transform 0.32s cubic-bezier(.35,0,.34,1), opacity 0.28s;
}
.cookie-banner.hide {
  opacity: 0;
  pointer-events: none;
  transform: translateY(100%);
}
.cookie-banner__text {
  flex: 1 1 280px;
  margin-right: 20px;
}
.cookie-banner__actions {
  display: flex;
  flex-direction: row;
  gap: 14px;
}
.cookie-btn {
  font-family: var(--font-display), serif;
  border: none;
  padding: 8px 22px;
  font-size: 1rem;
  border-radius: var(--radius-btn);
  background: var(--color-secondary);
  color: #fff;
  font-weight: 600;
  margin-right: 0;
  box-shadow: 0 1px 8px rgba(36,49,59,0.07);
  transition: background 0.14s, color 0.14s;
}
.cookie-btn.primary {
  background: var(--color-primary);
}
.cookie-btn.secondary {
  background: var(--color-secondary);
}
.cookie-btn.settings {
  background: var(--color-accent);
  color: var(--color-primary);
  border: 1px solid var(--color-border);
}
.cookie-btn:hover,.cookie-btn:focus {
  opacity: 0.87;
  background: var(--color-primary);
  color: #fff;
}

/* ------------------------- COOKIE MODAL -------------------------- */
.cookie-modal {
  position: fixed;
  left: 50%;
  top: 50%;
  transform: translate(-50%,-50%) scale(1);
  width: 94vw;
  max-width: 420px;
  background: var(--color-bg);
  border-radius: 22px;
  box-shadow: 0 12px 44px rgba(36,49,59,0.12);
  z-index: 10001;
  padding: 38px 26px 25px 26px;
  display: flex;
  flex-direction: column;
  gap: 24px;
  opacity: 1;
  transition: opacity 0.22s, transform 0.22s;
  pointer-events: all;
}
.cookie-modal.hide {
  opacity: 0;
  pointer-events: none;
  transform: translate(-50%,-38%) scale(0.92);
}
.cookie-modal__header {
  font-size: 1.36rem;
  font-family: var(--font-display), serif;
  font-weight: 600;
  color: var(--color-primary);
  margin-bottom: 9px;
}
.cookie-modal__categories {
  display: flex;
  flex-direction: column;
  gap: 16px;
  margin-bottom: 14px;
}
.cookie-modal__category {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 12px;
  font-size: 1rem;
  color: var(--color-primary);
}
.cookie-modal__category input[type="checkbox"] {
  accent-color: var(--color-secondary);
  width: 21px;
  height: 21px;
}
.cookie-modal__close {
  position: absolute;
  top: 16px;
  right: 20px;
  font-size: 1.55rem;
  color: var(--color-primary);
  background: none;
  border: none;
  opacity: 0.70;
  cursor: pointer;
  transition: opacity 0.16s;
}
.cookie-modal__close:hover,.cookie-modal__close:focus {
  opacity: 1;
  color: var(--color-secondary);
}
.cookie-modal .cookie-btn { margin-right: 12px; }

/* -------------- RESPONSIVE DESIGN, FLEXBOX & MOBILE BREAKPOINTS ------------- */
@media (max-width: 1000px) {
  .container { max-width: 99vw; }
}
@media (max-width: 850px) {
  .section { padding: 30px 10px; }
  .card-container, .feature-grid, .service-item-grid, .project-grid, .blog-post-grid {
    gap: 16px;
  }
}
@media (max-width: 768px) {
  .container { padding: 0 8px; }
  .section { padding: 28px 5px; }
  .content-wrapper,
  .footer-nav,
  .legal-links,
  .brand-info {
    flex-direction: column !important;
    gap: 14px;
    align-items: flex-start !important;
  }
  .testimonial-card { flex-direction: column; gap: 10px; padding: 18px 14px; }
  .card, .feature-grid > div, .service-item-grid > div, .blog-post-grid > div, .project-grid > div {
    min-width: 92vw;
    max-width: 98vw;
    padding: 16px 11px 12px 11px;
    gap: 7px;
  }
  .brand-info img { width: 38px; }
  h1 { font-size: 1.3rem !important; margin-bottom: 10px; }
  h2 { font-size: 1.10rem !important; margin-bottom: 8px; }
  .cookie-banner { flex-direction: column; align-items: flex-start; gap: 18px; padding: 18px 7px; }
  .cookie-modal { padding: 22px 8px 16px 10px; gap: 14px; margin: 0; }

  .text-image-section {
    flex-direction: column;
    gap: 14px;
    align-items: stretch;
  }
  .main-nav { display: none; }
  .mobile-menu-toggle { display: flex; top: 16px; right: 12px; }
}

@media (max-width: 450px) {
  .h1, h1 { font-size: 1.06rem !important; }
  .footer-nav, .brand-info, .legal-links {
    gap: 8px;
  }
}

/* ------------------------- MICRO-INTERACTIONS & HOVER -------------------------- */
.card, .feature-grid > div, .service-item-grid > div, .project-grid > div, .blog-post-grid > div {
  transition: box-shadow 0.19s, transform 0.09s;
}
.card:hover, .feature-grid > div:hover, .service-item-grid > div:hover, .project-grid > div:hover, .blog-post-grid > div:hover {
  box-shadow: var(--shadow-touch);
  transform: translateY(-3px) scale(1.03);
}

.cta-btn:active { background: var(--color-secondary); color: var(--color-primary); transform: scale(0.97); }

.testimonial-card:hover {
  box-shadow: 0 6px 18px rgba(36,49,59,0.11);
}

/* ------------------------- UTILITIES -------------------------- */
.d-none { display: none !important; }
.text-center { text-align: center; }
.text-right { text-align: right; }
.mb-0 { margin-bottom: 0px !important; }
.mb-2 { margin-bottom: 8px !important; }
.mt-2 { margin-top: 8px !important; }
.mb-1-5 { margin-bottom: 12px !important; }

/* ------------------------- LEGAL & COOKIE PAGES -------------------------- */
.legal-content {
  background: #fff;
  border-radius: var(--radius-card);
  box-shadow: var(--shadow-soft);
  padding: 32px 24px;
  margin-bottom: 40px;
  color: var(--color-text);
  font-size: 1rem;
}

/* ------------------------- OTHER COMPONENTS -------------------------- */
.secondary-contact-info p, .contact-details-short p, .contact-details-short a {
  font-size: 1rem;
  margin-bottom: 3px;
}
.secondary-contact-info strong, .contact-details-short strong {
  color: var(--color-primary);
}

/* ------------------------- SCROLLBAR (optional) -------------------------- */
::-webkit-scrollbar { width: 7px; background: var(--color-accent); }
::-webkit-scrollbar-thumb { background: var(--color-muted); border-radius: 10px; }

/* ------------------------- Z-INDEX GUARDRAILS -------------------------- */
header { z-index: 101; }
.main-nav { z-index: 102; }
.mobile-menu { z-index: 108; }
.cookie-banner { z-index: 9999; }
.cookie-modal { z-index: 10001; }

/* ------------------------- PRINT PRESETS -------------------------- */
@media print {
  header, footer, .cookie-banner, .cookie-modal, .mobile-menu { display: none !important; }
  .section, .container, .content-wrapper { box-shadow: none !important; background: #fff !important; padding: 0; }
}
