/* RCSpotter — shared auth form styles */
.rcs-password-field {
  display: grid;
  grid-template-columns: 1fr;
  grid-template-rows: auto;
  width: 100%;
  margin: 0;
}

.rcs-password-field input {
  grid-column: 1;
  grid-row: 1;
  width: 100%;
  box-sizing: border-box;
  padding-right: 2.85rem !important;
  margin: 0;
}

.rcs-password-field input:-webkit-autofill,
.rcs-password-field input:-webkit-autofill:hover,
.rcs-password-field input:-webkit-autofill:focus {
  -webkit-box-shadow: 0 0 0 1000px #0f172a inset;
  -webkit-text-fill-color: #f9fafb;
  caret-color: #f9fafb;
}

.rcs-password-toggle {
  grid-column: 1;
  grid-row: 1;
  justify-self: end;
  align-self: center;
  z-index: 2;
  border: none;
  background: transparent;
  color: #94a3b8;
  cursor: pointer;
  padding: 0;
  margin: 0 8px 0 0;
  width: 2.25rem !important;
  min-width: 2.25rem !important;
  max-width: 2.25rem !important;
  height: 2.25rem;
  flex: none !important;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  line-height: 0;
}

.rcs-password-toggle-icon {
  display: block;
  pointer-events: none;
}

.rcs-password-toggle:hover {
  background: rgba(148, 163, 184, 0.14);
  color: #e2e8f0;
}

.rcs-password-toggle:focus-visible {
  outline: 2px solid #22c55e;
  outline-offset: 2px;
}

.rcs-auth-hint {
  font-size: 12px;
  color: #9ca3af;
  margin: 4px 0 10px;
  line-height: 1.45;
}

.rcs-agreement-label {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  font-size: 13px;
  line-height: 1.45;
  margin: 12px 0 0;
  cursor: pointer;
}

.rcs-agreement-label input {
  width: auto;
  margin-top: 3px;
  flex-shrink: 0;
}

.rcs-lang-select {
  width: 100%;
  margin: 0 0 10px;
  padding: 8px 10px;
  border-radius: 8px;
  border: 1px solid var(--rcs-border, rgba(148, 163, 184, 0.35));
  background: var(--rcs-input-bg, #0f172a);
  color: var(--rcs-text, #f9fafb);
  font: inherit;
}

.rcs-auth-hint--compact {
  font-size: 10px;
  margin: 2px 0 6px;
  line-height: 1.35;
}

.rcs-lang-dropdown {
  position: relative;
  margin: 0 0 8px;
}

.rcs-lang-dropdown__trigger {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  width: 100%;
  box-sizing: border-box;
  padding: 8px 10px;
  border-radius: 8px;
  border: 1px solid var(--rcs-border, rgba(148, 163, 184, 0.35));
  background: var(--rcs-input-bg, #0f172a);
  color: var(--rcs-text, #f9fafb);
  cursor: pointer;
  font: inherit;
  text-align: left;
}

.rcs-lang-dropdown__trigger-inner,
.rcs-lang-dropdown__option {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}

.rcs-lang-dropdown__option {
  width: 100%;
  padding: 8px 10px;
  border: none;
  border-radius: 6px;
  background: transparent;
  color: inherit;
  cursor: pointer;
  font: inherit;
  text-align: left;
}

.rcs-lang-dropdown__chevron {
  flex-shrink: 0;
  color: var(--rcs-muted, #94a3b8);
  transition: transform 0.15s ease;
}

.rcs-lang-dropdown.is-open .rcs-lang-dropdown__chevron {
  transform: rotate(180deg);
}

.rcs-lang-dropdown__menu {
  position: absolute;
  top: calc(100% + 4px);
  left: 0;
  right: 0;
  z-index: 50;
  margin: 0;
  padding: 4px;
  list-style: none;
  border-radius: 8px;
  border: 1px solid var(--rcs-border, rgba(148, 163, 184, 0.35));
  background: var(--rcs-panel, #1e293b);
  max-height: 220px;
  overflow-y: auto;
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.4);
}

.rcs-lang-dropdown__flag {
  display: block;
  width: 24px;
  height: 18px;
  object-fit: cover;
  border-radius: 2px;
  flex-shrink: 0;
  box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.15);
}

.rcs-lang-dropdown__label {
  font-size: 13px;
  font-weight: 600;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.rcs-lang-dropdown__code {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.04em;
  color: var(--rcs-muted, #94a3b8);
}

.rcs-lang-dropdown__option:hover,
.rcs-lang-dropdown__option.is-active {
  background: rgba(34, 197, 94, 0.12);
}

[data-theme="light"] .rcs-lang-dropdown__trigger,
[data-theme="light"] .rcs-lang-dropdown__menu {
  background: var(--rcs-input-bg, #fff);
  color: var(--rcs-text, #0f172a);
}

[data-theme="light"] .rcs-lang-dropdown__menu {
  background: var(--rcs-panel, #f8fafc);
}

.auth-modal .rcs-lang-dropdown__trigger {
  width: 100%;
  padding: 9px 10px;
  border-radius: 8px;
  border: 1px solid var(--border, rgba(148, 163, 184, 0.35));
  background: #0f172a;
  color: #f9fafb;
}

.auth-modal .rcs-units-preset-select {
  margin-bottom: 8px;
}

.auth-modal .rcs-agreement-label {
  margin-top: 8px;
}

.rcs-auth-lang-picker {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 0 0 8px;
}

.rcs-auth-lang-picker__btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  min-width: 52px;
  padding: 6px 8px;
  border-radius: 8px;
  border: 1px solid var(--rcs-border, rgba(148, 163, 184, 0.35));
  background: var(--rcs-input-bg, rgba(15, 23, 42, 0.92));
  color: var(--rcs-text, #f9fafb);
  cursor: pointer;
  font: inherit;
  line-height: 1.1;
}

.rcs-auth-lang-picker__btn:hover {
  border-color: rgba(134, 239, 172, 0.45);
  background: rgba(30, 41, 59, 0.95);
}

.rcs-auth-lang-picker__btn.is-active {
  border-color: #86efac;
  box-shadow: 0 0 0 1px rgba(134, 239, 172, 0.35);
  background: rgba(34, 197, 94, 0.12);
}

.rcs-auth-lang-picker__flag {
  display: block;
  width: 28px;
  height: 21px;
  object-fit: cover;
  border-radius: 2px;
  box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.15);
}

.rcs-auth-lang-picker__code {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.04em;
  color: var(--rcs-muted, #94a3b8);
}

.rcs-auth-lang-picker__btn.is-active .rcs-auth-lang-picker__code {
  color: #bbf7d0;
}

.rcs-units-preset-select {
  width: 100%;
  margin: 0 0 10px;
  padding: 8px 10px;
  border-radius: 8px;
  border: 1px solid var(--rcs-border, rgba(148, 163, 184, 0.35));
  background: var(--rcs-input-bg, #0f172a);
  color: var(--rcs-text, #f9fafb);
  font: inherit;
}

[data-theme="light"] .rcs-auth-lang-picker__btn,
[data-theme="light"] .rcs-units-preset-select {
  background: var(--rcs-input-bg, #fff);
  color: var(--rcs-text, #0f172a);
}

[data-theme="light"] .rcs-auth-lang-picker__btn.is-active {
  background: rgba(34, 197, 94, 0.1);
}

.auth-modal .rcs-auth-lang-picker__btn {
  flex: 0 0 auto;
  width: auto;
  min-width: 52px;
  padding: 6px 8px;
  font-weight: 600;
}

.auth-modal .rcs-units-preset-select {
  width: 100%;
  box-sizing: border-box;
  padding: 9px 10px;
  border-radius: 8px;
  border: 1px solid var(--border, rgba(148, 163, 184, 0.35));
  background: #0f172a;
  color: #f9fafb;
}

.auth-modal .rcs-units-preset-select option {
  background: #0f172a;
  color: #f9fafb;
}

[data-theme="light"] .rcs-lang-select {
  background: var(--rcs-input-bg, #fff);
  color: var(--rcs-text, #0f172a);
}

.rcs-agreement-label a {
  color: #86efac;
}

.rcs-auth-register-only[hidden] {
  display: none !important;
}

.auth-modal .rcs-password-field input,
.auth-modal .rcs-agreement-label input {
  width: 100%;
}

.auth-modal .rcs-agreement-label input {
  width: auto;
}

.auth-modal button.rcs-password-toggle {
  flex: none !important;
  border: none;
  background: transparent;
  color: #94a3b8;
  padding: 0;
  width: 2.25rem !important;
  min-width: 2.25rem !important;
  max-width: 2.25rem !important;
  height: 2.25rem;
  border-radius: 8px;
}

.auth-modal button.rcs-password-toggle:hover {
  background: rgba(148, 163, 184, 0.14);
  color: #e2e8f0;
}

.rcs-pilot-page .rcs-password-field button.rcs-password-toggle {
  flex: none !important;
  width: 2.25rem !important;
  min-width: 2.25rem !important;
  max-width: 2.25rem !important;
  height: 2.25rem;
  padding: 0;
  font-size: inherit;
  font-weight: inherit;
  border: none;
  background: transparent;
  color: #94a3b8;
  border-radius: 8px;
}

[data-theme="light"] .rcs-password-toggle,
[data-theme="light"] .auth-modal button.rcs-password-toggle,
[data-theme="light"] .rcs-pilot-page .rcs-password-field button.rcs-password-toggle {
  color: #64748b;
}

[data-theme="light"] .rcs-password-toggle:hover,
[data-theme="light"] .auth-modal button.rcs-password-toggle:hover,
[data-theme="light"] .rcs-pilot-page .rcs-password-field button.rcs-password-toggle:hover {
  background: rgba(15, 23, 42, 0.06);
  color: #0f172a;
}

[data-theme="light"] .rcs-password-field input:-webkit-autofill,
[data-theme="light"] .rcs-password-field input:-webkit-autofill:hover,
[data-theme="light"] .rcs-password-field input:-webkit-autofill:focus {
  -webkit-box-shadow: 0 0 0 1000px #fff inset;
  -webkit-text-fill-color: #0f172a;
  caret-color: #0f172a;
}

.card .rcs-password-field input {
  padding-right: 2.85rem !important;
}

.card button.rcs-password-toggle {
  width: 2.25rem !important;
  min-width: 2.25rem !important;
  max-width: 2.25rem !important;
}

.rcs-auth-forgot {
  margin: 2px 0 12px;
  font-size: 13px;
  text-align: right;
}

.rcs-auth-forgot a {
  color: #86efac;
  text-decoration: none;
}

.rcs-auth-forgot a:hover {
  text-decoration: underline;
}

[data-theme="light"] .rcs-auth-forgot a {
  color: #15803d;
}

.rcs-auth-login-only[hidden] {
  display: none !important;
}
