/* magistral.su/way — голубая тема поверх базового style.css */

:root {
  --bg: #eef6ff;
  --bg-2: #dcebff;
  --ink: #0d2b47;
  --ink-2: #33597e;
  --muted: #6b8aa8;
  --line: #cfe2f7;
  --primary: #2f80ed;
  --primary-dark: #1b63c7;
  --primary-soft: #e3efff;
  --accent: #56ccf2;
}

body {
  background-color: #eef6ff;
  background-image:
    radial-gradient(900px 420px at 8% -8%, rgba(86, 204, 242, .22), transparent 60%),
    radial-gradient(760px 380px at 96% 0%, rgba(47, 128, 237, .16), transparent 58%);
  background-attachment: fixed, fixed;
}

/* ── шапка ─────────────────────────────────────────────────────────── */
.topbar {
  background: rgba(255, 255, 255, .88);
  border-bottom: 1px solid var(--line);
}
.logo__mark {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 30px; height: 30px;
  border-radius: 10px;
  background: linear-gradient(135deg, #2f80ed, #56ccf2);
  color: #fff;
  font-size: 15px;
}
.logo__text { font-weight: 800; letter-spacing: -.3px; }

/* ── герой ─────────────────────────────────────────────────────────── */
.hero {
  background:
    radial-gradient(620px 260px at 88% -30%, rgba(255, 255, 255, .35), transparent 60%),
    linear-gradient(135deg, #1b63c7 0%, #2f80ed 52%, #56ccf2 100%);
  border-radius: 26px;
  box-shadow: 0 16px 36px rgba(27, 99, 199, .22);
}
.hero h1 { font-weight: 800; letter-spacing: -.8px; }
.hero p { max-width: 52ch; }

/* ── карточки ──────────────────────────────────────────────────────── */
.card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 20px;
  box-shadow: 0 6px 22px rgba(28, 78, 140, .07);
  transition: transform .15s ease, box-shadow .15s ease, border-color .15s ease;
}
.card:hover {
  transform: translateY(-2px);
  border-color: #9cc6f2;
  box-shadow: 0 14px 30px rgba(28, 78, 140, .13);
}
.card__cover { border-radius: 20px 20px 0 0; }
.card__cover--empty {
  background:
    radial-gradient(320px 160px at 80% -10%, rgba(86, 204, 242, .5), transparent 65%),
    linear-gradient(135deg, #dcebff, #eef6ff);
}
.card__cover-emoji { font-size: 46px; opacity: .85; }
.card__city {
  background: rgba(255, 255, 255, .92);
  color: var(--primary-dark);
  font-weight: 700;
}
.card__title { font-weight: 800; letter-spacing: -.3px; }
.card__meta { color: var(--muted); gap: 12px; display: flex; flex-wrap: wrap; }

/* ── страница путеводителя ─────────────────────────────────────────── */
.quest-hero { border-radius: 24px; overflow: hidden; }
.quest-hero__city {
  background: rgba(255, 255, 255, .16);
  backdrop-filter: blur(6px);
  font-weight: 600;
}
.quest-title { font-weight: 800; letter-spacing: -.6px; }
.panel { border-radius: 20px; border-color: var(--line); }
.side-row { border-bottom: 1px solid #eaf3fc; }
.side-row:last-child { border-bottom: none; }

/* ── игра: задание ─────────────────────────────────────────────────── */
.riddle { font-size: 16.5px; line-height: 1.62; }
.riddle > p { margin: 0 0 12px; }

.riddle__fact,
.riddle__q,
.riddle__photo {
  border-radius: 16px;
  padding: 14px 16px;
  margin: 12px 0 0;
}
.riddle__fact {
  background: #f6faff;
  border: 1px solid #dbe9f8;
  border-left: 4px solid #8fbdec;
  font-size: 15.5px;
}
.riddle__fact strong { color: #2f6f9f; }

.riddle__q {
  background: #fff;
  border: 1px solid #cfe2f7;
  box-shadow: 0 4px 14px rgba(28, 78, 140, .06);
  font-size: 17.5px;
  font-weight: 600;
}
.riddle__q strong { color: var(--primary-dark); }

.riddle__photo {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  background: #eef8ff;
  border: 1px dashed #9cc6f2;
  font-size: 15.5px;
  color: #16456f;
}
.riddle__photo-ico { font-size: 18px; line-height: 1.3; }
.riddle__photo strong { color: var(--primary-dark); }

/* ── игра: таймер и баллы ──────────────────────────────────────────── */
.timerbar {
  border-radius: 16px;
  background: linear-gradient(135deg, #ffffff, #eef6ff);
  border: 1px solid var(--line);
}
.timerbar__time { font-variant-numeric: tabular-nums; }
.points-now {
  background: #f2f8ff;
  border-radius: 12px;
  padding: 10px 14px;
  color: var(--ink-2);
}

/* ── кнопки ────────────────────────────────────────────────────────── */
.btn {
  border-radius: 14px;
  font-weight: 700;
}
.btn--ghost { background: #fff; border-color: var(--line); }

/* ── таблица результатов ───────────────────────────────────────────── */
table.results { border-collapse: collapse; }
table.results th {
  font-size: 12px;
  letter-spacing: .8px;
  text-transform: uppercase;
  color: var(--muted);
  background: #f5faff;
}
table.results td, table.results th { border-bottom: 1px solid #eaf3fc; }
table.results tr.me td { background: #eef6ff; font-weight: 600; }

/* ── подвал ────────────────────────────────────────────────────────── */
.foot { background: #ffffff; border-top: 1px solid var(--line); }

@media (max-width: 640px) {
  .hero { border-radius: 20px; padding: 22px 18px; }
  .riddle { font-size: 16px; }
  .riddle__q { font-size: 17px; }
}

/* ── карта маршрута ────────────────────────────────────────────────── */
.map-panel { padding: 16px; }
/* нумерованные метки карты на странице маршрута */
.pm-pin span { display: block; width: 26px; height: 26px; line-height: 22px; text-align: center;
  border-radius: 50%; background: #b4552f; color: #fff; font-weight: 700; font-size: 12px;
  border: 2px solid #fff; box-shadow: 0 1px 4px rgba(15, 40, 60, .35); }
.quest-map {
  height: 340px;
  border-radius: 16px;
  overflow: hidden;
  border: 1px solid var(--line);
  background: #eef6ff;
}
@media (min-width: 900px) { .quest-map { height: 440px; } }
.leaflet-container { font-family: inherit; }
.map-pin2 {
  background: none;
  border: none;
  filter: drop-shadow(0 2px 4px rgba(13, 43, 71, .35));
}
.map-pin2 svg { overflow: visible; }

/* ── список заданий ────────────────────────────────────────────────── */
.tasks { display: flex; flex-direction: column; gap: 16px; margin-top: 18px; }
.task {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 20px;
  padding: 16px 18px 18px;
  box-shadow: 0 6px 22px rgba(28, 78, 140, .06);
  scroll-margin-top: 80px;
}
.task--ok { border-color: #b7e3c8; box-shadow: 0 6px 22px rgba(31, 157, 97, .10); }
.task--err { border-color: #f2cdc9; }
.task__head { display: flex; align-items: flex-start; gap: 12px; margin-bottom: 10px; }
.task__no {
  flex: 0 0 auto;
  width: 34px; height: 34px;
  border-radius: 10px;
  background: linear-gradient(135deg, #2f80ed, #56ccf2);
  color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-weight: 800; font-size: 16px;
}
.task--ok .task__no { background: linear-gradient(135deg, #1f9d61, #56cc8d); }
.task--err .task__no { background: linear-gradient(135deg, #c0453d, #e2544c); }
.task__title { flex: 1 1 auto; }
.task__title h2 { margin: 0; font-size: 18px; letter-spacing: -.3px; color: var(--ink); }
.task__addr { font-size: 12.5px; color: var(--muted); margin-top: 2px; }
.task__state {
  flex: 0 0 auto;
  font-size: 12px;
  font-weight: 700;
  color: var(--muted);
  background: #f4f9ff;
  border-radius: 999px;
  padding: 5px 11px;
  white-space: nowrap;
}
.task--ok .task__state { color: #16794a; background: #e8f8ef; }
.task--err .task__state { color: #a8352e; background: #fdeceb; }

.task__form { margin-top: 14px; display: flex; flex-direction: column; gap: 10px; }
.field--file .hint { margin-top: 4px; }
.task__form input[type=file] {
  width: 100%;
  font-size: 14px;
  padding: 9px 10px;
  border: 1px dashed #9cc6f2;
  border-radius: 12px;
  background: #f7fbff;
}
.task__result { margin-top: 14px; display: flex; flex-direction: column; gap: 10px; }
.task__ok { color: #16794a; font-weight: 700; margin-left: 8px; }
.task__err { color: #a8352e; font-weight: 700; margin-left: 8px; }
.task__photo img {
  max-width: 100%;
  border-radius: 14px;
  border: 1px solid var(--line);
}
.task__photoform { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.task__photoform input[type=file] {
  flex: 1 1 200px;
  font-size: 13px;
  padding: 8px 10px;
  border: 1px dashed #9cc6f2;
  border-radius: 12px;
  background: #f7fbff;
}

/* ── форма входа: размеры как на эталоне ─────────────────────────── */
.panel--auth { padding: 22px 22px 26px; }
.panel--auth h1 { font-size: 23px; line-height: 1.25; }
.panel--auth .field input { height: 48px; padding: 11px 14px; }
.panel--auth .btn--vk { font-weight: 700; }

/* ── рейтинг ─────────────────────────────────────────────────────── */
.rating-tabs { display: flex; gap: 8px; flex-wrap: wrap; margin: 16px 0 6px; }
.rating-tabs .chip { text-decoration: none; }
.rating-tabs .chip.is-active { text-decoration: none; }
.rating-table td, .rating-table th { padding: 10px 8px; }

/* ── плашки на картинке путеводителя ─────────────────────────────── */
.card__price {
  position: absolute;
  left: 12px;
  bottom: 12px;
  z-index: 2;
  background: #c0392b;
  color: #fff;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: .2px;
  padding: 5px 11px;
  border-radius: 999px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, .18);
}
.card__avail {
  position: absolute;
  right: 12px;
  bottom: 12px;
  z-index: 2;
  color: #fff;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: .2px;
  padding: 5px 11px;
  border-radius: 999px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, .18);
}
.card__avail--open { background: #1f9d61; }
.card__avail--soon { background: #1f5fa8; }
