:root{
  --blue: #0b5fb3;     
  --blue-hover:#094f93;
  --text:#1f2328;
  --muted:#6b7280;
  --border:#d1d5db;
  --bg:#f3f4f6;
  --white:#fff;
  --error:#d93025;
}

*{box-sizing:border-box}

html,body{
  height:100%;
}

body{
  margin:0;
  font-family: system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
  color:var(--text);
  background:var(--bg);
  display:flex;
  flex-direction:column;
}

.page{
  flex:1;
  display:flex;
  flex-direction:column;
  align-items:center;
  padding:40px 16px 24px;
}

.masthead{
  margin:12px 0 20px;
}
.brand-text{
  margin:0;
  font-size:28px;
  font-weight:700;
  color:var(--blue);
}

.card{
  width:100%;
  max-width:400px;
  background:var(--white);
  border:1px solid var(--border);
  border-radius:12px;
  padding:24px 20px;
  box-shadow:0 8px 24px rgba(0,0,0,0.06);
}

.card-title{
  margin:0 0 16px;
  font-size:20px;
  font-weight:700;
}

.form{
  display:flex;
  flex-direction:column;
  gap:14px;
}

.form input[type="email"],
.form input[type="password"]{
  width:100%;
  min-height:44px;
  padding:14px 12px;
  border:1px solid var(--border);
  border-radius:6px;
  font-size:15px;
  background:#fff;
  outline:none;
  transition:border .2s, box-shadow .2s, background .2s;
}

.form input[type="email"]:focus,
.form input[type="password"]:focus{
  border-color:var(--blue);
  box-shadow:0 0 0 3px rgba(11,95,179,0.15);
}

.form-row{
  display:flex;
  justify-content:flex-end;
  margin-top:-6px;
}

.link{
  color:var(--blue);
  text-decoration:none;
  font-weight:600;
}
.link:hover{ text-decoration:underline; }
.link.subtle{
  color:var(--muted);
  font-weight:500;
}

.btn{
  display:inline-block;
  width:100%;
  min-height:44px;
  padding:12px 14px;
  border-radius:24px;
  border:none;
  cursor:pointer;
  font-size:15px;
  font-weight:700;
}
.btn.primary{
  background:var(--blue);
  color:#fff;
  transition:background .2s, opacity .2s;
}
.btn.primary:hover{ background:var(--blue-hover); }
.btn[disabled]{ opacity:.65; cursor:not-allowed; }

/* Error */
.error{
  display:none;
  color:var(--error);
  font-size:13px;
  margin-top:-4px;
}

/* Divider with "or" text */
.divider-text {
  display: flex;
  align-items: center;
  text-align: center;
  color: var(--muted);
  font-size: 13px;
  margin: 18px 0 10px;
}
.divider-text::before,
.divider-text::after {
  content: "";
  flex: 1;
  border-bottom: 1px solid var(--border);
}
.divider-text:not(:empty)::before {
  margin-right: 0.75em;
}
.divider-text:not(:empty)::after {
  margin-left: 0.75em;
}

/* Social buttons */
.social-buttons {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 12px;
}
.btn.social {
  background: var(--white);
  color: var(--text);
  border: 1px solid var(--border);
  font-weight: 600;
  border-radius: 24px;
  transition: background .2s, box-shadow .2s;
}
.btn.social:hover {
  background: #f9fafb;
  box-shadow: 0 1px 3px rgba(0,0,0,0.08);
}
.btn.social.google { color: #202124; }
.btn.social.apple {
  background: #000;
  color: #fff;
  border: 1px solid #000;
}
.btn.social.apple:hover { background: #111; }

/* Small text */
.small{
  font-size:13px;
  color:var(--muted);
  margin:0;
  text-align:center;
}

/* Footer */
.footer{
  border-top:1px solid var(--border);
  background:transparent;
  padding:16px 12px 20px;
  text-align:center;
  margin-top:auto;   /* push footer to bottom */
}
.footer nav{
  display:flex;
  flex-wrap:wrap;
  gap:12px 16px;
  justify-content:center;
  margin-bottom:8px;
}
.footer-link{
  color:#4b5563;
  text-decoration:none;
  font-size:13px;
}
.footer-link:hover{ text-decoration:underline; }
.copyright{
  margin:0;
  font-size:12px;
  color:#6b7280;
}

/* Shake effect */
@keyframes shake {
  0% { transform: translateX(0); }
  25% { transform: translateX(-6px); }
  50% { transform: translateX(6px); }
  75% { transform: translateX(-6px)
