/* ==========================================================================
   myAURA — Design System
   Utilitarian, form-first aesthetic. Built for clarity over decoration.
   ========================================================================== */

@import url('https://fonts.googleapis.com/css2?family=Archivo:wght@500;600;700&family=IBM+Plex+Sans:wght@400;500;600&family=IBM+Plex+Mono:wght@500;600&display=swap');

:root {
  /* Palette */
  --navy:    #173353;
  --slate:   #2E4965;
  --sky:     #2E7FD5;
  --gold:    #B8924A;
  --cream:   #F6F4EF;
  --frost:   #E7F0FA;
  --green:   #2E7D52;
  --muted:   #687185;
  --ink:     #1C2733;
  --border:  #D7DCE3;
  --paper:   #FFFFFF;

  /* Type */
  --font-display: 'Archivo', 'Helvetica Neue', Arial, sans-serif;
  --font-body:    'IBM Plex Sans', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-mono:    'IBM Plex Mono', 'SF Mono', Consolas, monospace;

  /* Shape */
  --radius:    3px;
  --radius-lg: 4px;

  /* Elevation — kept flat; depth comes from borders, not shadow */
  --shadow:    0 1px 2px rgba(23, 51, 83, 0.06);
  --shadow-lg: 0 2px 8px rgba(23, 51, 83, 0.08);
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 15px;
  line-height: 1.55;
  color: var(--ink);
  background: var(--paper);
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-display);
  font-weight: 700;
  letter-spacing: -0.01em;
  margin: 0;
}

a { color: var(--sky); text-decoration: none; }
a:hover { text-decoration: underline; }

:focus-visible {
  outline: 2px solid var(--sky);
  outline-offset: 2px;
}

img { max-width: 100%; display: block; }

/* ==========================================================================
   Layout helpers
   ========================================================================== */

.container-wide {
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 2rem;
}

.hide-mobile { }

@media (max-width: 720px) {
  .hide-mobile { display: none !important; }
}

.hidden { display: none !important; }

.mb-1 { margin-bottom: 0.5rem; }
.mb-2 { margin-bottom: 1rem; }
.mt-2 { margin-top: 1rem; }

.text-sm { font-size: 0.85rem; }
.text-center { text-align: center; }
.text-muted { color: var(--muted); }

/* ==========================================================================
   Navigation
   A fixed registry bar — wordmark left, utility links right.
   ========================================================================== */

.nav {
  background: var(--navy);
  border-bottom: 3px solid var(--sky);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 1.5rem;
  height: 60px;
  position: sticky;
  top: 0;
  z-index: 100;
}

.nav-brand {
  display: flex;
  align-items: center;
  gap: 0.625rem;
}

.nav-brand-mark {
  width: 32px;
  height: 32px;
  background: var(--sky);
  color: var(--navy);
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.05rem;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius);
}

.nav-brand-text {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.1rem;
  color: white;
  letter-spacing: 0.01em;
}

.nav-brand-text span { color: var(--sky); }

.nav-links {
  display: flex;
  align-items: center;
  gap: 1.5rem;
}

.nav-links > a:not(.nav-btn) {
  color: rgba(255,255,255,0.78);
  font-size: 0.875rem;
  font-weight: 500;
  text-decoration: none;
}

.nav-links > a:not(.nav-btn):hover {
  color: white;
  text-decoration: none;
}

.nav-btn {
  background: var(--sky);
  color: white !important;
  font-size: 0.85rem;
  font-weight: 600;
  padding: 0.5rem 1.1rem;
  border-radius: var(--radius);
  text-decoration: none !important;
  border: 1px solid var(--sky);
  transition: background 0.12s ease;
}

.nav-btn:hover { background: #2670bd; }

/* ==========================================================================
   Buttons
   Rectangular, bordered, no gradients. State is shown by fill, not glow.
   ========================================================================== */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  font-family: var(--font-body);
  font-size: 0.9rem;
  font-weight: 600;
  padding: 0.6rem 1.25rem;
  border-radius: var(--radius);
  border: 1px solid transparent;
  cursor: pointer;
  text-decoration: none;
  transition: background 0.12s ease, border-color 0.12s ease, color 0.12s ease;
  line-height: 1.2;
}

.btn:focus-visible { outline-offset: 2px; }

.btn-primary {
  background: var(--navy);
  color: white;
  border-color: var(--navy);
}
.btn-primary:hover { background: var(--slate); border-color: var(--slate); }

.btn-secondary {
  background: var(--paper);
  color: var(--navy);
  border-color: var(--navy);
}
.btn-secondary:hover { background: var(--frost); }

.btn-ghost {
  background: transparent;
  color: var(--sky);
  border-color: var(--border);
}
.btn-ghost:hover { background: var(--frost); border-color: var(--sky); }

.btn-gold {
  background: var(--gold);
  color: var(--navy);
  border-color: var(--gold);
}
.btn-gold:hover { background: #a37f3e; border-color: #a37f3e; }

.btn-full { width: 100%; display: flex; }

.btn-sm {
  padding: 0.35rem 0.8rem;
  font-size: 0.78rem;
}

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

/* Spinner — used inside buttons during submission */
.spinner {
  display: inline-block;
  width: 14px;
  height: 14px;
  border: 2px solid rgba(255,255,255,0.35);
  border-top-color: white;
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ==========================================================================
   Cards & sections
   Signature device: a 3px top rule in sky-blue marks every primary panel —
   a quiet nod to the tab markers on a paper file folder.
   ========================================================================== */

.card {
  background: var(--paper);
  border: 1px solid var(--border);
  border-top: 3px solid var(--sky);
  border-radius: var(--radius-lg);
  padding: 1.25rem;
  box-shadow: var(--shadow);
}

.section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1rem;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid var(--border);
}

.section-title {
  font-family: var(--font-display);
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--navy);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

/* ==========================================================================
   Forms
   Labels above fields, square corners, visible borders at rest —
   nothing relies on a hover state to be legible.
   ========================================================================== */

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}

@media (max-width: 560px) {
  .form-row { grid-template-columns: 1fr; }
}

.form-group {
  margin-bottom: 1.1rem;
}

.form-label {
  display: block;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--ink);
  margin-bottom: 0.35rem;
  letter-spacing: 0.01em;
}

.form-label .req { color: var(--gold); font-weight: 700; }

.form-input {
  width: 100%;
  font-family: var(--font-body);
  font-size: 0.95rem;
  color: var(--ink);
  background: var(--paper);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 0.65rem 0.75rem;
  transition: border-color 0.12s ease, box-shadow 0.12s ease;
}

.form-input::placeholder { color: #A6AEBB; }

.form-input:focus {
  border-color: var(--sky);
  box-shadow: 0 0 0 3px rgba(46,127,213,0.12);
  outline: none;
}

.form-hint {
  font-size: 0.78rem;
  color: var(--muted);
  margin: 0.35rem 0 0;
  line-height: 1.4;
}

/* ==========================================================================
   Alerts
   Left-edge color bar instead of a filled background — keeps long
   error/success text legible without a wall of color.
   ========================================================================== */

.alert {
  padding: 0.75rem 1rem;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  border-left: 4px solid var(--muted);
  background: var(--paper);
  font-size: 0.85rem;
  line-height: 1.5;
  margin-bottom: 1rem;
}

.alert-error {
  border-left-color: #B3413B;
  background: #FCF3F2;
  color: #8C2F2A;
}

.alert-success {
  border-left-color: var(--green);
  background: #EFF7F1;
  color: var(--green);
}

/* ==========================================================================
   Badges — status stamps
   Rectangular, monospace, uppercase: read like a form status field
   rather than a chat-app pill.
   ========================================================================== */

.badge {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-family: var(--font-mono);
  font-size: 0.7rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  padding: 0.25rem 0.55rem;
  border-radius: 2px;
  border: 1px solid transparent;
  line-height: 1.4;
}

.badge-dot::before {
  content: '';
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: currentColor;
  display: inline-block;
}

.badge-green {
  color: var(--green);
  background: #EFF7F1;
  border-color: #CFE6D7;
}

.badge-blue {
  color: var(--sky);
  background: var(--frost);
  border-color: #C7DDF5;
}

.badge-gold {
  color: #8A6A2E;
  background: #FBF2E2;
  border-color: #ECD9B4;
}

.badge-gray {
  color: var(--muted);
  background: #F0F2F5;
  border-color: var(--border);
}

/* ==========================================================================
   Footer
   ========================================================================== */

.footer {
  border-top: 1px solid var(--border);
  padding: 2rem 1.5rem;
  text-align: center;
  font-size: 0.78rem;
  color: var(--muted);
  background: var(--cream);
}

.footer-links {
  display: flex;
  gap: 1.5rem;
  justify-content: center;
  margin-bottom: 0.75rem;
  font-size: 0.82rem;
}

.footer-links a { color: var(--slate); }
