
  *, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

  :root {
    --brand: #1a3a2a;
    --brand-mid: #2d6247;
    --brand-light: #4a9068;
    --brand-pale: #e8f4ed;
    --accent: #c8860a;
    --accent-light: #f7e9cc;
    --text: #1a1a1a;
    --text-mid: #444;
    --text-muted: #777;
    --border: #e0e0e0;
    --bg: #fafaf8;
    --white: #ffffff;
    --card-shadow: 0 2px 16px rgba(0,0,0,0.07);
    --nav-h: 70px;
  }

  body {
    font-family: 'DM Sans', sans-serif;
    background: var(--bg);
    color: var(--text);
    line-height: 1.6;
  }

  /* ── NAV ── */
  nav {
    position: fixed;
    top: 0; left: 0; right: 0;
    height: var(--nav-h);
    background: var(--white);
    border-bottom: 1px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 40px;
    z-index: 1000;
  }

  .logo {
    font-family: 'Playfair Display', serif;
    font-size: 26px;
    font-weight: 700;
    color: var(--brand);
    letter-spacing: -0.5px;
    cursor: pointer;
  }
  .logo span { color: var(--accent); }

  .nav-links {
    display: flex;
    gap: 4px;
    list-style: none;
  }

  .nav-links a {
    text-decoration: none;
    color: var(--text-mid);
    font-size: 14px;
    font-weight: 500;
    padding: 8px 14px;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s;
    white-space: nowrap;
  }

  .nav-links a:hover,
  .nav-links a.active {
    background: var(--brand-pale);
    color: var(--brand-mid);
  }

  .nav-cta {
    background: var(--brand) !important;
    color: var(--white) !important;
    border-radius: 8px;
    padding: 9px 18px !important;
  }
  .nav-cta:hover { background: var(--brand-mid) !important; }

  /* ── PAGES ── */
  .page {
    display: none;
    min-height: 100vh;
    padding-top: var(--nav-h);
  }
  .page.active { display: block; }

  /* ── SECTION UTILS ── */
  .container { max-width: 1100px; margin: 0 auto; padding: 0 24px; }
  .section { padding: 72px 0; }
  .section-sm { padding: 48px 0; }
  .tag {
    display: inline-block;
    background: var(--brand-pale);
    color: var(--brand-mid);
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 1px;
    text-transform: uppercase;
    padding: 5px 12px;
    border-radius: 20px;
    margin-bottom: 14px;
  }
  h1 { font-family: 'Playfair Display', serif; font-size: clamp(36px, 5vw, 58px); font-weight: 700; line-height: 1.15; color: var(--brand); }
  h2 { font-family: 'Playfair Display', serif; font-size: clamp(26px, 3vw, 38px); font-weight: 600; color: var(--brand); line-height: 1.25; }
  h3 { font-size: 18px; font-weight: 600; color: var(--text); }
  p { color: var(--text-mid); line-height: 1.7; }

  .btn {
    display: inline-block;
    padding: 13px 28px;
    border-radius: 10px;
    font-family: 'DM Sans', sans-serif;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    border: none;
    transition: all 0.2s;
    text-decoration: none;
  }
  .btn-primary { background: var(--brand); color: var(--white); }
  .btn-primary:hover { background: var(--brand-mid); }
  .btn-outline { background: transparent; color: var(--brand); border: 2px solid var(--brand); }
  .btn-outline:hover { background: var(--brand-pale); }
  .btn-accent { background: var(--accent); color: var(--white); }
  .btn-accent:hover { background: #b0740a; }

  /* ══════════════════════════════════
     PAGE 1 — HOME
  ══════════════════════════════════ */
  .hero {
    background: linear-gradient(135deg, var(--brand) 0%, var(--brand-mid) 60%, var(--brand-light) 100%);
    padding: 100px 0 80px;
    position: relative;
    overflow: hidden;
  }
  .hero::before {
    content: '';
    position: absolute;
    right: -100px; top: -100px;
    width: 500px; height: 500px;
    border-radius: 50%;
    background: rgba(255,255,255,0.04);
  }
  .hero::after {
    content: '';
    position: absolute;
    right: 100px; bottom: -150px;
    width: 300px; height: 300px;
    border-radius: 50%;
    background: rgba(255,255,255,0.03);
  }
  .hero-inner {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 24px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
  }
  .hero h1 { color: var(--white); margin-bottom: 20px; }
  .hero p { color: rgba(255,255,255,0.8); font-size: 18px; margin-bottom: 36px; }
  .hero-btns { display: flex; gap: 14px; flex-wrap: wrap; }
  .btn-white { background: var(--white); color: var(--brand); }
  .btn-white:hover { background: #f0f0ee; }
  .btn-ghost { background: transparent; color: var(--white); border: 2px solid rgba(255,255,255,0.5); }
  .btn-ghost:hover { background: rgba(255,255,255,0.1); }

  .hero-visual {
    display: flex;
    justify-content: center;
    align-items: center;
  }
  .hero-badge-stack {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 14px;
    max-width: 340px;
  }
  .hero-badge {
    background: rgba(255,255,255,0.12);
    border: 1px solid rgba(255,255,255,0.2);
    border-radius: 14px;
    padding: 20px;
    text-align: center;
    backdrop-filter: blur(4px);
  }
  .hero-badge .num { font-size: 32px; font-weight: 700; color: var(--white); font-family: 'Playfair Display', serif; }
  .hero-badge .lbl { font-size: 12px; color: rgba(255,255,255,0.7); margin-top: 4px; }
  .hero-badge.accent { background: rgba(200,134,10,0.3); border-color: rgba(200,134,10,0.5); }

  .features-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
    margin-top: 48px;
  }
  .feature-card {
    background: var(--white);
    border-radius: 16px;
    padding: 32px 28px;
    border: 1px solid var(--border);
    transition: all 0.25s;
    cursor: pointer;
  }
  .feature-card:hover { transform: translateY(-4px); box-shadow: var(--card-shadow); }
  .feature-icon {
    width: 52px; height: 52px;
    border-radius: 14px;
    background: var(--brand-pale);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    margin-bottom: 18px;
  }
  .feature-card h3 { margin-bottom: 10px; font-size: 17px; }
  .feature-card p { font-size: 14px; }

  .featured-listings {
    background: var(--white);
    padding: 72px 0;
  }
  .listings-row {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
    margin-top: 36px;
  }

  .horse-card {
    border-radius: 16px;
    border: 1px solid var(--border);
    overflow: hidden;
    background: var(--white);
    transition: all 0.25s;
    cursor: pointer;
  }
  .horse-card:hover { transform: translateY(-3px); box-shadow: var(--card-shadow); }
  .horse-card-img {
    width: 100%;
    height: 180px;
    object-fit: cover;
    background: var(--brand-pale);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 48px;
  }
  .horse-card-body { padding: 18px 20px; }
  .horse-card-body h3 { font-size: 16px; margin-bottom: 4px; }
  .horse-card-body .breed { font-size: 13px; color: var(--text-muted); margin-bottom: 10px; }
  .horse-card-meta { display: flex; justify-content: space-between; align-items: center; }
  .horse-card-meta .price { font-size: 18px; font-weight: 700; color: var(--brand-mid); }
  .horse-card-meta .age { font-size: 12px; color: var(--text-muted); background: var(--bg); padding: 4px 10px; border-radius: 20px; }

  .stats-strip {
    background: var(--brand);
    padding: 40px 0;
  }
  .stats-row {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    text-align: center;
  }
  .stat-item .num { font-size: 36px; font-weight: 700; color: var(--white); font-family: 'Playfair Display', serif; }
  .stat-item .lbl { font-size: 13px; color: rgba(255,255,255,0.65); margin-top: 4px; }
  .stat-item + .stat-item { border-left: 1px solid rgba(255,255,255,0.12); }

  /* ══════════════════════════════════
     PAGE 2 — HORSE LISTINGS
  ══════════════════════════════════ */
  .page-header {
    background: var(--white);
    padding: 48px 0 36px;
    border-bottom: 1px solid var(--border);
  }
  .page-header p { font-size: 16px; margin-top: 8px; }

  .filters-bar {
    background: var(--white);
    padding: 20px 0;
    border-bottom: 1px solid var(--border);
    position: sticky;
    top: var(--nav-h);
    z-index: 100;
  }
  .filters-inner {
    display: flex;
    gap: 12px;
    align-items: center;
    flex-wrap: wrap;
  }
  .filter-select {
    padding: 9px 16px;
    border: 1px solid var(--border);
    border-radius: 8px;
    font-family: 'DM Sans', sans-serif;
    font-size: 14px;
    color: var(--text);
    background: var(--white);
    cursor: pointer;
    outline: none;
  }
  .filter-select:focus { border-color: var(--brand-light); }
  .search-input {
    flex: 1;
    min-width: 200px;
    padding: 9px 16px;
    border: 1px solid var(--border);
    border-radius: 8px;
    font-family: 'DM Sans', sans-serif;
    font-size: 14px;
    outline: none;
  }
  .search-input:focus { border-color: var(--brand-light); }

  .listings-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
    padding: 40px 0;
  }

  .listing-card {
    border-radius: 16px;
    border: 1px solid var(--border);
    overflow: hidden;
    background: var(--white);
    transition: all 0.25s;
  }
  .listing-card:hover { box-shadow: var(--card-shadow); transform: translateY(-3px); }
  .listing-img {
    height: 200px;
    background: var(--brand-pale);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 56px;
    position: relative;
  }
  .listing-badge {
    position: absolute;
    top: 12px; left: 12px;
    background: var(--accent);
    color: var(--white);
    font-size: 11px;
    font-weight: 700;
    padding: 4px 10px;
    border-radius: 20px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
  }
  .listing-body { padding: 20px 22px; }
  .listing-body h3 { font-size: 17px; margin-bottom: 4px; }
  .listing-body .breed { font-size: 13px; color: var(--text-muted); }
  .listing-details {
    display: flex;
    gap: 16px;
    margin: 14px 0;
    flex-wrap: wrap;
  }
  .listing-detail {
    font-size: 12px;
    color: var(--text-muted);
    display: flex;
    align-items: center;
    gap: 5px;
  }
  .listing-detail span { color: var(--text); font-weight: 500; }
  .listing-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 14px;
    border-top: 1px solid var(--border);
    margin-top: 14px;
  }
  .listing-price { font-size: 20px; font-weight: 700; color: var(--brand-mid); }
  .btn-sm { padding: 8px 16px; font-size: 13px; border-radius: 8px; }

  /* ══════════════════════════════════
     PAGE 3 — SHOP
  ══════════════════════════════════ */
  .shop-categories {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    margin: 32px 0;
  }
  .cat-btn {
    padding: 9px 20px;
    border-radius: 24px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    border: 1px solid var(--border);
    background: var(--white);
    color: var(--text-mid);
    transition: all 0.2s;
    font-family: 'DM Sans', sans-serif;
  }
  .cat-btn.active, .cat-btn:hover {
    background: var(--brand);
    color: var(--white);
    border-color: var(--brand);
  }

  .shop-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 22px;
    padding-bottom: 60px;
  }
  .shop-card {
    border-radius: 14px;
    border: 1px solid var(--border);
    background: var(--white);
    overflow: hidden;
    transition: all 0.25s;
    cursor: pointer;
  }
  .shop-card:hover { box-shadow: var(--card-shadow); transform: translateY(-3px); }
  .shop-img {
    height: 160px;
    background: var(--brand-pale);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 44px;
  }
  .shop-body { padding: 14px 16px; }
  .shop-body h3 { font-size: 14px; font-weight: 600; margin-bottom: 6px; }
  .shop-body .shop-cat { font-size: 11px; color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.5px; margin-bottom: 10px; }
  .shop-footer { display: flex; justify-content: space-between; align-items: center; }
  .shop-price { font-size: 16px; font-weight: 700; color: var(--brand-mid); }
  .btn-cart { background: var(--brand-pale); color: var(--brand); border: none; padding: 7px 14px; border-radius: 8px; font-size: 13px; font-weight: 600; cursor: pointer; transition: all 0.2s; font-family: 'DM Sans', sans-serif; }
  .btn-cart:hover { background: var(--brand); color: var(--white); }

  /* ══════════════════════════════════
     PAGE 4 — ADD LISTING
  ══════════════════════════════════ */
  .form-page { padding: 60px 0; }
  .form-card {
    background: var(--white);
    border-radius: 20px;
    border: 1px solid var(--border);
    padding: 48px 52px;
    max-width: 760px;
    margin: 0 auto;
  }
  .form-card h2 { margin-bottom: 8px; }
  .form-card > p { margin-bottom: 36px; font-size: 15px; }

  .form-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 22px;
  }
  .form-group { display: flex; flex-direction: column; gap: 7px; }
  .form-group.full { grid-column: 1 / -1; }
  label { font-size: 13px; font-weight: 600; color: var(--text-mid); }
  input[type="text"],
  input[type="number"],
  input[type="email"],
  input[type="tel"],
  select,
  textarea {
    padding: 11px 14px;
    border: 1px solid var(--border);
    border-radius: 10px;
    font-family: 'DM Sans', sans-serif;
    font-size: 14px;
    color: var(--text);
    outline: none;
    transition: border 0.2s;
    background: var(--white);
  }
  input:focus, select:focus, textarea:focus { border-color: var(--brand-light); }
  textarea { resize: vertical; min-height: 110px; }

  .photo-upload {
    grid-column: 1 / -1;
    border: 2px dashed var(--border);
    border-radius: 14px;
    padding: 40px;
    text-align: center;
    color: var(--text-muted);
    cursor: pointer;
    transition: all 0.2s;
  }
  .photo-upload:hover { border-color: var(--brand-light); background: var(--brand-pale); }
  .photo-upload .upload-icon { font-size: 36px; margin-bottom: 12px; }
  .photo-upload p { font-size: 14px; }
  .photo-upload span { color: var(--brand-mid); font-weight: 600; }

  .form-submit { margin-top: 32px; display: flex; gap: 14px; justify-content: flex-end; }

  .plan-cards {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 18px;
    margin: 28px 0;
  }
  .plan-card {
    border: 2px solid var(--border);
    border-radius: 14px;
    padding: 22px 20px;
    cursor: pointer;
    transition: all 0.2s;
  }
  .plan-card.selected, .plan-card:hover {
    border-color: var(--brand-mid);
    background: var(--brand-pale);
  }
  .plan-card h4 { font-size: 15px; font-weight: 600; margin-bottom: 4px; }
  .plan-card .plan-price { font-size: 22px; font-weight: 700; color: var(--brand-mid); }
  .plan-card .plan-desc { font-size: 12px; color: var(--text-muted); margin-top: 6px; }

  /* ══════════════════════════════════
     PAGE 5 — EVENTS
  ══════════════════════════════════ */
  .events-layout {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 36px;
    padding: 48px 0;
  }
  .event-card {
    background: var(--white);
    border-radius: 16px;
    border: 1px solid var(--border);
    padding: 28px 30px;
    margin-bottom: 20px;
    display: grid;
    grid-template-columns: 72px 1fr;
    gap: 22px;
    align-items: start;
    transition: all 0.25s;
    cursor: pointer;
  }
  .event-card:hover { box-shadow: var(--card-shadow); }
  .event-date-box {
    background: var(--brand);
    border-radius: 12px;
    padding: 12px 10px;
    text-align: center;
    color: var(--white);
    min-width: 72px;
  }
  .event-date-box .month { font-size: 11px; font-weight: 600; letter-spacing: 1px; text-transform: uppercase; opacity: 0.8; }
  .event-date-box .day { font-size: 28px; font-weight: 700; font-family: 'Playfair Display', serif; line-height: 1; }
  .event-info h3 { font-size: 17px; margin-bottom: 6px; }
  .event-info .event-meta { display: flex; gap: 16px; margin-bottom: 10px; flex-wrap: wrap; }
  .event-meta-item { font-size: 13px; color: var(--text-muted); }
  .event-meta-item strong { color: var(--text); }
  .event-info p { font-size: 14px; }
  .event-tag {
    display: inline-block;
    font-size: 11px;
    font-weight: 600;
    padding: 3px 10px;
    border-radius: 20px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 10px;
  }
  .et-show { background: #e8f4ed; color: var(--brand-mid); }
  .et-race { background: #fff3e0; color: #c8860a; }
  .et-training { background: #e8eaf6; color: #3949ab; }
  .et-auction { background: #fce4ec; color: #c2185b; }

  .sidebar-widget {
    background: var(--white);
    border-radius: 16px;
    border: 1px solid var(--border);
    padding: 24px;
    margin-bottom: 24px;
  }
  .sidebar-widget h3 { font-size: 15px; margin-bottom: 18px; padding-bottom: 12px; border-bottom: 1px solid var(--border); }
  .mini-event {
    display: flex;
    gap: 12px;
    align-items: center;
    padding: 10px 0;
    border-bottom: 1px solid var(--border);
    cursor: pointer;
  }
  .mini-event:last-child { border: none; }
  .mini-date { width: 44px; height: 44px; background: var(--brand-pale); border-radius: 10px; display: flex; flex-direction: column; align-items: center; justify-content: center; flex-shrink: 0; }
  .mini-date .m { font-size: 10px; color: var(--brand-mid); font-weight: 600; text-transform: uppercase; }
  .mini-date .d { font-size: 16px; font-weight: 700; color: var(--brand); line-height: 1; }
  .mini-event-info .title { font-size: 13px; font-weight: 600; color: var(--text); }
  .mini-event-info .loc { font-size: 12px; color: var(--text-muted); }

  /* ══════════════════════════════════
     PAGE 6 — PHOTOS
  ══════════════════════════════════ */
  .photos-tabs {
    display: flex;
    gap: 8px;
    margin: 32px 0 28px;
    flex-wrap: wrap;
  }
  .photo-tab {
    padding: 9px 20px;
    border-radius: 24px;
    border: 1px solid var(--border);
    background: var(--white);
    color: var(--text-mid);
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
    font-family: 'DM Sans', sans-serif;
  }
  .photo-tab.active, .photo-tab:hover { background: var(--brand); color: var(--white); border-color: var(--brand); }

  .photo-masonry {
    columns: 3;
    gap: 16px;
    padding-bottom: 60px;
  }
  .photo-item {
    border-radius: 12px;
    overflow: hidden;
    margin-bottom: 16px;
    break-inside: avoid;
    position: relative;
    cursor: pointer;
    background: var(--brand-pale);
    border: 1px solid var(--border);
  }
  .photo-item-inner {
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: clamp(36px, 6vw, 64px);
    transition: transform 0.3s;
  }
  .photo-item:hover .photo-item-inner { transform: scale(1.04); }
  .photo-overlay {
    position: absolute;
    bottom: 0; left: 0; right: 0;
    background: linear-gradient(transparent, rgba(0,0,0,0.6));
    padding: 20px 14px 12px;
    opacity: 0;
    transition: opacity 0.2s;
  }
  .photo-item:hover .photo-overlay { opacity: 1; }
  .photo-overlay p { color: var(--white); font-size: 13px; font-weight: 500; }

  /* ══════════════════════════════════
     PAGE 7 — CONTACT
  ══════════════════════════════════ */
  .contact-layout {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    padding: 60px 0;
    align-items: start;
  }
  .contact-info h2 { margin-bottom: 16px; }
  .contact-info p { font-size: 15px; margin-bottom: 36px; }
  .contact-item {
    display: flex;
    gap: 16px;
    margin-bottom: 28px;
    align-items: flex-start;
  }
  .contact-icon {
    width: 48px; height: 48px;
    border-radius: 12px;
    background: var(--brand-pale);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    flex-shrink: 0;
  }
  .contact-item-text h4 { font-size: 14px; font-weight: 600; margin-bottom: 3px; }
  .contact-item-text p { font-size: 14px; }

  .social-row { display: flex; gap: 12px; margin-top: 32px; }
  .social-btn {
    width: 44px; height: 44px;
    border-radius: 10px;
    background: var(--brand-pale);
    color: var(--brand);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    cursor: pointer;
    transition: all 0.2s;
    text-decoration: none;
    border: 1px solid var(--border);
  }
  .social-btn:hover { background: var(--brand); color: var(--white); }

  .contact-form-card {
    background: var(--white);
    border-radius: 20px;
    border: 1px solid var(--border);
    padding: 40px;
  }
  .contact-form-card h3 { font-size: 20px; margin-bottom: 24px; }

  /* ══════════════════════════════════
     FOOTER
  ══════════════════════════════════ */
  footer {
    background: var(--brand);
    color: rgba(255,255,255,0.75);
    padding: 56px 0 32px;
  }
  .footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 40px;
    margin-bottom: 48px;
  }
  .footer-brand .logo { color: var(--white); font-size: 22px; }
  .footer-brand p { margin-top: 14px; font-size: 14px; line-height: 1.65; color: rgba(255,255,255,0.6); }
  .footer-col h4 { color: var(--white); font-size: 14px; font-weight: 600; margin-bottom: 16px; }
  .footer-col ul { list-style: none; }
  .footer-col ul li { margin-bottom: 10px; }
  .footer-col ul li a { color: rgba(255,255,255,0.6); text-decoration: none; font-size: 14px; cursor: pointer; transition: color 0.2s; }
  .footer-col ul li a:hover { color: var(--white); }
  .footer-bottom {
    border-top: 1px solid rgba(255,255,255,0.1);
    padding-top: 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 13px;
    color: rgba(255,255,255,0.4);
  }

  /* Responsive */
  @media (max-width: 900px) {
    .hero-inner, .features-grid, .listings-grid, .listings-row, .shop-grid,
    .events-layout, .footer-grid, .contact-layout { grid-template-columns: 1fr; }
    .hero-visual { display: none; }
    .form-grid { grid-template-columns: 1fr; }
    .form-group.full { grid-column: 1; }
    .photo-masonry { columns: 2; }
    .plan-cards { grid-template-columns: 1fr; }
    nav { padding: 0 16px; }
    .nav-links { display: none; }
    .form-card { padding: 28px 20px; }
  }
