/* Subpage layout — uses tokens.css for everything */

/* Prevent horizontal overflow on mobile */
html { overflow-x: hidden; }
body { overflow-x: hidden; max-width: 100vw; width: 100%; }
* { box-sizing: border-box; }

.eh-site-nav {
  position: sticky;
  top: 0;
  z-index: var(--z-nav);
  background: rgba(250, 250, 248, 0.94);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--eh-border-light);
}
.eh-nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-block: var(--space-3);
  gap: var(--space-6);
}
.eh-logo { display: inline-flex; }
.eh-nav-list {
  display: flex;
  gap: var(--space-6);
  list-style: none;
  margin: 0;
  padding: 0;
  align-items: center;
  flex-wrap: wrap;
}
.eh-nav-list a {
  color: var(--eh-fg-muted);
  text-decoration: none;
  font-size: var(--text-sm);
  font-weight: var(--weight-medium);
  padding: var(--space-2) var(--space-3);
  border-radius: var(--radius-sm);
  transition: color var(--duration-fast) var(--ease-out), background var(--duration-fast) var(--ease-out);
}
.eh-nav-list a:hover { color: var(--eh-fg); background: rgba(0,0,0,0.04); }
.eh-nav-list a.eh-nav-cta {
  background: var(--eh-fg);
  color: var(--eh-bg);
  font-weight: var(--weight-semibold);
}
.eh-nav-list a.eh-nav-cta:hover { background: var(--eh-accent); color: #fff; }

@media (max-width: 768px) {
  .eh-nav-inner { overflow: hidden; }
  .eh-nav-list { gap: var(--space-2); overflow: hidden; }
  .eh-nav-list li:nth-child(n+4):not(:last-child) { display: none; }
  .eh-container { overflow-x: hidden; }
  .eh-account-layout { overflow-x: hidden; }
}

.eh-breadcrumbs {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2);
  list-style: none;
  margin: var(--space-4) 0 0;
  padding: 0;
  font-size: var(--text-sm);
  color: var(--eh-fg-dim);
}
.eh-breadcrumbs li:not(:last-child)::after { content: '/'; margin-left: var(--space-2); color: var(--eh-fg-faint); }
.eh-breadcrumbs a { color: var(--eh-fg-muted); text-decoration: none; }
.eh-breadcrumbs a:hover { color: var(--eh-accent); text-decoration: underline; }
.eh-breadcrumbs li[aria-current="page"] { color: var(--eh-fg); font-weight: var(--weight-medium); }

.eh-page-header { background: linear-gradient(180deg, var(--eh-bg-alt) 0%, var(--eh-bg) 100%); }

.eh-grid { display: grid; gap: var(--space-6); }
.eh-grid--2 { grid-template-columns: repeat(auto-fit, minmax(min(100%, 360px), 1fr)); }
.eh-grid--3 { grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr)); }

.eh-card {
  background: #fff;
  border: 1px solid var(--eh-border);
  border-radius: var(--radius-lg);
  padding: var(--space-6);
}
.eh-card--bordered { border-width: 2px; }
.eh-card--accent { border: 2px solid var(--eh-accent); background: #fff; }

.eh-link {
  color: var(--eh-accent);
  text-decoration: none;
  font-weight: var(--weight-medium);
  font-size: var(--text-sm);
}
.eh-link:hover { text-decoration: underline; }

.eh-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: var(--space-3) var(--space-5);
  background: var(--eh-fg);
  color: var(--eh-bg);
  border: 1px solid var(--eh-fg);
  border-radius: var(--radius-md);
  font-size: var(--text-base);
  font-weight: var(--weight-semibold);
  text-decoration: none;
  cursor: pointer;
  transition: all var(--duration-fast) var(--ease-out);
  min-height: 44px;
}
.eh-btn:hover { background: var(--eh-accent); border-color: var(--eh-accent); color: #fff; }
.eh-btn--ghost {
  background: transparent;
  color: var(--eh-fg);
  border-color: var(--eh-border);
}
.eh-btn--ghost:hover { background: var(--eh-bg-alt); border-color: var(--eh-fg-muted); color: var(--eh-fg); }
.eh-btn--danger {
  background: transparent;
  color: var(--eh-accent);
  border-color: var(--eh-accent);
}
.eh-btn--danger:hover { background: var(--eh-accent); color: #fff; }

.eh-deflist { display: grid; grid-template-columns: max-content 1fr; gap: var(--space-2) var(--space-4); margin: 0 0 var(--space-4); }
.eh-deflist dt { color: var(--eh-fg-dim); font-size: var(--text-sm); }
.eh-deflist dd { color: var(--eh-fg); font-size: var(--text-sm); margin: 0; }

.eh-quick-links { list-style: none; padding: 0; margin: 0; }
.eh-quick-links li {
  padding: var(--space-3) 0;
  border-bottom: 1px solid var(--eh-border-light);
  font-size: var(--text-base);
  color: var(--eh-fg-muted);
}
.eh-quick-links li:last-child { border-bottom: 0; }
.eh-quick-links a { color: var(--eh-accent); font-weight: var(--weight-semibold); text-decoration: none; }
.eh-quick-links a:hover { text-decoration: underline; }

.eh-form { max-width: 600px; }
.eh-fieldset { border: 0; padding: 0; margin: 0 0 var(--space-8); }
.eh-fieldset legend { padding: 0 0 var(--space-4); }
.eh-field { display: block; margin-bottom: var(--space-4); }
.eh-field span { display: block; font-size: var(--text-sm); color: var(--eh-fg-muted); margin-bottom: var(--space-2); font-weight: var(--weight-medium); }
.eh-field input, .eh-field textarea, .eh-field select {
  width: 100%;
  padding: var(--space-3) var(--space-4);
  font: inherit;
  font-size: var(--text-base);
  color: var(--eh-fg);
  background: #fff;
  border: 1px solid var(--eh-border);
  border-radius: var(--radius-md);
  min-height: 44px;
}
.eh-field input:focus, .eh-field textarea:focus, .eh-field select:focus { outline: 2px solid var(--eh-accent); outline-offset: 1px; border-color: var(--eh-accent); }
.eh-field textarea { resize: vertical; min-height: 100px; }

.eh-checkbox { display: flex; align-items: center; gap: var(--space-2); margin-bottom: var(--space-3); font-size: var(--text-sm); color: var(--eh-fg-muted); cursor: pointer; }
.eh-checkbox input { width: auto; min-height: 20px; }

.eh-form-actions { display: flex; gap: var(--space-3); padding-top: var(--space-4); }

/* Account two-column layout: sticky sidebar + content */
.eh-account-layout {
  display: grid;
  grid-template-columns: 220px 1fr;
  gap: var(--space-10);
  align-items: start;
}
.eh-account-sidebar {
  background: #fff;
  border: 1px solid var(--eh-border);
  border-radius: var(--radius-lg);
  padding: var(--space-5);
  position: sticky;
  top: calc(60px + var(--space-4));
}
.eh-account-sidebar .eh-eyebrow { margin-bottom: var(--space-3); }
.eh-account-tabs { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: var(--space-1); }
.eh-account-tabs a {
  display: block;
  padding: var(--space-2) var(--space-3);
  border-radius: var(--radius-sm);
  color: var(--eh-fg-muted);
  text-decoration: none;
  font-size: var(--text-sm);
  font-weight: var(--weight-medium);
  transition: background var(--duration-fast), color var(--duration-fast);
  border-left: 3px solid transparent;
  margin-left: -3px;
}
.eh-account-tabs a:hover { background: var(--eh-bg-alt); color: var(--eh-fg); }
.eh-account-tabs a[aria-current="page"] {
  background: var(--eh-bg-alt);
  color: var(--eh-fg);
  border-left-color: var(--eh-accent);
  font-weight: var(--weight-semibold);
}
.eh-account-content { min-width: 0; }
@media (max-width: 768px) {
  .eh-account-layout { grid-template-columns: 1fr; gap: var(--space-6); }
  .eh-account-sidebar { position: static; padding: var(--space-3); }
  .eh-account-tabs { flex-direction: row; flex-wrap: wrap; gap: var(--space-1); overflow-x: auto; }
  .eh-account-tabs a { padding: var(--space-2) var(--space-3); border-left: 0; border-bottom: 2px solid transparent; white-space: nowrap; }
  .eh-account-tabs a[aria-current="page"] { border-left: 0; border-bottom-color: var(--eh-accent); }
}

.eh-empty-state { text-align: center; padding: var(--space-16) var(--space-6); background: var(--eh-bg-alt); border-radius: var(--radius-lg); }
.eh-empty-state .eh-h3 { color: var(--eh-fg-muted); }
.eh-empty-state .eh-btn { margin-top: var(--space-4); }

.eh-steps { list-style: none; padding: 0; margin: 0; counter-reset: step; }
.eh-step {
  display: grid;
  grid-template-columns: 48px 1fr;
  gap: var(--space-5);
  padding: var(--space-5) 0;
  border-bottom: 1px solid var(--eh-border-light);
}
.eh-step:last-child { border-bottom: 0; }
.eh-step-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--eh-fg);
  color: var(--eh-bg);
  font-weight: var(--weight-bold);
  font-family: var(--font-serif);
}
.eh-step .eh-h4 { margin-bottom: var(--space-1); }
.eh-step .eh-link { display: inline-block; margin-top: var(--space-2); }

.eh-site-footer {
  border-top: 1px solid var(--eh-border-light);
  padding: var(--space-12) 0;
  margin-top: var(--space-24);
  background: var(--eh-bg-alt);
}
.eh-footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: var(--space-4);
}
.eh-footer-links { display: flex; gap: var(--space-5); list-style: none; padding: 0; margin: 0; flex-wrap: wrap; }
.eh-footer-links a { color: var(--eh-fg-muted); text-decoration: none; font-size: var(--text-sm); }
.eh-footer-links a:hover { color: var(--eh-accent); text-decoration: underline; }
