/* variables */
:root {
  --bg-color: #e5e5f7;
}

/* CSS reset */

* {
  margin: 0;
  padding: 0;
}

*,
*::after,
*::before {
  box-sizing: border-box;
}

a {
  font-family: inherit;
  display: inline-block;
}

button {
  border: 0;
  cursor: pointer;
}

ul,
ol {
  list-style: none;
}

body {
  font-family: monospace;
  line-height: 1.4;
  color: #363535;
}
/* CSS reset END */

.container {
  min-height: 100vh;
  min-width: 100vw;
  opacity: 1;
  background-image: radial-gradient(#000 0.75px, var(--bg-color) 0.75px);
  background-size: 15px 15px;
  display: flex;
  justify-content: center;
  align-items: center;
  position: relative;
}

@keyframes party {
  0% {
    fill: #00008b;
  }
  50% {
    fill: #006400;
  }

  75% {
    fill: #363535;
  }

  100% {
    fill: #8b0000;
  }
}

.toggle {
  align-self: center;
  position: absolute;
  top: 2rem;
  display: flex;
  gap: 0.5rem;
}

.toggle__heading {
  font-size: 1.3rem;
  text-transform: capitalize;
  letter-spacing: 0.01rem;
  font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
}

.toggle__label {
  position: relative;
  width: 3rem;
  height: 1.5rem;
  border-radius: 3rem;
  background-color: #363535;
  cursor: pointer;
}

.toggle__label::after {
  content: "";
  position: absolute;
  margin-block-start: 0.22rem;
  margin-inline-start: 0.27rem;
  background-color: #e5e5f7;
  border-radius: 50%;
  width: 1rem;
  height: 1rem;
  transition: 0.3s;
}

.toggle__input {
  display: none;
}

.toggle__input:checked + .toggle__label {
  background-color: #000000;
}

.toggle__input:checked + .toggle__label::after {
  transform: translateX(1.45rem);
  background-color: #e0e0e0;
}

html:has(.toggle__input:checked) {
  --bg-color: #e0e0e0;
}

.card {
  display: flex;
  flex-direction: column;
  border-radius: 1rem;
  min-width: 28rem;
  /* overflow: hidden; */
  background-color: #eeeef8;
  box-shadow: 0 2px 0.5rem rgba(0, 0, 0, 0.1);
}

.top {
  position: relative;
  height: 7rem;
  opacity: 0.8;
  background-size: 23px 23px;
  background-image: repeating-linear-gradient(
    45deg,
    #000000 0,
    #000000 2.3000000000000003px,
    #e5e5f7 0,
    #e5e5f7 50%
  );
}

.container:has(.toggle__input:checked) .top__lights {
  opacity: 1;
  visibility: visible;
}

.top__lights {
  opacity: 0;
  visibility: hidden;
  transition: 0.3s;
  position: absolute;
  width: 14rem;
  height: 14rem;
  top: -4.3rem;
  left: -5rem;
  transform: rotate(-45deg);
}

.green-flag,
.red-flag {
  animation: party 0.6s alternate infinite;
}

.blue-flag {
  animation: party 0.6s alternate-reverse infinite;
}

.middle {
  justify-items: center;
  margin-block-start: -4rem;
}

.img-box {
  display: flex;
  position: relative;
  justify-content: center;
}

.personal-img {
  border-radius: 100%;
  margin-block-start: -0.8rem;
  width: 7rem;
  z-index: 1;
}

.img-box::before {
  border: solid 0.2rem #837c95;
  border-radius: 100%;
  content: "";
  position: absolute;
  background-color: #363535;
  width: 8rem;
  height: 100%;
}

.name {
  font-size: 1.4rem;
  margin-block: 0.5rem 0;
}

.title {
  font-size: 1rem;
}

.bottom {
  display: flex;
  margin-block-start: 1.7rem;
  border-top: solid 0.13rem #837c95;
}

.column {
  flex: 1;
  padding: 1.4rem 1.5rem;
  text-align: center;
}

.column:nth-child(2) {
  border-right: solid 0.13rem #837c95;
  border-left: solid 0.13rem #837c95;
}

.logo-list {
  display: flex;
  gap: 0.5rem;
  justify-content: center;
  margin-block-end: 0.1rem;
}

.logo {
  width: 1.4rem;
  height: 1.4rem;
}

@media (max-width: 500px) {
  html {
    font-size: 10.5px;
  }

  .container:has(.toggle__input:checked) .top__lights {
    width: 10rem;
    height: 10rem;
    top: -3rem;
    left: -2.6rem;
  }
}
