/* Base */
:root {
  --bg: #0b0b0c;
  --bg-soft: #121216;
  --bg-card: #16161d;
  --text: #f2f2f2;
  --muted: #b8b8c2;
  --accent: #ff7a1a;
  --accent-2: #ff9a3d;
  --border: #23232c;
  --success: #47d18c;
  --shadow: 0 20px 40px rgba(0, 0, 0, 0.35);
  --radius: 18px;
  --container: 1200px;
  --logo-url: url("../assets/images/logo.png");
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

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

img {
  max-width: 100%;
  display: block;
}

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

.container {
  width: min(100% - 32px, var(--container));
  margin-inline: auto;
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 14px 24px;
  border-radius: 999px;
  border: 1px solid transparent;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  color: #0b0b0c;
  font-weight: 600;
  box-shadow: var(--shadow);
  transition: transform 0.3s ease, box-shadow 0.3s ease, opacity 0.3s ease;
}

.btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 26px 50px rgba(255, 122, 26, 0.35);
}

.btn-outline {
  background: transparent;
  border-color: var(--accent);
  color: var(--accent);
  box-shadow: none;
}

.btn-outline:hover {
  background: rgba(255, 122, 26, 0.1);
}

.tag {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 14px;
  border-radius: 999px;
  background: rgba(255, 122, 26, 0.12);
  color: var(--accent);
  font-weight: 600;
  font-size: 13px;
  letter-spacing: 0.2px;
}

.section {
  padding: 80px 0;
}

.section-title {
  font-size: clamp(26px, 3vw, 40px);
  margin: 0 0 16px;
}

.section-subtitle {
  color: var(--muted);
  margin: 0 0 40px;
  max-width: 720px;
}

.grid {
  display: grid;
  gap: 24px;
}

.card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
  box-shadow: var(--shadow);
  transition: transform 0.3s ease, border 0.3s ease;
}

.card:hover {
  transform: translateY(-6px);
  border-color: rgba(255, 122, 26, 0.5);
}

.muted {
  color: var(--muted);
}

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

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0;
  height: 88px;
}

.logo {
  display: flex;
  align-items: center;
  gap: 12px;
  font-weight: 700;
  letter-spacing: 0.4px;
  height: 100%;
  flex: 0 0 auto;
}

.logo-mark {
  display: block;
  width: 180px;
  height: 88px;
  border-radius: 0;
  background: transparent;
  border: none;
  background-image: var(--logo-url);
  background-size: contain;
  background-repeat: no-repeat;
  background-position: center;
}

.nav-links,
.nav-cta,
.burger {
  align-self: center;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 24px;
}

.nav-links a {
  color: var(--muted);
  font-weight: 500;
  transition: color 0.3s ease;
}

.nav-links a:hover,
.nav-links a.active {
  color: var(--accent);
}

.nav-cta {
  display: flex;
  align-items: center;
  gap: 16px;
}

.burger {
  display: none;
  width: 44px;
  height: 44px;
  border-radius: 12px;
  border: 1px solid var(--border);
  background: #141418;
  color: var(--text);
  align-items: center;
  justify-content: center;
}

/* Hero */
.hero {
  padding: 100px 0 80px;
  background:
    linear-gradient(180deg, rgba(11, 11, 12, 0.6), rgba(11, 11, 12, 0.9)),
    url("../assets/images/hero-drift.jpg");
  background-size: cover;
  background-position: center;
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: "";
  position: absolute;
  width: 280px;
  height: 280px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 122, 26, 0.5), transparent 70%);
  opacity: 0.85;
  animation: heroCircleMove 12s ease-in-out infinite;
  pointer-events: none;
  z-index: 0;
}

.hero > .container {
  position: relative;
  z-index: 1;
}

@keyframes heroCircleMove {
  0% {
    transform: translate3d(-20%, -10%, 0);
  }
  50% {
    transform: translate3d(65%, 15%, 0);
  }
  100% {
    transform: translate3d(-20%, -10%, 0);
  }
}

.hero-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 40px;
  align-items: center;
}

.hero-title {
  font-size: clamp(34px, 4vw, 56px);
  margin: 16px 0;
  line-height: 1.1;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  margin-top: 28px;
}

.hero-card {
  background: linear-gradient(145deg, #141419, #101015);
  border: 1px solid var(--border);
  border-radius: 24px;
  padding: 32px;
  position: relative;
  overflow: hidden;
}

.hero-card::after {
  content: "";
  position: absolute;
  inset: auto -60px -60px auto;
  width: 220px;
  height: 220px;
  background: radial-gradient(circle, rgba(255, 122, 26, 0.45), transparent 60%);
}

.service-hero-card {
  display: grid;
  gap: 18px;
}

.service-photo {
  width: 100%;
  height: 220px;
  border-radius: 18px;
  object-fit: cover;
  border: 1px solid var(--border);
}

.media-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  align-items: center;
}

.media-image {
  width: 100%;
  height: 280px;
  border-radius: 18px;
  object-fit: cover;
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
}

.hero-stats {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
  margin-top: 24px;
}

.stat {
  padding: 16px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid var(--border);
}

.stat strong {
  font-size: 22px;
  display: block;
}

/* Services */
.services-grid {
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
}

.services-tiles {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.services-tiles > :nth-child(1),
.services-tiles > :nth-child(2) {
  grid-column: span 2;
}

.service-card {
  position: relative;
  overflow: hidden;
  min-height: 210px;
  background: #1a1a20;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 14px;
  padding: 24px;
}

.service-card::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(11, 11, 12, 0.1) 0%, rgba(11, 11, 12, 0.9) 72%);
  z-index: 1;
}

.service-card::after {
  content: "";
  position: absolute;
  inset: 0;
  background-image: var(--service-bg);
  background-repeat: no-repeat;
  background-size: var(--service-bg-size, 65%);
  background-position: var(--service-bg-position, right 10px bottom 8px);
  opacity: var(--service-bg-opacity, 0.7);
  z-index: 0;
}

.service-card > * {
  position: relative;
  z-index: 2;
}

.service-card h3 {
  margin: 0;
  font-size: 20px;
  max-width: 70%;
}

.service-price {
  font-size: 18px;
  color: var(--text);
  font-weight: 600;
}

.service-security {
  --service-bg: url("../assets/images/8857282f528966d508f62d4d43f7acb0.png");
  --service-bg-position: right 0 bottom 8px;
}

.service-keys {
  --service-bg: url("../assets/images/klyuchi-ot-mashini-png-10.png");
  --service-bg-position: right 0 bottom 8px;
}

.service-chip {
  --service-bg: url("../assets/images/5380473-637-1670334047.jpg");
  --service-bg-size: cover;
  --service-bg-position: center;
}

.service-electro {
  --service-bg: url("../assets/images/63cf67934c1146753d18ad1086a9256d.png");
  --service-bg-position: right 0 bottom 8px;
  --service-bg-opacity: 0.5;
}

.service-mechanic {
  --service-bg: url("../assets/images/motor.png");
  --service-bg-position: right 0 bottom 8px;
}

.service-upgrades {
  --service-bg: url("../assets/images/62b0625s-960.jpg");
  --service-bg-position: right 0 bottom 8px;
}

.service-icon {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: rgba(255, 122, 26, 0.15);
  display: grid;
  place-items: center;
  color: var(--accent);
  margin-bottom: 16px;
}

/* Process */
.steps {
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
}

.step-number {
  font-size: 28px;
  font-weight: 700;
  color: var(--accent);
}

/* Testimonials */
.testimonials {
  background: var(--bg-soft);
}

.testimonials-grid {
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
}

/* Gallery */
.gallery-grid {
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  align-items: stretch;
}

.gallery-item {
  border: none;
  padding: 0;
  background: transparent;
  cursor: pointer;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: var(--shadow);
  transition: transform 0.25s ease;
}

.gallery-item:hover {
  transform: translateY(-4px);
}

.gallery-item img {
  width: 100%;
  height: 200px;
  object-fit: cover;
  display: block;
}

.lightbox {
  position: fixed;
  inset: 0;
  background: rgba(5, 5, 8, 0.85);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 999;
  padding: 24px;
}

.lightbox.open {
  display: flex;
}

.lightbox-image {
  max-width: min(96vw, 1100px);
  max-height: 90vh;
  border-radius: 18px;
  box-shadow: var(--shadow);
}

.lightbox-close {
  position: absolute;
  top: 24px;
  right: 24px;
  width: 40px;
  height: 40px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: rgba(15, 15, 20, 0.9);
  color: var(--text);
  font-size: 18px;
  cursor: pointer;
}

/* Pricing */
.price-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 24px;
}

.price-header .section-title {
  margin: 0;
}

.section-note {
  color: var(--muted);
  max-width: 360px;
  margin: 6px 0 0;
}

.price-table {
  background: linear-gradient(180deg, #13131a 0%, #101015 100%);
  border: 1px solid var(--border);
  border-radius: 20px;
  overflow: hidden;
  box-shadow: var(--shadow);
}

.price-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 120px 120px;
  gap: 16px;
  padding: 18px 24px;
  border-top: 1px solid rgba(255, 255, 255, 0.04);
  align-items: center;
}

.price-row:first-child {
  border-top: none;
}

.price-name {
  color: var(--text);
}

.price-time {
  color: var(--muted);
}

.price-value {
  color: var(--text);
  font-weight: 600;
  text-align: right;
}

/* Contact */
.contact {
  display: grid;
  gap: 32px;
}

.contact-head {
  display: grid;
  gap: 12px;
}

.contact-body {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 32px;
  align-items: stretch;
}

.map-card {
  padding: 0;
  overflow: hidden;
  position: relative;
}

.map-embed {
  width: 100%;
  height: 320px;
  border: 0;
  display: block;
}

.map-overlay {
  position: absolute;
  left: 24px;
  top: 24px;
  transform: none;
  width: min(46%, 520px);
  z-index: 2;
}

.map-overlay-card {
  transform: none;
  transition: box-shadow 0.3s ease;
}

.map-overlay-card:hover {
  transform: none;
  border-color: var(--border);
  box-shadow: 0 26px 50px rgba(0, 0, 0, 0.45);
}

.map-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.contact-form {
  display: grid;
  gap: 16px;
}

.contact-photo {
  padding: 0;
  overflow: hidden;
}

.contact-photo img {
  width: 100%;
  height: 100%;
  min-height: 320px;
  object-fit: cover;
  display: block;
}

.field {
  display: grid;
  gap: 8px;
}

label {
  font-weight: 600;
}

input,
select,
textarea {
  background: #0f0f14;
  border: 1px solid var(--border);
  border-radius: 12px;
  color: var(--text);
  padding: 12px 14px;
  font-size: 15px;
  transition: border 0.3s ease, box-shadow 0.3s ease;
}

input[type="checkbox"] {
  width: 16px;
  height: 16px;
  margin-right: 8px;
  accent-color: var(--accent);
}

.field label a {
  color: var(--accent);
  text-decoration: underline;
}

input:focus,
select:focus,
textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(255, 122, 26, 0.2);
}

textarea {
  min-height: 120px;
  resize: vertical;
}

.form-status {
  padding: 12px 14px;
  border-radius: 12px;
  background: rgba(71, 209, 140, 0.12);
  color: var(--success);
  display: none;
}

.form-status.show {
  display: block;
}

/* Footer */
.footer {
  padding: 40px 0 60px;
  border-top: 1px solid var(--border);
}

.footer-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 24px;
  align-items: start;
}

.footer .logo {
  margin: 0 0 2px;
  align-items: flex-start;
}

.footer iframe {
  display: block;
  width: 150px;
  height: 60px;
  border: 0;
  margin: 0 0 8px;
}

.footer a {
  color: var(--muted);
  transition: color 0.3s ease;
}

.footer a:hover {
  color: var(--accent);
}

.messengers {
  display: flex;
  gap: 10px;
  margin-top: 8px;
}

.messenger-icon {
  width: 36px;
  height: 36px;
  border-radius: 999px;
  border: 1px solid var(--border);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--accent);
  background: rgba(255, 122, 26, 0.08);
  transition: transform 0.2s ease, border-color 0.2s ease;
}

.messenger-icon:hover {
  transform: translateY(-2px);
  border-color: rgba(255, 122, 26, 0.6);
}

.messenger-icon svg {
  width: 18px;
  height: 18px;
  fill: currentColor;
}

.messenger-icon .max-text {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.3px;
}

/* Utilities */
.split {
  display: flex;
  gap: 18px;
  align-items: center;
}

.pill {
  padding: 8px 14px;
  border-radius: 999px;
  background: rgba(255, 122, 26, 0.1);
  color: var(--accent);
  font-weight: 600;
}

/* Mobile */
@media (max-width: 900px) {
  .nav {
    height: 64px;
  }

  .logo-mark {
    width: 104px;
    height: 48px;
  }

  .hero-grid,
  .contact-body {
    grid-template-columns: 1fr;
  }

  .map-card {
    display: flex;
    flex-direction: column;
  }

  .map-embed {
    order: 1;
  }

  .map-overlay {
    order: 2;
    position: static;
    transform: none;
    width: 100%;
    margin-top: 16px;
  }

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

  .services-tiles {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .services-tiles > :nth-child(1),
  .services-tiles > :nth-child(2) {
    grid-column: span 2;
  }

  .price-header {
    flex-direction: column;
  }

  .nav-links {
    position: absolute;
    top: 72px;
    right: 16px;
    left: 16px;
    flex-direction: column;
    background: #101014;
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 18px;
    gap: 16px;
    display: none;
  }

  .nav-links.open {
    display: flex;
  }

  .burger {
    display: inline-flex;
  }

  .nav-cta {
    display: flex;
    gap: 8px;
  }

  .nav-cta .pill {
    display: none;
  }

  .nav-cta .btn {
    padding: 10px 16px;
    font-size: 14px;
  }
}

.phone-btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.phone-icon {
  width: 18px;
  height: 18px;
  fill: currentColor;
}

@media (max-width: 900px) {
  .phone-btn {
    padding: 10px;
    width: 40px;
    height: 40px;
    justify-content: center;
  }

  .phone-text {
    display: none !important;
  }
}

@media (hover: none) and (pointer: coarse) {
  .phone-btn {
    padding: 10px;
    width: 40px;
    height: 40px;
    justify-content: center;
  }

  .phone-text {
    display: none !important;
  }
}

@media (max-width: 640px) {
  .hero {
    padding-top: 72px;
  }

  .services-tiles {
    grid-template-columns: 1fr;
  }

  .services-tiles > :nth-child(1),
  .services-tiles > :nth-child(2) {
    grid-column: span 1;
  }

  .price-row {
    grid-template-columns: 1fr;
    text-align: left;
  }

  .price-value {
    text-align: left;
  }

  .hero-actions {
    flex-direction: column;
    align-items: stretch;
  }

  .section {
    padding: 64px 0;
  }
}

@media (prefers-reduced-motion: reduce) {
  * {
    scroll-behavior: auto !important;
    transition: none !important;
  }
}
