/* ===========================================================
   Pine Creek Acres — Rustic Cabin theme
   =========================================================== */

:root {
  --color-bg: #f6f1e7;
  --color-bg-alt: #efe6d3;
  --color-text: #3a2e22;
  --color-text-muted: #6b5c4b;
  --color-forest: #33473b;
  --color-forest-dark: #24332a;
  --color-wood: #7a4a2b;
  --color-wood-dark: #5c371f;
  --color-gold: #c98f37;
  --color-cream: #fffaf0;
  --color-border: #ded0b4;
  --shadow-soft: 0 8px 24px rgba(58, 46, 34, 0.12);
  --radius: 10px;
  --font-heading: 'Playfair Display', Georgia, serif;
  --font-body: 'Lora', Georgia, serif;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
}

body {
  font-family: var(--font-body);
  color: var(--color-text);
  background: var(--color-bg);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4 {
  font-family: var(--font-heading);
  color: var(--color-forest-dark);
  line-height: 1.2;
  margin: 0 0 0.5em;
}

a {
  color: var(--color-wood-dark);
  text-decoration: none;
}
a:hover { text-decoration: underline; }

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

.container {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ---------- Header ---------- */
.site-header {
  background: var(--color-forest);
  border-bottom: 4px solid var(--color-wood);
  position: sticky;
  top: 0;
  z-index: 50;
}

.site-header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 14px;
  padding-bottom: 14px;
  flex-wrap: wrap;
  gap: 12px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 16px;
  color: var(--color-cream) !important;
  text-decoration: none !important;
}

.brand-mark-img {
  height: 50px;
  width: auto;
  display: block;
  flex-shrink: 0;
}

.brand-mark { font-size: 1.8rem; }

.brand-text { display: flex; flex-direction: column; }

.brand-name {
  font-family: var(--font-heading);
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--color-cream);
}

.brand-tagline {
  font-size: 0.78rem;
  color: #d9cba8;
  letter-spacing: 0.02em;
  max-width: 220px;
}

.site-nav {
  display: flex;
  gap: 22px;
}

.site-nav a {
  color: #ecdfc2 !important;
  font-weight: 500;
  font-size: 0.98rem;
  padding: 6px 2px;
  border-bottom: 2px solid transparent;
}

.site-nav a:hover,
.site-nav a.active {
  color: #fff !important;
  border-bottom-color: var(--color-gold);
  text-decoration: none;
}

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 6px;
}
.nav-toggle span {
  width: 24px;
  height: 2px;
  background: var(--color-cream);
  display: block;
}

/* ---------- Hero ---------- */
.hero {
  background: linear-gradient(180deg, rgba(36,51,42,0.55), rgba(36,51,42,0.75)),
    linear-gradient(135deg, #4a5d43, #2c3d2c);
  color: var(--color-cream);
  padding: 90px 0 70px;
  text-align: center;
}

.hero h1 {
  color: #fff;
  font-size: 2.6rem;
  margin-bottom: 0.35em;
}

.hero p {
  font-size: 1.15rem;
  color: #eee3c8;
  max-width: 620px;
  margin: 0 auto;
}

.hero .btn { margin-top: 28px; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-block;
  padding: 11px 26px;
  border-radius: 6px;
  background: var(--color-gold);
  color: #2b1e0f !important;
  font-weight: 600;
  border: none;
  cursor: pointer;
  font-family: var(--font-body);
  font-size: 0.98rem;
  text-decoration: none !important;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}
.btn:hover { transform: translateY(-1px); box-shadow: var(--shadow-soft); }

.btn-secondary {
  background: transparent;
  border: 1.5px solid var(--color-cream);
  color: var(--color-cream) !important;
}

.btn-outline {
  background: transparent;
  border: 1.5px solid var(--color-wood);
  color: var(--color-wood-dark) !important;
}

.btn-danger {
  background: #a4432f;
  color: #fff !important;
}

.btn-small { padding: 6px 14px; font-size: 0.85rem; border-radius: 5px; }

/* ---------- Sections ---------- */
section { padding: 56px 0; }

.section-title {
  text-align: center;
  margin-bottom: 40px;
}
.section-title h2 { font-size: 2rem; }
.section-title p { color: var(--color-text-muted); }

.section-alt { background: var(--color-bg-alt); }

/* ---------- Cards / post grid ---------- */
.post-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 30px;
}

.card {
  background: var(--color-cream);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-soft);
  border: 1px solid var(--color-border);
  display: flex;
  flex-direction: column;
}

.card-img {
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: var(--color-bg-alt);
}
.card-img img { width: 100%; height: 100%; object-fit: cover; }

.card-body { padding: 20px 22px 24px; flex: 1; display: flex; flex-direction: column; }

.card-date {
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--color-gold);
  font-weight: 600;
  margin-bottom: 8px;
}

.card h3 { font-size: 1.3rem; margin-bottom: 10px; }
.card h3 a { color: var(--color-forest-dark); }

.card p.excerpt { color: var(--color-text-muted); flex: 1; margin-bottom: 16px; }

.read-more { font-weight: 600; color: var(--color-wood-dark); }

.empty-state {
  text-align: center;
  padding: 60px 20px;
  color: var(--color-text-muted);
}

/* ---------- Single post ---------- */
.post-header { text-align: center; padding: 60px 0 30px; }
.post-header h1 { font-size: 2.4rem; max-width: 800px; margin: 0 auto 12px; }
.post-meta { color: var(--color-text-muted); font-size: 0.9rem; }

.post-featured-img {
  max-width: 1000px;
  margin: 0 auto 40px;
  padding: 0 24px;
}
.post-featured-img img { border-radius: var(--radius); box-shadow: var(--shadow-soft); }

.post-content {
  max-width: 720px;
  margin: 0 auto;
  padding: 0 24px 60px;
  font-size: 1.08rem;
}
.post-content p { margin: 0 0 1.2em; }
.post-content img { border-radius: 8px; margin: 1.5em 0; }
.post-content h2, .post-content h3 { margin-top: 1.4em; }
.post-content blockquote {
  border-left: 4px solid var(--color-gold);
  margin: 1.5em 0;
  padding: 0.3em 0 0.3em 1.2em;
  color: var(--color-text-muted);
  font-style: italic;
}

.post-nav-back { text-align: center; padding-bottom: 40px; }

/* ---------- Gallery ---------- */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(230px, 1fr));
  gap: 14px;
}
.gallery-item {
  border-radius: 8px;
  overflow: hidden;
  box-shadow: var(--shadow-soft);
  cursor: pointer;
  aspect-ratio: 1 / 1;
  position: relative;
  background: var(--color-bg-alt);
}
.gallery-item img {
  width: 100%; height: 100%; object-fit: cover;
  transition: transform 0.25s ease;
}
.gallery-item:hover img { transform: scale(1.06); }
.gallery-item .caption {
  position: absolute; left: 0; right: 0; bottom: 0;
  background: linear-gradient(0deg, rgba(0,0,0,0.65), transparent);
  color: #fff;
  font-size: 0.8rem;
  padding: 18px 10px 8px;
  opacity: 0;
  transition: opacity 0.2s ease;
}
.gallery-item:hover .caption { opacity: 1; }

.lightbox {
  position: fixed; inset: 0;
  background: rgba(20, 15, 8, 0.92);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 200;
  padding: 30px;
}
.lightbox.open { display: flex; }
.lightbox img { max-width: 90vw; max-height: 80vh; border-radius: 6px; }
.lightbox-caption { color: #f0e6cf; text-align: center; margin-top: 14px; }
.lightbox-close, .lightbox-prev, .lightbox-next {
  position: absolute;
  background: rgba(255,255,255,0.12);
  border: none;
  color: #fff;
  font-size: 1.4rem;
  cursor: pointer;
  border-radius: 50%;
  width: 44px; height: 44px;
}
.lightbox-close { top: 20px; right: 20px; }
.lightbox-prev { left: 20px; top: 50%; transform: translateY(-50%); }
.lightbox-next { right: 20px; top: 50%; transform: translateY(-50%); }
.lightbox-close:hover, .lightbox-prev:hover, .lightbox-next:hover { background: rgba(255,255,255,0.25); }

/* ---------- About / intro block ---------- */
.about-section { padding: 26px 0; }

.about-block {
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  gap: 44px;
  align-items: start;
}
.about-block img { border-radius: var(--radius); box-shadow: var(--shadow-soft); }
.about-block h2 { font-size: 2rem; }
.about-block p:last-child { margin-bottom: 0; }

@media (max-width: 760px) {
  .about-block { grid-template-columns: 1fr; gap: 10px; }
  .about-block p:first-child { margin-bottom: 0.5em; }
}

/* ---------- Footer ---------- */
.site-footer {
  background: var(--color-forest-dark);
  color: #cbbf9e;
  padding: 26px 0;
  font-size: 0.85rem;
}
.site-footer-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
}
.footer-admin-link { color: #8fa088 !important; }

/* ---------- Forms (shared with admin) ---------- */
.form-group { margin-bottom: 20px; }
.form-group label {
  display: block;
  font-weight: 600;
  margin-bottom: 6px;
  color: var(--color-forest-dark);
}
.form-control {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid var(--color-border);
  border-radius: 6px;
  font-family: var(--font-body);
  font-size: 1rem;
  background: #fff;
}
textarea.form-control { min-height: 140px; resize: vertical; }
.form-hint { font-size: 0.82rem; color: var(--color-text-muted); margin-top: 4px; }

.alert {
  padding: 12px 16px;
  border-radius: 6px;
  margin-bottom: 20px;
  font-size: 0.95rem;
}
.alert-success { background: #e2eeda; color: #33502a; border: 1px solid #bcd8ac; }
.alert-error { background: #f6dcd6; color: #7a2c1a; border: 1px solid #edb5a8; }

/* ---------- Responsive ---------- */
@media (max-width: 720px) {
  .site-header-inner { flex-wrap: wrap; }
  .brand { flex: 1 1 auto; min-width: 0; }
  .brand-mark-img { height: 38px; }
  .brand-text { min-width: 0; }
  .brand-name {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    display: block;
  }
  .brand-tagline {
    display: block;
    font-size: 0.85rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 100%;
  }
  .nav-toggle {
    display: flex;
    flex-shrink: 0;
    margin-left: auto;
  }
  .site-nav {
    display: none;
    width: 100%;
    flex-direction: column;
    gap: 4px;
    padding-top: 10px;
  }
  .site-nav.open { display: flex; }
  .hero { padding: 60px 0 50px; }
  .hero h1 { font-size: 1.9rem; }
}
