/* Import Arizona Desert Theme Variables */
@import url('../styles/az-theme.css');

* { box-sizing: border-box; }
html, body {
  margin: 0; padding: 0;
  color: var(--text);
  background: var(--bg-page);
  font: 16px/1.45 ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, "Helvetica Neue", Arial, "Apple Color Emoji","Segoe UI Emoji","Segoe UI Symbol";
}

img { max-width: 100%; border: 0; display: block; }
a { color: var(--brand); text-decoration: none; }
a:hover { text-decoration: underline; }
.container { max-width: 1024px; margin: 0 auto; padding: 0 16px; }

/* Header & Nav */
.site-header { position: sticky; top: 0; z-index: 50; background: rgba(255,255,255,0.9); backdrop-filter: blur(8px); border-bottom: 1px solid var(--border); }
.nav { position: relative; display: flex; gap: 12px; align-items: center; justify-content: space-between; padding: 10px 0; }
.brand { display: inline-flex; align-items: center; gap: 8px; }
.brand-logo { width: 150px; height: auto; }

.menu-toggle { border: 1px solid var(--border); background: #fff; border-radius: 8px; padding: 6px 8px; cursor: pointer; }
.badge { display: inline-flex; width: 24px; height: 24px; border-radius: 999px; align-items: center; justify-content: center; background: var(--brand); color: #fff; font-weight: 700; }

/* Dropdown — JS positions it under the F button */
.menu-panel {
  position: absolute;
  top: 56px; left: 0;
  background: #fff; border: 1px solid var(--border); border-radius: 10px;
  display: flex; flex-direction: column;
  box-shadow: 0 8px 24px rgba(0,0,0,0.12);
  z-index: 60;
}
.menu-panel[hidden] { display: none !important; }
.menu-panel a { padding: 10px 12px; white-space: nowrap; }

/* Hero */
.hero { position: relative; }
/* HERO: skyline background (uses per-city var if set; fallback is relative to css/) */
.hero--skyline {
  /* default variable (relative to css/ folder) */
  --skyline-image: url('../images/phoenix-day.svg');

  /* layered background: subtle gradient overlay + skyline image (from variable or fallback) */
  background:
    linear-gradient(to top, rgba(17,24,39,0.65), rgba(17,24,39,0.18)),
    var(--skyline-image, url('../images/skyline.jpg')) center/cover no-repeat;

  color: #fff;
  position: relative;
  min-height: 340px;
  z-index: 0;
}

/* If you want less overlay so the photo shows more, reduce the first RGBA alpha (0.65 -> 0.25) */
.hero--skyline::before { display: none; }

.hero .container { padding: 56px 16px 24px; }
.hero-title { font-size: clamp(1.8rem, 3vw, 2.4rem); margin: 0 0 8px; }
.muted { color: var(--muted); }
.hero .muted { color: #e5e7eb; }

/* Search (home page) */
.search { display: flex; gap: 8px; margin-top: 12px; }
.search input { flex: 1; padding: 10px 12px; border: 1px solid var(--border); border-radius: 8px; background: var(--bg); color: var(--text); }
.search button { padding: 10px 12px; border-radius: 8px; border: none; background: var(--accent); color: #fff; cursor: pointer; font-weight: 500; transition: all 0.2s; }
.search button:hover { background: var(--accent-hover); transform: translateY(-1px); }

/* Tiles (raised buttons) */
.tiles { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; margin-top: 18px; }
@media (min-width: 640px) { .tiles { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (min-width: 960px) { .tiles { grid-template-columns: repeat(4, minmax(0, 1fr)); } }

.tile {
  box-shadow: var(--shadow);
  display: flex; flex-direction: column; gap: 6px;
  text-decoration: none; color: inherit;
  background: var(--tile-bg); border: 1px solid var(--border); border-radius: 12px;
  padding: 16px; align-items: center; justify-content: center; min-height: 110px;
  transition: box-shadow .15s ease, transform .15s ease, border-color .15s ease;
}
.tile:hover { border-color: var(--accent); box-shadow: var(--shadow-lg); transform: translateY(-1px); }
.tile-emoji { font-size: 32px; }
.tile-title { font-weight: 600; }

/* Forms */
.stack, .home-form { display: grid; gap: 12px; max-width: 720px; }
.field { display: grid; gap: 6px; }
.field input, .field select, .field textarea {
  width: 100%; padding: 10px 12px; border-radius: 8px; border: 1px solid var(--border);
  background: var(--bg); color: var(--text); transition: border-color 0.2s;
}
.field input:focus, .field select:focus, .field textarea:focus {
  outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px rgba(210, 105, 30, 0.1);
}
.grid-2 { display: grid; gap: 12px; grid-template-columns: 1fr 1fr; }
@media (max-width: 600px) { .grid-2 { grid-template-columns: 1fr; } }
.checks { display: flex; gap: 16px; border: 1px dashed var(--border); border-radius: 10px; padding: 10px 12px; }
.actions { display: flex; flex-wrap: wrap; gap: 8px; }
.actions button { padding: 10px 12px; border-radius: 8px; border: none; background: var(--accent); color: #fff; cursor: pointer; font-weight: 500; transition: all 0.2s; }
.actions button:hover { background: var(--accent-hover); transform: translateY(-1px); }
.actions button.secondary { background: #fff; border: 1px solid var(--border); color: var(--accent); }
.actions button.secondary:hover { background: var(--card); border-color: var(--accent); }

.tool-intro { max-width: 720px; }

/* Result card */
.result-card {
  margin-top: 18px;
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 16px;
  background: var(--card);
  box-shadow: var(--shadow);
  max-width: 920px;
}
.result-header { display: flex; gap: 12px; align-items: center; }
.status-pill {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 4px 10px; border-radius: 999px; font-weight: 700; color: #fff;
}
.status-pill.ok { background: var(--ok); }
.status-pill.warn { background: var(--warn); }
.status-pill.bad { background: var(--bad); }
.result-title { margin: 8px 0 4px; }
.result-desc { margin: 0 0 12px; }

.imagery { margin: 10px 0; display: grid; gap: 6px; max-width: 640px; }
.imagery img { width: 100%; height: auto; border-radius: 10px; border: 1px solid var(--border); }

/* New: no imagery friendly card */
.no-imagery {
  margin: 6px 0 10px;
  padding: 12px;
  border: 1px dashed var(--border);
  border-radius: 10px;
  background: #fffdf7;
  color: #7c2d12;
  display: none;
}
.no-imagery[hidden] { display: none; }
.no-imagery:not([hidden]) { display: block; }

/* Map */
.map { width: 100%; height: 340px; border-radius: 10px; border: 1px solid var(--border); margin: 6px 0 12px; }

.list-title { margin: 6px 0; font-size: 1rem; color: var(--brand-2); }
.nearby-list { margin: 0; padding-left: 0; list-style: none; }
.nearby-list li {
  margin: 4px 0; padding: 6px 8px; border: 1px solid var(--border); border-radius: 8px;
  cursor: pointer; display: flex; gap: 6px; align-items: center;
}
.nearby-list li:hover { background: #fafafa; }
.nearby-list .poi { width: 22px; display: inline-block; text-align: center; }

/* Footer */
.site-footer { border-top: 1px solid var(--border); margin-top: 32px; padding-bottom: 16px; }

/* Memo carousel */
.memos-carousel { display: grid; grid-template-columns: 40px 1fr 40px; gap: 8px; align-items: center; margin-top: 14px; }
.memo-viewport { min-height: 52px; display: grid; place-items: center; border-radius: 10px; padding: 12px 16px; background: rgba(0,0,0,0.35); }
.memo-viewport .memo { color: #fff; font-weight: 600; text-align: center; }
.memo-prev, .memo-next {
  border: 0; width: 36px; height: 36px; border-radius: 999px;
  background: rgba(0,0,0,0.55); color: #fff; cursor: pointer;
  display: inline-flex; align-items: center; justify-content: center;
  transition: background-color .15s ease;
}
.memo-prev { grid-column: 1; }
.memo-next { grid-column: 3; }
.memo-prev:hover, .memo-next:hover { background: rgba(0,0,0,0.75); }
.memo-prev:focus-visible, .memo-next:focus-visible { outline: 2px solid #fff; outline-offset: 2px; }

/* Header logo legibility */
.brand-logo {
  background: rgba(17, 24, 39, 0.60);
  backdrop-filter: blur(2px) saturate(110%);
  -webkit-backdrop-filter: blur(2px) saturate(110%);
  border: 1px solid rgba(255,255,255,0.20);
  border-radius: 10px;
  padding: 4px 6px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.18);
} /* ----------------------------------------------------------- */
