:root {
    --bg: #faf7f2;
    --surface: #ffffff;
    --text: #1f2937;
    --muted: #6b7280;
    --accent: #b4532a;
    --accent-dark: #8f3f1e;
    --border: #e7e1d8;
    --error: #b91c1c;
}

* { box-sizing: border-box; }

body {
    margin: 0;
    font-family: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
    background: var(--bg);
    color: var(--text);
    line-height: 1.5;
}

.hero {
    text-align: center;
    padding: 48px 16px 24px;
}
.hero h1 { margin: 0 0 8px; font-size: clamp(1.6rem, 4vw, 2.4rem); }
.hero > p { margin: 0 auto 24px; color: var(--muted); max-width: 560px; }

.controls {
    display: flex;
    gap: 12px;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
}
.controls label { display: flex; gap: 8px; align-items: center; color: var(--muted); }
.address-form { margin-top: 12px; }
.address-form input { flex: 1 1 260px; max-width: 360px; }
select, input[type="search"] {
    padding: 10px 12px;
    border: 1px solid var(--border);
    border-radius: 10px;
    background: var(--surface);
    font: inherit;
}

.btn {
    background: var(--accent);
    color: #fff;
    border: 0;
    border-radius: 10px;
    padding: 12px 20px;
    font: inherit;
    font-weight: 600;
    cursor: pointer;
    transition: background .15s, transform .1s;
}
.btn:hover { background: var(--accent-dark); }
.btn:active { transform: scale(.97); }
.btn:disabled { opacity: .6; cursor: wait; }

.status { min-height: 1.5em; margin-top: 16px; color: var(--muted); }
.status.error { color: var(--error); }

.layout {
    display: grid;
    grid-template-columns: minmax(0, 420px) 1fr;
    gap: 20px;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 16px 32px;
}
.list-wrap h2 { margin: 0 0 12px; font-size: 1.1rem; }
.list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 10px;
    max-height: 70vh;
    overflow-y: auto;
}
.card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 14px 16px;
    cursor: pointer;
    transition: border-color .15s, box-shadow .15s;
}
.card:hover, .card:focus-visible { border-color: var(--accent); box-shadow: 0 2px 10px rgb(0 0 0 / .06); outline: none; }
.card-head { display: flex; justify-content: space-between; gap: 12px; align-items: baseline; }
.card h3 { margin: 0; font-size: 1rem; }
.card p { margin: 4px 0 0; font-size: .92rem; }
.dist { color: var(--accent); font-weight: 600; white-space: nowrap; font-size: .9rem; }
.cat { color: var(--muted); }
.hours { color: var(--muted); font-size: .85rem !important; }
.actions { display: flex; gap: 14px; margin-top: 10px; }
.actions a { color: var(--accent); font-weight: 600; font-size: .9rem; text-decoration: none; }
.actions a:hover { text-decoration: underline; }
.empty { color: var(--muted); }

.map {
    height: 70vh;
    min-height: 360px;
    border-radius: 12px;
    border: 1px solid var(--border);
    position: sticky;
    top: 16px;
}

footer {
    text-align: center;
    color: var(--muted);
    font-size: .85rem;
    padding: 16px 16px 32px;
}
footer a { color: inherit; }

@media (max-width: 800px) {
    .layout { grid-template-columns: 1fr; }
    .map { order: -1; height: 45vh; position: static; }
    .list { max-height: none; }
}
