@import url("common.css");

/* Entry-page presentation. */
body.phase-landing,
body.phase-welcoming {
  min-height: 100svh;
}

body.phase-welcoming {
  background-color: var(--bg-welcoming);
  color: var(--text-dark);
}

#meshCanvas {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  z-index: 1;
  pointer-events: none;
  transition: opacity 1.5s ease-in-out;
}

.view-panel {
  width: 100%;
  min-height: 100svh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
}

.form-card {
  background: var(--card-blur-bg);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid rgba(190, 211, 239, 0.24);
  padding: 28px 20px;
  border-radius: 12px;
  width: 100%;
  max-width: 480px;
  box-shadow: 0 24px 48px rgba(0, 0, 0, 0.5);
  text-align: center;
}

.form-card h1,
.form-card h2 {
  line-height: 1.15;
}

.form-card h1 {
  font-size: clamp(2rem, 9vw, 3rem);
}

#sectionVerification .form-card h1 {
  font-size: clamp(0.5rem, 3vw, 1rem);
}

.form-card h2 {
  font-size: clamp(1.35rem, 6vw, 2rem);
}

.text-block {
  text-align: left;
}

.text-block p {
  margin-top: 20px;
  line-height: 1.7;
}

.welcoming-title {
  margin: 0;
  font-size: 1.1rem !important;
  text-align: center;
}

.divider-welcoming-message {
  border: none;
  border-top: 1px solid var(--bg-welcoming);
  margin: 16px 0;
}

.welcoming-message {
  width: 100%;
}

#welcomingMessageTo {
  text-align: left;
  margin: 0;
}

.welcoming-message-body {
  text-align: justify;
  margin-top: 0;
}

#welcomingMessageFrom {
  text-align: right;
  margin-top: 6px;
}

.greetingOnVerification {
  color: var(--accent-warm);
  font-size: 1.25rem;
  letter-spacing: 0.1em;
  margin-top: 24px;
  margin-bottom: 24px;
}

.input-group {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
}

input[type="text"] {
  width: 100%;
  min-height: 48px;
  padding: 12px 14px;
  background: rgba(11, 21, 48, 0.78);
  border: 1px solid var(--accent-disabled);
  border-radius: 8px;
  color: var(--text-light);
  font-size: 1rem;
  outline: none;
  transition: border-color 0.3s;
  text-align: center;
}

input[type="text"]::placeholder {
  color: rgba(245, 239, 230, 0.45);
  opacity: 1;
}

input[type="text"]::-ms-input-placeholder {
  color: rgba(245, 239, 230, 0.45);
}

input[type="text"]:focus {
  border-color: var(--accent-hover);
}

.checkbox-group {
  margin: 24px 0;
  text-align: center;
}

.custom-checkbox {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  cursor: pointer;
  font-size: 0.9rem;
  line-height: 1.45;
  color: var(--text-dark);
}

.custom-checkbox input {
  flex: 0 0 auto;
}

.btn-primary {
  width: 100%;
  min-height: 48px;
  padding: 12px 14px;
  background: var(--accent-warm);
  border: none;
  border-radius: 8px;
  color: var(--text-dark);
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition: background-color 0.3s, opacity 0.2s;
}

.btn-primary:hover:not(:disabled) {
  background: var(--accent-hover);
}

.btn-primary:disabled {
  background: var(--accent-disabled);
  color: rgba(242, 243, 241, 0.45);
  cursor: not-allowed;
}

.auth-error {
  color: #f28c8c;
  font-size: 0.85rem;
  margin-top: 12px;
}

body.phase-welcoming .form-card {
  background: rgba(239, 242, 238, 0.72);
  border-color: rgba(255, 255, 255, 0.48);
  box-shadow: 0 30px 60px rgba(35, 52, 72, 0.2);
}

body.phase-welcoming .btn-primary {
  background: #d69a6a;
  color: #17263a;
}

body.phase-welcoming .btn-primary:hover:not(:disabled) {
  background: #e4af83;
}

body.phase-welcoming .btn-primary:disabled {
  background: #a8b4bd;
  color: rgba(23, 38, 58, 0.45);
}

@media (min-width: 768px) {
  .view-panel {
    padding: 32px;
  }

  .form-card {
    padding: 40px;
    border-radius: 16px;
  }

  .greetingOnVerification {
    font-size: 2.2rem;
    margin-top: 16px;
    margin-bottom: 16px;
  }
}

@media (min-width: 1024px) {
  .view-panel {
    padding: 40px;
  }
}

@keyframes shake {
  0%, 100% { transform: translateX(0); }
  20%, 60% { transform: translateX(-6px); }
  40%, 80% { transform: translateX(6px); }
}

body.phase-welcoming #meshCanvas {
  opacity: 0.7;
}

body.phase-welcoming .form-card {
  color: var(--text-dark);
}
