/* Layout + utilities for Skimmer login (mirrors FusionAuth hosted theme) */
:root {
  --page-background: #F4F5F6;
  --panel-background: #FFFFFF;
  --font-color: #313438;
  --primary-button: #4795EC;
  --primary-button-focus: #3570B1;
  --primary-button-text: #FFFFFF;
  --link-color: #4795EC;
  --input-text: #313438;
  --input-bg: #FFFFFF;
  --panel-border: #D0D2D4;
}

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

body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  font-family: 'Open Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Helvetica, Arial, sans-serif;
  font-size: 14px;
  line-height: 1.43;
  color: var(--font-color);
  background: var(--page-background);
  -webkit-font-smoothing: antialiased;
}

main.page-main {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 60px 20px 24px;
  background: var(--page-background);
}

.login-wrap {
  width: 100%;
  max-width: 400px;
}

.logo-row {
  display: flex;
  justify-content: center;
  margin-bottom: 24px;
}

.skmr-logo { height: 40px; width: auto; }

.login-card {
  background: var(--panel-background);
  border-radius: 8px;
  box-shadow: 0 0 5px -2px rgba(10, 10, 11, 0.1), 0 3px 4px 0 rgba(10, 10, 11, 0.1);
  overflow: hidden;
}

.login-card-inner { padding: 32px; }

.login-title {
  font-size: 16px;
  font-weight: 600;
  text-align: center;
  margin: 0 0 24px;
  line-height: 1.25rem;
}

.login-form { display: flex; flex-direction: column; }

.field { margin-bottom: 16px; }

label.field-label {
  display: block;
  font-size: 14px;
  font-weight: 600;
  margin-bottom: 8px;
  line-height: 1rem;
  color: var(--input-text);
}

input.field-input {
  display: block;
  width: 100%;
  font-size: 14px;
  line-height: 1.43;
  padding: 12px;
  border: 1px solid #D0D2D4;
  border-radius: 6px;
  background: var(--input-bg);
  color: var(--input-text);
  outline: none;
}

input.field-input:focus {
  border-color: var(--link-color);
  box-shadow: 0 0 0 3px rgba(71, 149, 236, 0.35);
}

input.field-input::placeholder { color: rgba(49, 52, 56, 0.5); }

input.field-input.is-invalid {
  border-color: #DB382B;
  box-shadow: 0 0 0 3px rgba(219, 56, 43, 0.2);
}

.field-error-text {
  display: none;
  margin: 6px 0 0;
  font-size: 12px;
  line-height: 1.33;
  color: #DB382B;
  font-weight: 400;
  letter-spacing: normal;
}

.field-error-text.is-visible {
  display: block;
}

.field-label.is-invalid {
  color: #DB382B;
}

.password-wrap { position: relative; }

.checkbox-row {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  margin-top: 4px;
}

.checkbox-row input[type="checkbox"] {
  width: 16px;
  height: 16px;
  margin-top: 2px;
  accent-color: var(--primary-button);
  border-radius: 2px;
}

.checkbox-row label {
  font-size: 14px;
  line-height: 1.43;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}

.info-icon {
  width: 16px;
  height: 16px;
  color: #256295;
  flex-shrink: 0;
}

.btn-primary {
  display: block;
  width: 100%;
  margin-top: 24px;
  padding: 12px 16px;
  font-size: 14px;
  font-weight: 600;
  line-height: 20px;
  color: var(--primary-button-text);
  background: var(--primary-button);
  border: none;
  border-radius: 6px;
  cursor: pointer;
  transition: background-color 0.15s ease;
}

.btn-primary:hover { background: var(--primary-button-focus); }
.btn-primary:active { background: #244B76; }

.login-links {
  margin-top: 24px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  text-align: center;
  font-size: 14px;
}

.login-links a {
  color: var(--link-color);
  text-decoration: none;
}

.login-links a:hover { text-decoration: underline; }

.site-footer {
  width: 100%;
  max-width: 400px;
  margin: 24px auto 24px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  font-size: 12px;
  color: rgba(49, 52, 56, 0.7);
}

.site-footer a {
  color: var(--link-color);
  text-decoration: none;
}

.site-footer a:hover { text-decoration: underline; }

.footer-links { display: flex; gap: 12px; align-items: center; }

.login-alert {
  display: none;
  align-items: flex-start;
  gap: 10px;
  padding: 12px 14px;
  margin-bottom: 16px;
  border-radius: 6px;
  background: #F8D6D4;
  color: #AF2C22;
  font-size: 14px;
  line-height: 1.43;
}

.login-alert.is-visible { display: flex; }

.login-alert svg {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
  margin-top: 1px;
}

.btn-primary:disabled {
  opacity: 0.7;
  cursor: wait;
}
