.card-box-interface {
  background-image: url("/assets/images/StarField-a6f000f7.jpg");
  background-size: cover;
  min-height: 100vh;
  padding: 20px;
}

.card-box-header {
  text-align: center;
  color: white;
  margin-bottom: 30px;

  h1 {
    font-size: 2.5em;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.8);
    margin-bottom: 20px;
  }
}

.card-box-selectors {
  background: rgba(0, 0, 0, 0.7);
  padding: 20px;
  border-radius: 10px;
  max-width: 900px;
  margin: 0 auto 40px;

  .selector-row {
    display: flex;
    gap: 15px;
    align-items: flex-end;
    flex-wrap: wrap;
    justify-content: center;
  }

  .selector-group {
    display: flex;
    flex-direction: column;

    label {
      color: white;
      font-weight: bold;
      margin-bottom: 5px;
      font-size: 12px;
      text-transform: uppercase;
    }

    select {
      padding: 8px 12px;
      border-radius: 5px;
      border: 2px solid #17a2b8;
      background: white;
      font-size: 14px;
      min-width: 140px;
    }
  }

  .load-cards-btn {
    padding: 10px 25px;
    background: #28a745;
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 14px;
    font-weight: bold;
    transition: background 0.3s;

    &:hover {
      background: #218838;
    }
  }
}

.card-box-stage {
  width: 100%;
  height: 600px;
  perspective: 1200px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 30px;
}

.card-box-3d {
  position: relative;
  width: 300px;
  height: 450px;
  transform-style: preserve-3d;
  transition: transform 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

.card-box-card {
  position: absolute;
  width: 300px;
  height: 450px;
  transform-style: preserve-3d;
  transition: all 0.5s ease;
  backface-visibility: hidden;

  &.expanded {
    transform: none !important;
    width: 100%;
    max-width: 600px;
    height: auto;
    min-height: 600px;
    position: relative;
  }
}

.card-box-card-front {
  position: absolute;
  width: 100%;
  height: 100%;
  backface-visibility: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
}

.card-box-backing {
  width: 100%;
  height: 100%;
  background: white;
  border-radius: 15px;
  box-shadow: 0 8px 30px rgba(0,0,0,0.4);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.card-box-card-back-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 15px;
}

.card-box-card-content {
  display: none;
  width: 100%;
  transform: rotateY(0deg);

  .pane_guidance {
    width: 100%;
    max-width: 500px;
    margin: 0 auto;
    height: auto;
  }
}

.card-box-empty {
  text-align: center;
  color: white;
  font-size: 1.5em;
  text-shadow: 2px 2px 4px rgba(0,0,0,0.8);
  padding: 50px;
}

.card-box-controls {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 30px;
  margin-bottom: 20px;
}

.card-box-nav-btn {
  padding: 12px 30px;
  background: #17a2b8;
  color: white;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  font-size: 16px;
  font-weight: bold;
  transition: all 0.3s;
  box-shadow: 0 4px 10px rgba(0,0,0,0.3);

  &:hover {
    background: #138496;
    transform: translateY(-2px);
    box-shadow: 0 6px 15px rgba(0,0,0,0.4);
  }

  &:active {
    transform: translateY(0);
  }
}

.card-box-indicator {
  color: white;
  font-size: 1.5em;
  font-weight: bold;
  text-shadow: 2px 2px 4px rgba(0,0,0,0.8);
  min-width: 100px;
  text-align: center;
}

.card-box-actions {
  display: flex;
  justify-content: center;
  margin-bottom: 30px;
}

.card-box-expand-btn {
  padding: 12px 35px;
  background: #6f42c1;
  color: white;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  font-size: 16px;
  font-weight: bold;
  transition: all 0.3s;
  box-shadow: 0 4px 10px rgba(0,0,0,0.3);

  &:hover {
    background: #5a32a3;
    transform: translateY(-2px);
    box-shadow: 0 6px 15px rgba(0,0,0,0.4);
  }
}

@media (max-width: 768px) {
  .card-box-stage {
    height: 500px;
  }

  .card-box-3d {
    width: 250px;
    height: 375px;
  }

  .card-box-card {
    width: 250px;
    height: 375px;
  }

  .card-box-selectors .selector-row {
    flex-direction: column;
    align-items: stretch;

    .selector-group select {
      width: 100%;
    }
  }
}
