/* =============================================
   P4-Agrarservice und Dienstleistungen GmbH
   Main Stylesheet
   ============================================= */

/* --- Reset & Base --- */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Open Sans', Arial, sans-serif;
  font-size: 15px;
  color: #333;
  background: #fff;
  line-height: 1.7;
}

a {
  color: #c0392b;
  text-decoration: none;
  transition: color 0.2s;
}

a:hover {
  color: #922b21;
  text-decoration: underline;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

ul {
  list-style: none;
}

/* --- Typography --- */
h1, h2, h3, h4 {
  font-family: 'Open Sans', Arial, sans-serif;
  font-weight: 700;
  color: #222;
  line-height: 1.3;
}

h2 {
  font-size: 1.6rem;
  margin-bottom: 0.8rem;
}

h3 {
  font-size: 1.2rem;
  margin-bottom: 0.5rem;
}

p {
  margin-bottom: 1rem;
}

/* --- Container --- */
.container {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 20px;
}

/* =============================================
   HEADER / HERO
   ============================================= */

#header {
  position: relative;
  width: 100%;
  background: #1a1a1a;
  overflow: hidden;
}

.hero-image {
  width: 100%;
  height: 420px;
  object-fit: cover;
  object-position: center 60%;
  display: block;
  opacity: 0.88;
}

.hero-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(to bottom, rgba(0,0,0,0.18) 0%, rgba(0,0,0,0.45) 100%);
  pointer-events: none;
}

.logo-wrap {
  position: absolute;
  top: 28px;
  left: 40px;
  z-index: 10;
}

.logo-wrap .logo-text {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}

.logo-wrap .logo-p4 {
  font-size: 3.6rem;
  font-weight: 900;
  color: #fff;
  letter-spacing: -2px;
  line-height: 1;
  text-shadow: 2px 2px 8px rgba(0,0,0,0.6);
}

.logo-wrap .logo-p4 span {
  color: #c0392b;
}

.logo-wrap .logo-subtitle {
  font-size: 0.78rem;
  color: #f0f0f0;
  letter-spacing: 1px;
  text-transform: uppercase;
  text-shadow: 1px 1px 4px rgba(0,0,0,0.7);
  margin-top: 2px;
  max-width: 280px;
}

/* =============================================
   NAVIGATION
   ============================================= */

#navbar {
  background: #fff;
  border-bottom: 3px solid #c0392b;
  box-shadow: 0 2px 6px rgba(0,0,0,0.1);
  position: sticky;
  top: 0;
  z-index: 100;
}

#navbar .nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 20px;
}

#navbar ul {
  display: flex;
  flex-wrap: wrap;
}

#navbar ul li a {
  display: block;
  padding: 16px 18px;
  color: #333;
  font-size: 0.88rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  text-decoration: none;
  transition: color 0.2s, background 0.2s;
}

#navbar ul li a:hover,
#navbar ul li a.active {
  color: #c0392b;
  background: #fdf0ef;
}

.nav-contact-info {
  font-size: 0.82rem;
  color: #555;
  white-space: nowrap;
}

.nav-contact-info a {
  color: #c0392b;
  font-weight: 600;
}

/* Mobile hamburger */
.nav-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 10px;
}

.nav-toggle span {
  display: block;
  width: 25px;
  height: 3px;
  background: #333;
  margin: 5px 0;
  border-radius: 2px;
  transition: 0.3s;
}

/* =============================================
   MAIN CONTENT LAYOUT
   ============================================= */

#main-content {
  display: flex;
  max-width: 1100px;
  margin: 0 auto;
  padding: 40px 20px;
  gap: 40px;
}

.content-area {
  flex: 1;
  min-width: 0;
}

.sidebar {
  width: 260px;
  flex-shrink: 0;
}

/* =============================================
   HOME PAGE - VALUE PROPOSITIONS
   ============================================= */

.value-section {
  margin-bottom: 40px;
  padding-bottom: 40px;
  border-bottom: 1px solid #e8e8e8;
  display: flex;
  gap: 24px;
  align-items: flex-start;
}

.value-section:last-of-type {
  border-bottom: none;
}

.value-dropcap {
  font-size: 5rem;
  font-weight: 900;
  color: #c0392b;
  line-height: 0.85;
  font-family: Georgia, serif;
  flex-shrink: 0;
  width: 80px;
  text-align: center;
  padding-top: 4px;
}

.value-body h2 {
  font-size: 1.4rem;
  color: #222;
  margin-bottom: 10px;
}

.value-body p {
  color: #555;
  font-size: 0.95rem;
}

/* =============================================
   CONTACT NUMBERS SECTION
   ============================================= */

.contact-numbers {
  background: #f9f9f9;
  border-left: 4px solid #c0392b;
  padding: 28px 32px;
  margin: 30px 0;
}

.contact-numbers h3 {
  color: #c0392b;
  font-size: 1.1rem;
  margin-bottom: 18px;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.contact-numbers .phone-row {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 10px;
}

.contact-numbers .phone-label {
  color: #c0392b;
  font-weight: 700;
  font-size: 1rem;
  min-width: 80px;
}

.contact-numbers .phone-number {
  color: #333;
  font-size: 1.05rem;
  font-weight: 600;
}

.contact-numbers .phone-number a {
  color: #333;
}

/* =============================================
   SERVICES SECTION (Leistungen)
   ============================================= */

.services-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 28px;
  margin: 30px 0;
}

.service-card {
  background: #fff;
  border: 1px solid #e0e0e0;
  border-top: 4px solid #c0392b;
  padding: 28px 24px;
  transition: box-shadow 0.2s, transform 0.2s;
}

.service-card:hover {
  box-shadow: 0 6px 20px rgba(0,0,0,0.1);
  transform: translateY(-3px);
}

.service-card .service-icon {
  font-size: 2.4rem;
  margin-bottom: 14px;
}

.service-card h3 {
  color: #c0392b;
  font-size: 1.05rem;
  margin-bottom: 10px;
}

.service-card p {
  color: #666;
  font-size: 0.9rem;
  line-height: 1.6;
}

/* =============================================
   SIDEBAR
   ============================================= */

.sidebar-box {
  background: #f5f5f5;
  border: 1px solid #ddd;
  padding: 20px;
  margin-bottom: 24px;
}

.sidebar-box h3 {
  color: #c0392b;
  font-size: 0.95rem;
  text-transform: uppercase;
  letter-spacing: 1px;
  border-bottom: 2px solid #c0392b;
  padding-bottom: 8px;
  margin-bottom: 14px;
}

.sidebar-box p,
.sidebar-box address {
  font-size: 0.88rem;
  color: #555;
  font-style: normal;
  line-height: 1.7;
}

.sidebar-box a {
  color: #c0392b;
  font-weight: 600;
}

.sidebar-box .btn-contact {
  display: block;
  background: #c0392b;
  color: #fff;
  text-align: center;
  padding: 10px 16px;
  margin-top: 14px;
  font-size: 0.88rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  transition: background 0.2s;
  text-decoration: none;
}

.sidebar-box .btn-contact:hover {
  background: #922b21;
  text-decoration: none;
}

/* =============================================
   PAGE HERO BANNER (inner pages)
   ============================================= */

.page-banner {
  background: linear-gradient(135deg, #1a1a1a 0%, #2c2c2c 100%);
  color: #fff;
  padding: 50px 20px;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.page-banner::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  background: url('../images/hero.jpg') center/cover no-repeat;
  opacity: 0.25;
}

.page-banner .banner-content {
  position: relative;
  z-index: 1;
}

.page-banner h1 {
  font-size: 2.2rem;
  color: #fff;
  margin-bottom: 8px;
}

.page-banner p {
  color: #ddd;
  font-size: 1rem;
  margin: 0;
}

/* =============================================
   SECTION HEADINGS
   ============================================= */

.section-heading {
  font-size: 1.7rem;
  color: #222;
  margin-bottom: 8px;
  position: relative;
  padding-bottom: 12px;
}

.section-heading::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 60px;
  height: 3px;
  background: #c0392b;
}

.section-intro {
  color: #666;
  font-size: 0.95rem;
  margin-bottom: 30px;
  max-width: 680px;
}

/* =============================================
   ABOUT / UNTERNEHMEN PAGE
   ============================================= */

.about-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
  align-items: center;
  margin: 30px 0;
}

.about-grid img {
  border-radius: 2px;
  box-shadow: 0 4px 16px rgba(0,0,0,0.12);
}

.about-text h2 {
  color: #c0392b;
}

/* =============================================
   CONTACT PAGE
   ============================================= */

.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
  margin: 30px 0;
}

.contact-info-block h3 {
  color: #c0392b;
  margin-bottom: 16px;
}

.contact-info-block address {
  font-style: normal;
  line-height: 2;
  color: #444;
}

.contact-info-block address strong {
  color: #222;
}

.contact-form-block h3 {
  color: #c0392b;
  margin-bottom: 16px;
}

.contact-form .form-group {
  margin-bottom: 16px;
}

.contact-form label {
  display: block;
  font-size: 0.88rem;
  font-weight: 600;
  color: #444;
  margin-bottom: 5px;
}

.contact-form input,
.contact-form textarea,
.contact-form select {
  width: 100%;
  padding: 10px 14px;
  border: 1px solid #ccc;
  font-size: 0.9rem;
  font-family: inherit;
  background: #fafafa;
  transition: border-color 0.2s;
  outline: none;
}

.contact-form input:focus,
.contact-form textarea:focus {
  border-color: #c0392b;
  background: #fff;
}

.contact-form textarea {
  height: 130px;
  resize: vertical;
}

.btn-submit {
  background: #c0392b;
  color: #fff;
  border: none;
  padding: 12px 32px;
  font-size: 0.9rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  cursor: pointer;
  transition: background 0.2s;
}

.btn-submit:hover {
  background: #922b21;
}

/* Map placeholder */
.map-container {
  margin: 30px 0;
  border: 1px solid #ddd;
  overflow: hidden;
}

.map-container iframe {
  width: 100%;
  height: 380px;
  border: none;
  display: block;
}

/* =============================================
   IMPRESSUM / DATENSCHUTZ
   ============================================= */

.legal-content {
  max-width: 800px;
}

.legal-content h2 {
  color: #c0392b;
  margin-top: 30px;
  margin-bottom: 10px;
  font-size: 1.2rem;
}

.legal-content h2:first-child {
  margin-top: 0;
}

.legal-content p,
.legal-content address {
  font-style: normal;
  color: #555;
  font-size: 0.92rem;
  line-height: 1.8;
  margin-bottom: 12px;
}

/* =============================================
   FOOTER
   ============================================= */

#footer {
  background: #1a1a1a;
  color: #aaa;
  padding: 30px 20px;
  margin-top: 60px;
}

.footer-inner {
  max-width: 1100px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 16px;
}

.footer-copy {
  font-size: 0.82rem;
}

.footer-links {
  display: flex;
  gap: 20px;
}

.footer-links a {
  color: #aaa;
  font-size: 0.82rem;
  text-decoration: none;
  transition: color 0.2s;
}

.footer-links a:hover {
  color: #c0392b;
}

/* =============================================
   COOKIE NOTICE
   ============================================= */

#cookie-notice {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: rgba(30,30,30,0.97);
  color: #ddd;
  padding: 16px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  z-index: 9999;
  font-size: 0.85rem;
  flex-wrap: wrap;
}

#cookie-notice a {
  color: #e74c3c;
}

#cookie-notice button {
  background: #c0392b;
  color: #fff;
  border: none;
  padding: 8px 22px;
  font-size: 0.85rem;
  font-weight: 700;
  cursor: pointer;
  white-space: nowrap;
  transition: background 0.2s;
}

#cookie-notice button:hover {
  background: #922b21;
}

/* =============================================
   RESPONSIVE
   ============================================= */

@media (max-width: 900px) {
  #main-content {
    flex-direction: column;
  }

  .sidebar {
    width: 100%;
  }

  .about-grid,
  .contact-grid {
    grid-template-columns: 1fr;
  }

  .hero-image {
    height: 280px;
  }

  .logo-wrap .logo-p4 {
    font-size: 2.6rem;
  }
}

@media (max-width: 700px) {
  .nav-toggle {
    display: block;
  }

  #navbar ul {
    display: none;
    flex-direction: column;
    width: 100%;
    background: #fff;
    border-top: 1px solid #eee;
  }

  #navbar ul.open {
    display: flex;
  }

  #navbar ul li a {
    padding: 12px 20px;
    border-bottom: 1px solid #f0f0f0;
  }

  .nav-contact-info {
    display: none;
  }

  .nav-inner {
    flex-wrap: wrap;
  }

  .value-section {
    flex-direction: column;
    gap: 10px;
  }

  .value-dropcap {
    width: auto;
    font-size: 3.5rem;
  }

  .hero-image {
    height: 200px;
  }

  .logo-wrap {
    left: 16px;
    top: 14px;
  }

  .logo-wrap .logo-p4 {
    font-size: 2rem;
  }

  .logo-wrap .logo-subtitle {
    font-size: 0.65rem;
  }
}

/* =============================================
   UTILITY
   ============================================= */

.text-red { color: #c0392b; }
.text-center { text-align: center; }
.mt-20 { margin-top: 20px; }
.mb-20 { margin-bottom: 20px; }
.hidden { display: none; }
