* {
  box-sizing: border-box;
}

html:has(.profile-card-example) {
  height: 100vh;
}

body:has(.profile-card-example) {
  display: flex;
  justify-content: center;
  align-items: center;
  height: 100vh;
  font-family: open sans;
  color: #10214e;
}

article.profile-card-example {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-end;
  width: 50vw;
  max-width: 25em;
  min-width: 20em;
  border-radius: 1rem;
  background: rgb(0,239,255);
  background: linear-gradient(0deg, rgba(0,239,255,1) 40%, #4e54c8 100%);
  box-shadow: 0 0 20px 20px rgba(0,0,0,.1);
  transition: .25s;
}

header.profile-card-example-header {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  justify-content: flex-end;

  /* Je kunt selectors nesten! */
  h1 {
    margin: 2rem 0 1rem;
    color: rgba(0,239,255,1);
  }

}

button.profile-card-example-button {
  position: absolute;
  right: 1rem;
  top: 1rem;
  width: 2.5rem;
  height: 2.5rem;
  padding: .25rem;
  border: none;
  border-radius: 50%;
  background: rgba(0,239,255,1);
  transform: scale(.8);
  transition: .25s;
}
button.profile-card-example-button:focus {
  outline: none;
  background: #202592;
}
button.profile-card-example-button svg {
  position: absolute;
  top: calc(1.25rem - 12px);
  left: calc(1.25rem - 12px);
  stroke: #4e54c8;
  transition-delay: .25s;
}
button.profile-card-example-button:focus svg {
  stroke: rgba(0,239,255,1);
}
button.profile-card-example-button svg:nth-of-type(2) {
  opacity: 0;
  transition-delay: 0ms;
}

.profile-card-example-img {
  position: relative;
  top: 2rem;
  width: 10em;
  height: auto;
  border: 5px solid #fff;
  border-radius: 10em;
  box-shadow: 0 0 2px 2px rgba(0,0,0,.2);
  transition: .25s .15s;
}

.profile-card-example-dl {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  grid-template-areas:
    "html-dd css-dd js-dd"
    "html-dt css-dt js-dt"
    ;
  justify-items: center;
  align-items: start;
  width: 100%;
  margin-top: -3rem;
  margin-bottom: 0;
  padding: 5rem 0 3rem;
  text-align: center;
  background: rgb(255,255,255);

  dt {
    margin-top: .25rem;
    padding-top: .25rem;
    border-top: 1px solid rgba(0,0,0,0.3);
    font-weight: bold;
    &:nth-of-type(1) {
      grid-area: html-dt;
    }
    &:nth-of-type(2) {
      grid-area: css-dt;
      transform: translateY(1rem);
    }
    &:nth-of-type(3) {
      grid-area: js-dt;
    }
  }

  dd {
    margin: 0;
    padding-left: .3rem;
    transition: .25s .3s;
    &:nth-of-type(2) {
      transform: translateY(1rem);
    }
  }
}


.profile-card-example p {
  margin: 0;
}

.profile-card-example > p {
  width: 100%;
  margin-top: 0;
  padding: 3rem 2rem;
  border-radius: ;
  text-align: center;
  background: rgba(255,255,255, 0.5);
}

/* Deze styles zijn van toepassing als je op de knop klikt */
body.is-expanded {
  font-size: 1.15em;
}

body.is-expanded .profile-card-example {
  width: 60vw;
  max-width: 60vw;
}

body.is-expanded .profile-card-example-button svg:first-of-type {
  opacity: 0;
  transition-delay: 0ms;
}

body.is-expanded .profile-card-example-button svg:nth-of-type(2) {
  opacity: 1;
  transition-delay: .25s;
}

body.is-expanded .profile-card-example-dl dd {
  font-size: 1.75em;
}

body.is-expanded .profile-card-example-img {
  width: 15em;
}
