/* 
 * Spacing
 *  8, 16, 24, 32,
 * 40, 48, 56, 64,
 * 72, 80, 88, 96
 *
 */

/* Base styles */

body {
  --primary-bg-color: #aa55ee;
  --details-summary-bg-color: #f0f0f0; /*rgb(176, 85, 255, 25%);*/
  --details-bg-color: #fafafa; /*rgb(176, 85, 255, 10%);*/
  --fake-btn-color: #f0f0f0;
  --fake-btn-hover-color: #f5f5f5;
  --fake-btn-active-color: #f8f8f8;
  --link-image-size: 64px;
  --text-primary: #000302;
  --background: #fafafa;
  --text-footer: #666;
  --text-footer-link: #666;

  font-family: sans-serif;
  font-size: 1rem;
  color: var(--text-primary); /* Off-Black */
  background: var(--background); /* Off-White */
}

a {
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

p {
  box-sizing: border-box;
  margin: 0;
}

section {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

header {
  display: flex;
  flex-direction: column;
  align-items: center;
  background: var(--primary-bg-color);
}

main {
  display: flex;
  flex-direction: column;
  gap: 40px;
  margin: 0 0.75rem;
}

h1 {
  font-size: 2rem;
  color: #ffffdd;
}

h2 {
  font-size: 1.25rem;
  margin-bottom: 0.5rem;
  margin-bottom: 0.5rem;
}

ul {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  margin: 1rem 0;
}

details {
  background: var(--details-bg-color);
  border-radius: 16px;
  box-shadow: rgba(0, 0, 0, 0.24) 0px 3px 8px;
}

details summary {
  padding: 0.5rem 1rem;
  border-radius: 16px;

  font-size: 1rem;
  font-weight: 600;
  background: var(--details-summary-bg-color);
  cursor: pointer;
}

details[open] summary {
  border-radius: 16px 16px 0 0;
}

footer {
  margin: 2rem;
  color: var(--text-footer);
  text-align: center;
}

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

/* Specializations */

.example-games {
  margin-top: 1rem;
}

.example-games > div {
  padding-left: 0.5rem;
}

.game-list div {
  display: flex;
  justify-content: space-between;
  padding-right: 1rem;
}

.links-to-maps {
  display: flex;
  justify-content: space-around;
  gap: 2rem;
}

.fake-btn {
  display: flex;
  box-sizing: border-box;
  background: var(--fake-btn-color);
  box-shadow: rgba(0, 0, 0, 0.24) 0px 3px 8px;
  border-radius: 32px;

  font-size: 1rem;
  text-align: center;
}

.fake-btn:hover {
  background: var(--fake-btn-hover-color);
}

.fake-btn:active {
  box-shadow: none;
}

.fake-btn:active {
  background: var(--fake-btn-active-color);
}


p:has(.fake-btn) {
  margin-top: 1.5rem;
}

.map-link {
  padding: 0.5rem;

  flex-direction: column;
  align-items: center;
  gap: 8px;

  background: var(--fake-btn-color);
  border-radius: 32px;
}

.map-link img {
  padding: 8px;
  width: var(--link-image-size);
  height: var(--link-image-size);
}

.calendar-link {
  display: flex;
  justify-content: space-around;
}

.calendar-download {
  align-items: center;
  gap: 16px;
  padding: 1rem 2rem;
  padding-left: 4rem;
}

.calendar-download img {
  width: var(--link-image-size);
  height: var(--link-image-size);
}

.send-mail {
  align-items: center;
  gap: 16px;
  padding: 1rem;
}

.send-mail img {
  width: calc(0.9 * var(--link-image-size));
  height: calc(0.9 * var(--link-image-size));
  padding-left: 1rem;
}

.info-box-close {
  opacity: 0;
  background-color: orangered;
  position: absolute;
  top: -30px;
  left: -30px;
}

.info-box {
  gap: 0;
  position: relative;
}
.info-box-heading {
  background-color: #ffd43b;
  padding: 0.5rem 0.4rem;
  margin-bottom: 0;
  border-top-left-radius: 16px;
  border-top-right-radius: 16px;
}
.info-box-content {
  margin-top: 0;
  border: 3px solid #ffd43b;
  padding: 0.5rem;
  border-bottom-left-radius: 16px;
  border-bottom-right-radius: 16px;
}
.info-box-close-btn {
  position: absolute;
  top: 0;
  right: 0.3rem;
  transform: translateY(calc(100% - 0.3rem));
  padding: 0.3rem 0.5rem;
  cursor: pointer;
}

.info-box-close-btn:hover {
  transform: translateY(calc(100% - 0.3rem - 1px));
}

.info-box-close:focus ~ .info-box .info-box-close-btn,
.info-box-close-btn:hover {
  text-shadow: 0.1rem 0.1rem 2px rgba(0, 0, 0, 10%);
}

.info-box-close:focus ~ .info-box .info-box-close-btn,
.info-box-close-btn:active
{
  border: 2px solid black;
  transform: translateY(calc(100% - 0.5rem));
  border-radius: 16px;
}

.info-box-close:checked ~ .info-box {
  opacity: 0;
  position: absolute;
  top: -1000px;
  left: -1000px;
  background-color: orangered;
}

/* Responsive Variations */

@media(width >= 500px) {
  main {
    margin: 0 2rem;
  }
}
@media(width >= 600px) {
  :root {
    font-size: 1.25rem;
  }
  main {
    margin: 0 3.5rem;
  }

  ul {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    margin: 1.5rem 0;
  }
}

@media(width >= 800px) {
  :root {
    font-size: 1.5rem;
  }
  body {
    --link-image-size: 5rem;
  }
  .map-link {
    padding: 1rem;
  }

  .calendar-download {
    padding: 1.5rem;
  }

  .send-mail {
    justify-content: center;
  }
  .send-mail img {
    padding: 1.5rem;
  }
}

@media(width >= 900px) {
  main {
    max-width: 800px;
    margin: 0 auto;
  }
}

/* Dark Variation */
@media (prefers-color-scheme: dark) {
  --background: #333;
  --primary-bg-color: #aa55ee;
  --details-summary-bg-color: #f0f0f0; /*rgb(176, 85, 255, 25%);*/
  --details-bg-color: #fafafa; /*rgb(176, 85, 255, 10%);*/
  --fake-btn-color: #f0f0f0;
  --fake-btn-hover-color: #f5f5f5;
  --fake-btn-active-color: #f8f8f8;
  --link-image-size: 64px;
  --text-primary: #000302;
  --background: #fafafa;
  --text-footer: #666;
  --text-footer-link: #666;
}
