/* ==========================================================================
   ENGLISH SAFARI ISLAND 🇬🇧 - STYLES
   ========================================================================== */

.island-english {
  border-top: 5px solid #0284c7;
  background: linear-gradient(135deg, #ffffff 0%, #f0f9ff 100%);
}

.island-english:hover {
  box-shadow: 0 12px 28px rgba(2, 132, 199, 0.22);
  transform: translateY(-4px);
}

.english-container {
  max-width: 880px;
  margin: 0 auto;
}

.english-header-tabs {
  display: flex !important;
  gap: 8px !important;
  overflow-x: auto !important;
  -webkit-overflow-scrolling: touch;
  padding: 4px 2px !important;
  scrollbar-width: none;
  flex-wrap: nowrap !important;
  max-width: 100%;
}

.english-header-tabs::-webkit-scrollbar {
  display: none;
}

.english-header-tabs .english-tab-btn {
  white-space: nowrap;
  font-size: 0.9rem;
  padding: 8px 14px;
  border-radius: 20px;
  flex-shrink: 0;
  transition: all 0.2s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  font-weight: 700;
}

.english-subtabs {
  display: flex !important;
  gap: 6px !important;
  overflow-x: auto !important;
  -webkit-overflow-scrolling: touch;
  padding: 4px 2px !important;
  scrollbar-width: none;
  flex-wrap: nowrap !important;
}

.english-subtabs::-webkit-scrollbar {
  display: none;
}

.english-subtabs .level-pill {
  white-space: nowrap;
  flex-shrink: 0;
}

.english-stage-card {
  background: #ffffff;
  border-radius: 20px;
  padding: 16px;
  box-shadow: 0 8px 24px rgba(2, 132, 199, 0.08);
  border: 3px solid #bae6fd;
}

/* 1. LISTEN & TAP */
.english-stage-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 16px;
  background: #f0f9ff;
  border-radius: 14px;
  padding: 10px 14px;
  border: 2px solid #e0f2fe;
}

.english-score-badge {
  background: #0284c7;
  color: #ffffff;
  font-weight: 800;
  font-size: 1rem;
  padding: 6px 14px;
  border-radius: 20px;
  white-space: nowrap;
}

.english-prompt-box {
  display: flex;
  align-items: center;
  gap: 12px;
  flex: 1;
}

.english-audio-actions {
  display: flex;
  gap: 6px;
  align-items: center;
  flex-shrink: 0;
}

.btn-sound-replay {
  background: #0284c7;
  color: #fff;
  border: none;
  border-radius: 20px;
  padding: 6px 12px;
  font-size: 0.95rem;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 0 4px 10px rgba(2, 132, 199, 0.35);
  transition: transform 0.15s;
  display: flex;
  align-items: center;
  gap: 4px;
}

.btn-sound-replay:hover {
  transform: scale(1.05);
  background: #0369a1;
}

.btn-it-sound {
  background: #10b981 !important;
  box-shadow: 0 4px 10px rgba(16, 185, 129, 0.35) !important;
}

.btn-it-sound:hover {
  background: #059669 !important;
}

.btn-outline-it {
  background: #ecfdf5;
  color: #059669;
  border: 1.5px solid #a7f3d0;
  font-weight: 700;
}

.btn-outline-it:hover {
  background: #d1fae5;
  border-color: #34d399;
}

.english-prompt-text .en-text {
  font-size: 1.25rem;
  font-weight: 800;
  color: #0369a1;
}

.english-prompt-text .it-hint {
  font-size: 0.88rem;
  color: #64748b;
  font-weight: 600;
}

.english-choices-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 14px;
}

.english-choice-card {
  background: #ffffff;
  border: 3px solid #e2e8f0;
  border-radius: 16px;
  padding: 18px 12px;
  text-align: center;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  box-shadow: 0 4px 12px rgba(0,0,0,0.04);
  user-select: none;
  -webkit-user-select: none;
}

.english-choice-card:hover {
  border-color: #38bdf8;
  transform: translateY(-3px) scale(1.02);
  box-shadow: 0 8px 20px rgba(56, 189, 248, 0.15);
}

.english-choice-emoji {
  font-size: 3.2rem;
  margin-bottom: 6px;
  line-height: 1;
}

.english-choice-word {
  font-size: 1.2rem;
  font-weight: 900;
  color: #0f172a;
  letter-spacing: 0.5px;
}

.english-choice-it {
  font-size: 0.85rem;
  font-weight: 600;
  color: #64748b;
}

.correct-choice-anim {
  background: #dcfce7 !important;
  border-color: #22c55e !important;
  animation: bounceCorrect 0.6s ease-in-out;
}

.wrong-choice-anim {
  background: #fee2e2 !important;
  border-color: #ef4444 !important;
  animation: shakeWrong 0.5s ease-in-out;
}

@keyframes bounceCorrect {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.12); }
}

@keyframes shakeWrong {
  0%, 100% { transform: translateX(0); }
  25% { transform: translateX(-6px); }
  75% { transform: translateX(6px); }
}

/* 2. MAGIC WORD BUILDER */
.word-builder-stage {
  text-align: center;
}

.wb-hero-box {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  margin-bottom: 16px;
  background: #f8fafc;
  padding: 10px 16px;
  border-radius: 16px;
  border: 2px solid #e2e8f0;
}

.wb-emoji-giant {
  font-size: 3.5rem;
  line-height: 1;
}

.wb-info-right {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 6px;
}

.wb-audio-buttons {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.wb-translation {
  font-size: 1.05rem;
  font-weight: 700;
  color: #475569;
}

.wb-slots-row {
  display: flex;
  justify-content: center;
  gap: 12px;
  margin-bottom: 20px;
}

.word-builder-slot {
  width: 64px;
  height: 68px;
  background: #f1f5f9;
  border: 3px dashed #94a3b8;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.8rem;
  font-weight: 900;
  color: #0284c7;
  cursor: pointer;
  transition: all 0.2s;
}

.word-builder-slot.filled {
  background: #e0f2fe;
  border: 3px solid #0284c7;
  border-style: solid;
}

.word-builder-slot.slot-drag-hover {
  background: #bae6fd;
  transform: scale(1.08);
}

.wb-tiles-bank {
  background: #f0fdf4;
  border: 2px solid #bbf7d0;
  border-radius: 16px;
  padding: 12px;
  margin-bottom: 16px;
}

.wb-bank-label {
  font-size: 0.85rem;
  font-weight: 700;
  color: #166534;
  margin-bottom: 8px;
}

.wb-tiles-row {
  display: flex;
  justify-content: center;
  gap: 10px;
  flex-wrap: wrap;
}

.letter-tile {
  width: 54px;
  height: 56px;
  background: #ffffff;
  border: 3px solid #22c55e;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.6rem;
  font-weight: 900;
  color: #15803d;
  cursor: grab;
  box-shadow: 0 4px 10px rgba(34, 197, 94, 0.2);
  transition: all 0.15s;
  user-select: none;
  -webkit-user-select: none;
}

.letter-tile:hover {
  transform: translateY(-3px) scale(1.06);
  border-color: #16a34a;
}

.tile-used {
  opacity: 0.25;
  pointer-events: none;
  box-shadow: none;
}

/* ACTION BUTTONS (Super Colorful, Tactile & Kid-Friendly) */
.wb-bottom-controls,
.sorting-bottom-controls,
.listen-bottom-controls {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 14px;
  padding: 6px 0;
}

.btn-wb-action {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 22px;
  font-family: 'Quicksand', 'Nunito', sans-serif;
  font-size: 1rem;
  font-weight: 800;
  color: #ffffff;
  border: 2px solid rgba(255, 255, 255, 0.85);
  border-radius: 9999px;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.34, 1.56, 0.64, 1);
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.12), 0 3px 0 rgba(0, 0, 0, 0.15);
  user-select: none;
  -webkit-user-select: none;
  position: relative;
  overflow: hidden;
}

.btn-wb-action:hover {
  transform: translateY(-2px) scale(1.04);
}

.btn-wb-action:active {
  transform: translateY(2px) scale(0.97);
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.12), 0 1px 0 rgba(0, 0, 0, 0.15);
}

.btn-wb-action::after {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 60%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.35), transparent);
  transform: skewX(-20deg);
  transition: none;
}

.btn-wb-action:hover::after {
  left: 140%;
  transition: all 0.65s ease-in-out;
}

.btn-wb-reset {
  background: linear-gradient(135deg, #f59e0b 0%, #ea580c 100%);
  box-shadow: 0 4px 14px rgba(234, 88, 12, 0.35), 0 3px 0 #c2410c;
}

.btn-wb-reset:hover {
  box-shadow: 0 6px 18px rgba(234, 88, 12, 0.45), 0 4px 0 #c2410c;
}

.btn-wb-next {
  background: linear-gradient(135deg, #10b981 0%, #059669 50%, #047857 100%);
  box-shadow: 0 4px 14px rgba(16, 185, 129, 0.4), 0 3px 0 #047857;
  font-size: 1.05rem;
  padding: 11px 26px;
}

.btn-wb-next:hover {
  box-shadow: 0 6px 20px rgba(16, 185, 129, 0.5), 0 4px 0 #047857;
}

.btn-wb-random {
  background: linear-gradient(135deg, #a855f7 0%, #7c3aed 100%);
  box-shadow: 0 4px 14px rgba(124, 58, 237, 0.35), 0 3px 0 #6d28d9;
}

.btn-wb-random:hover {
  box-shadow: 0 6px 18px rgba(124, 58, 237, 0.45), 0 4px 0 #6d28d9;
}

.btn-wb-prev {
  background: linear-gradient(135deg, #64748b 0%, #475569 100%);
  box-shadow: 0 4px 12px rgba(71, 85, 105, 0.3), 0 3px 0 #334155;
}

.btn-wb-sound {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: linear-gradient(135deg, #0284c7 0%, #0369a1 100%);
  color: #ffffff;
  border: 2px solid #bae6fd;
  border-radius: 9999px;
  padding: 8px 18px;
  font-family: 'Quicksand', 'Nunito', sans-serif;
  font-weight: 800;
  font-size: 0.95rem;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.34, 1.56, 0.64, 1);
  box-shadow: 0 4px 12px rgba(2, 132, 199, 0.35), 0 2px 0 #075985;
}

.btn-wb-sound:hover {
  transform: translateY(-2px) scale(1.03);
  box-shadow: 0 6px 16px rgba(2, 132, 199, 0.45), 0 3px 0 #075985;
}

.btn-wb-sound:active {
  transform: translateY(2px);
  box-shadow: 0 2px 6px rgba(2, 132, 199, 0.35);
}

.btn-wb-icon {
  font-size: 1.15rem;
  line-height: 1;
}

.btn-wb-text {
  letter-spacing: 0.3px;
}

/* 3. VOCABULARY BASKET SORTING */
.sorting-stage {
  padding: 14px;
}

.sorting-prompt-banner {
  display: flex;
  align-items: center;
  gap: 12px;
  background: #f0f9ff;
  border: 2px solid #bae6fd;
  border-radius: 12px;
  padding: 8px 12px;
  margin-bottom: 12px;
}

.sorting-prompt-audio {
  display: flex;
  gap: 6px;
  align-items: center;
  flex-shrink: 0;
}

.sorting-prompt-text {
  display: flex;
  flex-direction: column;
}

.sorting-prompt-text .en-text {
  font-size: 1.05rem;
  font-weight: 800;
  color: #0369a1;
}

.sorting-prompt-text .it-hint {
  font-size: 0.82rem;
  color: #059669;
  font-weight: 700;
}

.english-baskets-row {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
  margin-bottom: 14px;
}

.english-basket {
  background: #ffffff;
  border: 3px dashed #cbd5e1;
  border-radius: 16px;
  overflow: hidden;
  transition: all 0.2s;
  cursor: pointer;
}

.english-basket.basket-drag-hover {
  background: #f8fafc;
  transform: scale(1.02);
  border-style: solid;
}

.english-basket-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 10px;
  font-size: 0.95rem;
  border-bottom: 1px solid #f1f5f9;
}

.english-basket-header .basket-labels {
  display: flex;
  flex-direction: column;
}

.english-basket-dropzone {
  min-height: 90px;
  padding: 8px;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-content: flex-start;
}

.drop-hint-text {
  font-size: 0.8rem;
  color: #94a3b8;
  font-style: italic;
  margin: auto;
}

.sorted-mini-tag {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: #f8fafc;
  border: 1.5px solid #e2e8f0;
  border-radius: 16px;
  padding: 3px 8px;
  font-size: 0.8rem;
  font-weight: 700;
}

.english-items-tray {
  background: #f8fafc;
  border: 2px solid #e2e8f0;
  border-radius: 14px;
  padding: 10px;
}

.items-tray-title {
  font-size: 0.85rem;
  font-weight: 800;
  color: #475569;
  margin-bottom: 8px;
}

.items-tray-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: center;
}

.english-sort-item {
  background: #ffffff;
  border: 2px solid #cbd5e1;
  border-radius: 12px;
  padding: 6px 10px;
  display: flex;
  align-items: center;
  gap: 6px;
  cursor: grab;
  transition: all 0.15s;
  user-select: none;
  -webkit-user-select: none;
}

.english-sort-item:hover, .english-sort-item.item-selected {
  border-color: #0284c7;
  background: #e0f2fe;
  transform: translateY(-2px);
}

.english-sort-item .item-emoji {
  font-size: 1.5rem;
  line-height: 1;
}

.english-sort-item .item-word {
  font-size: 0.9rem;
  font-weight: 800;
  color: #0f172a;
}

.english-sort-item .item-it {
  font-size: 0.75rem;
  color: #64748b;
}

/* 4. OPPOSITES */
.opposites-header-banner, .phrases-header-banner {
  background: #f0f9ff;
  border: 2px solid #bae6fd;
  border-radius: 12px;
  padding: 8px 12px;
  margin-bottom: 12px;
  font-size: 0.95rem;
  font-weight: 800;
  color: #0369a1;
  text-align: center;
}

.opposites-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
}

.opposite-pair-card {
  background: #ffffff;
  border: 2px solid #e2e8f0;
  border-radius: 16px;
  display: flex;
  align-items: center;
  overflow: hidden;
  box-shadow: 0 4px 10px rgba(0,0,0,0.03);
}

.opposite-half {
  flex: 1;
  padding: 12px 8px;
  text-align: center;
  cursor: pointer;
  transition: background 0.15s;
}

.opposite-half:hover {
  background: #f0f9ff;
}

.opposite-half.side-a {
  background: #fffbeb;
}

.opposite-half.side-a:hover {
  background: #fef3c7;
}

.opposite-half.side-b {
  background: #f0fdf4;
}

.opposite-half.side-b:hover {
  background: #dcfce7;
}

.opposite-half .opp-emoji {
  font-size: 2.4rem;
  margin-bottom: 4px;
}

.opposite-half .opp-word {
  font-size: 1.05rem;
  font-weight: 900;
  color: #0f172a;
}

.opposite-half .opp-it {
  font-size: 0.75rem;
  color: #64748b;
  font-weight: 600;
  margin-bottom: 4px;
}

.opp-audio-btns {
  display: flex;
  gap: 6px;
  justify-content: center;
  margin-top: 6px;
}

.opp-divider {
  font-size: 0.75rem;
  font-weight: 900;
  color: #94a3b8;
  padding: 0 4px;
}

.btn-sound-mini {
  background: #e0f2fe;
  border: none;
  border-radius: 12px;
  padding: 3px 8px;
  font-size: 0.78rem;
  font-weight: 700;
  cursor: pointer;
  color: #0284c7;
  transition: transform 0.1s;
}

.btn-sound-mini:hover {
  transform: scale(1.08);
}

.btn-sound-mini-it {
  background: #dcfce7 !important;
  color: #059669 !important;
}

/* 5. DAILY PHRASES */
.phrases-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
}

.daily-phrase-card {
  background: #ffffff;
  border: 2px solid #e0f2fe;
  border-radius: 16px;
  padding: 12px 14px;
  cursor: pointer;
  transition: all 0.2s;
  box-shadow: 0 4px 12px rgba(2, 132, 199, 0.05);
}

.daily-phrase-card:hover {
  border-color: #38bdf8;
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(56, 189, 248, 0.15);
}

.phrase-top-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 6px;
}

.phrase-scene-title {
  font-size: 0.85rem;
  font-weight: 800;
  color: #0284c7;
}

.phrase-emoji {
  font-size: 1.8rem;
}

.phrase-english {
  font-size: 1.15rem;
  font-weight: 900;
  color: #0f172a;
  margin-bottom: 2px;
}

.phrase-it {
  font-size: 0.85rem;
  font-weight: 700;
  color: #10b981;
  margin-bottom: 4px;
}

.phrase-context {
  font-size: 0.78rem;
  color: #64748b;
  margin-bottom: 8px;
}

.phrase-audio-row {
  display: flex;
  gap: 8px;
  margin-top: 10px;
}

.phrase-audio-row .btn {
  flex: 1;
  font-size: 0.82rem;
  padding: 6px 8px;
  border-radius: 10px;
}

/* ==========================================================================
   MOBILE RESPONSIVE (NO SCROLL VIEWPORT) FOR ENGLISH ISLAND
   ========================================================================== */

@media (max-width: 640px) {
  .english-stage-card {
    padding: 8px 6px;
    border-radius: 14px;
  }

  .english-stage-header {
    padding: 6px 8px;
    margin-bottom: 8px;
    gap: 6px;
  }

  .english-score-badge {
    font-size: 0.78rem;
    padding: 4px 8px;
  }

  .btn-sound-replay {
    padding: 4px 8px;
    font-size: 0.8rem;
  }

  .english-prompt-text .en-text {
    font-size: 0.95rem;
  }

  .english-prompt-text .it-hint {
    font-size: 0.72rem;
  }

  .english-choices-grid {
    gap: 8px;
  }

  .english-choice-card {
    padding: 10px 6px;
    border-radius: 12px;
  }

  .english-choice-emoji {
    font-size: 2.2rem;
    margin-bottom: 2px;
  }

  .english-choice-word {
    font-size: 0.95rem;
  }

  .english-choice-it {
    font-size: 0.7rem;
  }

  /* Word builder mobile */
  .wb-hero-box {
    padding: 6px 10px;
    gap: 8px;
    margin-bottom: 8px;
  }

  .wb-emoji-giant {
    font-size: 2.4rem;
  }

  .wb-translation {
    font-size: 0.85rem;
  }

  .wb-slots-row {
    gap: 6px;
    margin-bottom: 10px;
  }

  .word-builder-slot {
    width: 46px;
    height: 48px;
    font-size: 1.3rem;
    border-radius: 10px;
  }

  .wb-tiles-bank {
    padding: 6px 8px;
    margin-bottom: 8px;
  }

  .letter-tile {
    width: 40px;
    height: 42px;
    font-size: 1.2rem;
    border-radius: 8px;
  }

  /* Sorting mobile */
  .english-baskets-row {
    gap: 6px;
    margin-bottom: 8px;
  }

  .english-basket-header {
    padding: 4px 6px;
    font-size: 0.78rem;
  }

  .english-basket-dropzone {
    min-height: 60px;
    padding: 4px;
    gap: 3px;
  }

  .sorted-mini-tag {
    padding: 2px 5px;
    font-size: 0.65rem;
  }

  .english-sort-item {
    padding: 4px 6px;
    gap: 4px;
  }

  .english-sort-item .item-emoji {
    font-size: 1.15rem;
  }

  .english-sort-item .item-word {
    font-size: 0.75rem;
  }

  .english-sort-item .item-it {
    font-size: 0.62rem;
  }

  /* Opposites & Phrases mobile */
  .opposites-grid, .phrases-grid {
    grid-template-columns: 1fr;
    gap: 8px;
  }

  .opposite-half .opp-emoji {
    font-size: 1.8rem;
  }

  .opposite-half .opp-word {
    font-size: 0.9rem;
  }

  .daily-phrase-card {
    padding: 8px 10px;
  }

  .phrase-english {
    font-size: 0.95rem;
  }

  .phrase-audio-row {
    flex-direction: column;
    gap: 4px;
  }
}
