@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:wght@400;700&family=Lora:wght@400;500&display=swap');

:root {
  --green-deep:  #3B6D11;
  --green-mid:   #639922;
  --green-light: #EAF3DE;
  --amber:       #EF9F27;
  --amber-deep:  #854F0B;
  --cream:       #F7F4EE;
  --brown:       #3D2B0E;
  --muted:       #7A7060;
  --white:       #FFFFFF;
  --danger:      #E24B4A;
  --success:     #3B6D11;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body { font-family: 'Lora', Georgia, serif; background: var(--cream); color: var(--brown); line-height: 1.7; }

/* ── NAV ── */
.nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  padding: 1rem 2rem;
  display: flex; align-items: center; justify-content: space-between;
  background: rgba(247,244,238,0.95);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid rgba(59,109,17,0.1);
}
.nav-logo { display: flex; align-items: center; gap: 10px; text-decoration: none; }
.nav-logo-text { font-family: 'Playfair Display', serif; font-size: 18px; color: var(--green-deep); font-weight: 700; }
.nav-links { display: flex; align-items: center; gap: 1.5rem; }
.nav-links a { color: var(--muted); text-decoration: none; font-size: 14px; transition: color 0.2s; }
.nav-links a:hover { color: var(--green-deep); }
.nav-btn {
  background: var(--green-deep); color: var(--white);
  padding: 8px 18px; border-radius: 100px;
  font-size: 14px; text-decoration: none;
  transition: background 0.2s;
}
.nav-btn:hover { background: var(--green-mid); }
.nav-btn.amber { background: var(--amber); }
.nav-btn.amber:hover { background: var(--amber-deep); }

/* ── PAGE WRAPPER ── */
.page { min-height: 100vh; padding-top: 70px; }
.container { max-width: 1100px; margin: 0 auto; padding: 0 2rem; }
.container-sm { max-width: 520px; margin: 0 auto; padding: 0 2rem; }

/* ── AUTH PAGES ── */
.auth-page { min-height: 100vh; display: flex; align-items: center; justify-content: center; padding: 5rem 2rem 2rem; }
.auth-card { background: var(--white); border: 1px solid rgba(59,109,17,0.12); border-radius: 20px; padding: 2.5rem; width: 100%; max-width: 460px; }
.auth-logo { text-align: center; margin-bottom: 1.5rem; }
.auth-title { font-family: 'Playfair Display', serif; font-size: 1.8rem; color: var(--green-deep); text-align: center; margin-bottom: 0.5rem; }
.auth-sub { font-size: 0.9rem; color: var(--muted); text-align: center; margin-bottom: 2rem; }

/* ── FORMS ── */
.form-group { margin-bottom: 1.1rem; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
label { display: block; font-size: 13px; font-weight: 500; color: var(--brown); margin-bottom: 5px; }
input, select, textarea {
  width: 100%; padding: 11px 14px;
  border: 1px solid #D3D1C7; border-radius: 10px;
  font-family: 'Lora', serif; font-size: 14px;
  color: var(--brown); background: var(--white);
  transition: border-color 0.2s, box-shadow 0.2s;
  outline: none;
}
input:focus, select:focus, textarea:focus {
  border-color: var(--green-mid);
  box-shadow: 0 0 0 3px rgba(99,153,34,0.12);
}
textarea { resize: vertical; min-height: 100px; }

/* ── BUTTONS ── */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 12px 24px; border-radius: 100px;
  font-family: 'Lora', serif; font-size: 15px; font-weight: 500;
  border: none; cursor: pointer; transition: all 0.2s;
  text-decoration: none;
}
.btn-primary { background: var(--green-deep); color: var(--white); }
.btn-primary:hover { background: var(--green-mid); }
.btn-amber { background: var(--amber); color: var(--white); }
.btn-amber:hover { background: var(--amber-deep); }
.btn-outline { background: transparent; color: var(--green-deep); border: 1.5px solid var(--green-deep); }
.btn-outline:hover { background: var(--green-light); }
.btn-full { width: 100%; }
.btn-sm { padding: 8px 16px; font-size: 13px; }

/* ── ALERTS ── */
.alert { padding: 12px 16px; border-radius: 10px; font-size: 14px; margin-bottom: 1rem; }
.alert-error { background: #FCEBEB; color: #A32D2D; border: 1px solid #F09595; }
.alert-success { background: var(--green-light); color: var(--green-deep); border: 1px solid #97C459; }

/* ── CARDS ── */
.card { background: var(--white); border: 1px solid rgba(59,109,17,0.1); border-radius: 16px; padding: 1.5rem; transition: transform 0.2s, box-shadow 0.2s; }
.card:hover { transform: translateY(-2px); box-shadow: 0 8px 32px rgba(59,109,17,0.08); }

/* ── LISTING GRID ── */
.listings-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 1.5rem; padding: 2rem 0; }
.listing-card { background: var(--white); border: 1px solid rgba(59,109,17,0.1); border-radius: 16px; overflow: hidden; transition: transform 0.2s, box-shadow 0.2s; text-decoration: none; color: inherit; }
.listing-card:hover { transform: translateY(-3px); box-shadow: 0 8px 32px rgba(59,109,17,0.1); }
.listing-img { width: 100%; height: 200px; object-fit: cover; background: var(--green-light); display: flex; align-items: center; justify-content: center; font-size: 3rem; }
.listing-body { padding: 1.25rem; }
.listing-category { font-size: 11px; text-transform: uppercase; letter-spacing: 0.08em; color: var(--green-mid); font-weight: 500; margin-bottom: 6px; }
.listing-title { font-family: 'Playfair Display', serif; font-size: 1.1rem; color: var(--green-deep); margin-bottom: 6px; }
.listing-price { font-size: 1.1rem; font-weight: 500; color: var(--amber-deep); margin-bottom: 6px; }
.listing-location { font-size: 12px; color: var(--muted); }

/* ── FILTERS ── */
.filters { display: flex; gap: 12px; flex-wrap: wrap; padding: 1.5rem 0; }
.filter-select { padding: 8px 14px; border: 1px solid #D3D1C7; border-radius: 100px; font-family: 'Lora', serif; font-size: 13px; color: var(--brown); background: var(--white); cursor: pointer; outline: none; }
.filter-select:focus { border-color: var(--green-mid); }

/* ── PAGE HEADER ── */
.page-header { padding: 3rem 0 1rem; }
.page-header h1 { font-family: 'Playfair Display', serif; font-size: 2.2rem; color: var(--green-deep); margin-bottom: 0.5rem; }
.page-header p { color: var(--muted); font-size: 1rem; }

/* ── BADGE ── */
.badge { display: inline-block; padding: 3px 10px; border-radius: 100px; font-size: 11px; font-weight: 500; }
.badge-green { background: var(--green-light); color: var(--green-deep); }
.badge-amber { background: #FAEEDA; color: var(--amber-deep); }

/* ── DIVIDER ── */
.divider { text-align: center; color: var(--muted); font-size: 13px; margin: 1rem 0; position: relative; }
.divider::before { content: ''; position: absolute; top: 50%; left: 0; right: 0; height: 1px; background: #D3D1C7; }
.divider span { background: var(--white); padding: 0 12px; position: relative; }

/* ── LOADING ── */
.loading { text-align: center; padding: 3rem; color: var(--muted); }
.spinner { width: 32px; height: 32px; border: 3px solid var(--green-light); border-top-color: var(--green-deep); border-radius: 50%; animation: spin 0.8s linear infinite; margin: 0 auto 1rem; }
@keyframes spin { to { transform: rotate(360deg); } }

/* ── EMPTY STATE ── */
.empty-state { text-align: center; padding: 4rem 2rem; }
.empty-state-icon { font-size: 3rem; margin-bottom: 1rem; }
.empty-state h3 { font-family: 'Playfair Display', serif; font-size: 1.4rem; color: var(--green-deep); margin-bottom: 0.5rem; }
.empty-state p { color: var(--muted); margin-bottom: 1.5rem; }

/* ── FOOTER ── */
.footer { background: #1C1A14; padding: 2rem; text-align: center; margin-top: 4rem; }
.footer p { color: rgba(255,255,255,0.3); font-size: 12px; }

/* ── RESPONSIVE ── */
@media (max-width: 640px) {
  .form-row { grid-template-columns: 1fr; }
  .nav-links { display: none; }
  .page-header h1 { font-size: 1.6rem; }
}
