/* AInalytics — tema dark identico al cockpit v97
   Palette: allineata con costanti JS T.* */

:root {
  --bg: #0b0d14;
  --sidebar: #11131c;
  --card: #161924;
  --input: #1a1d2a;
  --border: #252839;
  --text: #eaedf3;
  --muted: #7b809a;
  --accent: #4f8cff;
  --teal: #2dd4bf;
  --green: #3dd68c;
  --red: #ff5c5c;
  --amber: #ffb347;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  background: var(--bg);
  color: var(--text);
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, system-ui, sans-serif;
  font-size: 14px;
  line-height: 1.4;
}

a, .link {
  color: var(--accent);
  text-decoration: none;
}
a:hover, .link:hover { text-decoration: underline; }

/* ────────────────────────────────────────────
   AUTH PAGES (login, change-password, errors)
   ──────────────────────────────────────────── */
.auth-body {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.auth-wrap {
  width: 100%;
  max-width: 420px;
}

.auth-header {
  text-align: center;
  margin-bottom: 36px;
}

.auth-logo {
  width: 76px;
  height: 76px;
  border-radius: 20px;
  background: linear-gradient(135deg, var(--accent), var(--teal));
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 38px;
  margin-bottom: 18px;
  box-shadow: 0 8px 32px rgba(79, 140, 255, 0.28);
}

.auth-header h1 {
  font-size: 28px;
  font-weight: 700;
  margin: 0 0 6px;
  letter-spacing: -0.5px;
}

.auth-header p {
  color: var(--muted);
  font-size: 12px;
  margin: 0;
  letter-spacing: 0.3px;
}

.auth-card {
  background: var(--card);
  border-radius: 16px;
  padding: 32px 28px;
  border: 1px solid var(--border);
  box-shadow: 0 12px 48px rgba(0, 0, 0, 0.3);
}

.field {
  margin-bottom: 16px;
}

.field label {
  display: block;
  color: var(--muted);
  font-size: 11px;
  font-weight: 600;
  margin-bottom: 6px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.input-wrap {
  position: relative;
}

.input-wrap .icon {
  position: absolute;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 15px;
  opacity: 0.6;
}

.input-wrap input {
  width: 100%;
  background: var(--input);
  color: var(--text);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 11px 14px 11px 38px;
  font-size: 14px;
  outline: none;
  font-family: inherit;
  transition: border 0.15s;
}

.input-wrap input:focus {
  border-color: var(--accent);
}

.btn-primary {
  width: 100%;
  background: var(--accent);
  color: #fff;
  border: none;
  border-radius: 8px;
  padding: 13px;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  margin-top: 8px;
  letter-spacing: 0.3px;
  transition: background 0.2s;
}

.btn-primary:hover {
  background: #6b9dff;
}

.btn-primary:disabled {
  background: var(--muted);
  cursor: default;
}

.alert-error {
  color: var(--red);
  font-size: 12px;
  margin-bottom: 12px;
  padding: 8px 12px;
  background: rgba(255, 92, 92, 0.08);
  border-radius: 6px;
  border: 1px solid rgba(255, 92, 92, 0.25);
}

.alert-success {
  color: var(--green);
  font-size: 12px;
  margin-bottom: 12px;
  padding: 8px 12px;
  background: rgba(61, 214, 140, 0.08);
  border-radius: 6px;
  border: 1px solid rgba(61, 214, 140, 0.25);
}

.demo-box {
  margin-top: 20px;
  padding-top: 16px;
  border-top: 1px dashed var(--border);
  font-size: 10px;
  color: var(--muted);
  line-height: 1.6;
}

.demo-title {
  font-weight: 700;
  margin-bottom: 4px;
  color: var(--text);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.demo-box b {
  color: var(--accent);
}

.auth-footer {
  text-align: center;
  margin-top: 20px;
  color: var(--muted);
  font-size: 10px;
  letter-spacing: 0.5px;
}

/* ────────────────────────────────────────────
   APP / COCKPIT
   ──────────────────────────────────────────── */
.app-body {
  margin: 0;
  min-height: 100vh;
}

#app-root {
  min-height: 100vh;
}

.splash {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 16px;
}

.splash-logo {
  width: 64px;
  height: 64px;
  border-radius: 14px;
  background: linear-gradient(135deg, var(--accent), var(--teal));
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-weight: 800;
  font-size: 20px;
  animation: pulse 1.2s ease-in-out infinite;
}

.splash-text {
  color: var(--muted);
  font-size: 13px;
}

@keyframes pulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.7; transform: scale(0.95); }
}
