* {
  box-sizing: border-box;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: #f6f6f7;
  color: #202223;
  margin: 0;
  padding: 16px;
  overflow-x: hidden;
}

/* Layout */
.container {
  max-width: 1170px;
  margin: 0 auto;
  padding: 0 12px;
}

/* Logo */
img {
  width: 200px;
  max-width: 100%;
  height: auto;
  margin-bottom: 20px;
}

/* Cards */
.card {
  background: #ffffff;
  border: 1px solid #e1e3e5;
  border-radius: 12px;
  padding: 20px;
  margin-bottom: 20px;
}

/* Input */
input {
  width: 100%;
  max-width: 100%;
  padding: 10px 12px;
  border-radius: 8px;
  border: 1px solid #c9cccf;
  font-size: 14px;
  margin-bottom: 12px;
}

input:focus {
  outline: none;
  border-color: #008060;
}

/* Buttons */
.button-row {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

button {
  padding: 8px 14px;
  border-radius: 8px;
  border: 1px solid #c9cccf;
  background: #fff;
  cursor: pointer;
  font-size: 14px;
}

.btn-primary {
  background: #008060;
  color: white;
  border: none;
}

.btn-danger {
  background: #d72c0d;
  color: white;
  border: none;
}

.btn-secondary {
  background: #f6f6f7;
}

/* Progress */
#progress {
  margin-top: 10px;
  font-size: 13px;
  color: #6d7175;
}

/* Split layout */
.split-layout {
  display: grid;
  grid-template-columns: minmax(300px, 380px) 1fr;
  gap: 20px;
  align-items: start;
}

/* Cube area */
.cube-wrapper {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

.view-toggle {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 12px;
}

canvas {
  max-width: 100%;
  height: auto;
  background: #ffffff;
  border: none;
  padding-top: 30px;
  border-radius: 8px;
}

#cube3d {
  display: none;
  justify-content: center;
  max-width: 100%;
  overflow: hidden;
}

/* Output */
#output {
  font-size: 14px;
  line-height: 1.6;
  min-height: 300px;
  word-break: break-word;
}

#output strong {
  font-weight: 600;
}

hr {
  border: none;
  border-top: 1px solid #e1e3e5;
  margin: 12px 0;
}

/* Mobile */
@media (max-width: 900px) {
  .split-layout {
    grid-template-columns: 1fr;
  }

  .card {
    padding: 16px;
  }
}

@media (max-width: 500px) {
  body {
    padding: 10px;
  }

  .container {
    padding: 0;
  }

  .button-row button {
    flex: 1 1 100%;
  }

  .view-toggle button {
    flex: 1 1 auto;
  }

  img {
    width: 160px;
  }
}


#orientationSelector {
  width: 100%;
  max-width: 100%;
  padding: 10px 12px;
  border-radius: 8px;
  border: 1px solid #c9cccf;
  font-size: 14px;
  margin-bottom: 12px;
  background: #ffffff;
  color: #202223;
  appearance: none;
  cursor: pointer;
}

/* Focus state (same as input) */
#orientationSelector:focus {
  outline: none;
  border-color: #008060;
}

.alert {
  display: flex;
  align-items: center; /* 🔥 fix */
  gap: 10px;

  padding: 12px 14px;
  margin-bottom: 14px;

  border-radius: 10px;
  border: 1px solid #cce3ff;
  border-left: 4px solid #007aff;

  background: #f4f8ff;
  color: #1a3c6e;

  font-size: 13px;
  line-height: 1.5;
}

.alert-icon {
  font-size: 15px;
  color: #007aff;
  line-height: 1; /* 🔥 prevents weird vertical shift */
}

.alert-yellow {
  display: flex;
  align-items: center;
  gap: 10px;

  padding: 12px 14px;
  margin-bottom: 14px;

  border-radius: 10px;
  border: 1px solid #fde68a;
  border-left: 4px solid #f59e0b; /* 🔥 yellow accent */

  background: #fffbeb;
  color: #78350f;

  font-size: 13px;
  line-height: 1.5;
}

.alert-icon-yellow {
  font-size: 15px;
  color: #f59e0b;
  line-height: 1;
}
