* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html, body {
  height: 100vh;
  overflow: hidden;
  position: fixed;
  width: 100%;
}

body {
  font-family: 'Arial', sans-serif;
  background: #E7DECF;
}

/* Mobile-friendly container */
.app-container {
  position: relative;
  max-width: 460px;
  margin: 0 auto;
  height: 100vh;
  background: #fff;
  box-shadow: 0 0 30px rgba(0, 0, 0, 0.1);
  overflow: hidden;
}

.screen {
  display: none;
  width: 100%;
  height: 100vh;
  background-size: contain;
  background-position: top center;
  background-repeat: no-repeat;
  position: relative;
  overflow: hidden;
}

.screen.active {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
}

/* Splash and Intro Screens */
.screen.clickable {
  cursor: pointer;
}

.screen img {
  width: 100%;
  max-height: 100vh;
  height: auto;
  display: block;
  object-fit: contain;
}

/* Mobile responsive */
@media (max-width: 480px) {
  .app-container {
    max-width: 100%;
    box-shadow: none;
  }

  .question-title {
    font-size: 24px;
  }

  .question-container {
    padding: 30px 15px;
  }

  .options-grid {
    gap: 10px;
  }

  .option-btn {
    padding: 14px 16px;
    font-size: 14px;
  }

  .text-input {
    padding: 14px 18px;
    font-size: 15px;
  }
}

/* Question Screens */
.question-container {
  width: 95%;
  max-width: 520px;
  padding: 40px 5px;
  margin-top: 25%;
  text-align: center;
  z-index: 10;
  position: relative;
}

.logo {
  position: absolute;
  top: 20px;
  left: 20px;
  width: 80px;
}

.fruit-icon {
  position: absolute;
  width: 60px;
}

.icon-1 { top: 20%; right: 10%; }
.icon-2 { bottom: 30%; left: 5%; }
.icon-3 { bottom: 15%; right: 8%; }

.question-title {
  font-family: 'Baloo 2', cursive;
  font-size: 32px;
  font-weight: 800;
  color: #FFED00;
  margin-bottom: 30px;
  line-height: 1.3;
}

/* Input Styles */
.input-group {
  margin: 20px 0;
}

.input-row {
  display: flex;
  gap: 12px;
}

.input-row-center {
  display: flex;
  justify-content: center;
  margin-bottom: 12px;
}

.text-input.half-width {
  width: calc(50% - 6px);
  flex: none;
}

#name.half-width {
  width: 60%;
}

.text-input {
  width: 100%;
  background: #FFFFFF;
  border-top: 4px solid #f5d20a;
  border-right: 3px solid #f5d20a;
  border-bottom: 2px solid #f5d20a;
  border-left: 3px solid #f5d20a;
  border-radius: 20px;
  padding: 14px 16px;
  font-family: 'Baloo 2', cursive;
  font-size: 18px;
  font-weight: 700;
  color: #FF6A1A;
  margin-bottom: 12px;
  outline: none;
  text-align: center;
}

.text-input::placeholder {
  color: #FF6A1A;
  opacity: 1;
  text-align: center;
}

.text-input:-webkit-autofill,
.text-input:-webkit-autofill:hover,
.text-input:-webkit-autofill:focus,
.text-input:-webkit-autofill:active {
  -webkit-text-fill-color: #FF6A1A !important;
  -webkit-box-shadow: 0 0 0 30px white inset !important;
  box-shadow: 0 0 0 30px white inset !important;
}

/* Button Options */
.options-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin: 20px 0;
}

.option-btn {
  background: #FFFFFF;
  border-top: 4px solid #FFED00;
  border-right: 3px solid #FFED00;
  border-bottom: 2px solid #FFED00;
  border-left: 3px solid #FFED00;
  border-radius: 20px;
  padding: 16px 20px;
  font-family: 'Baloo 2', cursive;
  font-size: 20px;
  font-weight: 700;
  color: #FF6A1A;
  cursor: pointer;
  transition: all 0.3s;
  line-height: 15px;
}

.option-btn:hover {
  transform: scale(1.05);
}

.option-btn.selected {
  background: #FFED00;
  transform: scale(1.05);
}

/* Next Button */
.next-btn {
  background: #FFED00;
  color: #FF6A1A;
  border: none;
  border-radius: 25px;
  padding: 5px 60px;
  font-family: 'Baloo 2', cursive;
  font-size: 22px;
  font-weight: 800;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(0,0,0,0.3);
  transition: all 0.3s;
  margin-top: 15px;
  text-transform: uppercase;
}

.next-btn:hover {
  transform: scale(1.05);
}

.next-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.next-btn.green-bg {
  background: #FF6A1A;
  color: #FFED00;
}

/* Background colors for screens */
#screen-1 {
  background-color: #ff5f07;
}

#screen-2 {
  background-color: #00cb45;
}

#screen-3 {
  background-color: #ff5f07;
  background-image: url('images/backgrounds/3rd screen background.webp');
}

#screen-4 {
  background-color: #00cb45;
  background-image: url('images/backgrounds/4th screen background.webp');
}

#screen-5 {
  background-color: #ff5f07;
  background-image: url('images/backgrounds/5th screen background.webp');
}

#screen-6 {
  background-color: #00cb45;
  background-image: url('images/backgrounds/6th screen background.webp');
}

#screen-7 {
  background-color: #ff5f07;
  background-image: url('images/backgrounds/7th screen background.webp');
}

#screen-8 {
  background-color: #00cb45;
  background-image: url('images/backgrounds/8th screen background.webp');
}

/* Screen-specific color overrides */
#screen-3 .question-title {
  color: #ffff00;
}

#screen-3 .next-btn {
  background: #ffff00;
}

#screen-4 .question-title {
  font-size: 25px;
  margin-bottom: 25px;
}

#screen-4 .options-grid {
  grid-template-columns: auto auto;
  justify-content: center;
  column-gap: 4px;
}

#screen-4 .option-btn {
  border-top: 4px solid #f5d20a;
  border-right: 3px solid #f5d20a;
  border-bottom: 2px solid #f5d20a;
  border-left: 3px solid #f5d20a;
  padding: 16px 12px;
  font-size: 16px;
  width: 166px;
  max-width: 166px;
}

#screen-5 .question-title {
  font-size: 25px;
  margin-bottom: 25px;
}

#screen-5 .options-grid {
  grid-template-columns: auto auto;
  justify-content: center;
  column-gap: 4px;
}

#screen-5 .option-btn {
  padding: 16px 12px;
  font-size: 16px;
  width: 166px;
  max-width: 166px;
}

#screen-6 .question-container {
  width: 63%;
}

#screen-7 .question-container {
  width: 85%;
  padding: 40px 20px;
}

#screen-7 .question-title {
  font-size: 27px;
}

#screen-7 .text-input {
  width: 66%;
}

#screen-8 .question-title {
  font-size: 25px;
  margin-bottom: 25px;
}

#screen-8 .options-grid {
  grid-template-columns: auto auto;
  justify-content: center;
  column-gap: 4px;
}

#screen-8 .option-btn {
  padding: 16px 12px;
  font-size: 16px;
  width: 166px;
  max-width: 166px;
}

/* Product bottles at bottom */
.product-image {
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 80%;
  max-width: 400px;
  pointer-events: none;
}

/* Result Screen */
.result-screen {
  background: linear-gradient(135deg, #00cb45 0%, #ff5f07 100%);
  position: relative;
  overflow-y: auto;
  overflow-x: hidden;
  height: 100vh;
  display: flex;
  flex-direction: column;
}

.result-content {
  flex: 1;
  padding: 20px 15px;
  display: flex;
  flex-direction: column;
  gap: 20px;
  overflow-y: auto;
}

.result-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 15px;
}

.image-container {
  width: 100%;
  max-width: 350px;
  border-radius: 15px;
  overflow: hidden;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.image-container img {
  width: 100%;
  height: auto;
  display: block;
}

.result-btn {
  background: #FFED00;
  color: #FF6A1A;
  border: none;
  border-radius: 25px;
  padding: 12px 40px;
  font-family: 'Baloo 2', cursive;
  font-size: 16px;
  font-weight: 800;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
  transition: all 0.3s;
  text-transform: uppercase;
  width: 100%;
  max-width: 250px;
}

.result-btn:hover {
  transform: scale(1.05);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.4);
}

.result-btn:active {
  transform: scale(0.98);
}

.print-btn {
  background: #FF6A1A;
  color: #FFED00;
}

.result-footer {
  padding: 15px;
  display: flex;
  justify-content: center;
}

.finish-btn {
  background: #00cb45;
  color: white;
  border: none;
  border-radius: 25px;
  padding: 14px 50px;
  font-family: 'Baloo 2', cursive;
  font-size: 18px;
  font-weight: 800;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
  transition: all 0.3s;
  text-transform: uppercase;
}

.finish-btn:hover {
  transform: scale(1.05);
  background: #00a838;
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.4);
}

.finish-btn:active {
  transform: scale(0.98);
}

@media (max-width: 480px) {
  .result-content {
    padding: 15px 10px;
    gap: 15px;
  }

  .result-card {
    gap: 12px;
  }

  .result-btn {
    padding: 10px 30px;
    font-size: 14px;
  }

  .finish-btn {
    padding: 12px 40px;
    font-size: 16px;
  }
}
