* {
  box-sizing: border-box;
}
img {
  max-width: 100%;
}
:root {
  --bg-message: oklch(0.7 0.1 229);
  --message-bmargin: 1rem;
  --bg-communication: oklch(0.7 0.0653 170.39);
  --default-radius: 1rem;
  --page-bg-color: #fcfcfc;
  --page-text-color: #111;
  --link-color: #111;
}

html,
body {
  font-family: 'Inconsolata', monospace;
  margin: 0;
  padding: 0;
  color: var(--page-text-color);
  background-color: var(--page-bg-color);
  height: 100%;
}

body.dark-theme {
  --page-bg-color: #000;
  --page-text-color: #fff;
  --link-color: #fff;
}

a {
  color: var(--link-color);
}

menu {
  margin: 0;
  padding: 0;
  padding-top: 1rem;
  display: flex;
  .logo {
    max-width: 8rem;
  }
  ul {
    margin: 0;
    padding: 0;
    margin-left: auto;
    list-style: none;
    display: flex;

    li {
      padding-left: 2rem;
    }
  }
}

.message {
  background-color: var(--bg-message);
  margin-bottom: var(--message-bmargin);
  padding: var(--default-radius);
  border-radius: 1rem;
  color: #fff;
  font-family: 'Quantico', sans-serif;
}

.movement {
  display: flex;
  justify-content: center;
  align-items: center;
  margin: 0;
  background: #f0f0f0;
  width: 20rem;
}

.player_hello {
  font-family: 'Quantico', sans-serif;
}
#content {
  max-width: 50rem;
  margin: 0 auto;
}
.result_message {
  background-color: var(--bg-message);
  display: flex;

  font-family: 'Quantico', sans-serif;

  .image {
    max-width: 200px;
    margin-right: 1rem;
  }
}

.controller {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
}
.rename_fleet {
  display: flex;
  .image {
    max-width: 300px;
    margin-right: 1rem;
  }
}
.typewriter {
  overflow: hidden; /* Ensures the content is not revealed until the animation */
  white-space: nowrap; /* Keeps the content on a single line */
  margin: 0 auto; /* Gives that scrolling effect as the typing happens */
  letter-spacing: 0.15em; /* Adjust as needed */
  animation: typing 1.5s steps(40, end);
}

@keyframes typing {
  from {
    width: 0;
  }
  to {
    width: 100%;
  }
}
@keyframes blink-caret {
  from,
  to {
    border-color: transparent;
  }
  50% {
    border-color: orange;
  }
}

.form {
  max-width: 500px;

  input {
    display: block;
    margin-bottom: 1rem;
    padding: 0.3rem;
  }
}
.general_status {
  .ship_type {
    margin-bottom: 1rem;
    img {
      width: 14px;
    }
    .ships {
      display: none;
      .ship_hp {
        margin-bottom: 0.4rem;
      }
    }
    .ships.active {
      display: block;
    }
  }
}
.horizontal {
  display: flex;
  gap: 10px;
}

.credit_box {
  display: flex;
  .image {
    max-width: 100px;
    margin-right: 2rem;
  }
}
.choice_box {
  font-family: 'Quantico', sans-serif;
  background-color: var(--bg-communication);
  padding: 1rem;
  border-radius: var(--default-radius);
  align-items: center;
  display: flex;
  .image {
    max-width: 200px;
    margin-right: 1rem;
  }
}
.shiplist {
  display: inline-block;

  .ship {
    display: flex;
    max-width: 600px;
    flex-wrap: wrap;
    margin-bottom: 1rem;

    .header {
      font-weight: bold;
    }

    .name,
    .image,
    .price,
    .buy_qty,
    .qty {
      margin-right: 1rem;
      width: 50px;
    }

    input[type='text'] {
      width: 50px;
    }

    .image {
      width: 100px;
      margin-right: 1rem;
    }
  }

  button {
    margin-left: auto;
  }
}
button {
  width: 60px;
  height: 60px;
  font-size: 24px;
  border: none;
  border-radius: 50%;
  background: #333;
  color: white;
  cursor: pointer;
  display: flex;
  justify-content: center;
  align-items: center;
  transition: background 0.2s;
}

button:hover {
  background: #555;
}

.center {
  background: #a00;
}

.center:hover {
  background: #c00;
}
