:root {
  --dark-text-color: #2A293E;
  --light-text-color: #f0f0f0;
  --dark-bg-color: #252525;
  --active-color: #0071e3;
  --active-hover-color: #5fc4ff;
}

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

html {
  font-family: -apple-system, BlinkMacSystemFont,
    'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell,
    'Open Sans', 'Helvetica Neue', sans-serif;
}

body {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    margin: 0;
}

nav {
  background-color: var(--dark-bg-color);
  width: 100%;
  height: 60px;
  display: flex;
  align-items: center;
  justify-content: center;
}

nav .bar {
  display: flex;
  justify-content: center;
  align-items: center;
  flex-shrink: 0;
  height: 5vh;
  gap: 30px;
}

nav a {
  text-decoration: none;
  color: var(--light-text-color);
  padding: 0 20px;
}

@media (width <= 768px) {
  nav .bar {
    gap: 10px;
    width: 100%;
  }

  nav .logo {
    width: 200%;
    padding: 0;
  }

  nav .pictos {
    width: 90%;
  }
}

.header-search .pictos .search-btn {
  display: none;
}

.search-bar {
  opacity: 0;
  visibility: hidden;
  transition: max-height 0.5s ease-out, opacity 0.5s ease-out, visibility 0.5s ease-out;
  overflow: hidden;
  max-height: 0;
  height: auto;
}

.header-search .search-bar,
.search-bar.active {
  visibility: visible;
  opacity: 1;
  max-height: 200px; /* some large value */
}

.header-search form,
.search-bar form {
  display: flex;
  flex-direction: row;
  justify-content: center;
  align-items: center;
  width: 1100px;
  max-width: 100vw;
  margin: 10px auto;
}

main {
  flex-grow: 1;
}

.w1100-main {
  display: flex;
  width: 1100px;
  max-width: 100vw;
  margin: auto;
  margin-top: 3em;
}

.w1100-main h2 {
  margin: 20px;
  font-weight: 700;
  font-size: 30px;
  letter-spacing: normal;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--dark-text-color);
}

h2 {
  font-size: 2.5rem;
  text-align: center;
  font-weight: 600;
  color: var(--dark-text-color);
  margin: 50px;
}

.logo {
    height: 65px;
}

.search-btn img {
    margin-top: 10px;
    width: 30px;
    height: 30px;
}

.learn {
    text-decoration: none;
    background-color: var(--active-color);
    border-radius: 20px;
    color: white;
    padding-left: 15px;
    padding-top: 7px;
    padding-bottom: 7px;
    padding-right: 15px;
}

.learn:hover {
    background-color: var(--active-color);
}

.rent {
    text-decoration: none;
    border: var(--active-color) solid 1.5px;
    border-radius: 20px;
    background-color: white;
    color: var(--active-color);
    padding-left: 15px;
    padding-top: 7px;
    padding-bottom: 7px;
    padding-right: 15px;
}

.rent:hover {
    background-color: var(--active-color);
    color: var(--light-text-color);
}

.square-container {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-around;
    width: 100%;
    margin-left: auto;
    margin-right: auto;
    background-color: var(--light-text-color);
    padding-bottom: 3em;
}

.square {
    width: 500px;
    height: 500px;
    display: flex;
    flex-direction: column;
    align-items: center;
    background-size: cover;
    background-position: center;
    margin-top: 30px;
    margin-bottom: 30px;
    border-radius: 15px;
    box-shadow: -2px 5px 33px 6px rgba(0, 0, 0, 0.35);
    position: relative;
    transition: opacity 0.5s ease-in-out;
}

.square::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(rgba(255, 255, 255), rgba(128, 128, 128));
  opacity: 0.2;
  transition: opacity 0.5s ease-in-out;
}

.square:hover::before {
  opacity: 0;
}

/* .square .round-button {
    position: absolute;
    bottom: 10px;
    right: 10px;
} */

.square p {
    text-align: center;
    color: white;
    padding: 10px;
    margin: 0;
    font-weight: lighter;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 1);
}

.square h2 {
    color: white;
    margin: 0;
    margin-top: 20px;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
}

.container {
    width: 400px;
    height: 400px;
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    display: flex;
    justify-content: center;
    align-items: end;
}

.btn-animated {
    width: 180px;
    height: 60px;
    cursor: pointer;
    background: transparent;
    border: 2px solid var(--active-color);
    background-color: var(--light-text-color);
    outline: none;
    transition: .8s ease-in-out;
    border-radius: 20px;
    position: relative;
}

.btn-animated svg {
    position: absolute;
    left: -2px;
    top: -2px;
    fill: none;
    stroke: #bae6ff;
    stroke-dasharray: 100 480;
    stroke-dashoffset: 100;
    transition: .8s ease-in-out;
    border-radius: 20px;
}

.btn-animated:hover {
    transition: 1s ease-in-out;
    background: var(--active-color);
}

.btn-animated:hover span {
    color : white;
}

.btn-animated:hover svg {
    stroke-dashoffset: -480;
}

.btn-animated span {
    color: white;
    font-size: 1.125rem;
    font-weight: 100;
}

.btn-animated span {
    color: var(--active-color);
    font-size: 18px;
    font-weight: 100;
    transition: .5s ease-in-out;
}

footer {
    margin-top: 3em;
    flex-shrink: 0;
    display: flex;
    justify-content: center;
    align-items: center;
    background-color: var(--dark-bg-color);
    color: var(--light-text-color);
    height: fit-content;
    padding: 2em;
}

.footer-container {
    display: flex;
    flex-direction: column;
    max-width: 100vw;
    width: 400px;
}

.footer-logo {
    display: flex;
    align-self: flex-start;
}

.footer-text p, .footer-legal p {
    margin: 2px 0;
}

.footer-legal {
  margin-top: 8px;
}

.footer-logo img {
    height: 65px;
    margin: 0;
}

footer a {
    color: #eee;
    text-decoration: none;
}

footer a:hover {
    color: var(--active-hover-color);
    text-decoration: underline;
}

form {
  display: flex;
  flex-direction: column;
  gap: 20px;
}
.form-group {
  display: flex;
  flex: auto 1;
  width: 100%;
  min-width: 0;
  border: 1px solid #ced4da;
  border-radius: 0.25rem;
}
.form-group > * {
  line-height: 1.5;
  font-size: 1rem;
  padding: 0.375rem 0.75rem;
  color: #212529;
  background-color: white;
}
.form-group label {
  white-space: nowrap;
  background-color: #e9e9e9;
  border-right: #ced4da;
  margin: 0;
}
.form-group input {
  display: block;
  width: 100%;
  border: none;
  border-radius: 0.25rem;
  transition: border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
}
.form-group input:focus {
  color: var(--dark-text-color);
  background-color: white;
  border-color: var(--active-color);
  outline: 0;
  box-shadow: 0 0 0 0.25rem rgba(6, 57, 132, 0.25);
}
form input[type=submit] {
  display: block;
  font-size: 0.9375rem;
  width: fit-content;
  margin : 0 auto;
  background-color: #0071e3;
  color: white;
  border: none;
  border-radius: 20px;
  padding: 10px;
  cursor: pointer;
}
form input[type="submit"]:disabled {
  background-color: #ccc;
  color: #999;
  cursor: inherit;
}

.car-thumbnail {
  width: 260px;
  max-width: 100vw;
  background-size: cover;
  background-position: center;
  border-radius: 10px;
  box-shadow: -2px 5px 33px 6px rgba(0, 0, 0, 0.35);
}
