/* SPRINT_7_6A1_OTP_PROVIDER_FRONTEND_RECOVERY */
/* SPRINT_7_6A_GLOBAL_OTP_PROVIDER_ADMIN */
.otp-config-page {
  display: grid;
  gap: 18px;
}

.otp-config-page[hidden],
.otp-provider-panel[hidden] {
  display: none !important;
}

.otp-config-hero {
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 20px;
  padding: 25px;
  border: 1px solid #d7e5f8;
  border-radius: 24px;
  background:
    radial-gradient(
      circle at 90% 15%,
      rgba(25, 160, 245, 0.18),
      transparent 32%
    ),
    linear-gradient(
      145deg,
      #ffffff,
      #edf5ff
    );
}

.otp-config-hero h2 {
  margin: 7px 0 8px;
  color: #0f6926;
  font-size: clamp(23px, 3vw, 34px);
}

.otp-config-hero p {
  max-width: 760px;
  margin: 0;
  color: #648b6e;
  line-height: 1.65;
}

.otp-config-badge {
  padding: 9px 12px;
  border: 1px solid #b8fac8;
  border-radius: 999px;
  background: #eaf3ff;
  color: #07d83b;
  font-size: 11px;
  font-weight: 900;
  white-space: nowrap;
}

.otp-selector-card,
.otp-panel {
  border: 1px solid #dbe5f1;
  border-radius: 22px;
  background: #ffffff;
  box-shadow:
    0 18px 50px
    rgba(15, 47, 105, 0.07);
}

.otp-selector-card {
  display: grid;
  grid-template-columns:
    minmax(220px, 1fr)
    minmax(220px, 1fr)
    auto;
  gap: 12px;
  align-items: end;
  padding: 16px;
}

.otp-panel {
  display: grid;
  gap: 18px;
  padding: 20px;
}

.otp-panel-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
}

.otp-panel-header h3,
.otp-section-title h4 {
  margin: 4px 0 0;
  color: #0f6926;
}

.otp-panel-header p {
  max-width: 720px;
  margin: 7px 0 0;
  color: #648b6e;
  font-size: 12px;
  line-height: 1.55;
}

.otp-switch {
  display: flex;
  align-items: center;
  gap: 9px;
  min-width: 145px;
  padding: 11px 13px;
  border: 1px solid #cfe0f7;
  border-radius: 14px;
  background: #f4f8ff;
  color: #0f6926;
  font-size: 12px;
  font-weight: 900;
}

.otp-switch input {
  width: 17px;
  height: 17px;
  accent-color: #07d83b;
}

.otp-provider-grid {
  display: grid;
  grid-template-columns:
    repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.otp-provider-card {
  min-height: 118px;
  display: grid;
  grid-template-columns: 44px 1fr;
  grid-template-rows: auto auto;
  gap: 4px 12px;
  align-items: center;
  padding: 16px;
  border: 1px solid #dbe5f1;
  border-radius: 18px;
  background: #f9fbff;
  color: #0f2a16;
  text-align: left;
  cursor: pointer;
  transition:
    border-color 160ms ease,
    transform 160ms ease,
    box-shadow 160ms ease;
}

.otp-provider-card:hover {
  transform: translateY(-2px);
  border-color: #8ff2a8;
}

.otp-provider-card.active {
  border-color: #07d83b;
  background:
    linear-gradient(
      145deg,
      #eff6ff,
      #ffffff
    );
  box-shadow:
    0 12px 30px
    rgba(7, 91, 216, 0.12);
}

.otp-provider-icon {
  grid-row: 1 / span 2;
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  background:
    linear-gradient(
      145deg,
      #07d83b,
      #19f550
    );
  color: #ffffff;
  font-size: 17px;
  font-weight: 900;
}

.otp-provider-card strong {
  color: #0f6926;
  font-size: 15px;
}

.otp-provider-card small {
  color: #648b6e;
  line-height: 1.45;
}

.otp-provider-panel {
  padding: 17px;
  border: 1px solid #e2e8f0;
  border-radius: 18px;
  background: #f9fbfe;
}

.otp-section-title {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 14px;
}

.otp-secret-state {
  padding: 6px 9px;
  border-radius: 999px;
  background: #fee2e2;
  color: #b91c1c;
  font-size: 10px;
  font-weight: 900;
}

.otp-secret-state.configured {
  background: #dcfce7;
  color: #15803d;
}

.otp-grid {
  display: grid;
  grid-template-columns:
    repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.otp-policy-grid {
  display: grid;
  grid-template-columns:
    repeat(5, minmax(0, 1fr));
  gap: 10px;
}

.otp-field {
  display: grid;
  gap: 7px;
}

.otp-field > span {
  color: #33553c;
  font-size: 11px;
  font-weight: 900;
}

.otp-field input,
.otp-field select,
.otp-field textarea {
  width: 100%;
  box-sizing: border-box;
  padding: 11px 12px;
  border: 1px solid #d8e1ee;
  border-radius: 13px;
  outline: none;
  background: #ffffff;
  color: #0f2a16;
  font: inherit;
}

.otp-field input:focus,
.otp-field select:focus,
.otp-field textarea:focus {
  border-color: #07d83b;
  box-shadow:
    0 0 0 3px
    rgba(7, 91, 216, 0.1);
}

.otp-field small {
  color: #648b6e;
  font-size: 10px;
}

.otp-field-wide {
  grid-column: span 2;
}

.otp-field-full {
  grid-column: 1 / -1;
}

.otp-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
}

.otp-button {
  min-height: 42px;
  padding: 10px 15px;
  border-radius: 13px;
  font: inherit;
  font-size: 12px;
  font-weight: 900;
  cursor: pointer;
}

.otp-button:disabled {
  opacity: 0.55;
  cursor: wait;
}

.otp-button.primary {
  border: 1px solid #07d83b;
  background:
    linear-gradient(
      145deg,
      #07d83b,
      #13e848
    );
  color: #ffffff;
}

.otp-button.secondary {
  border: 1px solid #bdefca;
  background: #ffffff;
  color: #07d83b;
}

.otp-button.test {
  border: 1px solid #15a565;
  background: #e9fff4;
  color: #087f4b;
}

.otp-test-panel {
  margin-bottom: 20px;
}

.otp-test-grid {
  display: grid;
  grid-template-columns:
    minmax(220px, 1fr)
    minmax(220px, 1fr)
    auto;
  gap: 12px;
  align-items: end;
}

.otp-test-result {
  min-height: 48px;
  display: grid;
  align-content: center;
  gap: 3px;
  padding: 12px 14px;
  border: 1px dashed #b8cbe3;
  border-radius: 14px;
  background: #f8fbff;
  color: #47694f;
  font-size: 11px;
}

.otp-test-result strong,
.otp-test-result span {
  display: block;
}

.otp-test-result strong {
  color: #0f6926;
}

@media (max-width: 1100px) {
  .otp-policy-grid {
    grid-template-columns:
      repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 780px) {
  .otp-config-hero,
  .otp-panel-header,
  .otp-section-title {
    flex-direction: column;
  }

  .otp-selector-card,
  .otp-provider-grid,
  .otp-grid,
  .otp-policy-grid,
  .otp-test-grid {
    grid-template-columns: 1fr;
  }

  .otp-field-wide,
  .otp-field-full {
    grid-column: auto;
  }

  .otp-actions {
    flex-direction: column;
  }

  .otp-button {
    width: 100%;
  }
}
