* {
  margin: 0;
  padding: 0;

}

body {
  background: #f1f2f3;
}

.container {
  box-sizing: border-box;
  width: 100%;
  max-width: 1500px;
  min-width: 1240px;
  margin: 20px auto;
  background: rgba(255, 255, 255, 0.95);
  border-radius: 20px;
  box-shadow: 0 15px 50px rgba(0, 0, 0, 0.15);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  color: #333;
}

.container  *{
  box-sizing: border-box;
}

header {
  background: linear-gradient(90deg, #2c3e50, #4a6491);
  color: white;
  padding: 25px 40px;
  text-align: center;
}

h1 {
  font-size: 2.4rem;
  margin-bottom: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 15px;
}


.subtitle {
  font-size: 1rem;
  opacity: 0.9;
  max-width: 90%;
  margin: 0 auto;
  line-height: 1.6;
}

.content {
  display: flex;
  flex: 1;
  min-height: 650px;
}

.settings {
  width: 380px;
  background: #f8f9fa;
  padding: 25px;
  border-right: 1px solid #e0e0e0;
  display: flex;
  flex-direction: column;
  gap: 25px;
}

.game-area {
  flex: 1;
  padding: 25px;
  display: flex;
  flex-direction: column;
}

.section-title {
  font-size: 1.5rem;
  font-weight: 700;
  margin-bottom: 20px;
  color: #2c3e50;
  display: flex;
  align-items: center;
  gap: 10px;
}

.section-title span {
  font-size: 1.8rem;
}

.setting-group {
  background: white;
  border-radius: 12px;
  padding: 20px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
}

.setting-item {
  margin-bottom: 20px;
}

label {
  display: block;
  font-weight: 500;
  margin-bottom: 8px;
  color: #2c3e50;
}

input, select {
  width: 100%;
  padding: 12px 15px;
  border: 1px solid #ddd;
  border-radius: 8px;
  font-size: 1rem;
  background: #f9f9f9;
  transition: all 0.3s;
}

input:focus, select:focus {
  outline: none;
  border-color: #3498db;
  box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.2);
}

.checkbox-group {
  display: flex;
  align-items: center;
  gap: 10px;
}

.checkbox-group input {
  width: auto;
}

.btn-group {
  display: flex;
  flex-direction: column;
  gap: 15px;
  margin-top: 10px;
}

button {
  padding: 14px 20px;
  border: none;
  border-radius: 8px;
  font-size: 1.1rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
}

button span {
  font-size: 1.4rem;
}

.btn-primary {
  background: linear-gradient(90deg, #3498db, #2980b9);
  color: white;
}

.btn-primary:hover {
  background: linear-gradient(90deg, #2980b9, #2573a7);
  transform: translateY(-2px);
  box-shadow: 0 5px 15px rgba(52, 152, 219, 0.4);
}

.btn-secondary {
  background: linear-gradient(90deg, #2ecc71, #27ae60);
  color: white;
}

.btn-secondary:hover {
  background: linear-gradient(90deg, #27ae60, #219d54);
  transform: translateY(-2px);
  box-shadow: 0 5px 15px rgba(46, 204, 113, 0.4);
}

.btn-warning {
  background: linear-gradient(90deg, #e74c3c, #c0392b);
  color: white;
}

.btn-warning:hover {
  background: linear-gradient(90deg, #c0392b, #a93226);
  transform: translateY(-2px);
  box-shadow: 0 5px 15px rgba(231, 76, 60, 0.4);
}

.game-info {
  display: flex;
  justify-content: space-between;
  background: #e3f2fd;
  padding: 20px;
  border-radius: 12px;
  margin-bottom: 30px;
}

.info-item {
  text-align: center;
  padding: 10px;
}

.info-value {
  font-size: 1.6rem;
  font-weight: 700;
  color: #2980b9;
}

.game-controls {
  display: flex;
  gap: 15px;
  margin-bottom: 30px;
}

.guess-input {
  display: flex;
  gap: 15px;
  margin-bottom: 30px;
  align-items: center;
}

.guess-input input {
  flex: 1;
  font-size: 1.5rem;
  text-align: center;
  letter-spacing: 5px;
  padding: 15px;
  font-weight: 700;
}

.history-title {
  font-size: 1.3rem;
  font-weight: 700;
  margin-bottom: 15px;
  display: flex;
  align-items: center;
  gap: 10px;
}

.history-container {
  flex: 1;
  background: #f8f9fa;
  border-radius: 12px;
  padding: 20px;
  overflow-y: auto;
  max-height: 350px;
}

.history-item {
  padding: 15px;
  border-bottom: 1px solid #eee;
  display: flex;
  align-items: center;
  gap: 20px;
}

.attempt-number {
  font-weight: 700;
  color: #2980b9;
  min-width: 50px;
}

.guess-value {
  font-size: 1.4rem;
  font-weight: 700;
  letter-spacing: 3px;
  min-width: 200px;
}

.guess-result {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 1.3rem;
  font-weight: 700;
}

.a-value {
  color: #27ae60;
}

.b-value {
  color: #e67e22;
}

.size-hint {
  color: #2980b9;
  font-weight: 700;
}

.game-message {
  text-align: center;
  padding: 20px;
  font-size: 1.5rem;
  font-weight: 700;
  color: #27ae60;
  margin-top: 20px;
  display: none;
}

.answer-reveal {
  background: #fffde7;
  padding: 15px;
  border-radius: 10px;
  text-align: center;
  font-size: 1.5rem;
  font-weight: 700;
  letter-spacing: 3px;
  color: #c0392b;
  margin-top: 20px;
  display: none;
}

.instructions {
  background: #e3f2fd;
  padding: 25px;
  border-radius: 15px;
  margin-top: 30px;
}

.instructions h3 {
  font-size: 1.4rem;
  margin-bottom: 15px;
  color: #2c3e50;
  display: flex;
  align-items: center;
  gap: 10px;
}

.instructions ul {
  padding-left: 25px;
}

.instructions li {
  margin-bottom: 10px;
  line-height: 1.6;
}

.game-type-tabs {
  display: flex;
  gap: 10px;
  margin-bottom: 20px;
}

.game-tab {
  padding: 12px 25px;
  background: #e0e0e0;
  border-radius: 8px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s;
}

.game-tab.active {
  background: #3498db;
  color: white;
}

footer {
  text-align: center;
  padding: 20px;
  color: #8a8a8a;
  margin-top: 10px;
  font-size: 0.9rem;
}
