/* === 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 {
  scroll-behavior: smooth;
}
article, aside, details, figcaption, figure, 
footer, header, hgroup, menu, nav, section {
  display: block;
}
body {
  line-height: 1.6;
  background: #F3EFEA;
  color: #152545;
}
ul, ol {
  list-style: none;
}
a {
  color: inherit;
  text-decoration: none;
  transition: color 0.18s;
}
img {
  max-width: 100%;
  display: block;
}
button {
  background: none;
  border: none;
  font: inherit;
  cursor: pointer;
  padding: 0;
}

/* === ROOT VARIABLES (with fallbacks) ===================== */
:root {
  --mf-primary: #152545;
  --mf-secondary: #3D89C9;
  --mf-accent: #F3EFEA;
  --mf-shadow: 0 2px 16px 0 rgba(21,37,69,0.09);
  --mf-radius: 18px;
  --mf-radius-md: 13px;
  --mf-radius-sm: 8px;
  --mf-size-xs: 8px;
  --mf-size-s: 16px;
  --mf-size-m: 24px;
  --mf-size-l: 32px;
  --mf-size-xl: 48px;
  --mf-font-display: 'Montserrat', Arial, Helvetica, sans-serif;
  --mf-font-body: 'Open Sans', Arial, Helvetica, sans-serif;
  --mf-error: #ED4747;
  --mf-success: #1fb676;
  --mf-neutral: #e5e9f2;
  --mf-dark: #152545;
  --mf-light: #F3EFEA;
  --mf-contrast-dark: #0d1831;
  --mf-contrast-light: #fff;
}

/* === BASE TYPOGRAPHY ==================================== */
body {
  font-family: var(--mf-font-body), Arial, Helvetica, sans-serif;
  font-size: 16px;
  background: var(--mf-accent);
  color: var(--mf-primary);
  letter-spacing: 0.01em;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--mf-font-display), Arial, Helvetica, sans-serif;
  font-weight: 800;
  color: var(--mf-primary);
  line-height: 1.1;
}
h1 {
  font-size: 2.75rem;
  margin-bottom: 12px;
  letter-spacing: -0.02em;
}
h2 {
  font-size: 2rem;
  margin-bottom: 10px;
  letter-spacing: -0.01em;
}
h3 {
  font-size: 1.25rem;
  margin-bottom: 7px;
}
h4, h5, h6 {
  font-size: 1.1rem;
  margin-bottom: 5px;
}
strong {
  font-weight: 700;
}
p, ul, ol, li {
  font-size: 1rem;
}
.text-section p, .text-section ul, .text-section li {
  font-size: 1.08rem;
  margin-bottom: 13px;
  color: var(--mf-primary);
}
a {
  color: var(--mf-secondary);
  font-weight: 700;
  transition: color 0.14s;
}
a:hover, a:focus {
  color: var(--mf-primary);
  text-decoration: underline;
}

/* === CONTAINERS & SPACING =============================== */
.container {
  width: 100%;
  max-width: 1110px;
  margin-left: auto;
  margin-right: auto;
  padding-left: 24px;
  padding-right: 24px;
}
.section {
  margin-bottom: 60px;
  padding: 40px 20px;
  background: transparent;
}
.content-wrapper {
  display: flex;
  flex-direction: column;
  gap: 24px;
  width: 100%;
}
.card-container {
  display: flex;
  flex-wrap: wrap;
  gap: 24px;
}
.card {
  background: #fff;
  border-radius: var(--mf-radius-md);
  box-shadow: var(--mf-shadow);
  padding: 28px 22px;
  margin-bottom: 20px;
  position: relative;
  display: flex;
  flex-direction: column;
  transition: transform 0.18s, box-shadow 0.18s;
}
.card:hover,
.card:focus-within {
  transform: translateY(-3px) scale(1.02);
  box-shadow: 0 8px 28px 0 rgba(21,37,69,0.19);
  z-index: 2;
}
.card-content {
  display: flex;
  flex-direction: column;
  justify-content: center;
}
.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 {
  background: #fff;
  border-radius: var(--mf-radius);
  padding: 20px 30px;
  display: flex;
  align-items: center;
  gap: 20px;
  box-shadow: var(--mf-shadow);
  min-width: 310px;
  margin-bottom: 20px;
  transition: box-shadow 0.18s, transform 0.18s;
  border: 2.5px solid var(--mf-neutral);
  position: relative;
}
.testimonial-card p {
  color: var(--mf-primary);
  font-weight: 600;
  font-size: 1.17rem;
}
.testimonial-card strong {
  font-size: 1rem;
  color: var(--mf-secondary);
  font-weight: bold;
}
.testimonial-card:hover,
.testimonial-card:focus-within {
  box-shadow: 0 6px 20px rgba(61,137,201,0.12);
  transform: translateY(-3px) scale(1.015);
  border-color: var(--mf-secondary);
}
.rating-summary {
  display: flex;
  align-items: center;
  gap: 11px;
  font-weight: bold;
  margin-top: 25px;
  color: var(--mf-primary);
  font-size: 1.18rem;
}
.feature-item {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 15px;
}

/* === HERO SECTION ========================= */
.hero {
  min-height: 450px;
  background: var(--mf-primary);
  color: #fff;
  padding: 54px 0 48px 0;
  display: flex;
  align-items: center;
  box-shadow: 0 12px 36px rgba(21,37,69,0.11);
}
.hero .container {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}
.hero .content-wrapper {
  gap: 18px;
}
.hero h1, .hero h2 {
  color: #fff;
  font-size: 2.5rem;
  font-weight: 900;
  letter-spacing: -0.025em;
}
.hero p {
  font-size: 1.20rem;
  color: #f3efeabb;
  font-weight: 500;
  line-height: 1.4;
}
.hero .btn {
  margin-top: 24px;
}

/* === BUTTONS =============================== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 13px 30px;
  font-family: var(--mf-font-display);
  font-weight: bold;
  border-radius: var(--mf-radius-sm);
  font-size: 1.06rem;
  box-shadow: none;
  border: none;
  outline: none;
  transition: background 0.18s, color 0.18s, transform 0.14s, box-shadow 0.14s;
  cursor: pointer;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.btn-primary {
  background: var(--mf-secondary);
  color: #fff;
  box-shadow: 0 3px 12px rgba(61,137,201,0.17);
}
.btn-primary:hover, .btn-primary:focus {
  background: var(--mf-primary);
  color: #fff;
  transform: translateY(-1.5px) scale(1.035);
  box-shadow: 0 7px 24px 0 rgba(21,37,69,0.15);
}
.btn-secondary {
  background: var(--mf-primary);
  color: #fff;
}
.btn-secondary:hover, .btn-secondary:focus {
  background: var(--mf-secondary);
  color: #fff;
}
.btn-ghost {
  background: transparent;
  border: 2px solid var(--mf-secondary);
  color: var(--mf-secondary);
}
.btn-ghost:hover, .btn-ghost:focus {
  background: var(--mf-secondary);
  color: #fff;
}

/* === FEATURES CARDS ===================== */
.features .content-wrapper,
.feature-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 24px;
  justify-content: space-between;
}
.features .content-wrapper > div,
.feature-grid > div {
  background: #fff;
  border-radius: var(--mf-radius-md);
  box-shadow: var(--mf-shadow);
  padding: 32px 20px 28px 20px;
  display: flex;
  flex-direction: column;
  gap: 13px;
  flex: 1 1 210px;
  align-items: flex-start;
  min-width: 210px;
  max-width: 260px;
  transition: box-shadow 0.16s, transform 0.13s;
}
.features .content-wrapper > div:hover,
.feature-grid > div:hover {
  box-shadow: 0 8px 20px 0 rgba(61,137,201,0.12);
  transform: translateY(-3px) scale(1.04);
  z-index: 2;
}
.features img {
  width: 48px;
  height: 48px;
  margin-bottom: 8px;
}
.features h3 {
  color: var(--mf-secondary);
}
.features p {
  font-size: 1.04rem;
}

/* === SPECIAL SNIPPETS & FACT BOXES ========================*/
.fact-snippets {
  margin-top: 12px;
  margin-bottom: 12px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.fact-snippets p {
  background: #fff;
  box-shadow: var(--mf-shadow);
  padding: 13px 19px;
  border-left: 4px solid var(--mf-secondary);
  border-radius: var(--mf-radius-sm);
  font-size: 1rem;
  color: var(--mf-primary);
  font-weight: 700;
  margin: 0;
}
.inventor-profiles {
  margin-bottom: 22px;
  background: var(--mf-neutral);
  padding: 14px 19px;
  border-radius: var(--mf-radius-sm);
  box-shadow: 0 2px 10px rgba(61,137,201,0.07);
}
.inventor-profiles h3 {
  margin-bottom: 8px;
  color: var(--mf-secondary);
}

/* === NAVIGATION BAR =========================== */
header {
  background: #fff;
  box-shadow: 0 2px 11px 0 rgba(21,37,69,0.06);
  position: relative;
  z-index: 10;
}
.main-nav {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 22px;
  height: 76px;
  padding: 0;
  font-family: var(--mf-font-display);
  font-size: 1.13rem;
  letter-spacing: 0.019em;
}
.main-nav .logo {
  margin-right: 22px;
  display: flex;
  align-items: center;
  height: 46px;
}
.main-nav .logo img {
  height: 46px;
  width: auto;
  transition: transform 0.21s;
}
.main-nav .logo:hover img {
  transform: scale(1.08) rotate(-6deg);
}
.main-nav a {
  display: inline-block;
  padding: 10px 9px;
  border-radius: var(--mf-radius-sm);
  color: var(--mf-primary);
  font-weight: 700;
  transition: background 0.16s, color 0.14s;
}
.main-nav a:hover, .main-nav a:focus {
  background: var(--mf-secondary);
  color: #fff;
}

/* === MOBILE BURGER MENU ==================== */
.mobile-menu-toggle {
  display: none;
  position: absolute;
  right: 26px;
  top: 20px;
  width: 46px;
  height: 46px;
  background: var(--mf-secondary);
  color: #fff;
  border-radius: 50%;
  font-size: 2rem;
  align-items: center;
  justify-content: center;
  z-index: 101;
  border: none;
  transition: background 0.16s, box-shadow 0.16s;
}
.mobile-menu-toggle:active,
.mobile-menu-toggle:focus {
  background: var(--mf-primary);
  box-shadow: 0 1px 9px rgba(61,137,201,0.14);
}
.mobile-menu {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: 100vh;
  width: 100vw;
  background: #fff;
  z-index: 1100;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  padding-top: 38px;
  padding-left: 0;
  transform: translateX(-100%);
  transition: transform 0.27s cubic-bezier(.48,.15,.48,1);
  box-shadow: 0 6px 58px 0 rgba(21,37,69,0.16);
}
.mobile-menu.open {
  transform: translateX(0);
}
.mobile-menu-close {
  align-self: flex-end;
  margin-right: 26px;
  background: var(--mf-secondary);
  color: #fff;
  border-radius: 50%;
  width: 42px;
  height: 42px;
  font-size: 2rem;
  border: none;
  margin-bottom: 18px;
  transition: background 0.14s;
  z-index: 1111;
}
.mobile-menu-close:focus, .mobile-menu-close:hover {
  background: var(--mf-primary);
}
.mobile-nav {
  display: flex;
  flex-direction: column;
  gap: 18px;
  width: 100%;
  padding-left: 38px;
}
.mobile-nav a {
  color: var(--mf-primary);
  font-size: 1.2rem;
  font-weight: 800;
  padding: 15px 0 15px 10px;
  border-radius: var(--mf-radius-md);
  transition: background 0.17s, color 0.13s;
}
.mobile-nav a:hover, .mobile-nav a:focus {
  background: var(--mf-secondary);
  color: #fff;
}

/* === CTA SECTION =========================== */
.cta {
  background: var(--mf-secondary);
  padding: 46px 0;
  color: #fff;
  border-radius: var(--mf-radius);
  box-shadow: 0 3px 16px 0 rgba(21,37,69,0.11);
  margin-bottom: 64px;
}
.cta h2, .cta p {
  color: #fff;
}
.cta .btn-primary {
  background: #fff;
  color: var(--mf-secondary);
  font-weight: 900;
}
.cta .btn-primary:hover {
  background: var(--mf-primary);
  color: #fff;
}

/* === FOOTER ================================ */
footer {
  background: var(--mf-primary);
  color: #fff;
  padding: 22px 0 16px 0;
  letter-spacing: 0.02em;
}
footer .container {
  display: flex;
}
footer .content-wrapper {
  display: flex;
  flex-direction: row;
  gap: 22px;
  align-items: center;
  flex-wrap: wrap;
  justify-content: flex-start;
  font-size: 1.01rem;
}
footer a {
  color: var(--mf-secondary);
  font-weight: 700;
  margin-right: 6px;
  border-bottom: 2.5px solid transparent;
  transition: border-color 0.18s, color 0.14s;
}
footer a:hover {
  border-bottom: 2.5px solid var(--mf-secondary);
  color: #fff;
}
footer span {
  font-weight: 600;
  color: #cad2dc;
  margin-left: 11px;
}

/* === MAP EMBED & CONTACT ICONS ============ */
.map-embed {
  margin-top: 24px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 8px;
  padding: 19px 20px;
  background: var(--mf-neutral);
  border-radius: var(--mf-radius-sm);
  box-shadow: 0 1px 9px rgba(21,37,69,0.05);
}
.text-section img {
  width: 22px;
  height: 22px;
  vertical-align: middle;
  margin-right: 8px;
}

/* === MISC COMPONENTS ====================== */
ul {
  padding-left: 18px;
}
ul li {
  margin-bottom: 9px;
  position: relative;
  padding-left: 12px;
}
ul li:before {
  content: '\2022';
  color: var(--mf-secondary);
  display: inline-block; 
  width: 12px;
  margin-left: -12px;
}
ul li strong {
  color: var(--mf-secondary);
}

/* === Section Spacing for ALL pages ========= */
section {
  margin-bottom: 60px;
  padding: 40px 20px;
}

/* === RESPONSIVE DESIGN ==================== */
@media (max-width: 1100px) {
  .container {
    max-width: 96vw;
    padding-left: 15px;
    padding-right: 15px;
  }
}
@media (max-width: 900px) {
  .features .content-wrapper > div,
  .feature-grid > div {
    min-width: 150px;
    max-width: 100%;
    flex: 1 1 48%;
  }
}
@media (max-width: 768px) {
  h1 { font-size: 2.10rem; }
  .hero h1, .hero h2 { font-size: 1.75rem; }
  .main-nav { display: none; }
  .mobile-menu-toggle {
    display: flex;
  }
  .container { padding-left: 6vw; padding-right: 6vw; }
  .features .content-wrapper,
  .feature-grid {
    flex-direction: column;
    gap: 20px;
  }
  .features .content-wrapper > div,
  .feature-grid > div {
    min-width: 100%;
    max-width: 100%;
    flex: 1 1 100%;
  }
  .content-grid {
    flex-direction: column;
    gap: 20px;
  }
  .text-image-section {
    flex-direction: column;
    align-items: flex-start;
    gap: 18px;
  }
  .card-container {
    flex-direction: column;
    gap: 18px;
  }
  .testimonial-card {
    min-width: 80vw;
    font-size: 1rem;
    padding: 15px 12px;
  }
  footer .content-wrapper {
    flex-direction: column;
    align-items: flex-start;
    gap: 14px;
  }
  .cta { border-radius: var(--mf-radius-md); margin-bottom: 38px; }
}
@media (max-width: 540px) {
  .hero {
    min-height: 320px;
    padding: 24px 0 26px 0;
  }
  section {
    margin-bottom: 38px;
    padding: 24px 8px;
  }
}

/* === MICRO-INTERACTIONS & EFFECTS =========== */
.card,
.features .content-wrapper > div,
.feature-grid > div,
.btn,
.testimonial-card {
  transition: box-shadow 0.17s, transform 0.17s;
}
.rating-summary img {
  filter: drop-shadow(0 4px 12px rgba(61,137,201,0.13));
}

/* === COOKIE CONSENT BANNER ================ */
.cookie-banner {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  background: #fff;
  color: var(--mf-primary);
  box-shadow: 0 -3px 24px rgba(21,37,69,0.16);
  border-top: 3px solid var(--mf-secondary);
  padding: 28px 24px;
  z-index: 1200;
  display: flex;
  align-items: center;
  gap: 18px;
  justify-content: space-between;
  flex-wrap: wrap;
  animation: cookie-banner-slidein 0.59s cubic-bezier(.38,.07,.65,.96);
}
@keyframes cookie-banner-slidein {
  0%   { transform: translateY(100%); opacity: 0; }
  70%  { transform: translateY(-6%); }
  100% { transform: translateY(0); opacity: 1; }
}
.cookie-banner .cookie-text {
  max-width: 430px;
  font-size: 1rem;
}
.cookie-banner .cookie-actions {
  display: flex;
  gap: 14px;
}
.cookie-banner .btn {
  font-size: 0.98rem;
  padding: 9px 22px;
}
.cookie-banner .btn-accept {
  background: var(--mf-success);
  color: #fff;
}
.cookie-banner .btn-accept:hover {
  background: #17ad65;
}
.cookie-banner .btn-reject {
  background: var(--mf-error);
  color: #fff;
}
.cookie-banner .btn-reject:hover {
  background: #c83030;
}
.cookie-banner .btn-settings {
  background: #fff;
  color: var(--mf-secondary);
  border: 2px solid var(--mf-secondary);
}
.cookie-banner .btn-settings:hover {
  background: var(--mf-secondary);
  color: #fff;
}

/* Cookie Modal */
.cookie-modal-overlay {
  position: fixed;
  z-index: 1300;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(21,37,69, 0.39);
  display: flex;
  align-items: center;
  justify-content: center;
  animation: cookie-modal-fadein 0.35s cubic-bezier(.43,.19,.67,1);
}
@keyframes cookie-modal-fadein {
  0% { opacity: 0; }
  100% { opacity: 1; }
}
.cookie-modal {
  background: #fff;
  color: var(--mf-primary);
  min-width: 340px;
  max-width: 97vw;
  border-radius: var(--mf-radius);
  padding: 36px 24px 27px 24px;
  box-shadow: 0 13px 42px rgba(21,37,69,0.23);
  display: flex;
  flex-direction: column;
  gap: 17px;
  position: relative;
}
.cookie-modal-close {
  position: absolute;
  top: 11px;
  right: 16px;
  background: var(--mf-secondary);
  color: #fff;
  border-radius: 50%;
  width: 34px;
  height: 34px;
  font-size: 1.55rem;
  border: none;
  z-index: 2;
  transition: background 0.15s;
}
.cookie-modal-close:focus,
.cookie-modal-close:hover {
  background: var(--mf-primary);
}
.cookie-modal h3 {
  color: var(--mf-secondary);
  font-size: 1.13rem;
  font-weight: 800;
  margin-bottom: 4px;
}
.cookie-category {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 10px;
}
.cookie-category span {
  font-weight: 700;
}
.cookie-toggle {
  appearance: none;
  width: 38px;
  height: 22px;
  background: var(--mf-neutral);
  border-radius: 12px;
  position: relative;
  outline: none;
  cursor: pointer;
  transition: background 0.18s;
}
.cookie-toggle:checked {
  background: var(--mf-secondary);
}
.cookie-toggle:before {
  content: '';
  position: absolute;
  top: 3px;
  left: 4px;
  width: 16px;
  height: 16px;
  background: #fff;
  border-radius: 50%;
  box-shadow: 0 1px 5px rgba(61,137,201,0.06);
  transition: left 0.18s;
}
.cookie-toggle:checked:before {
  left: 18px;
}
.cookie-category .locked {
  color: var(--mf-primary);
  opacity: 0.6;
  margin-left: 3px;
  font-size: 1.07em;
}
.cookie-modal-actions {
  display: flex;
  gap: 14px;
  margin-top: 14px;
}
.cookie-modal .btn {
  padding: 8px 20px;
  font-size: 1rem;
}

@media (max-width: 600px) {
  .cookie-banner {
    flex-direction: column;
    align-items: flex-start;
    gap: 16px;
    padding: 18px 10px;
  }
  .cookie-modal {
    min-width: 99vw;
    max-width: 99vw;
    padding: 21px 7vw 12px 6vw;
    border-radius: 13px;
  }
}

/* === Utility ======================== */
.sr-only { position: absolute !important; left: -9999px; top: auto; width: 1px; height: 1px; overflow: hidden; }

/* === Prevent unwanted overlap (layout QA) ===*/
.card, .testimonial-card, .feature-item, .fact-snippets p, .inventor-profiles, .map-embed, section {
  margin-bottom: 20px;
}

/* === Visual Geometric Shapes (bold modern style) ======== */
.hero::before {
  content: '';
  display: block;
  position: absolute;
  right: 0;
  top: 0;
  width: 210px;
  height: 210px;
  background: var(--mf-secondary);
  z-index: 0;
  opacity: 0.15;
  clip-path: polygon(80% 0,100% 0,100% 100%,60% 85%);
}
@media (max-width: 900px) {
  .hero::before { width: 120px; height: 120px; }
}

/* === BRAND GEOMETRIC LINES (optional) === */
.section-title {
  font-size: 1.8rem;
  font-weight: bold;
  color: var(--mf-primary);
  border-left: 7px solid var(--mf-secondary);
  padding-left: 13px;
  margin-bottom: 28px;
}

/* === END OF CSS STYLE =================================== */
