/* ==========================================================================
   Halyard Bank — App shell (dashboard, accounts, transfers, statements)
   ========================================================================== */

body.app {
  background: var(--fog);
  min-height: 100vh;
}

.app-header {
  background: var(--ink);
  color: var(--white);
  position: sticky;
  top: 0;
  z-index: 100;
}
.app-header .container {
  display: flex;
  align-items: center;
  gap: 32px;
  height: 64px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: var(--step-1);
  color: var(--white);
  text-decoration: none;
  flex-shrink: 0;
}
.brand svg { flex-shrink: 0; }

.app-nav {
  display: flex;
  gap: 4px;
  flex: 1;
}
.app-nav a {
  color: rgba(255,255,255,0.65);
  text-decoration: none;
  font-size: var(--step--1);
  font-weight: 600;
  padding: 8px 14px;
  border-radius: var(--radius-sm);
  transition: color var(--transition), background var(--transition);
}
.app-nav a:hover { color: var(--white); background: rgba(255,255,255,0.08); }
.app-nav a[aria-current="page"] {
  color: var(--white);
  background: rgba(255,255,255,0.12);
}

.app-user {
  display: flex;
  align-items: center;
  gap: 14px;
  font-size: var(--step--1);
}
.app-user .avatar {
  width: 34px; height: 34px;
  border-radius: 50%;
  background: var(--brass);
  color: var(--ink);
  display: flex; align-items: center; justify-content: center;
  font-weight: 700;
  font-family: var(--font-display);
}

.nav-toggle {
  display: none;
  background: none;
  border: none;
  color: var(--white);
  cursor: pointer;
  padding: 8px;
}

.app-main {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 36px 24px 80px;
}

.page-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 28px;
}
.page-head h1 { margin: 0; font-size: var(--step-3); }
.page-head .sub { color: var(--text-muted); font-size: var(--step-0); }

.grid-2 {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 24px;
}

.summary-strip {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
  margin-bottom: 28px;
}
.summary-tile {
  padding: 22px 24px;
}
.summary-tile .label {
  font-size: var(--step--1);
  color: var(--text-muted);
  font-weight: 600;
  margin-bottom: 6px;
}
.summary-tile .value {
  font-family: var(--font-mono);
  font-size: var(--step-2);
  font-weight: 600;
  color: var(--navy);
}
.summary-tile .delta {
  font-size: var(--step--1);
  margin-top: 4px;
}
.delta-up { color: var(--ok); }
.delta-down { color: var(--danger); }

.account-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 24px;
  border-bottom: 1px solid var(--fog);
  text-decoration: none;
  color: inherit;
  transition: background var(--transition);
}
.account-row:last-child { border-bottom: none; }
.account-row:hover { background: rgba(20,33,61,0.03); }
.account-row .a-name { font-weight: 600; }
.account-row .a-meta { font-size: var(--step--1); color: var(--text-muted); margin-top: 2px; }
.account-row .a-balance { font-family: var(--font-mono); font-weight: 600; font-size: var(--step-1); }

.card-head {
  padding: 20px 24px;
  border-bottom: 1px solid var(--fog);
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.card-head h2 { font-size: var(--step-1); margin: 0; }
.card-head a { font-size: var(--step--1); font-weight: 600; color: var(--navy); text-decoration: none; }
.card-head a:hover { text-decoration: underline; }

table.txns {
  width: 100%;
  border-collapse: collapse;
}
table.txns th {
  text-align: left;
  font-size: var(--step--1);
  color: var(--text-muted);
  font-weight: 600;
  padding: 12px 24px;
  border-bottom: 1px solid var(--fog);
}
table.txns td {
  padding: 14px 24px;
  border-bottom: 1px solid var(--fog);
  font-size: var(--step--1);
}
table.txns tr:last-child td { border-bottom: none; }
table.txns .t-amount { font-family: var(--font-mono); font-weight: 600; text-align: right; white-space: nowrap; }
.amt-in { color: var(--ok); }
.amt-out { color: var(--ink); }

.route-nav {
  padding: 20px 24px;
}
.route-nav h2 { font-size: var(--step-0); margin-bottom: 14px; }
.route-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 0;
  text-decoration: none;
  color: var(--ink);
  font-size: var(--step--1);
  font-weight: 600;
}
.route-item .dot {
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--brass);
  flex-shrink: 0;
}

.alert {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  padding: 14px 16px;
  border-radius: var(--radius-md);
  font-size: var(--step--1);
  margin-bottom: 20px;
}
.alert-info { background: rgba(20,33,61,0.06); color: var(--navy); }
.alert-success { background: rgba(47,107,79,0.1); color: var(--ok); }
.alert-error { background: rgba(162,59,46,0.08); color: var(--danger); }

.progress-line {
  display: flex;
  align-items: center;
  margin-bottom: 32px;
  max-width: 480px;
}
.progress-line .p-step {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  flex: 1;
  position: relative;
}
.progress-line .p-dot {
  width: 12px; height: 12px;
  border-radius: 50%;
  background: var(--fog-dark);
  border: 2px solid var(--fog-dark);
  z-index: 1;
}
.progress-line .p-step.done .p-dot,
.progress-line .p-step.active .p-dot {
  background: var(--brass);
  border-color: var(--brass);
}
.progress-line .p-step::after {
  content: '';
  position: absolute;
  top: 5px;
  left: 50%;
  width: 100%;
  height: 2px;
  background: var(--fog-dark);
  z-index: 0;
}
.progress-line .p-step:last-child::after { display: none; }
.progress-line .p-step.done::after { background: var(--brass); }
.progress-line .p-label {
  font-size: 11px;
  font-weight: 600;
  color: var(--text-muted);
  text-align: center;
}
.progress-line .p-step.active .p-label,
.progress-line .p-step.done .p-label { color: var(--ink); }

.app-footer {
  text-align: center;
  padding: 24px;
  font-size: var(--step--1);
  color: var(--text-muted);
}

.demo-banner {
  background: var(--brass);
  color: var(--ink);
  text-align: center;
  font-size: 13px;
  font-weight: 600;
  padding: 8px 16px;
}

@media (max-width: 860px) {
  .grid-2 { grid-template-columns: 1fr; }
  .summary-strip { grid-template-columns: 1fr; }
  .app-nav { display: none; }
  .nav-toggle { display: block; }
  table.txns th:nth-child(3), table.txns td:nth-child(3) { display: none; }
}
