.ttt-divider {
  border: 0;
  height: 1px;
  background: var(--line, rgba(31, 42, 68, 0.12));
  margin: 32px 0;
  width: 100%;
}

.ttt-section {
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 32px 24px;
  background: #fcfbf8;
  box-shadow: 0 6px 20px rgba(31, 42, 68, 0.08);
  margin-top: 16px;
  width: 100%;
  max-width: 100%;
  min-width: 0;
  box-sizing: border-box;
}

.ttt-fireworks {
  display: none;
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

.ttt-fireworks.is-active {
  display: block;
}

.ttt-title {
  font-family: 'Montserrat', sans-serif;
  font-weight: 700;
  font-size: 1.35rem;
  color: #1f2a44;
  margin: 0 0 20px 0;
  max-width: 100%;
}

.ttt-wrapper {
  font-family: 'Poppins', sans-serif;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: 100%;
  max-width: 280px;
  min-width: 0;
  margin: 0 auto;
  box-sizing: border-box;
}

.ttt-status {
  display: block;
  font-size: 1.05rem;
  font-weight: 600;
  margin-bottom: 16px;
  color: #1f2a44;
}

.ttt-board {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  width: 100%;
  max-width: 100%;
  min-width: 0;
  box-sizing: border-box;
}

.ttt-cell {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-width: 0;
  height: 0;
  padding: 50% 0;
  background: #ffffff;
  border: 1.5px solid var(--line, #d8d4cc);
  border-radius: 10px;
  box-shadow: 0 2px 6px rgba(31, 42, 68, 0.05);
  font-family: 'Montserrat', sans-serif;
  font-size: 2rem;
  font-weight: 700;
  line-height: 0;
  cursor: pointer;
  user-select: none;
  box-sizing: border-box;
  transition: background 0.15s ease, transform 0.1s ease, border-color 0.15s ease;
}

.ttt-cell:hover {
  background: #f5f2eb;
  border-color: #1f2a44;
}

.ttt-cell[data-mark="X"] {
  color: #2563eb;
}

.ttt-cell[data-mark="O"] {
  color: #dc2743;
}

.ttt-cell.ttt-win {
  background: #fef3c7;
  border-color: #f59e0b;
  transform: scale(1.04);
}

.ttt-reset-btn {
  margin-top: 20px;
  padding: 10px 24px;
  font-family: 'Montserrat', sans-serif;
  font-size: 0.95rem;
  font-weight: 600;
  border: none;
  border-radius: 8px;
  background: #1f2a44;
  color: #ffffff;
  cursor: pointer;
  transition: opacity 0.2s ease, transform 0.1s ease;
}

.ttt-reset-btn:hover {
  opacity: 0.9;
}

#lightbox {
  z-index: 9999;
}

@media (max-width: 640px) {
  .ttt-section {
    padding: 20px 16px;
  }

  .ttt-title {
    font-size: 1.15rem;
  }

  .ttt-wrapper {
    max-width: 240px;
  }

  .ttt-cell {
    font-size: 1.65rem;
  }
}
