:root {
  --bg: #0b0b0d;
  --bg-soft: #141417;
  --card: #1a1a1e;
  --border: #2a2a2f;
  --text: #f2f2f4;
  --text-dim: #a3a3ab;
  --accent: #ffffff;
  --accent-soft: #d6d6db;
  --radius: 16px;
  --maxw: 1160px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

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

a { color: inherit; text-decoration: none; }

img { display: block; }

.wrap {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 24px;
}

/* Header */
header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(11, 11, 13, 0.85);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 24px;
}

.logo {
  font-size: 19px;
  font-weight: 700;
  letter-spacing: -0.01em;
  display: flex;
  align-items: center;
  gap: 10px;
}

.logo-mark {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: #fff;
  object-fit: cover;
  flex-shrink: 0;
}

.logo span { color: var(--text-dim); font-weight: 400; }

.nav-links {
  display: flex;
  gap: 28px;
  font-size: 14px;
  color: var(--text-dim);
}

.nav-links a:hover { color: var(--text); }

.nav-cta {
  background: var(--accent);
  color: #0b0b0d;
  padding: 9px 18px;
  border-radius: 999px;
  font-size: 14px;
  font-weight: 600;
  white-space: nowrap;
}

.nav-cta:hover { background: var(--accent-soft); }

@media (max-width: 720px) {
  .nav-links { display: none; }
}

/* Hero */
.hero {
  padding: 90px 24px 70px;
  background: radial-gradient(ellipse 70% 60% at 30% 0%, #1e1e24 0%, var(--bg) 70%);
  overflow: hidden;
}

.hero-solo { text-align: center; }

.hero-solo .hero-copy { max-width: 720px; margin: 0 auto; }
.hero-solo .hero-badges,
.hero-solo .hero-actions { justify-content: center; }

.hero h1 {
  font-size: clamp(32px, 4.6vw, 54px);
  font-weight: 700;
  letter-spacing: -0.02em;
  margin: 0 0 18px;
}

.hero p {
  color: var(--text-dim);
  font-size: 18px;
  max-width: 520px;
  margin: 0 0 32px;
}

.hero-badges {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 36px;
}

.badge {
  border: 1px solid var(--border);
  background: var(--bg-soft);
  color: var(--text-dim);
  font-size: 13px;
  padding: 7px 14px;
  border-radius: 999px;
}

.badge-accent {
  border-color: #4a4a52;
  background: #232327;
  color: var(--text);
  font-weight: 600;
}

.hero-actions {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
}

.btn {
  padding: 13px 26px;
  border-radius: 999px;
  font-size: 15px;
  font-weight: 600;
  display: inline-block;
}

.btn-primary { background: var(--accent); color: #0b0b0d; }
.btn-primary:hover { background: var(--accent-soft); }

.btn-outline {
  border: 1px solid var(--border);
  color: var(--text);
}
.btn-outline:hover { border-color: #4a4a52; }

/* Section shell */
section { padding: 70px 24px; }

.section-head {
  text-align: center;
  max-width: 620px;
  margin: 0 auto 44px;
}

.section-head h2 {
  font-size: clamp(26px, 3.5vw, 36px);
  margin: 0 0 12px;
  letter-spacing: -0.01em;
}

.section-head p { color: var(--text-dim); font-size: 16px; margin: 0; }

.eyebrow {
  display: inline-block;
  color: var(--text-dim);
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 10px;
}

/* Catalog */
.catalog-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 20px;
  max-width: var(--maxw);
  margin: 0 auto;
}

.product-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform 0.15s ease, border-color 0.15s ease;
}

.product-card:hover {
  transform: translateY(-3px);
  border-color: #4a4a52;
}

.product-photos {
  display: grid;
  grid-template-columns: repeat(var(--n, 3), 1fr);
  gap: 1px;
  background: var(--border);
}

.product-photos img {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: contain;
  background: #f5f5f7;
  padding: 14px;
}

.product-body { padding: 20px 22px 22px; flex: 1; display: flex; flex-direction: column; }

.product-card h3 { font-size: 18px; margin: 0 0 6px; }

.product-price {
  font-size: 15px;
  font-weight: 600;
  color: var(--accent);
  margin: 0 0 12px;
}

.product-specs {
  color: var(--text-dim);
  font-size: 13.5px;
  line-height: 1.6;
  margin: 0 0 16px;
  flex: 1;
}

.product-card .btn { align-self: flex-start; font-size: 13.5px; padding: 9px 18px; }

/* Model spec table (accordion-ish simple list) */
.spec-toggle-wrap { margin-top: 44px; }

details.spec-block {
  background: var(--bg-soft);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 18px 22px;
  margin-bottom: 10px;
  transition: border-color 0.15s ease;
}

details.spec-block:hover { border-color: #3a3a40; }

details.spec-block summary {
  cursor: pointer;
  font-weight: 600;
  font-size: 15.5px;
  list-style: none;
}

details.spec-block summary::-webkit-details-marker { display: none; }

details.spec-block summary::after {
  content: "+";
  float: right;
  color: var(--text-dim);
}

details.spec-block[open] summary::after { content: "\2212"; }

.spec-block-body {
  margin-top: 12px;
  color: var(--text-dim);
  font-size: 14px;
  line-height: 1.7;
  white-space: pre-line;
}

/* Services — photo cards, price + description always visible */
.service-group-title {
  max-width: var(--maxw);
  margin: 40px auto 16px;
  font-size: 15px;
  font-weight: 600;
  color: var(--text-dim);
}

.service-group-title:first-of-type { margin-top: 6px; }

.services-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 16px;
  max-width: var(--maxw);
  margin: 0 auto;
}

.service-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  transition: transform 0.15s ease, border-color 0.15s ease;
}

.service-card:hover {
  transform: translateY(-3px);
  border-color: #4a4a52;
}

.service-card-photo {
  aspect-ratio: 1 / 1;
  background: #f5f5f7;
  overflow: hidden;
}

.service-card-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.service-card-photo-fallback {
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-soft);
}

.service-card-photo-fallback span { font-size: 40px; opacity: 0.7; }

.service-card-body { padding: 16px 18px 18px; }

.service-card h4 {
  font-size: 14.5px;
  font-weight: 600;
  margin: 0 0 6px;
  line-height: 1.3;
}

.service-card p {
  color: var(--text-dim);
  font-size: 12.5px;
  line-height: 1.5;
  margin: 0 0 10px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.service-card-price {
  font-size: 14px;
  font-weight: 700;
  color: var(--accent);
}

/* Full price-list tables (inside catalog accordions) */
.price-table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 12px;
  border-radius: 10px;
  overflow: hidden;
}

.price-table tr:nth-child(odd) { background: rgba(255,255,255,0.02); }

.price-table tr:hover { background: rgba(255,255,255,0.05); }

.price-table td {
  padding: 11px 14px;
  font-size: 14px;
}

.price-table td:first-child { color: var(--text); }

.price-table td:last-child {
  text-align: right;
  font-weight: 700;
  color: var(--accent);
  white-space: nowrap;
}

/* Why us */
.why-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 20px;
  max-width: var(--maxw);
  margin: 0 auto;
}

.why-item { text-align: center; padding: 10px; }
.why-item .num {
  font-size: 32px;
  font-weight: 700;
  margin-bottom: 8px;
}
.why-item .label { color: var(--text-dim); font-size: 14px; }

.store-photos {
  max-width: var(--maxw);
  margin: 32px auto 10px;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  height: 220px;
}

.store-photos img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: var(--radius);
  border: 1px solid var(--border);
}

@media (max-width: 640px) {
  .store-photos { grid-template-columns: 1fr; height: auto; }
  .store-photos img { height: 200px; }
}

.store-photos-caption {
  max-width: var(--maxw);
  margin: 12px auto 0;
  text-align: center;
  color: var(--text-dim);
  font-size: 13px;
}

/* Contact */
.contact-box {
  max-width: var(--maxw);
  margin: 0 auto;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 40px;
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  gap: 40px;
}

@media (max-width: 800px) {
  .contact-box { grid-template-columns: 1fr; }
}

.contact-info h3 { font-size: 22px; margin: 0 0 18px; }

.contact-row {
  display: flex;
  gap: 12px;
  margin-bottom: 14px;
  font-size: 15px;
  color: var(--text-dim);
}

.contact-row b { color: var(--text); font-weight: 600; min-width: 90px; }

.map-frame {
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid var(--border);
  min-height: 260px;
  background: var(--bg-soft);
}

.map-frame iframe { width: 100%; height: 100%; min-height: 260px; border: 0; }

/* Final CTA */
.final-cta {
  text-align: center;
  padding: 90px 24px;
  background: linear-gradient(180deg, var(--bg) 0%, #17171b 100%);
}

.final-cta h2 { font-size: clamp(26px, 4vw, 38px); margin: 0 0 14px; }
.final-cta p { color: var(--text-dim); margin: 0 0 30px; }

footer {
  border-top: 1px solid var(--border);
  padding: 30px 24px;
  text-align: center;
  color: var(--text-dim);
  font-size: 13px;
}

footer a { color: var(--text-dim); }
footer a:hover { color: var(--text); }

/* Reviews */
.reviews-total {
  color: var(--text-dim);
  font-size: 14px;
  margin: 0;
}

.reviews-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 16px;
  max-width: var(--maxw);
  margin: 0 auto 24px;
}

.review-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px 22px;
}

.review-card-head {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 12px;
}

.review-avatar {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: var(--bg-soft);
  border: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 15px;
  flex-shrink: 0;
}

.review-author { font-size: 14.5px; font-weight: 600; }
.review-stars { color: #f5b942; font-size: 12.5px; letter-spacing: 1px; }
.review-date { margin-left: auto; color: var(--text-dim); font-size: 12px; white-space: nowrap; }

.review-body {
  color: var(--text-dim);
  font-size: 13.5px;
  line-height: 1.6;
  margin: 0;
  white-space: pre-line;
}

.reviews-note {
  max-width: var(--maxw);
  margin: 0 auto;
  color: var(--text-dim);
  font-size: 13px;
  text-align: center;
}

.reviews-note a { text-decoration: underline; }
.reviews-note a:hover { color: var(--text); }

.reviews-see-all {
  display: flex;
  gap: 14px;
  justify-content: center;
  flex-wrap: wrap;
  margin-top: 16px;
}

/* Social section */
.social-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 14px;
  max-width: var(--maxw);
  margin: 0 auto;
}

.social-tile {
  display: flex;
  align-items: center;
  gap: 12px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 18px 20px;
  font-size: 15px;
  font-weight: 600;
  transition: border-color 0.15s ease, transform 0.15s ease;
}

.social-tile:hover {
  border-color: #4a4a52;
  transform: translateY(-2px);
}

/* Contact picker modal */
#contact-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
  z-index: 100;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 24px;
}

#contact-overlay.open { display: flex; }

#contact-modal {
  width: 100%;
  max-width: 380px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 18px;
  padding: 32px 28px 26px;
  text-align: center;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
}

#contact-avatar {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  object-fit: cover;
  margin: 0 auto 14px;
}

#contact-modal h3 { font-size: 19px; margin: 0 0 8px; }
#contact-modal p { color: var(--text-dim); font-size: 13.5px; margin: 0 0 22px; }

.contact-option {
  display: flex;
  align-items: center;
  gap: 14px;
  background: var(--bg-soft);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 13px 16px;
  margin-bottom: 10px;
  text-align: left;
  transition: border-color 0.15s ease, transform 0.15s ease, background 0.15s ease;
}

.contact-option:hover {
  border-color: #4a4a52;
  background: #1f1f24;
  transform: translateX(2px);
}

.contact-option .c-icon {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 19px;
  font-weight: 700;
  color: #fff;
  flex-shrink: 0;
}

.c-icon-tg { background: #229ED9; }
.c-icon-vk { background: #0077FF; font-size: 14px; }
.c-icon-avito { background: #00A046; font-size: 16px; }
.c-icon-max { background: #7E23F2; font-size: 16px; }
.c-icon-yandex { background: #FC3F1D; font-size: 16px; }

.contact-option .c-text {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.contact-option .c-text b { font-size: 14.5px; font-weight: 600; }
.contact-option .c-text small { color: var(--text-dim); font-size: 12.5px; }

.contact-option .c-arrow {
  color: var(--text-dim);
  font-size: 16px;
  transition: transform 0.15s ease;
}

.contact-option:hover .c-arrow { transform: translateX(3px); color: var(--text); }

#contact-close-btn {
  background: none;
  border: none;
  color: var(--text-dim);
  font-size: 13.5px;
  cursor: pointer;
  margin-top: 8px;
  padding: 6px;
}

#contact-close-btn:hover { color: var(--text); }

/* Admin panel */
.admin-shell {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.admin-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 28px;
  border-bottom: 1px solid var(--border);
  background: var(--bg-soft);
}

.admin-topbar .logo { font-size: 16px; }

.admin-main {
  flex: 1;
  max-width: 900px;
  margin: 0 auto;
  padding: 40px 24px 80px;
  width: 100%;
}

.admin-main h1 { font-size: 26px; margin: 0 0 6px; }
.admin-main .sub { color: var(--text-dim); font-size: 14px; margin: 0 0 32px; }

.admin-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 22px 24px;
  margin-bottom: 16px;
}

.admin-card h2 {
  font-size: 16px;
  margin: 0 0 16px;
}

.admin-field { margin-bottom: 14px; }

.admin-field label {
  display: block;
  font-size: 12.5px;
  color: var(--text-dim);
  margin-bottom: 6px;
}

.admin-field input,
.admin-field textarea {
  width: 100%;
  background: var(--bg-soft);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 10px 12px;
  color: var(--text);
  font-size: 14px;
  font-family: inherit;
  outline: none;
  resize: vertical;
}

.admin-field input:focus,
.admin-field textarea:focus { border-color: #4a4a52; }

.admin-field textarea { min-height: 140px; line-height: 1.6; }

.admin-row { display: flex; gap: 14px; }
.admin-row > * { flex: 1; }

.admin-save-btn {
  background: var(--accent);
  color: #0b0b0d;
  border: none;
  padding: 10px 22px;
  border-radius: 999px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
}

.admin-save-btn:hover { background: var(--accent-soft); }

.admin-delete-btn {
  background: none;
  border: 1px solid #6a2c2c;
  color: #f0a7a7;
  padding: 9px 18px;
  border-radius: 999px;
  font-size: 13px;
  cursor: pointer;
}

.admin-delete-btn:hover { background: #3a1a1a; }

.service-photo-field {
  display: flex;
  align-items: center;
  gap: 14px;
}

.admin-photo-preview {
  width: 64px;
  height: 64px;
  border-radius: 10px;
  object-fit: cover;
  border: 1px solid var(--border);
  flex-shrink: 0;
}

.admin-flash {
  background: #16321f;
  border: 1px solid #2d5a3c;
  color: #9adcb0;
  padding: 12px 16px;
  border-radius: 10px;
  font-size: 14px;
  margin-bottom: 20px;
}

.admin-flash.error {
  background: #3a1a1a;
  border-color: #6a2c2c;
  color: #f0a7a7;
}

.admin-logout {
  color: var(--text-dim);
  font-size: 13px;
  border: 1px solid var(--border);
  padding: 7px 14px;
  border-radius: 999px;
}
.admin-logout:hover { color: var(--text); }

/* Login / register screens */
.auth-shell {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
}

.auth-box {
  width: 100%;
  max-width: 380px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 32px 28px;
}

.auth-box h1 { font-size: 20px; margin: 0 0 6px; text-align: center; }
.auth-box .sub { color: var(--text-dim); font-size: 13.5px; text-align: center; margin: 0 0 26px; }

.auth-box .admin-save-btn { width: 100%; padding: 11px; margin-top: 6px; }

.auth-switch {
  text-align: center;
  font-size: 13.5px;
  color: var(--text-dim);
  margin-top: 18px;
}

.auth-switch a { color: var(--text); text-decoration: underline; }
