/* ===================================================================
   GCRP theme — frontier / western, dark with gold accent.
   Accent color is injected via --accent / --accent-dark (config-driven).
=================================================================== */
:root {
  --bg: #10140b;
  --bg-2: #161b0e;
  --panel: #1c2312;
  --panel-2: #242c17;
  --line: rgba(227, 162, 74, 0.18);
  --text: #ece3c2;
  --muted: #a7ad8c;
  --accent: #e3a24a;
  --accent-dark: #9c7330;
  --danger: #c0563f;
  --ok: #84a85c;
  --warn: #e0a23f;
  --radius: 14px;
  --shadow: 0 18px 50px rgba(0, 0, 0, 0.6);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background:
    radial-gradient(1200px 600px at 70% -10%, rgba(227, 162, 74,0.10), transparent 60%),
    linear-gradient(180deg, var(--bg) 0%, var(--bg-2) 100%);
  color: var(--text);
  font-family: "Crimson Text", Georgia, serif;
  font-size: 18px;
  line-height: 1.65;
  min-height: 100vh;
}

h1, h2, h3, h4, .nav-brand, .cta-button { font-family: "Cinzel", serif; }

a { color: var(--accent); text-decoration: none; }
a:hover { color: #f0c885; }

img { max-width: 100%; display: block; }

.page { min-height: 60vh; }

.container { width: min(1180px, 92%); margin: 0 auto; }

/* ---------- Navbar ---------- */
.navbar {
  position: sticky; top: 0; z-index: 100;
  backdrop-filter: blur(10px);
  background: rgba(13, 11, 8, 0.72);
  border-bottom: 1px solid var(--line);
  transition: background .25s ease, box-shadow .25s ease;
}
.navbar.scrolled { background: rgba(13, 11, 8, 0.94); box-shadow: 0 10px 30px rgba(0,0,0,.45); }
.nav-inner { width: min(1180px, 94%); margin: 0 auto; display: flex; align-items: center; gap: 18px; min-height: 68px; }
.nav-brand { display: flex; align-items: center; gap: 10px; font-size: 1.35rem; font-weight: 700; color: var(--text); letter-spacing: 1px; }
.nav-brand i { color: var(--accent); }
.brand-logo { height: 46px; width: auto; display: block; }
.footer-logo { height: 96px; width: auto; display: block; margin-bottom: 10px; }
.nav-links { margin-left: auto; display: flex; align-items: center; gap: 5px; flex-wrap: wrap; justify-content: flex-end; }
.nav-links a { color: var(--text); padding: 8px 10px; border-radius: 8px; font-family: "Cinzel", serif; font-size: .92rem; transition: background .2s, color .2s; }
.nav-links a:hover, .nav-links a.active { background: rgba(227, 162, 74,0.14); color: var(--accent); }
.nav-discord { color: #c9d2ff !important; }
.nav-staff-cta { display: inline-flex; align-items: center; gap: 10px; flex-shrink: 0; }
.staff-cta-welcome { color: var(--muted); font-family: "Crimson Text", serif; white-space: nowrap; }
/* Compact, self-contained button so the generic .nav-links a rule can't distort it. */
.nav-staff-cta .cta-button { padding: 7px 14px; font-size: .82rem; border-radius: 8px; color: #1a1206; }
.nav-staff-cta .cta-button:hover { color: #1a1206; }
.nav-staff-cta .cta-button.secondary { color: var(--text); }
.nav-staff-cta a:hover { background: transparent; }

.nav-dropdown { position: relative; }
.nav-link-static { cursor: pointer; }
.nav-dropdown-menu {
  position: absolute; top: 100%; left: 0; min-width: 200px;
  background: var(--panel); border: 1px solid var(--line); border-radius: 12px;
  padding: 8px; display: none; flex-direction: column; box-shadow: var(--shadow);
}
.nav-dropdown:hover .nav-dropdown-menu, .nav-dropdown.open .nav-dropdown-menu { display: flex; }
.nav-dropdown-menu a { display: block; }

.nav-burger { display: none; background: none; border: 0; cursor: pointer; flex-direction: column; gap: 5px; padding: 8px; margin-left: auto; }
.nav-burger span { width: 24px; height: 2px; background: var(--text); display: block; transition: .25s; }

/* ---------- Buttons ---------- */
.cta-button {
  display: inline-flex; align-items: center; gap: 9px; justify-content: center;
  background: linear-gradient(135deg, var(--accent), var(--accent-dark));
  color: #1a1206; font-weight: 700; padding: 12px 22px; border-radius: 10px;
  border: 1px solid rgba(255,255,255,.12); cursor: pointer; font-size: .95rem;
  letter-spacing: .5px; transition: transform .15s ease, box-shadow .2s ease;
}
.cta-button:hover { transform: translateY(-2px); box-shadow: 0 12px 28px rgba(227, 162, 74,.28); color: #1a1206; }
.cta-button.secondary { background: transparent; color: var(--text); border-color: var(--line); }
.cta-button.secondary:hover { background: rgba(227, 162, 74,.12); color: var(--accent); }

/* ---------- Hero ---------- */
.hero {
  position: relative; padding: 120px 0 90px; text-align: center;
  border-bottom: 1px solid var(--line);
  background:
    radial-gradient(900px 400px at 50% 0%, rgba(227, 162, 74,0.12), transparent 70%);
}
.hero .kicker { color: var(--accent); letter-spacing: 5px; text-transform: uppercase; font-size: .8rem; font-family: "Cinzel", serif; }
.hero h1 { font-size: clamp(2.6rem, 6vw, 4.6rem); margin: 14px 0 18px; line-height: 1.05; }
.hero p.lead { max-width: 720px; margin: 0 auto 30px; color: var(--muted); font-size: 1.2rem; }
.hero-actions { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; }

/* ---------- Live stats strip ---------- */
.stats-strip { width: min(1000px, 92%); margin: -42px auto 0; position: relative; z-index: 5;
  display: grid; grid-template-columns: repeat(5, 1fr); gap: 1px; background: var(--line);
  border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); }
.stat-cell { background: var(--panel); padding: 22px 16px; text-align: center; }
.stat-cell .num { font-family: "Cinzel", serif; font-size: 2rem; color: var(--accent); font-weight: 700; }
.stat-cell .label { color: var(--muted); font-size: .82rem; text-transform: uppercase; letter-spacing: 1.5px; }
.live-dot { display: inline-block; width: 9px; height: 9px; border-radius: 50%; background: var(--ok); margin-right: 6px; box-shadow: 0 0 0 0 rgba(111,160,90,.6); animation: pulse 2s infinite; }
@keyframes pulse { 0%{box-shadow:0 0 0 0 rgba(111,160,90,.5);} 70%{box-shadow:0 0 0 10px rgba(111,160,90,0);} 100%{box-shadow:0 0 0 0 rgba(111,160,90,0);} }

/* ---------- Sections ---------- */
.section { padding: 80px 0; }
.section-head { text-align: center; max-width: 720px; margin: 0 auto 48px; }
.section-head .kicker { color: var(--accent); letter-spacing: 4px; text-transform: uppercase; font-size: .78rem; }
.section-head h2 { font-size: clamp(1.9rem, 3.5vw, 2.8rem); margin: 10px 0 14px; }
.section-head p { color: var(--muted); }

.card-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(290px, 1fr)); gap: 22px; }
.feature-card {
  background: linear-gradient(180deg, var(--panel), var(--panel-2));
  border: 1px solid var(--line); border-radius: var(--radius); padding: 28px;
  transition: transform .2s ease, border-color .2s ease;
}
.feature-card:hover { transform: translateY(-4px); border-color: rgba(227, 162, 74,.4); }
.feature-card .icon { width: 52px; height: 52px; border-radius: 12px; display: grid; place-items: center;
  background: rgba(227, 162, 74,.14); color: var(--accent); font-size: 1.4rem; margin-bottom: 16px; }
.feature-card h3 { margin: 0 0 10px; font-size: 1.25rem; }
.feature-card p { color: var(--muted); margin: 0; }

/* ---------- Staff cards ---------- */
.staff-group { margin-bottom: 36px; }
.staff-group h3 { text-align: center; color: var(--accent); letter-spacing: 2px; margin-bottom: 18px; }
.staff-cards { display: flex; flex-wrap: wrap; gap: 18px; justify-content: center; }
.staff-card { width: 150px; text-align: center; background: var(--panel); border: 1px solid var(--line); border-radius: 14px; padding: 16px; }
.staff-avatar { width: 84px; height: 84px; border-radius: 50%; margin: 0 auto 10px; object-fit: cover; border: 2px solid var(--accent); }
.staff-name { font-family: "Cinzel", serif; font-size: .95rem; }
.staff-title { font-size: .8rem; color: var(--accent); margin-top: 3px; }

/* ---------- CTA band ---------- */
.cta-band { text-align: center; padding: 80px 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line);
  background: radial-gradient(700px 300px at 50% 50%, rgba(227, 162, 74,.10), transparent 70%); }
.cta-band h2 { font-size: clamp(1.8rem, 3.5vw, 2.6rem); }
.cta-band p { color: var(--muted); max-width: 620px; margin: 12px auto 26px; }

/* ---------- Footer ---------- */
.site-footer { border-top: 1px solid var(--line); background: var(--bg-2); margin-top: 60px; }
.footer-inner { width: min(1180px, 92%); margin: 0 auto; padding: 50px 0 30px; display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 30px; }
.footer-brand i { color: var(--accent); font-size: 1.4rem; }
.footer-brand p { color: var(--muted); margin: 8px 0 0; }
.footer-links { display: flex; flex-direction: column; gap: 8px; }
.footer-cta { display: flex; flex-direction: column; gap: 10px; align-items: flex-start; }
.footer-bottom { text-align: center; color: var(--muted); font-size: .85rem; padding: 18px; border-top: 1px solid var(--line); }

/* ---------- Generic content pages ---------- */
.content-wrap { width: min(900px, 92%); margin: 0 auto; padding: 70px 0; }
.content-wrap h1 { font-size: clamp(2rem, 4vw, 3rem); }
.content-wrap h2 { color: var(--accent); margin-top: 36px; border-bottom: 1px solid var(--line); padding-bottom: 8px; }
.content-wrap ul { padding-left: 22px; }
.content-wrap li { margin-bottom: 8px; }
.lead-block { color: var(--muted); font-size: 1.15rem; }

/* ---------- Shared toolbar / inputs ---------- */
.toolbar { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; margin-bottom: 24px; }
.input, select.input, textarea.input {
  background: var(--panel); border: 1px solid var(--line); color: var(--text);
  border-radius: 10px; padding: 11px 14px; font-family: inherit; font-size: .95rem; width: 100%;
}
.input:focus { outline: none; border-color: var(--accent); }
.search-grow { flex: 1 1 240px; }

.state-msg { text-align: center; color: var(--muted); padding: 60px 0; }

/* ---------- Roster ---------- */
.dept { border: 1px solid var(--line); border-radius: var(--radius); margin-bottom: 16px; overflow: hidden; background: var(--panel); }
.dept-head { display: flex; align-items: center; justify-content: space-between; padding: 18px 22px; cursor: pointer; }
.dept-head:hover { background: var(--panel-2); }
.dept-left { display: flex; align-items: center; gap: 14px; }
.dept-icon { width: 44px; height: 44px; border-radius: 10px; display: grid; place-items: center; background: rgba(227, 162, 74,.14); color: var(--accent); }
.dept-name { font-family: "Cinzel", serif; font-size: 1.2rem; }
.dept-sub { color: var(--muted); font-size: .85rem; }
.dept-right { display: flex; align-items: center; gap: 12px; color: var(--muted); }
.badge { background: rgba(227, 162, 74,.16); color: var(--accent); border-radius: 20px; padding: 3px 12px; font-weight: 700; font-size: .85rem; }
.dept .chev { transition: transform .25s; }
.dept.is-open .chev { transform: rotate(180deg); }
.dept-body { display: none; padding: 0 22px 18px; }
.dept.is-open .dept-body { display: block; }
.rank-block { margin-top: 16px; }
.rank-title { display: flex; justify-content: space-between; color: var(--accent); font-family: "Cinzel", serif; border-bottom: 1px solid var(--line); padding-bottom: 6px; margin-bottom: 12px; }
.members { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 14px; }
.member { background: var(--panel-2); border: 1px solid var(--line); border-radius: 12px; padding: 16px; }
.member-top { display: flex; justify-content: space-between; gap: 10px; }
.m-name { margin: 0; font-size: 1.1rem; }
.m-rank { color: var(--muted); font-size: .85rem; }
.m-status { font-size: .75rem; padding: 3px 10px; border-radius: 20px; height: fit-content; white-space: nowrap; }
.m-status.active { background: rgba(111,160,90,.18); color: #9fcf86; }
.m-status.loa { background: rgba(216,163,65,.18); color: var(--warn); }
.m-status.inactive { background: rgba(192,86,63,.18); color: #e08a76; }
.m-divider { height: 1px; background: var(--line); margin: 12px 0; }
.m-meta { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.m-field-label { color: var(--muted); font-size: .72rem; text-transform: uppercase; letter-spacing: 1px; }
.m-field-value { font-size: .92rem; }
.license-pill { display: inline-block; background: rgba(227, 162, 74,.14); color: var(--accent); border-radius: 16px; padding: 2px 10px; font-size: .78rem; margin: 4px 4px 0 0; }
.filter-chip { background: var(--panel); border: 1px solid var(--line); color: var(--text); border-radius: 20px; padding: 7px 16px; cursor: pointer; font-family: "Cinzel", serif; font-size: .82rem; }
.filter-chip.is-active { background: var(--accent); color: #1a1206; border-color: var(--accent); }

/* ---------- Directory grids (businesses / real estate) ---------- */
.dir-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 20px; }
.dir-item { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; cursor: pointer; transition: transform .2s, border-color .2s; }
.dir-item:hover { transform: translateY(-4px); border-color: rgba(227, 162, 74,.4); }
.dir-item.is-hidden { opacity: .55; }
.dir-media { position: relative; aspect-ratio: 16/10; background: var(--panel-2); }
.dir-media img { width: 100%; height: 100%; object-fit: cover; }
.dir-pill { position: absolute; top: 10px; left: 10px; background: rgba(0,0,0,.6); color: #fff; border-radius: 16px; padding: 3px 10px; font-size: .75rem; }
.dir-body { padding: 16px; }
.dir-top { display: flex; justify-content: space-between; gap: 10px; }
.dir-title { margin: 0; font-size: 1.15rem; }
.dir-sub { color: var(--muted); font-size: .85rem; }
.dir-badge { font-size: .72rem; padding: 3px 10px; border-radius: 20px; height: fit-content; white-space: nowrap; }
.dir-badge.for_sale { background: rgba(111,160,90,.18); color: #9fcf86; }
.dir-badge.owned { background: rgba(192,86,63,.18); color: #e08a76; }
.dir-meta { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 12px; color: var(--muted); font-size: .88rem; }
.dir-meta strong { color: var(--accent); }

/* ---------- Modal / editor ---------- */
.overlay { position: fixed; inset: 0; background: rgba(0,0,0,.7); display: none; z-index: 200; padding: 30px; overflow: auto; }
.modal { width: min(760px, 100%); margin: 30px auto; background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); }
.modal-head { display: flex; justify-content: space-between; align-items: flex-start; padding: 22px; border-bottom: 1px solid var(--line); }
.modal-kicker { color: var(--accent); font-size: .78rem; text-transform: uppercase; letter-spacing: 2px; }
.modal-title { font-family: "Cinzel", serif; font-size: 1.6rem; margin: 6px 0 0; }
.modal-close { background: none; border: 0; color: var(--muted); font-size: 1.4rem; cursor: pointer; }
.modal-body { padding: 22px; }
.modal-main-image { width: 100%; aspect-ratio: 16/9; object-fit: cover; border-radius: 12px; background: var(--panel-2); }
.thumb-row { display: flex; gap: 8px; margin-top: 10px; flex-wrap: wrap; }
.thumb { width: 76px; border: 1px solid var(--line); border-radius: 8px; overflow: hidden; cursor: pointer; background: none; padding: 0; }
.thumb.is-active { border-color: var(--accent); }
.thumb img { height: 50px; width: 100%; object-fit: cover; }
.detail-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin-top: 18px; }
.detail-cell { background: var(--panel-2); border: 1px solid var(--line); border-radius: 10px; padding: 12px; }
.detail-cell .k { color: var(--muted); font-size: .72rem; text-transform: uppercase; letter-spacing: 1px; }
.detail-cell .v { font-size: 1.05rem; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.form-grid label { display: block; }
.form-grid .full { grid-column: 1 / -1; }
.form-label { color: var(--muted); font-size: .8rem; display: block; margin-bottom: 6px; }
.editor-msg { display: none; padding: 10px 14px; border-radius: 8px; margin-bottom: 14px; }
.editor-msg.error { background: rgba(192,86,63,.18); color: #e08a76; }
.editor-msg.success { background: rgba(111,160,90,.18); color: #9fcf86; }
.row-actions { display: flex; gap: 10px; justify-content: flex-end; margin-top: 18px; }

@media (min-width: 1025px) and (max-width: 1320px) {
  .staff-cta-welcome { display: none; }
}

@media (max-width: 1024px) {
  .nav-burger { display: flex; }
  .nav-links { position: fixed; inset: 68px 0 auto 0; flex-direction: column; align-items: stretch;
    background: var(--bg-2); border-bottom: 1px solid var(--line); padding: 14px; gap: 4px;
    transform: translateY(-120%); transition: transform .3s; }
  .nav-links.is-open { transform: translateY(0); }
  .nav-dropdown-menu { position: static; box-shadow: none; }
  .stats-strip { grid-template-columns: 1fr 1fr; }
  .footer-inner { grid-template-columns: 1fr; }
  .detail-grid, .form-grid { grid-template-columns: 1fr; }
}
