.opposites-shell { width: min(1100px, 100%); height: 100dvh; margin: auto; padding: max(10px, env(safe-area-inset-top)) max(18px, env(safe-area-inset-right)) max(12px, env(safe-area-inset-bottom)) max(18px, env(safe-area-inset-left)); display: grid; grid-template-rows: auto minmax(0, 1fr); gap: 8px; }
.opposites-header { display: flex; justify-content: space-between; align-items: start; gap: 12px; }
.opposites-header h1 { margin: 4px 0 0; font-size: clamp(26px, 4vw, 38px); line-height: 1.1; }
.opposites-header .profile-summary { padding-top: 0; }
.opposites-activity { display: grid; grid-template-rows: 40px auto minmax(0, 1fr) 76px 64px; gap: 8px; padding: 12px 20px; border-radius: 24px; background: var(--paper); border: 3px solid white; box-shadow: 0 12px 30px rgb(29 72 87 / 12%); min-height: 0; }
.opposites-activity .practice-top { min-height: 0; }
#opposites-instruction { margin: 0; font-size: clamp(24px, 3vw, 32px); text-align: center; }
.opposites-pictures { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px; min-height: 0; }
.opposite-card { display: grid; grid-template-rows: minmax(0, 1fr) 82px; gap: 9px; min-height: 0; min-width: 0; }
.opposite-picture { position: relative; overflow: hidden; border: 3px solid #d3e1e5; border-radius: 19px; background: #fffaf0; min-height: 0; }
.opposite-picture img { display: block; width: 200%; height: 100%; max-width: none; pointer-events: none; user-select: none; }
.opposite-picture img.is-right-panel { transform: translateX(-50%); }
.opposite-slot { display: flex; align-items: center; justify-content: center; border: 3px dashed #7299aa; border-radius: 17px; background: var(--blue-soft); min-height: 72px; touch-action: none; }
.opposite-slot:empty::after { content: "Drop word here"; color: #446879; font-size: 22px; font-weight: 750; pointer-events: none; }
.opposite-slot.is-over { background: #d7ecf7; outline: 4px solid var(--blue); outline-offset: 2px; }
.opposite-card.is-over .opposite-picture { border-color: var(--blue); box-shadow: inset 0 0 0 3px var(--blue); }
.opposite-slot.is-wrong { border: 4px solid var(--red); background: var(--red-soft); }
.opposite-slot.is-correct { border: 4px solid var(--green); background: var(--green-soft); }
.opposites-word-bank { position: relative; display: flex; align-items: center; justify-content: center; gap: 28px; min-height: 72px; border: 2px dashed #9ab6c2; border-radius: 16px; padding: 4px 12px; }
.opposites-word-bank::before { content: "Words"; position: absolute; top: -10px; left: 14px; padding: 0 5px; background: var(--paper); color: var(--blue-dark); font-size: 13px; font-weight: 750; }
.opposites-word-bank:empty::after { content: "Drag words back here"; color: #446879; font-size: 21px; font-weight: 750; }
.opposites-word-bank.is-over { background: #d7ecf7; outline: 4px solid var(--blue); outline-offset: 2px; }
.opposite-word { min-width: 160px; min-height: 62px; padding: 6px 20px; border: 3px solid var(--blue); border-radius: 16px; background: white; color: var(--ink); font-size: clamp(28px, 4vw, 38px); font-weight: 850; line-height: 1.15; touch-action: none; user-select: none; -webkit-user-select: none; -webkit-touch-callout: none; cursor: grab; }
.opposite-word.is-held { opacity: .3; }
.opposite-word:disabled { opacity: 1; color: var(--green); border-color: var(--green); cursor: default; }
.opposite-drag-ghost { position: fixed; z-index: 1000; pointer-events: none; margin: 0; box-shadow: 0 8px 20px rgb(0 0 0 / 20%); transform: scale(1.04); cursor: grabbing; }
.opposites-controls { display: flex; align-items: center; justify-content: space-between; gap: 15px; min-height: 60px; }
#opposites-feedback { margin: 0; color: var(--blue-dark); font-size: clamp(18px, 2.5vw, 24px); font-weight: 800; }
#opposites-feedback.is-wrong { color: var(--red); }
#opposites-feedback.is-correct { color: var(--green); }
.opposites-controls button { min-width: 140px; min-height: 58px; }
.opposites-controls button:disabled { opacity: .5; cursor: default; }
.opposites-finish { display: grid; place-content: center; text-align: center; border-radius: 24px; background: var(--paper); }
.opposites-finish h2 { font-size: 44px; margin: 10px; }
.opposites-finish p { font-size: 20px; }
.finish-flag { font-size: 70px; }
.opposites-finish a { text-decoration: none; display: grid; place-content: center; }
body.has-active-task-list .opposites-shell { padding-bottom: max(80px, env(safe-area-inset-bottom)); }
@media (max-height: 650px) and (orientation: landscape) {
  .opposites-shell { padding-top: 6px; gap: 4px; }
  .opposites-header h1 { font-size: 28px; }
  .opposites-activity { grid-template-rows: 32px auto minmax(0, 1fr) 62px 54px; gap: 5px; padding: 8px 16px; }
  .opposite-card { grid-template-rows: minmax(0, 1fr) 66px; gap: 5px; }
  .opposite-word { min-height: 54px; font-size: 28px; }
  .opposites-word-bank { min-height: 62px; padding: 2px 10px; }
  .opposite-slot { min-height: 62px; }
  .opposites-controls button { min-height: 50px; }
  #opposites-instruction { font-size: 25px; }
}
@media (orientation: portrait) and (max-width: 820px) { .opposites-shell { display: none !important; } }
