/* =========================================================
   Efficient Home Guide - Main Stylesheet
   Version: 1.0
   ========================================================= */

/* CSS Reset */
*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body,
h1,
h2,
h3,
h4,
p,
ul,
ol,
figure {
  margin: 0;
}

body {
  font-family: Arial, Helvetica, sans-serif;
  background: #f8faf7;
  color: #24302a;
  line-height: 1.6;
  font-size: 16px;
}

img,
picture {
  max-width: 100%;
  display: block;
}

a {
  color: #1f6f4a;
  text-decoration: none;
}

a:hover,
a:focus {
  color: #145536;
  text-decoration: underline;
}

ul,
ol {
  padding-left: 1.25rem;
}

/* Accessibility */
.skip-link {
  position: absolute;
  top: -48px;
  left: 16px;
  background: #123524;
  color: #ffffff !important;
  padding: 0.75rem 1rem;
  z-index: 1000;
  border-radius: 0 0 6px 6px;
  font-weight: 700;
}

.skip-link:focus {
  top: 0;
}

/* Layout */
.container {
  width: min(1120px, calc(100% - 32px));
  margin: 0 auto;
}

.content-narrow {
  max-width: 760px;
}

.section {
  padding: 4rem 0;
}

.section-muted {
  background: #eef6f1;
}

.section-cta {
  background: #123524;
  color: #ffffff;
  text-align: center;
}

.section-cta h2,
.section-cta p {
  color: #ffffff;
}

.section-header {
  max-width: 760px;
  margin-bottom: 2rem;
}

.section-header h2 {
  font-size: clamp(1.7rem, 3vw, 2.3rem);
  color: #123524;
  margin-bottom: 0.75rem;
}

.section-header p {
  color: #4a5b51;
}

/* Header */
.site-header {
  background: #ffffff;
  border-bottom: 1px solid #dfe9e3;
  position: sticky;
  top: 0;
  z-index: 500;
}

.header-container {
  min-height: 72px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
}

.site-logo {
  font-weight: 700;
  font-size: 1.15rem;
  color: #123524;
}

.site-logo:hover,
.site-logo:focus {
  color: #123524;
  text-decoration: none;
}

.main-nav ul {
  list-style: none;
  display: flex;
  align-items: center;
  gap: 1.25rem;
  padding: 0;
}

.main-nav a {
  color: #24302a;
  font-weight: 600;
  font-size: 0.95rem;
}

.main-nav a:hover,
.main-nav a:focus {
  color: #1f6f4a;
}

/* Hero */
.hero {
  background:
    linear-gradient(120deg, rgba(18, 53, 36, 0.94), rgba(31, 111, 74, 0.88)),
    #123524;
  color: #ffffff;
  padding: 5rem 0;
}

.hero-container {
  max-width: 920px;
}

.eyebrow {
  color: #f3c969;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  font-size: 0.85rem;
  margin-bottom: 1rem;
}

.hero h1 {
  font-size: clamp(2.2rem, 6vw, 4.5rem);
  line-height: 1.05;
  max-width: 900px;
  margin-bottom: 1.25rem;
}

.hero-description {
  font-size: 1.15rem;
  max-width: 720px;
  color: #edf7f1;
  margin-bottom: 2rem;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
}

/* Buttons */
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0.75rem 1.1rem;
  border-radius: 999px;
  font-weight: 700;
  border: 2px solid transparent;
  transition: transform 0.15s ease, background 0.15s ease, color 0.15s ease;
}

.button:hover,
.button:focus {
  transform: translateY(-1px);
  text-decoration: none;
}

.button-primary {
  background: #f3c969;
  color: #123524;
}

.button-primary:hover,
.button-primary:focus {
  background: #ffd978;
  color: #123524;
}

.button-secondary {
  background: transparent;
  color: #ffffff;
  border-color: #ffffff;
}

.button-secondary:hover,
.button-secondary:focus {
  background: #ffffff;
  color: #123524;
}

/* Cards */
.category-grid,
.article-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1.25rem;
}

.category-card,
.article-card {
  background: #ffffff;
  border: 1px solid #dfe9e3;
  border-radius: 18px;
  padding: 1.5rem;
  box-shadow: 0 10px 26px rgba(18, 53, 36, 0.06);
}

.category-card h3,
.article-card h3 {
  font-size: 1.2rem;
  line-height: 1.3;
  margin-bottom: 0.75rem;
}

.category-card h3 a,
.article-card h3 a {
  color: #123524;
}

.category-card p,
.article-card p {
  color: #4a5b51;
}

.article-category {
  display: inline-block;
  color: #1f6f4a;
  font-size: 0.82rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin-bottom: 0.75rem;
}

.read-more {
  display: inline-block;
  margin-top: 1rem;
  font-weight: 700;
}

/* Trust Section */
.content-narrow h2 {
  color: #123524;
  font-size: clamp(1.6rem, 3vw, 2.2rem);
  margin-bottom: 1rem;
}

.content-narrow p + p {
  margin-top: 1rem;
}

/* Footer */
.site-footer {
  background: #0f2a1d;
  color: #dce8e1;
  padding: 3rem 0 1.5rem;
}

.footer-container {
  display: flex;
  justify-content: space-between;
  gap: 2rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.16);
  padding-bottom: 2rem;
}

.footer-brand {
  max-width: 420px;
}

.footer-logo {
  color: #ffffff;
  font-weight: 700;
  font-size: 1.15rem;
  margin-bottom: 0.5rem;
}

.footer-nav ul {
  list-style: none;
  padding: 0;
  display: grid;
  gap: 0.5rem;
}

.footer-nav a {
  color: #dce8e1;
}

.footer-nav a:hover,
.footer-nav a:focus {
  color: #f3c969;
}

.footer-bottom {
  padding-top: 1.5rem;
  font-size: 0.9rem;
  color: #b9c9c0;
}

/* Focus Styles */
:focus-visible {
  outline: 3px solid #f3c969;
  outline-offset: 3px;
}

/* Responsive */
@media (max-width: 900px) {
  .category-grid,
  .article-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .header-container {
    align-items: flex-start;
    flex-direction: column;
    padding: 1rem 0;
  }

  .main-nav ul {
    flex-wrap: wrap;
    gap: 0.75rem 1rem;
  }
}

@media (max-width: 640px) {
  .section {
    padding: 3rem 0;
  }

  .hero {
    padding: 4rem 0;
  }

  .category-grid,
  .article-grid {
    grid-template-columns: 1fr;
  }

  .footer-container {
    flex-direction: column;
  }

  .button {
    width: 100%;
  }
}