/* https://stylelint.io/demo/# */

@font-face {
  font-family: Raleway;
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url('../fonts/Raleway-VariableFont_wght.woff2') format('woff2-variations'),
       url('../fonts/Raleway-VariableFont_wght.woff2') format('woff2');
}

@font-face {
  font-family: Raleway;
  font-style: italic;
  font-weight: 100 900;
  font-display: swap;
  src: url('../fonts/Raleway-Italic-VariableFont_wght.woff2') format('woff2-variations'),
       url('../fonts/Raleway-Italic-VariableFont_wght.woff2') format('woff2');
}

:root {
  /* Colors - Teambox & Tealk Design Tokens */
  --tb-bg-page: #13152a;
  --tb-bg-card: #fff;
  --tb-text-main: #202a4d;
  --tb-text-muted: #6c757d;
  --tb-text-version: rgb(255 255 255 / 75%);

  /* Primary Brand (Teambox Orange) */
  --tb-primary: #e0593f;
  --tb-primary-hover: #d0513d;
  --tb-primary-focus-ring: rgb(224 89 63 / 25%);
  --tb-primary-btn-focus-ring: rgb(224 89 63 / 40%);

  /* Borders & Shadows */
  --tb-border-card: rgb(255 255 255 / 8%);
  --tb-border-input: #dee2e6;
  --tb-shadow-card: 0 1rem 3rem rgb(0 0 0 / 45%);

  /* Danger / Alert */
  --tb-danger: #c8313f;
  --tb-alert-bg: #f8d7da;
  --tb-alert-border: #f5c2c7;
  --tb-alert-text: #842029;
}

*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  height: 100%;
  overflow: hidden;
}

body {
  background: var(--tb-bg-page);
  font-family: Raleway, system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  font-size: 1rem;
  line-height: 1.5;
  color: var(--tb-text-main);
  height: 100%;
  overflow: hidden;
  -webkit-overflow-scrolling: auto;
}

.centered-card {
  position: fixed;
  top: 50%;
  left: 50%;
  -webkit-transform: translate(-50%, -50%);
  transform: translate(-50%, -50%);
  width: 480px;
  max-width: 92vw;
}

.card {
  position: relative;
  display: flex;
  flex-direction: column;
  min-width: 0;
  overflow-wrap: break-word;
  background-color: var(--tb-bg-card);
  background-clip: border-box;
  border: 1px solid var(--tb-border-card);
  border-radius: 0.5rem;
  padding: 3rem;
  box-shadow: var(--tb-shadow-card);
}

.text-center {
  text-align: center;
  overflow-wrap: anywhere;
}

.p-2 {
  padding: 0.5rem;
}

.p-3 {
  padding: 1rem;
}

.fw-semibold {
  font-weight: 600;
}

.text-danger {
  color: var(--tb-danger) !important;
}

label {
  display: block;
  margin-bottom: 0.25rem;
}

label.mt-3 {
  margin-top: 1rem;
}

.required::after, label.required::after {
  content: " *";
  font-weight: bold;
}

.form-control {
  display: block;
  width: 100%;
  padding: 0.4rem 0.75rem;
  font-size: 16px;
  font-family: inherit;
  font-weight: 400;
  line-height: 1.5;
  color: var(--tb-text-main);
  background-color: #fff;
  background-clip: padding-box;
  border: 1px solid var(--tb-border-input);
  border-radius: 0.4rem;
  transition: border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
  outline: 0;
}

.form-control:focus {
  outline: 0;
  border-color: var(--tb-primary);
  box-shadow: 0 0 0 0.25rem var(--tb-primary-focus-ring);
}

.password-field-wrapper {
  position: relative;
  display: flex;
  align-items: center;
  width: 100%;
}

.password-field-wrapper .form-control {
  padding-right: 2.75rem;
}

.btn-toggle-password {
  position: absolute;
  right: 0.5rem;
  top: 50%;
  transform: translateY(-50%);
  background: transparent;
  border: none;
  padding: 0.25rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  outline: 0;
}

.btn-toggle-password .eye-icon {
  display: inline-block;
  vertical-align: middle;
  pointer-events: none;
  opacity: 0.7;
  transition: opacity 0.15s ease-in-out;
}

.btn-toggle-password:hover .eye-icon {
  opacity: 1;
}

.btn-toggle-password:focus-visible {
  outline: 2px solid var(--tb-primary-focus-ring);
  border-radius: 0.25rem;
}

input:focus {
  outline: 0;
  border-color: var(--tb-primary) !important;
  box-shadow: 0 0 0 0.25rem var(--tb-primary-focus-ring) !important;
}

.my-3 {
  margin-top: 1rem;
  margin-bottom: 1rem;
}

.btn {
  display: inline-block;
  padding: 0.5rem 1.25rem;
  font-size: 1rem;
  font-family: inherit;
  font-weight: 600;
  line-height: 1.5;
  color: #fff;
  text-align: center;
  text-decoration: none;
  vertical-align: middle;
  cursor: pointer;
  border: 1px solid transparent;
  border-radius: 0.4rem;
  transition: color 0.15s ease-in-out, background-color 0.15s ease-in-out, border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
  -webkit-appearance: none;
  appearance: none;
}

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

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

.btn-primary:focus {
  outline: none;
  box-shadow: 0 0 0 0.25rem var(--tb-primary-btn-focus-ring);
}

.alert-danger {
  color: var(--tb-alert-text);
  background-color: var(--tb-alert-bg);
  border: 1px solid var(--tb-alert-border);
  border-radius: 0.4rem;
  font-size: 0.9rem;
  overflow-wrap: anywhere;
}

.app-version {
  position: fixed;
  bottom: 0.75rem;
  left: 1rem;
  font-size: 0.75rem;
  color: var(--tb-text-version);
  -webkit-user-select: none;
  user-select: none;
  pointer-events: none;
}

.spinner {
  display: inline-block;
  width: 1rem;
  height: 1rem;
  vertical-align: -0.15em;
  margin-right: 0.5rem;
  border: 2px solid #fff;
  border-right-color: transparent;
  border-radius: 50%;
  -webkit-animation: spinner-border 0.75s linear infinite;
  animation: spinner-border 0.75s linear infinite;
}

@-webkit-keyframes spinner-border {
  to {
    -webkit-transform: rotate(360deg);
    transform: rotate(360deg);
  }
}

@keyframes spinner-border {
  to {
    transform: rotate(360deg);
  }
}

.btn:disabled {
  opacity: 0.85;
  cursor: not-allowed;
  transform: none;
}

/* Prevent iOS Safari from auto-coloring detected text (addresses, hostnames) */
a[x-apple-data-detectors],
.server-info a {
  color: inherit !important;
  text-decoration: none !important;
  font-size: inherit !important;
  font-family: inherit !important;
  font-weight: inherit !important;
  line-height: inherit !important;
  pointer-events: none !important;
  cursor: default !important;
}

.server-info, .server-info * {
  color: var(--tb-text-main) !important;
  text-decoration: none !important;
}

.server-hostname, .server-hostname * {
  font-size: 0.85rem !important;
  color: var(--tb-text-muted) !important;
  margin-top: 0.35rem;
  text-decoration: none !important;
  pointer-events: none !important;
  cursor: default !important;
}

@media (max-width: 576px) {
  .card {
    padding: 1.75rem 1.25rem;
  }

  .btn {
    width: 100%;
    padding: 0.6rem 1rem;
  }

  .app-version {
    bottom: 0.5rem;
    left: 0.75rem;
    font-size: 0.7rem;
  }
}
