:root {
  --blue: #2563EB;
  --blue-hover: #1d4ed8;
  --bg: #0A0A0A;
  --card: #161616;
  --input: #1E1E1E;
  --border: #333333;
  --text: #F4F4F5;
  --text-muted: #ABABAB;
  --error: #EF4444;
  --orange: #F97316;
  --green: #22C55E;
  --yellow: #EAB308;
  --gold: #C9924A;
}

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

html,
body {
  height: 100%;
}

body {
  margin: 0;
  padding: 0;
  font-family: Inter, system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial, sans-serif;
  background: var(--bg);
  color: var(--text);
}

label {
  display: block;
  font-size: 13px;
  color: #F4F4F5;
  margin-bottom: 8px;
}

input[type="email"],
input[type="password"],
input[type="text"] {
  width: 100%;
  background: var(--input);
  border: 1px solid var(--border);
  color: var(--text);
  border-radius: 8px;
  padding: 12px 16px;
  transition: border-color 0.2s;
  font-size: 14px;
}

input,
textarea,
select {
  color: #CCCCCC;
  -webkit-text-fill-color: #CCCCCC !important;
}

input::placeholder,
textarea::placeholder {
  color: #6B6B6B;
  opacity: 1;
}

input:-webkit-autofill,
input:-webkit-autofill:hover,
input:-webkit-autofill:focus {
  -webkit-text-fill-color: #CCCCCC !important;
  box-shadow: 0 0 0px 1000px #1E1E1E inset !important;
}

input[type="email"]:focus,
input[type="password"]:focus,
input[type="text"]:focus {
  border-color: var(--blue);
  outline: none;
}

button {
  font-family: inherit;
}

.page {
  min-height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 32px 16px;
}

.title-top {
  position: absolute;
  top: 18px;
  left: 0;
  right: 0;
  text-align: center;
  color: var(--text-muted);
  font-size: 13px;
  letter-spacing: 3px;
  text-transform: uppercase;
}

.card {
  width: 100%;
  max-width: 420px;
  background: var(--card);
  border-radius: 12px;
  padding: 40px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.5);
}

.h1 {
  margin: 0 0 8px 0;
  font-size: 22px;
  font-weight: 600;
  color: var(--text);
}

.sub {
  margin: 0 0 32px 0;
  font-size: 14px;
  color: var(--text-muted);
}

.field {
  margin-bottom: 18px;
}

.muted {
  color: #F4F4F5;
  font-weight: 600;
}

.val {
  color: #ABABAB;
}

.password-wrap {
  position: relative;
}

.password-wrap input {
  padding-right: 48px;
}

.toggle-eye {
  position: absolute;
  top: 50%;
  right: 12px;
  transform: translateY(-50%);
  width: 34px;
  height: 34px;
  border: 0;
  background: transparent;
  color: var(--text-muted);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
}

.toggle-eye:hover {
  color: var(--text);
}

.row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin: 6px 0 8px;
}

.remember {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--text-muted);
  font-size: 13px;
  user-select: none;
}

.remember input {
  accent-color: var(--blue);
}

.submit {
  width: 100%;
  min-height: 48px;
  margin-top: 8px;
  background: var(--blue);
  color: var(--text);
  border: none;
  border-radius: 8px;
  padding: 14px;
  font-weight: 600;
  font-size: 15px;
  cursor: pointer;
  transition: background 0.15s, opacity 0.15s;
}

.submit:hover {
  background: var(--blue-hover);
}

.submit:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

#error-msg {
  display: none;
  color: var(--error);
  font-size: 14px;
  margin-top: 12px;
  text-align: center;
  padding: 10px;
  border-radius: 6px;
  background: rgba(239, 68, 68, 0.1);
}

.forgot {
  display: block;
  text-align: center;
  margin-top: 16px;
  font-size: 13px;
  color: var(--text-muted);
  text-decoration: none;
  transition: color 0.15s;
}

.forgot:hover {
  color: var(--text);
}

@media (max-width: 767px) {
  .page {
    padding: 0;
    align-items: flex-start;
    justify-content: flex-start;
    padding-top: 48px;
  }

  .card {
    max-width: none;
    width: 100%;
    border-radius: 0;
    padding: 24px;
    box-shadow: none;
  }

  .auth-card {
    min-height: calc(100vh - 48px);
  }
}

