/* ------------------------------------------------------------
   Felstpallo Genussküche – Minimalist UI (Flexbox ONLY)
   ------------------------------------------------------------
   Colors:
     Primary:   #3D2931
     Secondary: #E4B269
     Accent:    #F2EFE9
   Fonts:
     Display:   'Bitter', serif
     Body:      'Open Sans', Arial, sans-serif
   ------------------------------------------------------------ */

/* RESET & NORMALIZATION */
html {
  box-sizing: border-box;
  font-size: 100%;
  scroll-behavior: smooth;
}
*, *:before, *:after {
  box-sizing: inherit;
  margin: 0;
  padding: 0;
  border: 0;
  font: inherit;
  vertical-align: baseline;
}
body {
  font-family: 'Open Sans', Arial, sans-serif;
  color: #3D2931;
  background: #fff;
  line-height: 1.6;
  min-height: 100vh;
  font-size: 16px;
  letter-spacing: 0.01em;
  -webkit-font-smoothing: antialiased;
  background-color: #F2EFE9;
}
img, svg {
  display: block;
  max-width: 100%;
  height: auto;
}
main, nav, header, footer, section, aside, article {
  display: block;
}
a {
  color: #3D2931;
  text-decoration: none;
  transition: color 0.2s;
  outline: none;
}
ul, ol {
  list-style: none;
}
button, input, select, textarea {
  font-family: inherit;
  font-size: 100%;
  color: inherit;
  background: none;
  border: none;
  outline: none;
}

/* ----------------------------------------------
   TYPOGRAPHY
   ---------------------------------------------- */
h1, .hero h1, .thankyou h1 {
  font-family: 'Bitter', serif;
  font-size: 2.5rem;
  font-weight: 700;
  color: #3D2931;
  margin-bottom: 16px;
  line-height: 1.18;
}
h2 {
  font-family: 'Bitter', serif;
  font-size: 2rem;
  color: #3D2931;
  margin-bottom: 24px;
  font-weight: 700;
  line-height: 1.2;
}
h3, .footer-contact strong, .feature-item h3 {
  font-family: 'Bitter', serif;
  font-size: 1.25rem;
  color: #3D2931;
  font-weight: 600;
  margin-bottom: 12px;
  line-height: 1.25;
}
h4 {
  font-family: 'Bitter', serif;
  font-size: 1rem;
  font-weight: 600;
  margin-bottom: 10px;
  color: #3D2931;
}
p, ul, ol {
  font-size: 1rem;
  margin-bottom: 16px;
}
strong {
  font-weight: 700;
  color: #3D2931;
}

/* -----------------------------------------------
   CONTAINERS AND SPACING
   ----------------------------------------------- */
.container {
  width: 100%;
  max-width: 1040px;
  margin: 0 auto;
  padding: 0 20px;
  display: flex;
  flex-direction: column;
}
.content-wrapper {
  display: flex;
  flex-direction: column;
  gap: 24px;
}
.section {
  margin-bottom: 60px;
  padding: 40px 20px;
  background: #fff;
  border-radius: 16px;
  box-shadow: 0 1px 8px rgba(61,41,49,0.05), 0 4px 18px rgba(61,41,49,0.04);
}

/* -----------------------------------------------
   HEADER & NAVIGATION
   ----------------------------------------------- */
header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: #fff;
  box-shadow: 0 2px 12px rgba(61,41,49,0.07);
  padding: 20px 0 20px 0;
  position: sticky;
  top: 0;
  z-index: 100;
}
header > a img {
  height: 40px;
  width: auto;
  margin-right: 32px;
}
.main-menu {
  display: flex;
  align-items: center;
  gap: 24px;
}
.main-menu a {
  font-size: 1rem;
  color: #3D2931;
  padding: 8px 10px;
  border-radius: 6px;
  transition: background 0.2s, color 0.2s;
}
.main-menu a:hover, .main-menu a:focus {
  background: #F2EFE9;
  color: #E4B269;
}
.cta-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: 'Bitter', serif;
  font-size: 1rem;
  font-weight: 600;
  background: #E4B269;
  color: #3D2931;
  border-radius: 8px;
  padding: 11px 28px;
  margin-left: 32px;
  box-shadow: 0 2px 12px rgba(61,41,49,0.08);
  cursor: pointer;
  transition: background 0.2s, box-shadow 0.2s, color 0.2s;
}
.cta-btn:hover, .cta-btn:focus {
  background: #3D2931;
  color: #fff;
  box-shadow: 0 2px 16px rgba(61,41,49,0.13);
}

/* Hamburger for mobile */
.mobile-menu-toggle {
  display: none;
  background: none;
  border: none;
  font-size: 2rem;
  color: #3D2931;
  cursor: pointer;
  margin-left: 24px;
  padding: 6px 12px;
  border-radius: 8px;
  transition: background .16s;
}
.mobile-menu-toggle:active, .mobile-menu-toggle:focus {
  background: #E4B26925;
}

/* ---------------------------------------------
   MOBILE MENU OVERLAY
   --------------------------------------------- */
.mobile-menu {
  position: fixed;
  top: 0; left: 0; bottom: 0; right: 0;
  z-index: 999;
  background: rgba(61,41,49, 0.93);
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  justify-content: flex-start;
  transform: translateX(100%);
  transition: transform 0.27s cubic-bezier(.7,.17,.25,1);
  pointer-events: none;
  opacity: 0;
}
.mobile-menu.open {
  transform: translateX(0%);
  pointer-events: auto;
  opacity: 1;
}
.mobile-menu-close {
  margin: 24px 32px 0 0;
  font-size: 2.1rem;
  color: #fff;
  background: none;
  border: none;
  cursor: pointer;
  align-self: flex-end;
  padding: 6px 10px;
  border-radius: 6px;
  transition: background 0.16s;
}
.mobile-menu-close:hover, .mobile-menu-close:focus {
  background: #E4B26933;
}
.mobile-nav {
  margin-top: 40px;
  display: flex;
  flex-direction: column;
  gap: 18px;
  width: 100%;
  align-items: flex-start;
  padding-left: 48px;
}
.mobile-nav a {
  color: #fff;
  font-size: 1.25rem;
  padding: 10px 0;
  border-radius: 0 18px 18px 0;
  min-width: 60vw;
  transition: color 0.15s, background 0.18s;
}
.mobile-nav a:hover, .mobile-nav a:focus {
  color: #E4B269;
  background: #3D2931;
}
@media (max-width: 1070px) {
  .container {
    padding: 0 12px;
  }
}
@media (max-width: 900px) {
  .main-menu {
    gap: 16px;
  }
  .cta-btn {
    margin-left: 18px;
    padding: 10px 18px;
  }
}
@media (max-width: 830px) {
  header {
    flex-wrap: wrap;
    padding: 18px 0 10px 0;
  }
  .main-menu, .cta-btn {
    display: none;
  }
  .mobile-menu-toggle {
    display: block;
  }
}

/* ---------------------------------------------
   HERO SECTIONS
   --------------------------------------------- */
.hero {
  padding: 0;
  background: #F2EFE9;
  width: 100%;
  margin-bottom: 60px;
  display: flex; /* fallback for legacy browsers */
}
.hero .container {
  padding-top: 60px; padding-bottom: 50px;
  display: flex;
  flex-direction: column;
  align-items: center;
  min-height: 340px;
}
.hero .content-wrapper {
  align-items: center;
  text-align: center;
}
.hero p {
  max-width: 500px;
  color: #3D2931;
  font-size: 1.18rem;
}
.hero .cta-btn {
  margin-top: 20px;
}

/* ---------------------------------------------
   FEATURE GRIDS & CARDS
   --------------------------------------------- */
.feature-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 32px;
  margin-bottom: 24px;
  justify-content: space-between;
}
.feature-grid > div {
  flex: 1 1 220px;
  min-width: 200px;
  background: #fff;
  border-radius: 14px;
  box-shadow: 0 2px 10px rgba(61,41,49,0.05);
  padding: 28px 22px 24px 22px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  transition: box-shadow 0.18s, transform 0.16s;
}
.feature-grid > div:hover {
  box-shadow: 0 6px 24px rgba(61,41,49,0.12);
  transform: translateY(-3px) scale(1.022);
}
.feature-grid img {
  width: 44px;
  margin-bottom: 10px;
}

/* Quick links & tags */
.quick-links, .tags-filter {
  margin-top: 12px;
  font-size: 1rem;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}
.quick-links a, .tags-filter a {
  color: #3D2931;
  padding: 5px 12px;
  border-radius: 7px;
  background: #F2EFE9;
  font-weight: 600;
  transition: background 0.15s, color 0.15s;
}
.quick-links a:hover, .tags-filter a:hover {
  background: #E4B269;
  color: #3D2931;
}

/* ---------------------------------------------
   TESTIMONIAL CARD
   --------------------------------------------- */
.testimonial-card {
  display: flex;
  align-items: center;
  gap: 20px;
  padding: 20px;
  background: #fff;
  border-radius: 12px;
  box-shadow: 0 2px 10px rgba(61,41,49,0.07);
  margin-bottom: 24px;
  font-size: 1.06rem;
  color: #3D2931;
  line-height: 1.5;
  min-width: 0;
  flex-wrap: wrap;
  transition: box-shadow 0.18s;
}
.testimonial-card strong {
  margin-left: auto;
  font-family: 'Open Sans', Arial, sans-serif;
  font-weight: 700;
  font-size: 1rem;
  color: #3D2931;
  letter-spacing: .01em;
}
.testimonial-card:hover {
  box-shadow: 0 8px 28px rgba(61,41,49,0.13);
}

/* ---------------------------------------------
   BLOG LIST, POPULAR POSTS
   --------------------------------------------- */
.blog-list {
  display: flex;
  flex-direction: column;
  gap: 28px;
  margin-bottom: 18px;
}
.blog-list article {
  background: #fff;
  padding: 24px;
  border-radius: 10px;
  box-shadow: 0 2px 8px rgba(61,41,49,0.06);
  transition: box-shadow 0.18s, transform 0.14s;
}
.blog-list article:hover {
  box-shadow: 0 7px 22px rgba(61,41,49,0.11);
  transform: translateY(-2px) scale(1.011);
}
.popular-posts ul {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-top: 8px;
}
.popular-posts a {
  color: #3D2931;
  transition: color 0.17s;
}
.popular-posts a:hover, .popular-posts a:focus {
  color: #E4B269;
}

/* ---------------------------------------------
   FORMS & SEARCH BAR
   --------------------------------------------- */
.search-bar {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-top: 17px;
}
.search-bar input[type="text"] {
  padding: 9px 18px;
  font-size: 1rem;
  border-radius: 7px;
  border: 1px solid #e9e5dc;
  min-width: 210px;
  background: #fff;
  transition: border 0.16s, box-shadow 0.13s;
}
.search-bar input[type="text"]:focus {
  border-color: #E4B269;
  outline: none;
}
.search-bar button {
  background: #E4B269;
  border-radius: 7px;
  padding: 7px 11px;
  display: flex;
  align-items: center;
  cursor: pointer;
  border: none;
  transition: background 0.2s;
  height: 100%;
}
.search-bar button:hover {
  background: #3D2931;
}
.search-bar button img {
  width: 18px;
  height: 18px;
  filter: brightness(0) saturate(100%) invert(9%) sepia(14%) saturate(2453%) hue-rotate(294deg) brightness(91%) contrast(95%);
}
.search-bar button:hover img {
  filter: brightness(0) saturate(100%) invert(84%) sepia(18%) saturate(600%) hue-rotate(16deg) brightness(95%) contrast(97%);
}

/* ---------------------------------------------
   FOOTER
   --------------------------------------------- */
footer {
  background: #fff;
  border-top: 1px solid #F2EFE9;
  margin-top: 60px;
  padding-top: 38px;
  padding-bottom: 20px;
  font-size: 1rem;
  box-shadow: 0 -1px 8px rgba(61,41,49,0.04);
}
footer .container {
  flex-direction: column;
  align-items: center;
}
footer .content-wrapper {
  flex-direction: column;
  align-items: center;
  gap: 30px;
  text-align: center;
}
.footer-menu {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  justify-content: center;
}
.footer-menu a {
  color: #3D2931;
  background: #F2EFE9;
  padding: 7px 17px;
  border-radius: 9px;
  font-size: .97rem;
  font-weight: 500;
  transition: background 0.19s, color 0.17s;
}
.footer-menu a:hover, .footer-menu a:focus {
  background: #E4B269;
  color: #fff;
}
.footer-contact {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  color: #3D2931;
  font-size: 0.99rem;
}
.footer-contact img {
  width: 16px;
  height: auto;
  margin-right: 7px;
  display: inline-block;
  vertical-align: middle;
}
.social-links {
  display: flex;
  gap: 14px;
  align-items: center;
  margin-top: 7px;
  justify-content: center;
}
.social-links a {
  display: inline-flex;
  padding: 6px;
  border-radius: 7px;
  background: #F2EFE9;
  transition: background .16s;
}
.social-links a:hover {
  background: #E4B269;
}
footer p {
  font-size: .92rem;
  margin: 0;
  color: #685656;
}
footer img[alt="Felstpallo Genussküche Logo"] {
  width: 75px;
  height: auto;
  margin-bottom: 7px;
}

/* ---------------------------------------------
   CARD LAYOUTS & FLEX UTILS
   --------------------------------------------- */
.card-container {
  display: flex;
  flex-wrap: wrap;
  gap: 24px;
}
.card {
  margin-bottom: 20px;
  position: relative;
  background: #fff;
  border-radius: 14px;
  box-shadow: 0 2px 10px rgba(61,41,49,0.04);
  display: flex;
  flex-direction: column;
  gap: 13px;
  padding: 30px 25px;
  transition: box-shadow 0.13s, transform 0.14s;
}
.card:hover {
  box-shadow: 0 8px 32px rgba(61,41,49,0.10);
  transform: translateY(-2px) scale(1.01);
}
.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;
}
.feature-item {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 15px;
}

/****** Additional Utility Spacing ******/
@media (max-width: 768px) {
  .feature-grid {
    flex-direction: column;
    gap: 18px;
    align-items: stretch;
  }
  .content-grid, .card-container {
    flex-direction: column;
    gap: 18px;
  }
  .text-image-section {
    flex-direction: column;
    gap: 18px;
  }
  .testimonial-card {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
  }
  header {
    gap: 14px;
  }
  .container {
    padding: 0 6px;
  }
}

/* ---------------------------------------------
   UL LISTS, ICONS, and TABLES
   --------------------------------------------- */
ul, ol {
  margin-left: 21px;
  margin-bottom: 18px;
  padding-left: 0;
  list-style: disc inside;
  color: #51413f;
}
ul li, ol li {
  margin-bottom: 7px;
  padding-left: 0;
}
ul li:last-child, ol li:last-child {
  margin-bottom: 0;
}

/* Icon links in text */
p img[alt] {
  display: inline-block;
  width: 18px;
  vertical-align: bottom;
  margin-right: 6px;
  margin-bottom: 2px;
}

/* ---------------------------------------------
   CALL TO ACTION SECTIONS
   --------------------------------------------- */
.cta-section {
  background: #F2EFE9;
  border-radius: 12px;
  padding: 22px 18px;
  margin-top: 17px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 13px;
}
.cta-section .cta-btn {
  margin-left: 0;
  margin-top: 7px;
}

/* ---------------------------------------------
   THANK YOU / SPECIAL PAGES
   --------------------------------------------- */
.thankyou {
  background: #fff;
  border-radius: 16px;
  box-shadow: 0 1px 8px rgba(61,41,49,0.05);
  margin-top: 42px;
  display: flex;
  align-items: center;
  min-height: 350px;
  padding: 34px 0;
}

/* ---------------------------------------------
   COOKIE CONSENT BANNER
   --------------------------------------------- */
.cookie-banner {
  position: fixed;
  bottom: 0;
  left: 0; right: 0;
  width: 100%;
  background: #3D2931;
  color: #fff;
  box-shadow: 0 -2px 14px rgba(61,41,49,0.18);
  z-index: 1000;
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 24px 10px;
  font-size: 1rem;
  gap: 32px;
  pointer-events: auto;
  opacity: 1;
  transition: transform 0.33s cubic-bezier(.7,.2,.23,1), opacity 0.18s;
}
.cookie-banner.hidden {
  transform: translateY(120%);
  opacity: 0;
  pointer-events: none;
}
.cookie-banner .cookie-actions {
  display: flex;
  gap: 18px;
  margin-left: 22px;
}
.cookie-btn {
  border-radius: 8px;
  background: #E4B269;
  color: #3D2931;
  font-family: 'Bitter', serif;
  font-size: 1rem;
  font-weight: 600;
  padding: 9px 16px;
  margin-left: 0;
  min-width: 120px;
  cursor: pointer;
  transition: background .18s, color .17s, box-shadow .17s;
  box-shadow: 0 1px 4px rgba(44,40,49,0.10);
}
.cookie-btn:focus, .cookie-btn:hover {
  background: #3D2931;
  color: #fff;
}
.cookie-btn.secondary {
  background: #fff;
  color: #3D2931;
  border: 1px solid #E4B269;
  font-weight: 400;
}
.cookie-btn.secondary:hover {
  background: #E4B269;
  color: #3D2931;
}

/* Cookie Modal */
.cookie-modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(61,41,49,.93);
  z-index: 1011;
  display: flex;
  justify-content: center;
  align-items: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.22s;
}
.cookie-modal-overlay.open {
  opacity: 1;
  pointer-events: auto;
}
.cookie-modal {
  background: #fff;
  color: #3D2931;
  border-radius: 17px;
  box-shadow: 0 6px 44px rgba(61,41,49,0.23);
  width: 95vw;
  max-width: 400px;
  padding: 34px 24px 28px 24px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  position: relative;
  animation: fadeInUp .4s cubic-bezier(.29,.68,.46,1.26);
}
@keyframes fadeInUp {
  from { transform: translateY(50px) scale(0.98); opacity: 0; }
  to { transform: translateY(0) scale(1); opacity: 1; }
}
.cookie-modal h2 {
  font-size: 1.32rem;
  color: #3D2931;
  margin-bottom: 8px;
}
.cookie-modal .cookie-categories {
  display: flex;
  flex-direction: column;
  gap: 11px;
}
.cookie-category {
  display: flex;
  align-items: center;
  gap: 16px;
  font-size: 1rem;
  background: #F2EFE9;
  padding: 11px 15px;
  border-radius: 7px;
}
.cookie-category input[type='checkbox'] {
  appearance: none;
  width: 18px;
  height: 18px;
  border: 2px solid #E4B269;
  border-radius: 5px;
  margin-right: 8px;
  background: #fff;
  transition: border .18s, background .17s;
  cursor: pointer;
  position: relative;
}
.cookie-category input[type='checkbox']:checked {
  background: #E4B269;
  border-color: #3D2931;
}
.cookie-category input[type='checkbox']:checked:after {
  content: '';
  display: block;
  position: absolute;
  width: 8px; height: 8px;
  top: 3px; left: 3px;
  background: #3D2931;
  border-radius: 2px;
}
.cookie-category input[disabled] {
  opacity: 0.4;
  cursor: default;
}
.cookie-modal .modal-actions {
  display: flex;
  gap: 17px;
  margin-top: 21px;
  justify-content: flex-end;
}
.cookie-modal .modal-title {
  font-family: 'Bitter', serif;
  font-weight: 700;
}
.cookie-modal .cookie-modal-close {
  position: absolute;
  top: 18px;
  right: 16px;
  font-size: 1.7rem;
  color: #685656;
  background: none;
  border: none;
  cursor: pointer;
  border-radius: 5px;
  padding: 3px 7px;
}
.cookie-modal .cookie-modal-close:hover {
  background: #E4B26922;
}

@media (max-width: 510px) {
  .cookie-modal {
    padding: 18px 6vw 14px 6vw;
  }
}

/* ---------------------------------------------
   TRANSITIONS & MICRO-INTERACTIONS
   --------------------------------------------- */
a, button, .cta-btn, .feature-grid > div, .card {
  transition: color 0.16s, background 0.19s, box-shadow .18s, transform .14s;
}

/* ---------------------------------------------
   RESPONSIVE ADAPTATIONS (Mobile-first)
   --------------------------------------------- */
@media (max-width: 600px) {
  h1, .hero h1, .thankyou h1 {
    font-size: 2rem;
  }
  h2 {
    font-size: 1.28rem;
  }
  .hero .container {
    padding-top: 35px; padding-bottom: 25px;
    min-height: 220px;
  }
  section, .section {
    padding: 28px 3vw;
  }
  .thankyou {
    padding: 24px 0;
  }
}
@media (max-width: 430px) {
  .footer-menu, .social-links {
    flex-direction: column;
    gap: 6px;
  }
}

/* ---------------------------------------------
   FOCUS STYLES FOR ACCESSIBILITY
   --------------------------------------------- */
:focus {
  outline: 2px solid #E4B269 !important;
  outline-offset: 2px;
}

/* Hide visually but keep accessible */
.visually-hidden {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  margin: -1px !important;
  padding: 0 !important;
  border: 0 !important;
  overflow: hidden !important;
  clip: rect(1px, 1px, 1px, 1px);
}
