/* ======= 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, main, 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;
}
body {
  line-height: 1.5;
  background: #F6F6F3;
  color: #234162;
  font-family: 'Georgia', 'Times New Roman', Times, serif;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
img, picture, video, canvas, svg {
  display: block;
  max-width: 100%;
  height: auto;
}
input, button, textarea, select {
  font: inherit;
}
a {
  color: inherit;
  text-decoration: none;
  transition: color 0.2s;
}
ul, ol {
  list-style: none;
}
button {
  border: none;
  background: none;
  cursor: pointer;
  outline: none;
}

/* ======= BRAND FONTS & COLORS ======= */
:root {
  --primary: #234162;
  --secondary: #74A37A;
  --accent: #F6F6F3;
  --text: #232224;
  --surface: #fff;
  --muted: #E8EBE7;
  --heading-font: 'Georgia', 'Times New Roman', Times, serif;
  --body-font: 'Open Sans', Arial, serif;
}

/* ======= TYPOGRAPHY ======= */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--heading-font);
  color: var(--primary);
  letter-spacing: 0.02em;
  line-height: 1.2;
  font-weight: 700;
}
h1 { font-size: 2.5rem; margin-bottom: 24px; }
h2 { font-size: 2rem; margin-bottom: 20px; }
h3 { font-size: 1.25rem; margin-bottom: 12px; font-style: italic; }
h4, h5, h6 { font-size: 1rem; }
p, ul, ol, li, blockquote, cite {
  font-family: var(--body-font);
  color: var(--text);
  font-size: 1.063rem; /*17px*/
  line-height: 1.7;
}
p:not(:last-child) {
  margin-bottom: 16px;
}
.subtitle {
  color: var(--secondary);
  font-size: 1.25rem;
  line-height: 1.4;
  margin-bottom: 24px;
  font-family: var(--body-font);
}
blockquote {
  font-family: var(--heading-font);
  font-style: italic;
  background: var(--muted);
  color: var(--primary);
  border-left: 4px solid var(--secondary);
  padding: 12px 18px 12px 28px;
  margin-bottom: 10px;
  font-size: 1.2rem;
}
cite {
  font-size: 1rem;
  color: #576877;
  font-family: var(--body-font);
  margin-left: 18px;
}
strong { font-weight: 700; }

/* ======= CONTAINERS & LAYOUT ======= */
.container {
  width: 100%;
  max-width: 1100px;
  margin: 0 auto;
  padding-left: 20px;
  padding-right: 20px;
}
.content-wrapper {
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 16px;
  align-items: flex-start;
  /* breathing room for each section */
}

/* Main section spacing */
section {
  margin-bottom: 60px;
  padding: 40px 20px;
  background: transparent;
}
/* Alternate background for key sections */
section:nth-of-type(odd) {
  background: var(--accent);
}

/* FLEX LAYOUTS */
.feature-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 24px;
  margin-top: 24px;
  margin-bottom: 12px;
}
.feature-item {
  background: var(--surface);
  min-width: 240px;
  flex: 1 1 220px;
  max-width: 290px;
  border-radius: 18px;
  box-shadow: 0 2px 12px 0 rgba(35,65,98,0.08);
  padding: 28px 22px 22px 22px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 15px;
  border: 1px solid var(--muted);
  transition: box-shadow 0.2s;
}
.feature-item:hover {
  box-shadow: 0 4px 24px 0 rgba(35,65,98,0.14);
}

.card-container, .card-grid, .project-list, .blog-list, .tips-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 24px;
  margin-top: 16px;
}

.card, .blog-post, .tip-item, .project-item {
  background: var(--surface);
  border-radius: 18px;
  box-shadow: 0 2px 12px 0 rgba(35,65,98,0.08);
  margin-bottom: 20px;
  padding: 24px 20px 18px 20px;
  position: relative;
  border: 1px solid var(--muted);
  display: flex;
  flex-direction: column;
  gap: 14px;
  transition: box-shadow 0.22s, border-color 0.22s;
}
.card:hover, .blog-post:hover, .tip-item:hover, .project-item:hover {
  box-shadow: 0 6px 32px 0 rgba(35,65,98,0.18);
  border-color: var(--secondary);
}

.text-image-section {
  display: flex;
  align-items: center;
  gap: 30px;
  flex-wrap: wrap;
}

.content-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  justify-content: space-between;
}

/* Testimonials */
.testimonial-card {
  display: flex;
  align-items: center;
  gap: 20px;
  padding: 20px 20px 20px 32px;
  margin-bottom: 24px;
  border-left: 4px solid var(--secondary);
  background: var(--surface);
  border-radius: 14px;
  box-shadow: 0 1px 8px 0 rgba(35,65,98,0.05);
  transition: box-shadow 0.18s, border-color 0.2s;
}
.testimonial-card:hover {
  box-shadow: 0 4px 12px 0 rgba(35,65,98,0.15);
  border-left-color: var(--primary);
}

/* CATEGORY TAGS, FILTERS, ETC */
.category-tag,
.category-filter {
  background: var(--muted);
  color: var(--primary);
  font-family: var(--body-font);
  border-radius: 8px;
  font-size: 1rem;
  font-weight: 600;
  padding: 4px 14px;
  margin-bottom: 12px;
  display: inline-block;
  letter-spacing: 0.04em;
}

/* NEWSLETTER SIGNUP */
.newsletter-signup {
  background: var(--surface);
  border-radius: 14px;
  box-shadow: 0 2px 12px 0 rgba(35,65,98,0.06);
  padding: 20px 22px;
  margin-top: 12px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

/* ======= HEADER & NAVIGATION ======= */
header {
  background: var(--surface);
  border-bottom: 1px solid var(--muted);
  position: sticky;
  top: 0;
  z-index: 50;
}
header .container {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  justify-content: space-between;
  padding-top: 18px;
  padding-bottom: 18px;
  gap: 18px;
}
header nav {
  display: flex;
  gap: 22px;
}
header nav a {
  font-family: var(--body-font);
  color: var(--primary);
  font-weight: 600;
  letter-spacing: 0.02em;
  font-size: 1rem;
  position: relative;
  padding: 2px 4px;
  transition: color 0.18s;
}
header nav a:after {
  content: '';
  display: block;
  height: 2px;
  background: var(--secondary);
  border-radius: 2px;
  width: 0;
  transition: width 0.2s;
  margin-top: 2px;
}
header nav a:hover,
header nav a:focus {
  color: var(--secondary);
}
header nav a:hover:after,
header nav a:focus:after {
  width: 100%;
}

.btn-primary {
  font-family: var(--body-font);
  padding: 10px 28px;
  background: var(--primary);
  color: #fff;
  border-radius: 999px;
  font-size: 1.063rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  box-shadow: 0 1px 10px 0 rgba(35,65,98,0.07);
  transition: background 0.16s, color 0.14s, transform 0.12s;
  margin-left: 12px;
  border: 1px solid var(--primary);
  display: inline-block;
}
.btn-primary:hover, .btn-primary:focus {
  background: var(--secondary);
  color: var(--primary);
  border-color: var(--secondary);
  transform: translateY(-1px) scale(1.01);
}
.btn-link {
  color: var(--primary);
  background: transparent;
  font-family: var(--body-font);
  font-size: 1rem;
  font-weight: 600;
  border-radius: 4px;
  padding: 0 6px 0 0;
  position: relative;
  transition: color 0.14s;
}
.btn-link:after {
  content: '';
  display: inline-block;
  width: 0;
  height: 2px;
  background: var(--secondary);
  border-radius: 2px;
  position: absolute;
  left: 0;
  bottom: -3px;
  transition: width 0.18s;
}
.btn-link:hover, .btn-link:focus {
  color: var(--secondary);
}
.btn-link:hover:after, .btn-link:focus:after {
  width: 100%;
}

/* ======= MOBILE MENU ======= */
.mobile-menu-toggle {
  font-size: 1.75rem;
  color: var(--primary);
  background: transparent;
  border-radius: 8px;
  padding: 6px 14px;
  margin-left: 12px;
  display: none;
  transition: background 0.12s;
}
.mobile-menu-toggle:focus, .mobile-menu-toggle:hover {
  background: var(--muted);
}

.mobile-menu {
  position: fixed;
  top: 0;
  right: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(35,65,98,0.95);
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  align-items: flex-end;
  z-index: 1003;
  transform: translateX(100%);
  opacity: 0;
  pointer-events: none;
  transition: transform 0.38s cubic-bezier(0.4,0.82,0.23,1), opacity 0.3s;
}
.mobile-menu.open {
  transform: translateX(0);
  opacity: 1;
  pointer-events: auto;
}
.mobile-menu-close {
  font-size: 2.2rem;
  color: #fff;
  background: transparent;
  border-radius: 8px;
  padding: 8px 18px 8px 8px;
  margin: 36px 24px 8px 0;
  transition: background 0.15s;
}
.mobile-menu-close:hover, .mobile-menu-close:focus {
  background: var(--secondary);
  color: var(--primary);
}
.mobile-nav {
  margin: 24px 0 0 0;
  display: flex;
  flex-direction: column;
  gap: 26px;
  width: 92vw;
  align-items: flex-start;
  padding-left: 30px;
}
.mobile-nav a {
  color: #fff;
  font-family: var(--body-font);
  font-size: 1.3rem;
  font-weight: 700;
  padding: 3px 6px;
  letter-spacing: 0.01em;
  border-radius: 8px;
  transition: background 0.16s, color 0.16s;
  margin-bottom: 4px;
}
.mobile-nav a:hover, .mobile-nav a:focus {
  background: var(--secondary);
  color: var(--primary);
}

/* Hide desktop nav/btn by default on small screens */
@media (max-width: 1024px) {
  header nav, header .btn-primary {
    display: none;
  }
  .mobile-menu-toggle {
    display: inline-block;
  }
}
@media (min-width: 1025px) {
  .mobile-menu,
  .mobile-menu-toggle {
    display: none !important;
  }
}

/* ======= FOOTER ======= */
footer {
  background: var(--primary);
  color: #fff;
  padding: 48px 0 16px 0;
  font-family: var(--body-font);
}
footer .container {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 28px;
  margin-bottom: 18px;
}
footer nav {
  display: flex;
  gap: 18px;
  flex-wrap: wrap;
}
footer nav a {
  color: #F8F9FB;
  font-size: 1rem;
  font-weight: 600;
  border-radius: 4px;
  padding: 2px 6px;
  transition: background 0.16s, color 0.16s;
}
footer nav a:hover, footer nav a:focus {
  background: var(--secondary);
  color: var(--primary);
}
.contact-footer {
  display: flex;
  flex-direction: column;
  gap: 7px;
  font-size: 1rem;
}
.contact-footer img {
  width: 18px;
  vertical-align: middle;
  margin-right: 7px;
  margin-bottom: 3px;
}
footer small {
  display: block;
  width: 100%;
  text-align: center;
  color: #c3ced3;
  font-size: 0.95rem;
  margin-top: 6px;
}

/* ======= COOKIE CONSENT BANNER ======= */
.cookie-banner {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  background: var(--surface);
  color: var(--text);
  box-shadow: 0 -2px 18px rgba(44,62,80,0.10);
  border-top: 1px solid var(--muted);
  padding: 22px 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 22px;
  z-index: 9999;
  font-family: var(--body-font);
  animation: banner-slidein 0.5s;
}
@keyframes banner-slidein {
  from { transform: translateY(100%); }
  to { transform: translateY(0); }
}
.cookie-banner-content {
  flex: 1 1 auto;
  max-width: 560px;
  font-size: 1.1rem;
}
.cookie-banner-buttons {
  display: flex;
  gap: 16px;
  flex-shrink: 0;
}
.cookie-btn {
  padding: 9px 19px;
  font-size: 1.05rem;
  margin: 0 2px;
  border-radius: 18px;
  font-family: var(--body-font);
  font-weight: 700;
  letter-spacing: 0.01em;
  transition: background 0.14s, color 0.14s, border 0.13s;
}
.cookie-btn.accept {
  background: var(--secondary);
  border: 1px solid var(--secondary);
  color: var(--primary);
}
.cookie-btn.accept:hover, .cookie-btn.accept:focus {
  background: var(--primary);
  color: #fff;
  border-color: var(--primary);
}
.cookie-btn.reject {
  background: transparent;
  border: 1px solid var(--secondary);
  color: var(--secondary);
}
.cookie-btn.reject:hover, .cookie-btn.reject:focus {
  background: var(--secondary);
  color: var(--primary);
}
.cookie-btn.settings {
  background: transparent;
  border: 1px solid var(--primary);
  color: var(--primary);
}
.cookie-btn.settings:hover, .cookie-btn.settings:focus {
  background: var(--primary);
  color: #fff;
}
/* Cookie Preferences Modal */
.cookie-modal {
  position: fixed;
  left: 50%;
  top: 50%;
  transform: translate(-50%,60%) scale(0.97);
  background: var(--surface);
  border-radius: 22px;
  box-shadow: 0 8px 32px 0 rgba(35,65,98,0.18);
  border: 1px solid var(--muted);
  padding: 38px 32px 32px 32px;
  z-index: 99999;
  min-width: 300px;
  max-width: 96vw;
  min-height: 220px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s, transform 0.32s;
  display: flex;
  flex-direction: column;
  gap: 22px;
}
.cookie-modal.open {
  opacity: 1;
  transform: translate(-50%,-50%) scale(1);
  pointer-events: auto;
}
.cookie-modal-header {
  font-family: var(--heading-font);
  font-size: 1.3rem;
  color: var(--primary);
  margin-bottom: 10px;
}
.cookie-categories {
  display: flex;
  flex-direction: column;
  gap: 16px;
  font-family: var(--body-font);
  font-size: 1.1rem;
}
.cookie-category {
  display: flex;
  align-items: center;
  gap: 10px;
}
.cookie-modal-btn-close {
  align-self: flex-end;
  background: none;
  color: var(--primary);
  font-size: 1.7rem;
  border-radius: 6px;
  padding: 4px 8px;
  transition: background 0.14s;
  position: absolute;
  top: 10px;
  right: 14px;
}
.cookie-modal-btn-close:hover, .cookie-modal-btn-close:focus {
  background: var(--muted);
}
.cookie-modal-actions {
  display: flex;
  gap: 14px;
  margin-top: 12px;
  justify-content: flex-end;
}
/* Custom styled toggles */
.cookie-toggle {
  display: inline-flex;
  align-items: center;
}
.cookie-toggle input[type="checkbox"] {
  width: 22px;
  height: 22px;
  accent-color: var(--secondary);
}
.cookie-toggle .always-on {
  color: var(--secondary);
  font-weight: 700;
}

/* ======= FORMS (Contact Page) ======= */
input, textarea {
  border-radius: 9px;
  border: 1px solid var(--muted);
  padding: 11px 15px;
  font-size: 1rem;
  background: var(--surface);
  margin-bottom: 14px;
  width: 100%;
  font-family: var(--body-font);
  box-sizing: border-box;
  transition: border-color 0.14s, box-shadow 0.15s;
}
input:focus, textarea:focus {
  outline: none;
  border-color: var(--secondary);
  box-shadow: 0 0 3px var(--secondary);
}
label {
  font-family: var(--body-font);
  font-size: 1rem;
  color: var(--primary);
  margin-bottom: 4px;
  font-weight: 700;
}

/* ======= CONFIRMATION MESSAGE ======= */
.confirmation-message {
  background: var(--muted);
  color: var(--primary);
  border-radius: 10px;
  padding: 24px 20px;
  margin-bottom: 18px;
  font-family: var(--body-font);
}

/* ======= RESPONSIVE DESIGN ======= */
@media (max-width: 1024px) {
  .feature-grid, .card-container, .card-grid, .content-grid, .project-list, .blog-list, .tips-grid {
    gap: 18px;
  }
  .container {
    padding-left: 8px;
    padding-right: 8px;
  }
}
@media (max-width: 768px) {
  h1 { font-size: 2rem; }
  h2 { font-size: 1.3rem; }
  .subtitle, p, li, blockquote, cite { font-size: 1rem; }
  section { padding: 28px 8px; }
  .feature-grid, .card-container, .card-grid, .content-grid, .project-list, .blog-list, .tips-grid {
    flex-direction: column;
    gap: 16px;
  }
  .feature-item, .card, .project-item, .tip-item, .blog-post {
    max-width: 100%;
    min-width: unset;
    width: 100%;
  }
  .testimonial-card {
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
    padding: 16px 12px 16px 17px;
  }
  .footer .container {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
  }
}
@media (max-width: 520px) {
  h1 { font-size: 1.35rem; }
  h2 { font-size: 1.08rem; }
  .btn-primary, .cookie-btn {
    font-size: 0.93rem;
    padding: 8px 14px;
  }
  .cookie-banner {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
    padding: 16px 5px;
  }
  .cookie-banner-content {
    max-width: 95vw;
    font-size: 0.96rem;
  }
  .cookie-banner-buttons {
    flex-wrap: wrap;
    gap: 9px;
  }
  .cookie-modal {
    padding: 22px 7vw 18px 7vw;
  }
}

/* ======= MICRO-INTERACTIONS & EFFECTS ======= */
li img {
  vertical-align: middle;
  width: 21px;
  margin-right: 7px;
}
a:focus {
  outline: 2px solid var(--secondary);
  outline-offset: 2px;
}
button:focus {
  outline: 2px solid var(--secondary);
  outline-offset: 2px;
}

/* ----- Section rules from mission ----- */
.section { margin-bottom: 60px; padding: 40px 20px; }
.card-container { display: flex; flex-wrap: wrap; gap: 24px; }
.card { margin-bottom: 20px; position: relative; }
.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; }
.feature-item { display: flex; flex-direction: column; align-items: flex-start; gap: 15px; }

/* Guarantee proper contrast for testimonials (always dark text on light) */
.testimonial-card,
.testimonial-card blockquote,
.testimonial-card cite {
  color: var(--primary) !important;
  background: var(--surface) !important;
}

/* Extra: Animate appearance of content cards */
.card, .feature-item, .tip-item, .project-item, .blog-post {
  opacity: 0;
  transform: translateY(18px);
  animation: fade-in-card 0.67s cubic-bezier(.77,0,0.18,1) 0.1s forwards;
}
@keyframes fade-in-card {
  from { opacity: 0; transform: translateY(18px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ======= ACCESSIBILITY ======= */
::-webkit-input-placeholder { color: #9faab7; }
::-moz-placeholder { color: #9faab7; }
:-ms-input-placeholder { color: #9faab7; }
::placeholder { color: #9faab7; }

/* ======= EXTRAS ======= */
hr {
  border: 0;
  border-top: 1px solid var(--muted);
  margin: 36px 0 28px 0;
}

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