:root {
  color-scheme: dark;
  --bg: #090d16;
  --panel: rgba(18, 24, 38, 0.82);
  --panel-soft: rgba(255, 255, 255, 0.045);
  --border: rgba(255, 255, 255, 0.10);
  --text: #f6f7fb;
  --muted: #a5aec0;
  --accent: #f8b84e;
  --accent-strong: #ffca68;
  --danger: #ff7b7b;
  --success: #5ee0a0;
  --shadow: 0 24px 70px rgba(0, 0, 0, 0.33);
}

* { box-sizing: border-box; }
html { min-height: 100%; background: var(--bg); }
body {
  margin: 0;
  min-height: 100vh;
  font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--text);
  background:
    radial-gradient(circle at 10% 0%, rgba(248, 184, 78, 0.12), transparent 28%),
    radial-gradient(circle at 90% 20%, rgba(87, 126, 255, 0.12), transparent 30%),
    linear-gradient(180deg, #0b101c 0%, #080b12 100%);
}

button, input, select { font: inherit; }
button { cursor: pointer; }
.hidden { display: none !important; }

.bg-orb {
  position: fixed;
  width: 360px;
  height: 360px;
  filter: blur(100px);
  opacity: .13;
  border-radius: 50%;
  pointer-events: none;
}
.orb-one { left: -170px; top: 16vh; background: #f7b449; }
.orb-two { right: -180px; bottom: 10vh; background: #4f6cff; }

.shell {
  width: min(980px, calc(100% - 28px));
  margin: 0 auto;
  padding: 42px 0 56px;
  position: relative;
  z-index: 1;
}

.hero {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 24px;
}
.eyebrow, .section-kicker {
  color: var(--accent-strong);
  font-size: .78rem;
  letter-spacing: .11em;
  text-transform: uppercase;
  font-weight: 800;
}
h1 { font-size: clamp(2.2rem, 7vw, 4.8rem); margin: 8px 0 8px; letter-spacing: -.055em; line-height: .98; }
h2 { margin: 5px 0 0; font-size: 1.65rem; letter-spacing: -.025em; }
h3 { margin: 5px 0 0; font-size: 1.3rem; }
.subtitle { color: var(--muted); margin: 0; max-width: 600px; line-height: 1.55; }
.live-pill, .count-badge {
  border: 1px solid var(--border);
  background: var(--panel-soft);
  color: var(--muted);
  border-radius: 999px;
  padding: 9px 12px;
  font-size: .82rem;
  white-space: nowrap;
}
.live-dot {
  display: inline-block;
  width: 7px;
  height: 7px;
  margin-right: 6px;
  border-radius: 50%;
  background: var(--success);
  box-shadow: 0 0 14px var(--success);
}

.panel {
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 24px;
  padding: 24px;
  margin-bottom: 18px;
  box-shadow: var(--shadow);
  backdrop-filter: blur(18px);
}
.panel-heading { display: flex; align-items: center; justify-content: space-between; gap: 14px; margin-bottom: 20px; }
.panel-heading.compact { margin-bottom: 16px; }
.big-emoji { font-size: 2.4rem; }
.divider { height: 1px; background: var(--border); margin: 22px 0; }

.form-grid { display: grid; grid-template-columns: 190px 1fr; gap: 26px; align-items: start; }
.avatar-picker {
  min-height: 220px;
  border: 1px dashed rgba(255, 255, 255, .18);
  background: var(--panel-soft);
  border-radius: 20px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 8px;
  text-align: center;
  padding: 18px;
  color: var(--muted);
  cursor: pointer;
}
.avatar-picker input { display: none; }
.avatar-picker small { font-size: .72rem; color: #7f899d; }
.avatar-preview {
  width: 92px;
  height: 92px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  overflow: hidden;
  background: rgba(255,255,255,.06);
  font-size: 2rem;
  border: 2px solid rgba(255,255,255,.1);
}
.avatar-preview img { width: 100%; height: 100%; object-fit: cover; }
.fields { display: grid; gap: 14px; }
label > span:first-child { display: block; color: #d7dce6; margin-bottom: 7px; font-size: .9rem; font-weight: 650; }
input, select {
  width: 100%;
  border: 1px solid var(--border);
  background: rgba(6, 9, 16, .52);
  color: var(--text);
  border-radius: 13px;
  padding: 13px 14px;
  outline: none;
  transition: border-color .18s, box-shadow .18s;
}
input:focus, select:focus { border-color: rgba(248,184,78,.55); box-shadow: 0 0 0 3px rgba(248,184,78,.09); }
.primary-button, .custom-add button {
  border: 0;
  border-radius: 13px;
  padding: 14px 18px;
  font-weight: 850;
  background: linear-gradient(135deg, var(--accent-strong), #f29b38);
  color: #241505;
  box-shadow: 0 10px 28px rgba(248, 184, 78, .2);
}

.me-layout { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 18px; }
.avatar {
  width: 78px;
  height: 78px;
  border-radius: 50%;
  overflow: hidden;
  display: grid;
  place-items: center;
  background: linear-gradient(135deg, rgba(248,184,78,.18), rgba(255,255,255,.05));
  border: 2px solid rgba(255,255,255,.11);
  font-size: 1.7rem;
  flex: 0 0 auto;
}
.avatar img { width: 100%; height: 100%; object-fit: cover; }
.me-name { font-size: 1.55rem; font-weight: 900; letter-spacing: -.025em; }
.me-meta { color: var(--muted); margin-top: 3px; }
.me-total { text-align: right; }
.me-total strong { display: block; font-size: 1.9rem; color: var(--accent-strong); }
.me-total span { color: var(--muted); font-size: .8rem; }
.progress-wrap { margin-top: 18px; }
.progress-label { display: flex; justify-content: space-between; color: var(--muted); font-size: .82rem; margin-bottom: 8px; }
.progress-track { height: 10px; background: rgba(255,255,255,.06); border-radius: 999px; overflow: hidden; }
.progress-bar { height: 100%; min-width: 0; border-radius: inherit; background: linear-gradient(90deg, #f29b38, #ffd77d); transition: width .35s ease; }
.me-actions { margin-top: 16px; display: flex; gap: 10px; flex-wrap: wrap; }
.secondary-button, .file-button {
  border: 1px solid var(--border);
  background: rgba(255,255,255,.045);
  color: var(--muted);
  border-radius: 11px;
  padding: 9px 11px;
  font-size: .82rem;
}
.file-button input { display: none; }

.drink-controls { display: grid; grid-template-columns: 180px 1fr; gap: 18px 28px; align-items: center; }
.quick-buttons { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
.quick-buttons button {
  border: 1px solid rgba(248,184,78,.22);
  background: rgba(248,184,78,.075);
  color: #ffd689;
  border-radius: 12px;
  padding: 12px 8px;
  font-weight: 800;
}
.quick-buttons button:hover { background: rgba(248,184,78,.14); }
.custom-add { grid-column: 2; display: flex; gap: 8px; }
.custom-add input { flex: 1; }
.custom-add button { padding-inline: 16px; }

.leaderboard { display: grid; gap: 9px; }
.leader-row {
  display: grid;
  grid-template-columns: 46px 54px minmax(0, 1fr) auto;
  gap: 13px;
  align-items: center;
  border: 1px solid rgba(255,255,255,.07);
  background: rgba(255,255,255,.035);
  border-radius: 17px;
  padding: 12px 14px;
}
.leader-row.top-one { border-color: rgba(255,199,86,.26); background: linear-gradient(90deg, rgba(248,184,78,.09), rgba(255,255,255,.025)); }
.rank { font-size: 1.1rem; font-weight: 900; color: #a9b2c4; text-align: center; }
.rank.medal { font-size: 1.55rem; }
.leader-avatar { width: 50px; height: 50px; font-size: 1.25rem; }
.leader-name { font-weight: 850; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.leader-meta { margin-top: 3px; color: var(--muted); font-size: .8rem; }
.leader-score { text-align: right; }
.leader-score strong { display: block; font-size: 1.2rem; color: var(--accent-strong); }
.leader-score span { color: var(--muted); font-size: .75rem; }
.empty { color: var(--muted); text-align: center; padding: 30px 10px; }

.history { display: grid; gap: 8px; }
.history-row { display: flex; justify-content: space-between; gap: 12px; padding: 11px 13px; border-radius: 12px; background: rgba(255,255,255,.035); }
.history-row strong { color: #ffd689; }
.history-row time { color: var(--muted); font-size: .82rem; }

.toast {
  position: fixed;
  left: 50%;
  bottom: 22px;
  transform: translate(-50%, 20px);
  background: #1b2333;
  border: 1px solid var(--border);
  border-radius: 13px;
  padding: 11px 14px;
  box-shadow: var(--shadow);
  opacity: 0;
  pointer-events: none;
  transition: .2s ease;
  z-index: 20;
  max-width: min(92vw, 560px);
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }
.toast.error { border-color: rgba(255,123,123,.35); color: #ffd1d1; }

footer { color: #6f788b; font-size: .76rem; text-align: center; line-height: 1.5; padding: 12px 18px 0; }

@media (max-width: 720px) {
  .shell { padding-top: 26px; }
  .hero { align-items: flex-start; flex-direction: column; gap: 12px; }
  .panel { padding: 18px; border-radius: 20px; }
  .form-grid { grid-template-columns: 1fr; }
  .avatar-picker { min-height: 160px; }
  .drink-controls { grid-template-columns: 1fr; }
  .quick-buttons, .custom-add { grid-column: 1; }
  .me-layout { grid-template-columns: auto 1fr; }
  .me-total { grid-column: 1 / -1; text-align: left; display: flex; align-items: baseline; gap: 7px; }
  .quick-buttons { grid-template-columns: repeat(2, 1fr); }
  .leader-row { grid-template-columns: 36px 46px minmax(0,1fr); padding: 11px 10px; gap: 9px; }
  .leader-avatar { width: 44px; height: 44px; }
  .leader-score { grid-column: 3; text-align: left; display: flex; align-items: baseline; gap: 6px; margin-top: -4px; }
  .leader-score strong { font-size: 1rem; }
  .count-badge { font-size: .72rem; }
}

.field-hint {
  display: block;
  color: #7f899d;
  font-size: .74rem;
  line-height: 1.4;
  margin-top: 7px;
}
.auth-divider {
  display: flex;
  align-items: center;
  gap: 12px;
  color: #6f788b;
  font-size: .75rem;
  margin: 24px 0;
  text-transform: uppercase;
  letter-spacing: .08em;
}
.auth-divider::before, .auth-divider::after { content: ""; height: 1px; background: var(--border); flex: 1; }
.login-box {
  display: grid;
  grid-template-columns: minmax(220px, .8fr) minmax(320px, 1.2fr);
  gap: 22px;
  align-items: center;
  padding: 18px;
  border: 1px solid var(--border);
  border-radius: 18px;
  background: rgba(255,255,255,.028);
}
.login-box h3 { margin-top: 5px; }
.login-box p { color: var(--muted); margin: 7px 0 0; font-size: .84rem; line-height: 1.45; }
.login-form { display: grid; grid-template-columns: 1fr 150px auto; gap: 8px; }
.login-button { color: var(--text); white-space: nowrap; }
.legacy-pin {
  margin-top: 18px;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 16px;
  align-items: center;
  border: 1px solid rgba(248,184,78,.28);
  background: rgba(248,184,78,.07);
  border-radius: 16px;
  padding: 15px;
}
.legacy-pin strong { display: block; color: #ffd689; margin-bottom: 4px; }
.legacy-pin span { color: var(--muted); font-size: .8rem; line-height: 1.4; }
.legacy-pin-controls { display: flex; gap: 8px; }
.legacy-pin-controls input { width: 120px; }
.legacy-pin-controls button { padding: 12px 14px; white-space: nowrap; }

@media (max-width: 720px) {
  .login-box { grid-template-columns: 1fr; }
  .login-form { grid-template-columns: 1fr; }
  .legacy-pin { grid-template-columns: 1fr; }
  .legacy-pin-controls { display: grid; grid-template-columns: 1fr; }
  .legacy-pin-controls input { width: 100%; }
}

/* Navigation and gallery */
.page-nav {
  display: inline-flex;
  gap: 7px;
  padding: 6px;
  margin: 0 0 18px;
  border: 1px solid var(--border);
  border-radius: 16px;
  background: rgba(18, 24, 38, .72);
  backdrop-filter: blur(18px);
}
.page-nav-button {
  border: 0;
  border-radius: 11px;
  padding: 10px 16px;
  background: transparent;
  color: var(--muted);
  font-weight: 800;
}
.page-nav-button.active {
  background: rgba(248, 184, 78, .14);
  color: var(--accent-strong);
  box-shadow: inset 0 0 0 1px rgba(248, 184, 78, .18);
}
.gallery-intro { color: var(--muted); margin: -2px 0 18px; line-height: 1.5; }
.gallery-upload {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: stretch;
  gap: 10px;
  padding-top: 4px;
}
.gallery-file-button {
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 12px;
  border: 1px dashed rgba(255,255,255,.18);
  background: rgba(255,255,255,.035);
  border-radius: 14px;
  padding: 12px 14px;
  cursor: pointer;
}
.gallery-file-button input { display: none; }
.gallery-file-button span { font-weight: 800; white-space: nowrap; }
.gallery-file-button small { color: var(--muted); overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.gallery-login-notice {
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 13px 14px;
  color: var(--muted);
  background: rgba(255,255,255,.03);
  line-height: 1.45;
}
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}
.gallery-card {
  min-width: 0;
  overflow: hidden;
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 18px;
  background: rgba(255,255,255,.035);
}
.gallery-photo-button {
  display: block;
  width: 100%;
  aspect-ratio: 1 / 1;
  padding: 0;
  border: 0;
  background: #070a10;
  overflow: hidden;
}
.gallery-photo-button img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
  transition: transform .22s ease;
}
.gallery-photo-button:hover img { transform: scale(1.025); }
.gallery-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 11px 12px;
}
.gallery-author {
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 9px;
}
.gallery-author-avatar {
  width: 34px;
  height: 34px;
  flex: 0 0 34px;
  display: grid;
  place-items: center;
  overflow: hidden;
  border-radius: 50%;
  background: rgba(248,184,78,.1);
  border: 1px solid var(--border);
  font-size: .85rem;
}
.gallery-author-avatar img { width: 100%; height: 100%; object-fit: cover; }
.gallery-author strong {
  display: block;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  font-size: .88rem;
}
.gallery-author time { display: block; margin-top: 2px; color: var(--muted); font-size: .69rem; }
.gallery-delete {
  border: 1px solid rgba(255,123,123,.2);
  background: rgba(255,123,123,.07);
  color: #ffb0b0;
  border-radius: 9px;
  padding: 7px 8px;
  font-size: .72rem;
}
.gallery-empty { grid-column: 1 / -1; }
.photo-lightbox {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: grid;
  place-items: center;
  padding: 32px;
  background: rgba(0,0,0,.88);
  backdrop-filter: blur(10px);
}
.photo-lightbox img {
  max-width: min(1200px, 94vw);
  max-height: 90vh;
  object-fit: contain;
  border-radius: 16px;
  box-shadow: 0 30px 90px rgba(0,0,0,.5);
}
.lightbox-close {
  position: fixed;
  top: 18px;
  right: 20px;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  border: 1px solid rgba(255,255,255,.18);
  background: rgba(18,24,38,.84);
  color: white;
  font-size: 1.75rem;
  line-height: 1;
}
.modal-open { overflow: hidden; }

@media (max-width: 800px) {
  .gallery-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 560px) {
  .page-nav { width: 100%; display: grid; grid-template-columns: 1fr 1fr; }
  .gallery-upload { grid-template-columns: 1fr; }
  .gallery-file-button { align-items: flex-start; flex-direction: column; gap: 4px; }
  .gallery-file-button small { width: 100%; }
  .gallery-grid { grid-template-columns: 1fr; }
  .gallery-photo-button { aspect-ratio: 4 / 3; }
  .photo-lightbox { padding: 14px; }
}

/* Multiple beverages and profile editing */
.beverage-summary-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin-top: 18px;
}
.beverage-summary-card {
  border: 1px solid rgba(255,255,255,.075);
  background: rgba(255,255,255,.032);
  border-radius: 14px;
  padding: 12px 13px;
}
.beverage-summary-top { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; }
.beverage-summary-top strong { color: #f3f5fa; }
.beverage-summary-top span { color: var(--accent-strong); font-size: .82rem; white-space: nowrap; }
.beverage-summary-card small { display: block; color: var(--muted); font-size: .72rem; margin-top: 6px; }
.mini-progress { height: 6px; margin-top: 9px; border-radius: 999px; overflow: hidden; background: rgba(255,255,255,.06); }
.mini-progress > div { height: 100%; border-radius: inherit; background: linear-gradient(90deg, #f29b38, #ffd77d); }

.profile-edit-panel {
  margin-top: 18px;
  padding: 17px;
  border-radius: 18px;
  border: 1px solid rgba(248,184,78,.2);
  background: rgba(248,184,78,.045);
}
.profile-edit-heading { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 14px; }
.beverage-edit-form { display: grid; gap: 12px; }
.beverage-edit-list { display: grid; gap: 10px; }
.beverage-edit-row {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(130px, .7fr) auto;
  gap: 10px;
  align-items: end;
  padding: 12px;
  border: 1px solid rgba(255,255,255,.07);
  border-radius: 14px;
  background: rgba(6,9,16,.25);
}
.beverage-edit-status { min-width: 145px; display: grid; gap: 7px; align-self: center; }
.beverage-edit-status span, .beverage-edit-status small { color: var(--muted); font-size: .75rem; }
.beverage-edit-status strong { color: var(--accent-strong); }
.danger-button {
  border: 1px solid rgba(255,123,123,.28);
  background: rgba(255,123,123,.07);
  color: #ffc0c0;
  border-radius: 10px;
  padding: 8px 10px;
  font-size: .76rem;
}
.profile-edit-divider { height: 1px; background: var(--border); margin: 16px 0; }
.add-beverage-form {
  display: grid;
  grid-template-columns: minmax(180px, 1fr) minmax(160px, 1fr) 130px auto;
  gap: 9px;
  align-items: end;
}
.add-beverage-form strong { display: block; }
.add-beverage-form small { display: block; color: var(--muted); margin-top: 4px; font-size: .74rem; }
.add-beverage-form .secondary-button { height: 46px; color: var(--text); }

.drink-beverage-picker { grid-column: 2; }
.drink-beverage-picker > span { color: var(--muted); font-size: .78rem; margin-bottom: 6px; }
.quick-buttons { grid-column: 2; }
.history-row > div { display: grid; gap: 3px; }
.history-row > div span { color: var(--muted); font-size: .75rem; }

@media (max-width: 720px) {
  .beverage-summary-grid { grid-template-columns: 1fr; }
  .beverage-summary-top { align-items: flex-start; }
  .beverage-edit-row { grid-template-columns: 1fr; }
  .beverage-edit-status { min-width: 0; }
  .add-beverage-form { grid-template-columns: 1fr; }
  .drink-beverage-picker, .quick-buttons { grid-column: 1; }
}

/* Shared chat */
.chat-panel { padding-bottom: 18px; }
.chat-intro { color: var(--muted); margin: -2px 0 16px; line-height: 1.5; }
.chat-live { white-space: nowrap; }
.chat-messages {
  height: min(58vh, 620px);
  min-height: 340px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 14px;
  border: 1px solid rgba(255,255,255,.07);
  border-radius: 18px;
  background: rgba(5,8,14,.35);
  scroll-behavior: smooth;
}
.chat-message { display: grid; grid-template-columns: 38px minmax(0, 1fr); gap: 9px; align-items: start; }
.chat-avatar {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  overflow: hidden;
  border-radius: 50%;
  border: 1px solid var(--border);
  background: rgba(255,255,255,.04);
}
.chat-avatar img { width: 100%; height: 100%; object-fit: cover; }
.chat-bubble {
  min-width: 0;
  width: fit-content;
  max-width: min(760px, 92%);
  padding: 10px 12px;
  border: 1px solid rgba(255,255,255,.075);
  border-radius: 6px 16px 16px 16px;
  background: rgba(255,255,255,.045);
}
.chat-message.own-message .chat-bubble {
  border-color: rgba(248,184,78,.18);
  background: rgba(248,184,78,.065);
}
.chat-meta { display: flex; align-items: center; gap: 8px; margin-bottom: 5px; }
.chat-meta strong { font-size: .82rem; color: var(--accent-strong); }
.chat-meta time { color: var(--muted); font-size: .66rem; }
.chat-delete {
  margin-left: auto;
  width: 24px;
  height: 24px;
  padding: 0;
  border-radius: 50%;
  border: 0;
  background: transparent;
  color: var(--muted);
  font-size: 1rem;
}
.chat-delete:hover { background: rgba(255,123,123,.09); color: #ffb0b0; }
.chat-text { color: #eef1f7; line-height: 1.45; overflow-wrap: anywhere; white-space: normal; }
.chat-form {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 9px;
  align-items: end;
  margin-top: 12px;
}
.chat-form textarea {
  min-height: 52px;
  max-height: 150px;
  resize: vertical;
  line-height: 1.4;
}
.chat-form small { grid-column: 1 / -1; color: var(--muted); font-size: .7rem; }
.chat-send { min-height: 52px; }

@media (max-width: 560px) {
  .page-nav { grid-template-columns: repeat(3, 1fr); }
  .page-nav-button { padding: 10px 8px; font-size: .82rem; }
  .chat-messages { height: 55vh; min-height: 320px; padding: 10px; }
  .chat-form { grid-template-columns: 1fr; }
  .chat-form small { grid-column: 1; }
  .chat-send { min-height: 46px; }
  .chat-bubble { max-width: 100%; }
}


/* Location */
.location-panel { overflow: hidden; }
.location-address-card {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  padding: 16px;
  margin-bottom: 16px;
  border: 1px solid rgba(248,184,78,.18);
  border-radius: 18px;
  background: rgba(248,184,78,.055);
}
.location-pin {
  width: 46px;
  height: 46px;
  flex: 0 0 46px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  background: rgba(248,184,78,.13);
  font-size: 1.35rem;
}
.location-address-card strong { display: block; color: var(--accent-strong); font-size: 1rem; margin-bottom: 5px; }
.location-address-card p { margin: 0; color: #d4d9e3; line-height: 1.5; }
.location-map-wrap {
  position: relative;
  width: 100%;
  height: 420px;
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: 20px;
  background: rgba(255,255,255,.035);
}
.location-map { width: 100%; height: 100%; border: 0; display: block; }
.location-actions { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 16px; }
.location-actions a { display: inline-flex; align-items: center; justify-content: center; text-decoration: none; }
.location-route-button { min-height: 48px; }
.location-map-button { min-height: 48px; color: var(--text); padding: 14px 18px; }
.location-hint { color: var(--muted); font-size: .78rem; line-height: 1.5; margin: 12px 0 0; }

@media (max-width: 560px) {
  .page-nav { display: grid; grid-template-columns: repeat(4, 1fr); width: 100%; }
  .page-nav-button { padding: 10px 5px; font-size: .76rem; }
  .location-map-wrap { height: 52vh; min-height: 330px; max-height: 470px; border-radius: 16px; }
  .location-actions { display: grid; grid-template-columns: 1fr; }
  .location-actions a { width: 100%; }
  .location-address-card { padding: 13px; }
}
