/* RESET */
*,
*:before,
*:after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: Arial, Helvetica, sans-serif;
}

:focus,
:active {
  outline: none;
}
a:focus,
a:active {
  outline: none;
}

html,
body {
  width: 100%;
  font-size: 14px;
  line-height: 1.5;
}
input,
button,
textarea {
  font-family: inherit;
}
button {
  cursor: pointer;
}
ul li {
  list-style: none;
}
img {
  vertical-align: top;
}

/* primary colors */
:root {
  --dark: #1f1f1f;
  --light: #f5f5f5;
  --accent: rgb(230, 204, 9);
  --text: #dcd0d0;
}

body {
  color: var(--text);
  background-image: url(img/car.webp);
  background-size: cover;
  background-position: center;
}
.container {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 20px;
}
.header {
  background: var(--dark);
  color: white;
}
.header__inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  height: 70px;
}
.logo span {
  color: var(--accent);
}
.nav a {
  color: white;
  margin-left: 20px;
  text-decoration: none;
}
.nav a:hover {
  color: var(--accent);
}
.hero {
  background: rgba(0, 0, 0, 0.8);
  color: white;
  padding: 80px 0;
  text-align: center;
}
.hero h1 {
  font-size: 42px;
  margin-bottom: 15px;
}
.hero p {
  font-size: 18px;
  margin-bottom: 30px;
}
button {
  background: var(--accent);
  color: #282825;
  border: none;
  padding: 14px 32px;
  border-radius: 10px;
  cursor: pointer;
  transition: 0.3s ease;
}
button:hover {
  background: #c62828;
}
button,
.nav a,
.card {
  transition: 0.3s ease;
}

.services {
  margin: 60px auto;
}
.services h2 {
  color: #fff;
  text-align: center;
  margin-bottom: 40px;
  font-weight: 700;
  font-size: larger;
}
.services__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}
.card {
  background: rgba(36, 27, 27, 0.2);
  color: #faf9f9;
  padding: 40px 20px;
  border: 5px solid transparent;
  border-radius: 12px;
  text-align: center;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.08);
}
.card:hover {
  transform: translateY(-4px);
  background-color: rgba(9, 5, 5, 0.5);
  border-color: var(--accent);
}


.why {
  padding: 60px 0;
}
.why ul {
  margin-top: 20px;
}
.why li {
  margin-bottom: 10px;
  font-size: 18px;
}

.contacts {
  margin: 60px auto;
  text-align: center;
}
.btn-outline {
  background: transparent;
  color: var(--accent);
  border: 2px solid var(--accent);
}
.btn-outline:hover {
  background: var(--accent);
  color: white;
}

.footer {
  background: var(--dark);
  color: white;
  text-align: center;
  padding: 20px;
}

/* ADAPTIVE */
/* Средние экраны */
@media (max-width: 768px) {
  .services__grid {
    grid-template-columns: 1fr;
  }
  .nav {
    display: none;
  }
  .hero h1 {
    font-size: 32px;
  }
}

/* Маленькие экраны 375px */
@media (max-width: 375px) {
  .container {
    padding: 0 10px;
  }
  .hero h1 {
    font-size: 24px;
  }
  .hero p {
    font-size: 14px;
    margin-bottom: 20px;
  }
  button {
    padding: 10px 20px;
    font-size: 14px;
  }
  .card {
    padding: 30px 15px;
  }
  .why li {
    font-size: 16px;
  }
  .contacts p,
  .contacts .btn-outline {
    font-size: 14px;
  }
}

/* Очень маленькие экранчики 320px */
@media (max-width: 320px) {
  .hero h1 {
    font-size: 20px;
  }
  .hero p {
    font-size: 13px;
  }
  button {
    padding: 8px 16px;
    font-size: 12px;
  }
  .card {
    padding: 25px 10px;
  }
  .why li {
    font-size: 14px;
  }
  .contacts p,
  .contacts .btn-outline {
    font-size: 12px;
  }
}
