@import url("https://fonts.googleapis.com/css2?family=Red+Hat+Display:wght@500;700;900&display=swap");

:root {
  --bg-color:    hsl(225, 100%, 94%);
  --light-bg:    hsl(225, 100%, 98%);
  --white:       hsl(0, 0%, 100%);
  --dark-blue:   hsl(223, 47%, 23%);
  --muted-blue:  hsl(224, 23%, 55%);
  --purple:      hsl(245, 75%, 52%);
  --purple-hover:hsl(245, 75%, 60%);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  background-color: var(--bg-color);
  font-family: "Red Hat Display", sans-serif;
  font-size: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  margin: 0;
}

.bg-pattern {
  width: 100vw;
  height: 50vh;
  background-image: url(images/pattern-background-desktop.svg);
  background-size: cover;
  background-repeat: no-repeat;
  position: fixed;
  top: 0;
  left: 0;
  z-index: -1;
}

@media (max-width: 768px) {
  .bg-pattern {
    background-image: url(images/pattern-background-mobile.svg);
  }
}

img {
  max-width: 100%;
}

.card {
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
  border-radius: 10px;
  overflow: hidden;
  width: 400px;
  max-width: 90vw;
}

.card-header {
  height: 200px;
}

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

.card-content {
  background-color: var(--white);
  padding: 30px;
}

.card-title {
  margin: 0;
  margin-bottom: 30px;
  color: var(--dark-blue);
  text-align: center;
  font-size: 25px;
  font-weight: 900;
}

.card-excerpt {
  color: var(--muted-blue);
  text-align: center;
  line-height: 1.5rem;
  margin: 10px 0 20px;
}

.plan-box {
  background-color: var(--light-bg);
  border: 0;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: space-around;
  height: 80px;
  width: 100%;
  padding: 10px;
}

.profile-img {
  border-radius: 50%;
  overflow: hidden;
  height: 40px;
  width: 40px;
}

.plan-info {
  display: flex;
  flex-direction: column;
  flex-basis: 50%;
}

.plan-info .plan-price {
  color: var(--muted-blue);
  margin-top: 5px;
  font-size: 16px;
}

.btn {
  background-color: var(--purple);
  border: 0;
  border-radius: 10px;
  color: var(--white);
  box-shadow: 0 5px 15px var(--purple);
  font-size: 16px;
  height: 40px;
  width: 100%;
  margin: 30px 0;
  cursor: pointer;
  transition: background-color 0.3s ease, box-shadow 0.3s ease;
}

.btn:hover {
  background-color: var(--purple-hover);
  box-shadow: 0 8px 20px var(--purple);
}

.btn:active {
  transform: scale(0.98);
}

.btn:focus-visible {
  outline: 3px solid var(--dark-blue);
  outline-offset: 2px;
}

.cancel {
  text-align: center;
  margin: 0;
}

.cancel a {
  text-decoration: none;
  color: var(--muted-blue);
  font-weight: bold;
  cursor: pointer;
  margin-bottom: 10px;
  transition: color 0.2s ease;
  display: inline-block;
}

.cancel a:hover {
  color: var(--dark-blue);
}

.change a {
  color: var(--purple);
  text-decoration: underline;
  font-weight: bold;
  transition: color 0.2s ease, text-decoration 0.2s ease;
}

.change a:hover {
  color: var(--purple-hover);
  text-decoration: none;
}

.plan {
  color: var(--dark-blue);
  font-weight: 900;
}

@media (max-width: 375px) {
  .card {
    width: 350px;
  }

  .card-content {
    padding: 25px;
  }

  .card-title {
    font-size: 22px;
    margin-bottom: 20px;
  }

  .card-excerpt {
    font-size: 15px;
    line-height: 1.4rem;
  }

  .plan-box {
    height: 70px;
    padding: 8px;
  }

  .btn {
    height: 45px;
    margin: 25px 0;
  }
}
