﻿:root {
  --bg: #f4f3ee;
  --panel: #fffdf8;
  --line: #dccdbd;
  --text: #1a241d;
  --muted: #56645c;
  --primary: #205e4f;
  --primary-dark: #154339;
  --accent: #ca7d38;
  --danger: #9f2f2f;
  --radius: 16px;
  --shadow: 0 18px 35px rgba(26, 36, 29, 0.13);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: Manrope, sans-serif;
  color: var(--text);
  background:
    radial-gradient(circle at 15% 0%, rgba(202, 125, 56, 0.22), transparent 40%),
    radial-gradient(circle at 90% 100%, rgba(32, 94, 79, 0.24), transparent 35%),
    var(--bg);
}

h1,
h2,
h3 {
  margin: 0;
  font-family: "Space Grotesk", sans-serif;
}

.hidden {
  display: none !important;
}

.auth-shell {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 1rem;
}

.auth-card {
  width: min(480px, 100%);
  background: rgba(255, 253, 248, 0.92);
  border: 1px solid var(--line);
  border-radius: 22px;
  box-shadow: var(--shadow);
  padding: 1.35rem;
}

.mini-tag {
  margin: 0 0 0.45rem;
  color: var(--primary);
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-weight: 700;
}

.auth-sub {
  margin: 0.5rem 0 1rem;
  color: var(--muted);
}

.stack-form {
  display: grid;
  gap: 0.72rem;
}

label {
  display: grid;
  gap: 0.33rem;
  font-weight: 600;
  font-size: 0.95rem;
}

input,
textarea,
button {
  font: inherit;
}

input,
textarea {
  border: 1px solid var(--line);
  background: #fff;
  color: var(--text);
  border-radius: 11px;
  padding: 0.62rem 0.68rem;
}

input:focus,
textarea:focus {
  outline: 2px solid rgba(32, 94, 79, 0.26);
  border-color: var(--primary);
}

button {
  border: 0;
  border-radius: 11px;
  padding: 0.62rem 0.9rem;
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  color: white;
  font-weight: 700;
  cursor: pointer;
}

button:hover {
  opacity: 0.95;
}

.error-msg {
  margin: 0;
  color: #b53030;
}

.app-shell {
  min-height: 100vh;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 30;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 0.6rem;
  align-items: center;
  border-bottom: 1px solid rgba(220, 205, 189, 0.8);
  backdrop-filter: blur(10px);
  background: rgba(244, 243, 238, 0.86);
  padding: 0.6rem;
}

.top-nav {
  display: flex;
  gap: 0.45rem;
  flex-wrap: wrap;
}

.left-nav {
  justify-content: flex-start;
}

.right-nav {
  justify-content: flex-end;
}

.nav-btn,
.logo-btn {
  border: 1px solid var(--line);
  background: rgba(255, 253, 248, 0.88);
  color: var(--text);
  border-radius: 999px;
  font-weight: 700;
  padding: 0.46rem 0.76rem;
}

.nav-btn.active,
.logo-btn.active {
  border-color: var(--primary);
  color: var(--primary-dark);
  background: rgba(32, 94, 79, 0.11);
}

.logo-btn {
  font-family: "Space Grotesk", sans-serif;
  font-size: 1.02rem;
}

.profile-wrap {
  position: relative;
}

.profile-btn {
  border-radius: 50%;
  width: 2.2rem;
  height: 2.2rem;
  font-size: 1.04rem;
  padding: 0;
}

.profile-menu {
  position: absolute;
  right: 0;
  top: 2.55rem;
  min-width: 180px;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: #fff;
  box-shadow: var(--shadow);
  padding: 0.45rem;
  display: grid;
  gap: 0.25rem;
}

.menu-item {
  background: transparent;
  color: var(--text);
  border: 0;
  text-align: left;
  border-radius: 9px;
  padding: 0.5rem 0.55rem;
}

.menu-item:hover {
  background: #f3eee7;
}

.menu-item.danger {
  color: var(--danger);
}

.main-wrap {
  max-width: 1180px;
  margin: 0 auto;
  padding: 1rem;
}

.view {
  animation: fade 0.22s ease;
}

@keyframes fade {
  from {
    opacity: 0;
    transform: translateY(7px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.lead {
  color: var(--muted);
  margin: 0.45rem 0 1rem;
}

.grid-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.85rem;
}

.card {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--panel);
  box-shadow: var(--shadow);
  padding: 0.85rem;
}

.card-image {
  width: 100%;
  max-height: 240px;
  object-fit: cover;
  border-radius: 13px;
  margin-bottom: 0.68rem;
}

.chip-row {
  display: flex;
  gap: 0.42rem;
  flex-wrap: wrap;
}

.chip {
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 0.2rem 0.55rem;
  font-size: 0.83rem;
  background: rgba(255, 255, 255, 0.74);
}

.chip.offer {
  border-color: rgba(202, 125, 56, 0.5);
  background: rgba(202, 125, 56, 0.12);
}

.card-title {
  margin-top: 0.52rem;
  font-size: 1.06rem;
}

.card-meta {
  margin: 0.35rem 0;
  color: var(--muted);
  font-size: 0.92rem;
}

.card-desc {
  margin: 0;
}

.form-panel {
  max-width: 680px;
  background: var(--panel);
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
  border-radius: var(--radius);
  padding: 0.85rem;
}

.offers-layout {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 0.85rem;
}

.offers-column {
  display: grid;
  gap: 0.65rem;
  align-content: start;
}

.offer-item {
  border: 1px solid var(--line);
  border-radius: 13px;
  background: var(--panel);
  box-shadow: var(--shadow);
  padding: 0.75rem;
  cursor: pointer;
}

.offer-item.active {
  border-color: var(--primary);
  outline: 2px solid rgba(32, 94, 79, 0.18);
}

.map-column {
  position: sticky;
  top: 5.1rem;
  height: calc(100vh - 6rem);
}

#map {
  width: 100%;
  height: 100%;
  min-height: 460px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.empty {
  color: var(--muted);
  margin: 0;
}

.feedback-msg {
  margin: 0;
  color: var(--primary-dark);
  font-weight: 600;
}

.card-action {
  margin-top: 0.75rem;
  background: #eaf0ed;
  color: var(--primary-dark);
  border: 1px solid rgba(32, 94, 79, 0.24);
}

.modal {
  position: fixed;
  inset: 0;
  z-index: 50;
  background: rgba(18, 21, 19, 0.6);
  display: grid;
  place-items: center;
  padding: 1rem;
}

.modal-card {
  width: min(880px, 100%);
  max-height: 92vh;
  overflow: auto;
  background: #faf7f1;
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 0.9rem;
  box-shadow: var(--shadow);
  position: relative;
  display: grid;
  gap: 0.8rem;
}

.modal-close {
  position: absolute;
  top: 0.45rem;
  right: 0.45rem;
  width: 2rem;
  height: 2rem;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: #fff;
  color: #2a2a2a;
  padding: 0;
}

.comments-panel {
  border: 1px solid var(--line);
  border-radius: 13px;
  background: #fff;
  padding: 0.75rem;
}

.comments-list {
  display: grid;
  gap: 0.55rem;
  margin-bottom: 0.65rem;
}

.comment-item {
  border: 1px solid #eadfce;
  border-radius: 11px;
  padding: 0.55rem;
  background: #fffcf6;
}

.comment-meta {
  margin: 0 0 0.3rem;
  color: var(--muted);
  font-size: 0.86rem;
}

.comment-text {
  margin: 0;
}

@media (max-width: 1024px) {
  .topbar {
    grid-template-columns: 1fr;
    justify-items: center;
  }

  .left-nav,
  .right-nav {
    justify-content: center;
  }

  .offers-layout {
    grid-template-columns: 1fr;
  }

  .map-column {
    position: static;
    height: 420px;
  }

  #map {
    min-height: 380px;
  }

  .grid-list {
    grid-template-columns: 1fr;
  }
}
