/* =========================================================================
   FROSTFIRE FORTUNE — PRODUCTION RESPONSIVE & SYMMETRICAL STYLING
   ========================================================================= */

:root {
  --ff-bg-dark: #050d13;
  --ff-gold: #f5c84c;
  --ff-gold-bright: #ffe685;
  --ff-gold-dark: #8e6a24;
  --ff-emerald: #00e599;
  --ff-ice-cyan: #00d2ff;
  --ff-fire-red: #ff4747;
  --ff-fire-amber: #ff9800;
  --ff-text: #eaf2f8;
  --ff-text-muted: #8ca3b8;
  --ff-panel-bg: rgba(6, 16, 24, 0.96);
  --ff-border: rgba(245, 200, 76, 0.22);
  --ff-font: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Vazirmatn", sans-serif;
}

.ff-root {
  position: relative;
  isolation: isolate;
  min-width: 0;
  max-width: 1120px;
  margin: 0 auto;
  min-height: calc(100vh - 70px);
  padding: 10px 14px max(20px, env(safe-area-inset-bottom));
  font-family: var(--ff-font);
  color: var(--ff-text);
  overflow-x: clip;
  box-sizing: border-box;
  direction: rtl;
}

.ff-root * {
  box-sizing: border-box;
}

.ff-backdrop {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  background: url('/assets/games/frostfire-fortune/background/casino_bg.webp') center center / cover no-repeat;
  filter: brightness(0.35) saturate(1.2);
  z-index: -2;
  pointer-events: none;
}

.ff-mist {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  background: radial-gradient(circle at 50% 12%, rgba(0, 229, 153, 0.08), transparent 45%),
              radial-gradient(circle at 80% 80%, rgba(255, 71, 71, 0.06), transparent 45%),
              linear-gradient(180deg, rgba(5, 13, 19, 0.85) 0%, rgba(5, 13, 19, 0.96) 100%);
  z-index: -1;
  pointer-events: none;
}

/* =========================================================================
   TOPBAR
   ========================================================================= */
.ff-topbar {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 12px;
  min-height: 56px;
  padding: 6px 14px;
  background: rgba(5, 16, 25, 0.9);
  border: 1px solid var(--ff-border);
  border-radius: 16px;
  backdrop-filter: blur(10px);
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.35);
  margin-bottom: 10px;
}

.ff-nav-back {
  justify-self: start;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 44px;
  min-width: 44px;
  padding: 0 14px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 10px;
  color: var(--ff-gold);
  text-decoration: none;
  font-weight: 600;
  font-size: 0.88rem;
  transition: all 0.2s ease;
}

.ff-nav-back:hover {
  background: rgba(245, 200, 76, 0.15);
  border-color: var(--ff-gold);
  color: #fff;
}

.ff-title-wrap {
  text-align: center;
  direction: ltr;
  line-height: 1.1;
}

.ff-kicker {
  display: block;
  font-size: 0.65rem;
  letter-spacing: 2px;
  color: var(--ff-emerald);
  font-weight: 800;
}

.ff-brand-title {
  display: block;
  margin-top: 3px;
  font-size: 1.25rem;
  font-weight: 900;
  letter-spacing: 1px;
  color: var(--ff-gold-bright);
  text-shadow: 0 0 14px rgba(245, 200, 76, 0.4);
}

.ff-brand-title i {
  font-style: normal;
  color: var(--ff-ice-cyan);
}

.ff-status-pill {
  justify-self: end;
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.8rem;
}

.ff-status-pill span {
  color: var(--ff-emerald);
  display: flex;
  align-items: center;
  gap: 6px;
}

.ff-dot-live {
  display: inline-block;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--ff-emerald);
  box-shadow: 0 0 8px var(--ff-emerald);
  animation: ffPulse 1.8s infinite;
}

.ff-rtp-badge {
  padding: 5px 10px;
  background: rgba(0, 229, 153, 0.1);
  border: 1px solid rgba(0, 229, 153, 0.3);
  border-radius: 16px;
  color: var(--ff-emerald);
  font-weight: 700;
  font-size: 0.78rem;
}

/* =========================================================================
   STAGE CONTAINER
   ========================================================================= */
.ff-stage {
  position: relative;
  max-width: 860px;
  margin: 0 auto;
  width: 100%;
  padding: 0 !important;
}

/* =========================================================================
   JACKPOT HEADER
   ========================================================================= */
.ff-jackpot-header {
  width: 100%;
  min-height: 76px;
  padding: 10px 18px;
  background: linear-gradient(180deg, rgba(8, 22, 32, 0.95), rgba(4, 12, 18, 0.98));
  border: 2px solid var(--ff-gold-dark);
  border-radius: 16px 16px 8px 8px;
  box-shadow: inset 0 0 0 2px rgba(245, 200, 76, 0.18), 0 10px 30px rgba(0, 0, 0, 0.5);
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.ff-jackpot-content {
  text-align: center;
}

.ff-jackpot-eyebrow {
  display: block;
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 2px;
  color: var(--ff-emerald);
}

.ff-jackpot-value {
  display: block;
  margin: 2px 0;
  font-size: 1.35rem;
  font-weight: 900;
  color: var(--ff-gold-bright);
  text-shadow: 0 0 12px rgba(255, 230, 128, 0.5);
}

.ff-jackpot-sub {
  display: block;
  font-size: 0.72rem;
  color: var(--ff-text-muted);
}

/* =========================================================================
   ELEMENTAL METERS
   ========================================================================= */
.ff-meters {
  width: 100%;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin-top: 8px;
}

.ff-meter {
  padding: 8px 14px;
  background: rgba(6, 16, 24, 0.9);
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  min-height: 52px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.ff-meter--ice {
  border-color: rgba(0, 210, 255, 0.3);
}

.ff-meter--fire {
  border-color: rgba(255, 71, 71, 0.3);
}

.ff-meter__info {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.76rem;
  font-weight: 700;
  margin-bottom: 5px;
}

.ff-meter--ice .ff-meter__info { color: var(--ff-ice-cyan); }
.ff-meter--fire .ff-meter__info { color: var(--ff-fire-red); }

.ff-meter__track {
  height: 7px;
  background: rgba(0, 0, 0, 0.6);
  border-radius: 8px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.ff-meter__fill {
  height: 100%;
  width: 0%;
  transition: width 0.35s cubic-bezier(0.2, 0.8, 0.2, 1);
  border-radius: 8px;
}

.ff-meter__fill--ice {
  background: linear-gradient(90deg, #0088ff, #00d2ff);
  box-shadow: 0 0 8px var(--ff-ice-cyan);
}

.ff-meter__fill--fire {
  background: linear-gradient(90deg, #ff9800, #ff4747);
  box-shadow: 0 0 8px var(--ff-fire-red);
}

/* =========================================================================
   CABINET & 6x5 GRID
   ========================================================================= */
.ff-cabinet-section {
  width: 100%;
  margin-top: 8px;
}

.ff-cabinet-frame {
  position: relative;
  width: 100%;
  padding: 12px;
  border: 2px solid var(--ff-gold-dark);
  border-radius: 16px;
  background: linear-gradient(145deg, #152620, #08161f 25%, #050e14 75%, #20170e);
  box-shadow: inset 0 0 0 2px rgba(245, 200, 76, 0.18), 0 16px 45px rgba(0, 0, 0, 0.6);
  overflow: hidden;
}

.ff-reels {
  position: relative;
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 6px;
  padding: 8px;
  background: #02080d;
  border-radius: 11px;
  border: 1px solid rgba(0, 229, 153, 0.25);
  overflow: hidden;
  width: 100%;
}

.ff-column {
  display: grid;
  grid-template-rows: repeat(5, minmax(0, 1fr));
  gap: 6px;
  min-width: 0;
}

.ff-cell {
  position: relative;
  aspect-ratio: 1.15 / 1;
  min-width: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(145deg, rgba(16, 32, 46, 0.9), rgba(6, 16, 24, 0.95));
  border: 1px solid rgba(245, 200, 76, 0.12);
  border-radius: 8px;
  overflow: hidden;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.ff-cell img {
  display: block;
  width: 90%;
  height: 90%;
  object-fit: contain;
  filter: drop-shadow(0 3px 6px rgba(0, 0, 0, 0.7));
  transform: translateZ(0);
  transition: transform 0.2s ease, filter 0.2s ease;
}

.ff-cell.is-spinning img {
  animation: ffReelSpin 0.18s infinite linear;
  filter: blur(2px) brightness(1.2);
}

.ff-cell.is-win {
  border-color: var(--ff-gold);
  background: rgba(245, 200, 76, 0.25);
  box-shadow: 0 0 16px var(--ff-gold), inset 0 0 10px var(--ff-gold-bright);
  transform: scale(1.05);
  z-index: 2;
}

.ff-cell.is-win img {
  animation: ffWinPulse 0.6s infinite alternate ease-in-out;
}

/* Floating cascade & multiplier pills */
.ff-cascade-float {
  position: absolute;
  top: 18px;
  right: 18px;
  display: flex;
  gap: 6px;
  z-index: 5;
  pointer-events: none;
}

.ff-float-pill {
  padding: 3px 9px;
  background: rgba(4, 12, 18, 0.88);
  border: 1px solid var(--ff-emerald);
  border-radius: 14px;
  font-size: 0.72rem;
  color: var(--ff-emerald);
  backdrop-filter: blur(4px);
}

.ff-float-pill--mult {
  border-color: var(--ff-gold);
  color: var(--ff-gold);
}

/* =========================================================================
   STATUS MESSAGE
   ========================================================================= */
.ff-message {
  width: 100%;
  min-height: 42px;
  margin-top: 8px;
  padding: 8px 14px;
  background: rgba(5, 15, 23, 0.92);
  border: 1px solid rgba(0, 229, 153, 0.15);
  border-radius: 12px;
  text-align: center;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--ff-text);
  transition: all 0.3s ease;
}

.ff-message.is-win {
  border-color: rgba(245, 200, 76, 0.45);
  background: rgba(245, 200, 76, 0.15);
  color: var(--ff-gold-bright);
  box-shadow: 0 0 20px rgba(245, 200, 76, 0.12);
}

/* =========================================================================
   SUMMARY BAR
   ========================================================================= */
.ff-summary-bar {
  width: 100%;
  margin-top: 8px;
  display: grid;
  grid-template-columns: 1fr 0.8fr 1.25fr;
  gap: 8px;
}

.ff-stat-card {
  min-height: 56px;
  padding: 7px 12px;
  background: linear-gradient(135deg, rgba(8, 22, 32, 0.95), rgba(4, 14, 22, 0.95));
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px;
  text-align: center;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.ff-stat-card small {
  display: block;
  font-size: 0.72rem;
  color: var(--ff-text-muted);
  margin-bottom: 2px;
}

.ff-stat-val {
  display: block;
  font-size: 1.15rem;
  font-weight: 800;
  color: #fff;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.ff-stat-val--win { color: var(--ff-gold); }
.ff-stat-val--balance { color: var(--ff-emerald); }

/* =========================================================================
   CONTROLS BAR
   ========================================================================= */
.ff-controls {
  width: 100%;
  margin-top: 10px;
  padding: 10px 16px;
  border-radius: 16px;
  background: rgba(6, 16, 24, 0.95);
  border: 1px solid var(--ff-border);
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 16px;
  align-items: center;
}

.ff-bet-section {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  min-width: 0;
}

.ff-control-label {
  display: block;
  margin-bottom: 4px;
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--ff-text-muted);
}

.ff-bet-picker {
  display: flex;
  align-items: center;
  gap: 6px;
}

.ff-btn-asset {
  min-width: 44px;
  min-height: 44px;
  width: 44px;
  height: 44px;
  padding: 0;
  background: transparent;
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.15s ease;
  touch-action: manipulation;
}

.ff-btn-asset img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  filter: drop-shadow(0 2px 5px rgba(0, 0, 0, 0.5));
}

.ff-btn-asset:active { transform: scale(0.92); }
.ff-btn-asset:disabled { opacity: 0.45; cursor: not-allowed; filter: grayscale(1); }

.ff-bet-display input {
  width: 84px;
  min-height: 44px;
  height: 44px;
  background: rgba(0, 0, 0, 0.6);
  border: 1px solid var(--ff-border);
  border-radius: 10px;
  color: var(--ff-gold-bright);
  font-size: 1rem;
  font-weight: 800;
  text-align: center;
  outline: none;
  font-family: inherit;
}

.ff-spin-section {
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 90px;
}

.ff-spin-btn {
  position: relative;
  min-width: 74px;
  min-height: 74px;
  width: 74px;
  height: 74px;
  padding: 0;
  background: transparent;
  border: none;
  cursor: pointer;
  border-radius: 50%;
  transition: transform 0.2s cubic-bezier(0.34, 1.56, 0.64, 1);
  touch-action: manipulation;
}

.ff-spin-btn img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  filter: drop-shadow(0 4px 12px rgba(0, 229, 153, 0.4));
  transition: filter 0.2s ease;
}

.ff-spin-btn:hover img {
  filter: drop-shadow(0 0 18px var(--ff-emerald));
  transform: scale(1.05);
}

.ff-spin-btn:active { transform: scale(0.92); }
.ff-spin-btn:disabled { opacity: 0.45; cursor: not-allowed; filter: grayscale(0.8); }

.ff-options-section {
  display: flex;
  align-items: flex-end;
  justify-content: flex-end;
  gap: 10px;
  min-width: 0;
}

.ff-auto-wrap {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  min-width: 110px;
}

.ff-auto-wrap select {
  width: 100%;
  min-height: 44px;
  height: 44px;
  padding: 0 10px;
  background: rgba(0, 0, 0, 0.6);
  border: 1px solid var(--ff-border);
  border-radius: 10px;
  color: var(--ff-text);
  font-size: 0.88rem;
  font-weight: 700;
  outline: none;
  cursor: pointer;
}

.ff-turbo-wrap {
  display: flex;
  align-items: flex-end;
}

.ff-turbo-toggle {
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

.ff-turbo-toggle input { display: none; }

.ff-turbo-switch {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-width: 62px;
  min-height: 56px;
  padding: 4px 8px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 10px;
  color: var(--ff-text-muted);
  transition: all 0.2s ease;
}

.ff-turbo-switch b {
  font-size: 16px;
  color: var(--ff-gold);
}

.ff-turbo-switch small {
  font-size: 9px;
  margin-top: 2px;
}

.ff-turbo-toggle input:checked + .ff-turbo-switch {
  background: rgba(245, 200, 76, 0.18);
  border-color: var(--ff-gold);
  color: var(--ff-gold-bright);
  box-shadow: 0 0 10px rgba(245, 200, 76, 0.3);
}

.ff-turbo-switch small {
  font-size: 9px;
  margin-top: 2px;
}

.ff-turbo-toggle input:checked + .ff-turbo-switch {
  background: rgba(245, 200, 76, 0.18);
  border-color: var(--ff-gold);
  color: var(--ff-gold-bright);
  box-shadow: 0 0 10px rgba(245, 200, 76, 0.3);
}

/* =========================================================================
   TOOLS BAR
   ========================================================================= */
.ff-tools {
  width: 100%;
  margin-top: 8px;
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 6px;
}

.ff-tools button {
  min-width: 0;
  min-height: 44px;
  padding: 4px 6px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 10px;
  background: rgba(6, 16, 24, 0.85);
  color: var(--ff-text-muted);
  font-size: 0.78rem;
  font-weight: 600;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  transition: all 0.2s ease;
}

.ff-tools button:hover {
  background: rgba(245, 200, 76, 0.12);
  border-color: var(--ff-gold);
  color: #fff;
}

.ff-tools b {
  color: var(--ff-emerald);
  font-size: 14px;
}

/* =========================================================================
   BONUS OVERLAY
   ========================================================================= */
.ff-bonus-banner {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%) scale(0.85);
  width: min(520px, calc(100% - 28px));
  background: radial-gradient(circle at center, rgba(16, 32, 48, 0.98), rgba(4, 10, 16, 0.98));
  border: 3px solid var(--ff-gold);
  border-radius: 20px;
  padding: 24px;
  text-align: center;
  box-shadow: 0 0 50px rgba(0, 229, 153, 0.4), 0 0 30px rgba(255, 71, 71, 0.4);
  z-index: 100;
  opacity: 0;
  pointer-events: none;
  transition: all 0.35s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.ff-bonus-banner.is-active {
  opacity: 1;
  pointer-events: auto;
  transform: translate(-50%, -50%) scale(1);
}

.ff-bonus-kicker {
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 2px;
  color: var(--ff-emerald);
}

.ff-bonus-headline {
  margin: 6px 0;
  font-size: 1.45rem;
  font-weight: 900;
  color: var(--ff-gold-bright);
}

.ff-bonus-count-wrap {
  margin: 12px 0;
  font-size: 2rem;
  font-weight: 900;
  color: var(--ff-ice-cyan);
}

.ff-bonus-count-wrap small {
  display: block;
  font-size: 0.78rem;
  color: var(--ff-text-muted);
}

/* =========================================================================
   MODAL / POPUP
   ========================================================================= */
.ff-modal {
  position: fixed;
  inset: 0;
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 1200;
}

.ff-modal.is-open {
  display: flex;
}

.ff-modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.78);
  backdrop-filter: blur(5px);
}

.ff-modal-sheet {
  position: relative;
  width: min(640px, calc(100% - 28px));
  max-height: min(82vh, 700px);
  background: var(--ff-panel-bg);
  border: 1px solid var(--ff-border);
  border-radius: 18px;
  padding: 24px;
  overflow-y: auto;
  box-shadow: 0 12px 50px rgba(0, 0, 0, 0.8);
}

.ff-modal-close {
  position: sticky;
  float: left;
  top: 0;
  z-index: 2;
  width: 40px;
  height: 40px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 50%;
  color: #fff;
  font-size: 1.3rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

.ff-modal-body {
  clear: both;
}

.ff-modal-kicker {
  display: block;
  font-size: 0.7rem;
  letter-spacing: 2px;
  color: var(--ff-emerald);
  font-weight: 800;
}

.ff-modal-body h3 {
  margin: 6px 0 12px;
  font-size: 1.2rem;
  color: var(--ff-gold);
}

.ff-paytable-cards {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin-top: 12px;
}

.ff-pay-card {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 10px;
  background: rgba(12, 26, 38, 0.7);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 10px;
}

.ff-pay-card img {
  width: 40px;
  height: 40px;
  object-fit: contain;
}

.ff-pay-card strong {
  display: block;
  font-size: 0.82rem;
  color: var(--ff-text);
}

.ff-pay-card span {
  font-size: 0.74rem;
  color: var(--ff-gold);
}

.ff-pay-card--jackpot {
  grid-column: span 2;
  border-color: var(--ff-gold);
  background: rgba(245, 200, 76, 0.12);
}

.ff-rules-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
  margin: 14px 0;
  text-align: center;
}

.ff-rules-grid div {
  padding: 10px 6px;
  background: rgba(12, 26, 38, 0.7);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 10px;
}

.ff-rules-grid b {
  display: block;
  font-size: 1rem;
  color: var(--ff-emerald);
}

.ff-rules-grid span {
  font-size: 0.68rem;
  color: var(--ff-text-muted);
}

.ff-rules-list {
  padding-right: 18px;
  font-size: 0.84rem;
  line-height: 1.8;
  color: var(--ff-text-muted);
}

.ff-rules-list li {
  margin-bottom: 6px;
}

.ff-rules-list strong {
  color: var(--ff-text);
}

.ff-fair-fields label {
  display: block;
  font-size: 0.8rem;
  color: var(--ff-text-muted);
  margin-bottom: 10px;
}

.ff-fair-fields input {
  width: 100%;
  min-height: 44px;
  margin-top: 4px;
  padding: 8px 12px;
  background: rgba(0, 0, 0, 0.6);
  border: 1px solid var(--ff-border);
  border-radius: 8px;
  color: var(--ff-gold);
  font-size: 0.85rem;
  font-family: monospace;
  direction: ltr;
}

/* =========================================================================
   KEYFRAMES
   ========================================================================= */
@keyframes ffPulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.4; transform: scale(0.85); }
}

@keyframes ffReelSpin {
  0% { transform: translateY(-8%); }
  50% { transform: translateY(8%); }
  100% { transform: translateY(-8%); }
}

@keyframes ffWinPulse {
  0% { transform: scale(1); filter: drop-shadow(0 0 4px var(--ff-gold)); }
  100% { transform: scale(1.1); filter: drop-shadow(0 0 16px var(--ff-gold-bright)); }
}

/* =========================================================================
   RESPONSIVE (MOBILE & TABLET)
   ========================================================================= */
@media (max-width: 720px) {
  .ff-root {
    padding: 6px 8px calc(14px + env(safe-area-inset-bottom));
  }

  .ff-topbar {
    grid-template-columns: 44px 1fr auto;
    min-height: 50px;
    padding: 4px 8px;
    border-radius: 12px;
  }

  .ff-nav-back {
    min-width: 44px;
    min-height: 44px;
    padding: 0;
    justify-content: center;
  }

  .ff-nav-back span, .ff-status-pill span {
    display: none;
  }

  .ff-brand-title {
    font-size: 1.05rem;
  }

  .ff-jackpot-header {
    min-height: 64px;
    padding: 6px 12px;
  }

  .ff-jackpot-value {
    font-size: 1.15rem;
  }

  .ff-cabinet-frame {
    padding: 6px;
    border-radius: 12px;
  }

  .ff-reels {
    gap: 3px;
    padding: 4px;
  }

  .ff-column {
    gap: 3px;
  }

  .ff-cell {
    aspect-ratio: 1 / 1;
    border-radius: 6px;
  }

  .ff-controls {
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding: 10px;
    border-radius: 14px;
  }

  .ff-bet-section {
    width: 100%;
    align-items: center;
  }

  .ff-bet-picker {
    width: 100%;
    justify-content: center;
    gap: 8px;
  }

  .ff-bet-display input {
    width: 100px;
  }

  .ff-spin-section {
    order: 2;
    width: 100%;
  }

  .ff-spin-btn {
    min-width: 72px;
    min-height: 72px;
    width: 72px;
    height: 72px;
  }

  .ff-options-section {
    order: 3;
    width: 100%;
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 8px;
    align-items: flex-end;
  }

  .ff-auto-wrap {
    min-width: 0;
    width: 100%;
  }

  .ff-turbo-wrap {
    width: auto;
  }

  .ff-turbo-switch {
    min-height: 44px;
    height: 44px;
    min-width: 70px;
    padding: 0 10px;
    flex-direction: row;
    gap: 6px;
  }

  .ff-tools {
    grid-template-columns: repeat(3, 1fr);
    gap: 4px;
  }

  .ff-paytable-cards {
    grid-template-columns: 1fr;
  }

  .ff-pay-card--jackpot {
    grid-column: span 1;
  }

  .ff-rules-grid {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 370px) {
  .ff-options-section {
    grid-template-columns: 1fr;
  }
  .ff-turbo-wrap {
    display: none;
  }
  .ff-tools button span {
    display: none;
  }
  .ff-tools button b {
    font-size: 16px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}