body {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: #f8f9fa;
  font-family: 'Noto Sans JP', sans-serif;
}

.container {
  max-width: 1200px;
  width: 100%;
  padding: 2rem;
}

/* ロゴのレスポンシブ対応 */
.site-logo {
  max-width: 100%;
  height: auto;
  max-height: 60px;
}

.main-title {
  font-weight: 700;
  font-size: 2.5rem;
  color: #333;
  margin-bottom: 2rem;
  text-align: center;
}

.login-frames-container {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
  max-width: 900px;
  margin: 0 auto;
}

.login-frame {
  justify-content: flex-start;
}

.register-frame {
  justify-content: center;
}

.register-content {
  text-align: center;
}

.register-description {
  font-size: 1.1rem;
  color: #666;
  margin-bottom: 2rem;
  line-height: 1.6;
}

/* メンテナンスフレームのスタイル */
.maintenance-frame {
  border: 3px solid #dc3545 !important;
  background-color: #fff5f5 !important;
  box-shadow: 0 4px 15px rgba(220, 53, 69, 0.2) !important;
}

.maintenance-frame .frame-header {
  background: linear-gradient(135deg, #dc3545 0%, #c82333 100%);
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
}

.maintenance-frame .frame-header h2 {
  color: white;
  font-weight: 700;
  margin: 0;
  line-height: 1.2;
}

.maintenance-message {
  background-color: #fff;
  border: 1px solid #f5c6cb;
  border-radius: 8px;
  padding: 1.5rem;
  color: #721c24;
  font-size: 1rem;
  line-height: 1.8;
  text-align: left;
  margin-bottom: 0;
}

.content-frame {
  max-width: 900px;
  margin: 0 auto;
}

.content-frame .forgot-password-frame,
.content-frame .register-frame {
  background: none;
  box-shadow: none;
  border: none;
  padding: 0;
  min-height: auto;
  display: block;
  justify-content: flex-start;
}

#mainView,
#forgotPasswordView,
#registerView,
#termsView {
  transition: opacity 0.3s ease;
}

@media (max-width: 768px) {
  .login-frames-container {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }

  .main-title {
    font-size: 2rem;
    margin-bottom: 2rem;
  }

  .login-frame,
  .register-frame {
    padding: 1.5rem;
  }

  /* モバイル表示時のロゴサイズ調整 */
  .site-logo {
    max-height: 45px;
  }
}

h1 {
  font-weight: 700;
  font-size: 1.8rem;
  color: #333;
}

.login-form {
  margin-top: 1.5rem;
}

.btn-primary {
  background-color: var(--primary-color);
  border-color: var(--primary-color);
  padding: 0.6rem 1rem;
  font-weight: 500;
  margin-top: 0.5rem;
  line-height: 1.5;
}

.btn-primary:hover {
  background-color: var(--primary-hover);
  border-color: var(--primary-hover);
}

/* 利用規約画面のスタイル */
#termsView {
  background: white;
  border-radius: 8px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
  padding: 2rem;
}

.terms-content {
  text-align: left;
}

.terms-text-container {
  background-color: #f8f9fa;
  border: 1px solid #dee2e6;
  border-radius: 4px;
  padding: 1.5rem;
  max-height: 400px;
  overflow-y: auto;
  margin-bottom: 1rem;
}

.terms-text {
  font-size: 0.9rem;
  line-height: 1.8;
  color: #333;
  white-space: pre-wrap;
  word-wrap: break-word;
  margin: 0;
  font-family: 'Noto Sans JP', sans-serif;
}

.form-check {
  padding-left: 1.5rem;
}

.form-check-input {
  cursor: pointer;
  width: 1.2rem;
  height: 1.2rem;
  margin-top: 0.2rem;
}

.form-check-label {
  cursor: pointer;
  font-size: 1rem;
  font-weight: 500;
  color: #333;
  user-select: none;
}

#acceptTermsBtn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

@media (max-width: 768px) {
  #termsView {
    padding: 1.5rem;
  }

  .terms-text-container {
    max-height: 300px;
    padding: 1rem;
  }

  .terms-text {
    font-size: 0.85rem;
  }
}