/* ==========================================================================
   Desert Armor Korps — desertarmor.com
   Rebuilt 2026. Palette and marks drawn from the club's original
   iWeb/EverWeb site and logo (olive/khaki desert theme, palm + AZ mark).
   ========================================================================== */

:root {
  --olive-dark:   #3c3b28;
  --olive:        #6b6b47;
  --olive-light:  #828160;
  --khaki:        #c9bd9a;
  --sand:         #f4ecd8;
  --sand-light:   #faf6ec;
  --charcoal:     #202019;
  --ink:          #2a2a22;
  --accent:       #8a6d2f;
  --accent-light: #b8933f;
  --cream:        #f7f3e8;
  --border:       #a89b78;

  --font-head: 'Oswald', 'Arial Narrow', sans-serif;
  --font-body: 'Barlow', Arial, sans-serif;

  --max-width: 1160px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font-body);
  background: var(--sand-light);
  color: var(--ink);
  line-height: 1.55;
}

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

a { color: var(--accent); text-decoration: none; }
a:hover { color: var(--accent-light); text-decoration: underline; }

h1, h2, h3, h4 {
  font-family: var(--font-head);
  text-transform: uppercase;
  letter-spacing: 0.03em;
  color: var(--olive-dark);
  margin: 0 0 0.5em;
}

.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 20px;
}

/* ---------- Top bar ---------- */
.topbar {
  background: var(--charcoal);
  color: var(--khaki);
  font-size: 0.8rem;
  padding: 6px 0;
  text-align: center;
  letter-spacing: 0.04em;
}
.topbar a { color: var(--sand); }

/* ---------- Header / nav ---------- */
.site-header {
  background: var(--olive-dark);
  border-bottom: 4px solid var(--accent);
}
.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 12px;
  padding-bottom: 12px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 14px;
  color: var(--cream);
}
.brand img { height: 56px; width: auto; }
.brand-text .club-name {
  font-family: var(--font-head);
  font-size: 1.5rem;
  letter-spacing: 0.06em;
  color: var(--cream);
  line-height: 1.1;
}
.brand-text .club-sub {
  font-size: 0.78rem;
  color: var(--khaki);
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.nav-toggle {
  display: none;
  background: none;
  border: 2px solid var(--khaki);
  color: var(--cream);
  font-size: 1.4rem;
  padding: 4px 10px;
  border-radius: 4px;
  cursor: pointer;
}

.main-nav ul {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  list-style: none;
  margin: 0;
  padding: 0;
}
.main-nav a {
  display: block;
  color: var(--cream);
  font-family: var(--font-head);
  font-size: 0.85rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 8px 12px;
  border-radius: 4px;
  text-decoration: none;
}
.main-nav a:hover,
.main-nav a.active {
  background: var(--accent);
  color: #fff;
}

/* ---------- Hero banner (original battlefield photo) ---------- */
.hero-banner {
  position: relative;
  background: var(--olive-dark);
}
.hero-banner img {
  width: 100%;
  height: clamp(220px, 42vw, 460px);
  object-fit: cover;
  object-position: center 35%;
}
.hero-banner::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(20,18,10,0.05) 0%, rgba(20,18,10,0.55) 55%, rgba(20,18,10,0.88) 100%);
}
.hero-banner-copy {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  padding: 22px 20px 28px;
  z-index: 1;
}
.hero-banner-copy .container { padding: 0 20px; }
.hero-banner-copy h1 {
  color: var(--cream);
  font-size: clamp(1.5rem, 4vw, 2.6rem);
  text-shadow: 0 2px 10px rgba(0,0,0,0.7);
  max-width: 22ch;
}
.hero-banner-copy p {
  color: var(--sand);
  max-width: 62ch;
  text-shadow: 0 1px 6px rgba(0,0,0,0.7);
}
.hero-banner-copy .btn-outline {
  border-color: var(--sand);
}

/* ---------- Alert / next-event strip ---------- */
.alert-strip {
  background: var(--accent);
  color: #fff;
  text-align: center;
  padding: 10px 16px;
  font-family: var(--font-head);
  letter-spacing: 0.04em;
  text-transform: uppercase;
  font-size: 0.95rem;
}
.alert-strip a { color: #fff; text-decoration: underline; }

/* ---------- Section basics ---------- */
section { padding: 44px 0; }
section.alt { background: var(--sand); }
.section-title {
  border-bottom: 3px solid var(--accent);
  padding-bottom: 8px;
  margin-bottom: 24px;
  display: inline-block;
}

/* ---------- Cards / grids ---------- */
.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 20px;
}
.card {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 6px;
  overflow: hidden;
  box-shadow: 0 2px 6px rgba(0,0,0,0.08);
  display: flex;
  flex-direction: column;
}
.card img { aspect-ratio: 4 / 3; object-fit: cover; }
.card-body { padding: 14px 16px; flex: 1; display: flex; flex-direction: column; }
.card-body h3 { font-size: 1rem; margin-bottom: 6px; }
.card-body .meta {
  font-size: 0.78rem;
  color: var(--olive);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 8px;
}
.card-body p { font-size: 0.9rem; flex: 1; }
.card-body .btn { margin-top: 10px; }

.btn {
  display: inline-block;
  background: var(--accent);
  color: #fff !important;
  font-family: var(--font-head);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 9px 18px;
  border-radius: 4px;
  text-decoration: none !important;
  font-size: 0.85rem;
}
.btn:hover { background: var(--accent-light); }
.btn-outline {
  background: transparent;
  border: 2px solid var(--cream);
  color: var(--cream) !important;
}

/* ---------- About / stats ---------- */
.stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 20px;
  text-align: center;
  margin-top: 28px;
}
.stat .num {
  font-family: var(--font-head);
  font-size: 2.2rem;
  color: var(--accent);
}
.stat .label {
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--olive);
}

/* ---------- Footer ---------- */
.site-footer {
  background: var(--charcoal);
  color: var(--khaki);
  padding: 36px 0 20px;
  font-size: 0.9rem;
}
.site-footer a { color: var(--sand); }
.footer-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 24px;
  margin-bottom: 24px;
}
.footer-grid h4 { color: var(--cream); font-size: 0.85rem; }
.footer-grid ul { list-style: none; padding: 0; margin: 0; }
.footer-grid li { margin-bottom: 6px; }
.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.15);
  padding-top: 16px;
  text-align: center;
  font-size: 0.78rem;
  color: var(--border);
}

/* ---------- Article / converted archive pages ---------- */
.article-body {
  max-width: none;
}
.article-body > p {
  margin: 0 0 1em;
  font-size: 1rem;
  max-width: 75ch;
}
p.meta {
  font-family: var(--font-head);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--olive);
  font-size: 0.85rem;
  margin-top: -8px;
  margin-bottom: 20px;
}
.photo-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 10px;
  margin: 10px 0 24px;
  max-width: none;
}
.photo-grid .photo {
  margin: 0;
}
.photo-grid .photo img {
  width: 100%;
  height: 130px;
  object-fit: cover;
  border-radius: 5px;
  border: 1px solid var(--border);
  background: var(--khaki);
  display: block;
}
.photo-grid .photo a:hover img { outline: 2px solid var(--accent); }

.photo-grid-captioned {
  grid-template-columns: repeat(3, 1fr);
  gap: 20px 18px;
}
.photo-grid-captioned .photo img {
  height: 220px;
}
.photo-grid-captioned .photo figcaption {
  font-size: 0.85rem;
  color: var(--ink);
  margin-top: 6px;
  line-height: 1.4;
}
@media (max-width: 950px) {
  .photo-grid-captioned { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 600px) {
  .photo-grid-captioned { grid-template-columns: 1fr; }
  .photo-grid-captioned .photo img { height: 200px; }
}

.link-list {
  list-style: none;
  margin: 0 0 24px;
  padding: 0;
  display: grid;
  gap: 6px;
}
.link-list li {
  border-bottom: 1px dashed var(--border);
  padding-bottom: 6px;
}
.link-list a {
  font-family: var(--font-head);
  text-transform: uppercase;
  letter-spacing: 0.03em;
  font-size: 0.9rem;
}

.index-list {
  display: grid;
  gap: 14px;
  max-width: 720px;
}
.index-list .index-row {
  display: flex;
  align-items: center;
  gap: 14px;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 10px 14px;
}
.index-list .index-row img {
  width: 72px;
  height: 54px;
  object-fit: cover;
  border-radius: 4px;
  flex-shrink: 0;
  background: var(--khaki);
}
.index-list .index-row .idx-title {
  font-family: var(--font-head);
  text-transform: uppercase;
  letter-spacing: 0.03em;
  font-size: 0.95rem;
}
.index-list .index-row .idx-date {
  font-size: 0.78rem;
  color: var(--olive);
}

/* ---------- Responsive ---------- */
@media (max-width: 820px) {
  .main-nav {
    display: none;
    width: 100%;
    order: 3;
  }
  .main-nav.open { display: block; }
  .main-nav ul { flex-direction: column; }
  .site-header .container { flex-wrap: wrap; }
  .nav-toggle { display: block; }
  .hero .container { flex-direction: column; text-align: center; }
}

@media (max-width: 480px) {
  .brand-text .club-name { font-size: 1.15rem; }
  .brand img { height: 42px; }
  section { padding: 30px 0; }
}
