* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  --bg:       #0a0a0a;
  --text:     #f0f0f0;
  --accent:   #B18638;
  --muted:    #7a7a7a;
  --card-bg:  #0d0d0d;
  --border:   rgba(255, 255, 255, 0.08);
}

body {
  font-family: 'Outfit', sans-serif;
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
  overflow-x: hidden;
}

@keyframes pageFadeIn { from { opacity: 0; } to { opacity: 1; } }
body { animation: pageFadeIn 0.15s ease forwards; }
body.page-out { animation: none; opacity: 0; transition: opacity 0.07s ease; }

/* ── Header ── */
#site-header {
  position: fixed;
  top: 0; left: 0;
  width: 100%;
  z-index: 100;
  background: var(--bg);
  border-bottom: 1px solid var(--border);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.1rem 2.5rem;
}

.header-logo {
  font-family: 'Orbitron', sans-serif;
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--text);
  text-decoration: none;
  letter-spacing: 0.2em;
}

.header-logo span {
  color: var(--muted);
  font-weight: 400;
  letter-spacing: 0.1em;
  margin-left: 0.4em;
  font-size: 0.75rem;
}

.header-nav {
  display: flex;
  gap: 2rem;
}

.header-nav a {
  font-size: 13px;
  color: var(--muted);
  text-decoration: none;
  font-weight: 300;
  letter-spacing: 0.5px;
  transition: color 0.2s ease;
}

.header-nav a:hover { color: var(--text); }

/* ── Hero ── */
.hero {
  padding: 9.5rem 2.5rem 3.5rem;
  max-width: 860px;
  border-bottom: 1px solid var(--border);
}

.hero-label {
  font-family: 'Orbitron', sans-serif;
  font-size: 0.6rem;
  letter-spacing: 0.45em;
  color: var(--muted);
  margin-bottom: 1.5rem;
}

.hero h1 {
  font-size: 4rem;
  font-weight: 400;
  letter-spacing: -0.02em;
  line-height: 1.1;
  margin-bottom: 1.1rem;
}

.hero-sub {
  font-size: 1rem;
  font-weight: 300;
  color: var(--muted);
  line-height: 1.7;
}

/* ── App Grid ── */
.app-grid-wrapper {
  padding: 2.5rem 2.5rem 8rem;
}

.section-label {
  font-family: 'Orbitron', sans-serif;
  font-size: 0.6rem;
  letter-spacing: 0.4em;
  color: var(--muted);
  margin-bottom: 1.5rem;
}

.app-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 1px;
  background: var(--border);
  border: 1px solid var(--border);
}

/* ── App Card ── */
.app-card {
  background: var(--card-bg);
  display: flex;
  flex-direction: column;
  transition: background 0.2s ease;
  cursor: default;
}

.app-card:hover {
  background: #111;
}

.card-accent-bar {
  height: 2px;
  background: var(--card-accent, var(--accent));
  opacity: 0.6;
  transition: opacity 0.2s;
}

.app-card:hover .card-accent-bar {
  opacity: 1;
}

.card-body {
  padding: 1.75rem;
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
  flex: 1;
}

.card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.card-name {
  font-family: 'Orbitron', sans-serif;
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: var(--text);
}

.badge {
  font-family: 'Orbitron', sans-serif;
  font-size: 0.55rem;
  font-weight: 400;
  letter-spacing: 0.12em;
  padding: 0.2rem 0.55rem;
  text-transform: uppercase;
}

.badge--live {
  color: var(--accent);
  border: 1px solid rgba(177, 134, 56, 0.3);
}

.badge--soon {
  color: var(--muted);
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.badge--beta {
  color: #8b5cf6;
  border: 1px solid rgba(139, 92, 246, 0.35);
}

.card-desc {
  font-size: 0.88rem;
  font-weight: 300;
  color: var(--muted);
  line-height: 1.75;
  flex: 1;
}

.card-btn {
  display: inline-block;
  align-self: flex-start;
  margin-top: 0.5rem;
  padding: 0.6rem 1.2rem;
  font-family: 'Outfit', sans-serif;
  font-size: 0.85rem;
  font-weight: 300;
  color: var(--text);
  text-decoration: none;
  border: 1px solid rgba(255, 255, 255, 0.15);
  transition: border-color 0.2s, color 0.2s;
  position: relative;
}

.card-btn::before {
  content: '';
  position: absolute;
  inset: -6px;
  background: var(--card-accent, var(--accent));
  opacity: 0;
  filter: blur(10px);
  z-index: -1;
  transition: opacity 0.2s;
}

.card-btn:not(.disabled):hover {
  border-color: var(--card-accent, var(--accent));
  color: var(--card-accent, var(--accent));
}

.card-btn:not(.disabled):hover::before {
  opacity: 0.1;
}

.card-btn.disabled {
  opacity: 0.3;
  cursor: not-allowed;
  pointer-events: none;
}

/* ── Footer ── */
#site-footer {
  position: fixed;
  bottom: 0; left: 0;
  width: 100%;
  background: var(--bg);
  border-top: 1px solid var(--border);
  z-index: 50;
}

.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.1rem 2.5rem;
}

.footer-copy {
  font-size: 13px;
  color: var(--muted);
  font-weight: 300;
  letter-spacing: 0.5px;
}

.footer-nav {
  display: flex;
  gap: 2rem;
}

.footer-nav a {
  font-size: 13px;
  color: var(--muted);
  text-decoration: none;
  font-weight: 300;
  letter-spacing: 0.5px;
  transition: color 0.2s ease;
}

.footer-nav a:hover { color: var(--text); }

/* ── Responsive ── */
@media (max-width: 768px) {
  .header-inner    { padding: 1rem 1.25rem; }
  .hero            { padding: 7rem 1.25rem 2.5rem; }
  .hero h1         { font-size: 2.5rem; }
  .app-grid-wrapper { padding: 1.75rem 1.25rem 7rem; }
  .app-grid        { grid-template-columns: 1fr; }
  .footer-inner    { padding: 1rem 1.25rem; }
}

/* ── Utilities ── */
.hidden { display: none !important; }

/* ═══════════════════════════════════════
   AUTH PAGE
═══════════════════════════════════════ */
.auth-wrap {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 6rem 1.5rem 3rem;
}

.auth-card {
  width: 100%;
  max-width: 420px;
  background: var(--card-bg);
  border: 1px solid var(--border);
  padding: 2.5rem;
  display: flex;
  flex-direction: column;
  gap: 1.75rem;
}

.auth-top { display: flex; flex-direction: column; gap: 0.5rem; }

.auth-eyebrow {
  font-family: 'Orbitron', sans-serif;
  font-size: 0.55rem;
  letter-spacing: 0.45em;
  color: var(--muted);
}

.auth-title {
  font-size: 1.5rem;
  font-weight: 400;
  letter-spacing: -0.01em;
}

.auth-tabs {
  display: flex;
  border-bottom: 1px solid var(--border);
}

.auth-tab {
  flex: 1;
  background: none;
  border: none;
  border-bottom: 2px solid transparent;
  margin-bottom: -1px;
  padding: 0.6rem 0;
  font-family: 'Outfit', sans-serif;
  font-size: 0.82rem;
  font-weight: 300;
  color: var(--muted);
  cursor: pointer;
  letter-spacing: 0.03em;
  transition: color 0.2s, border-color 0.2s;
}
.auth-tab.active {
  color: var(--text);
  border-bottom-color: var(--accent);
}

.auth-form { display: none; flex-direction: column; gap: 1.1rem; }
.auth-form.active { display: flex; }

.field-group { display: flex; flex-direction: column; gap: 0.45rem; }

.field-group label {
  font-size: 0.75rem;
  font-weight: 300;
  color: var(--muted);
  letter-spacing: 0.04em;
}

.field-group input {
  background: #111;
  border: 1px solid var(--border);
  color: var(--text);
  font-family: 'Outfit', sans-serif;
  font-size: 0.9rem;
  font-weight: 300;
  padding: 0.65rem 0.85rem;
  outline: none;
  transition: border-color 0.2s;
  width: 100%;
}
.field-group input:focus { border-color: var(--accent); box-shadow: 0 0 0 3px rgba(177,134,56,0.25); }
.field-group input::placeholder { color: #444; }

.auth-error {
  font-size: 0.78rem;
  font-weight: 300;
  color: #ff4444;
  min-height: 1em;
}

.auth-submit {
  background: none;
  border: 1px solid rgba(177, 134, 56, 0.35);
  color: var(--accent);
  font-family: 'Outfit', sans-serif;
  font-size: 0.88rem;
  font-weight: 300;
  padding: 0.75rem 1.5rem;
  cursor: pointer;
  letter-spacing: 0.04em;
  transition: border-color 0.2s, background 0.2s;
  position: relative;
}
.auth-submit:hover {
  border-color: var(--accent);
  background: rgba(177, 134, 56, 0.05);
}

/* ═══════════════════════════════════════
   HEADER RIGHT (icons + panels)
═══════════════════════════════════════ */
.header-right {
  display: flex;
  align-items: center;
  gap: 0.25rem;
  position: relative;
}

.hdr-icon-wrap { position: relative; }

.hdr-icon-btn {
  background: none;
  border: none;
  color: var(--muted);
  cursor: pointer;
  padding: 0.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: color 0.2s;
  border-radius: 2px;
}
.hdr-icon-btn:hover { color: var(--text); }

/* dropdown panels */
.header-panel {
  display: none;
  position: absolute;
  top: calc(100% + 0.75rem);
  right: 0;
  background: #0d0d0d;
  border: 1px solid var(--border);
  min-width: 220px;
  z-index: 200;
  flex-direction: column;
}
.header-panel.active { display: flex; }

.panel-header {
  padding: 0.9rem 1rem 0.75rem;
  border-bottom: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
}

.panel-title {
  font-family: 'Orbitron', sans-serif;
  font-size: 0.55rem;
  letter-spacing: 0.4em;
  color: var(--muted);
}

.panel-username {
  font-size: 0.88rem;
  font-weight: 300;
  color: var(--text);
}

.panel-empty {
  padding: 1.25rem 1rem;
  font-size: 0.82rem;
  font-weight: 300;
  color: var(--muted);
}

.panel-divider {
  height: 1px;
  background: var(--border);
  margin: 0.25rem 0;
}

.panel-item {
  background: none;
  border: none;
  color: var(--muted);
  font-family: 'Outfit', sans-serif;
  font-size: 0.83rem;
  font-weight: 300;
  padding: 0.65rem 1rem;
  text-align: left;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 0.65rem;
  transition: color 0.15s, background 0.15s;
}
.panel-item:hover { color: var(--text); background: rgba(255,255,255,0.03); }
.panel-item--danger { color: #ff4444; }
.panel-item--danger:hover { color: #ff6666; background: rgba(255,68,68,0.06); }

/* ═══════════════════════════════════════
   HOME — EMPTY STATE
═══════════════════════════════════════ */
.empty-state {
  min-height: calc(100vh - 60px);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  padding: 5rem 2rem;
  text-align: center;
}

.empty-icon { margin-bottom: 0.5rem; }

.empty-title {
  font-size: 1.35rem;
  font-weight: 400;
  letter-spacing: -0.01em;
}

.empty-sub {
  font-size: 0.9rem;
  font-weight: 300;
  color: var(--muted);
  max-width: 340px;
  line-height: 1.7;
}

.choose-apps-btn {
  margin-top: 0.75rem;
  background: none;
  border: 1px solid rgba(177, 134, 56, 0.35);
  color: var(--accent);
  font-family: 'Outfit', sans-serif;
  font-size: 0.9rem;
  font-weight: 300;
  padding: 0.75rem 2rem;
  cursor: pointer;
  letter-spacing: 0.04em;
  transition: border-color 0.2s, background 0.2s;
}
.choose-apps-btn:hover {
  border-color: var(--accent);
  background: rgba(177, 134, 56, 0.05);
}

.choose-apps-btn--sm {
  font-size: 0.8rem;
  padding: 0.55rem 1.25rem;
  margin-top: 0;
}

/* ── Home grid with apps ── */
.app-grid-wrapper { padding: 5.5rem 2.5rem 8rem; }

.add-more-wrap {
  margin-top: 2rem;
  display: flex;
  justify-content: flex-start;
}

/* ═══════════════════════════════════════
   APP PICKER MODAL
═══════════════════════════════════════ */
.picker-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.75);
  backdrop-filter: blur(4px);
  z-index: 300;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
}
.picker-overlay.active { display: flex; }

.picker-modal {
  background: #0d0d0d;
  border: 1px solid var(--border);
  width: 100%;
  max-width: 580px;
  max-height: 85vh;
  display: flex;
  flex-direction: column;
  animation: pageFadeIn 0.15s ease;
}

.picker-modal-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  padding: 1.75rem 1.75rem 1.25rem;
  border-bottom: 1px solid var(--border);
}

.picker-eyebrow {
  font-family: 'Orbitron', sans-serif;
  font-size: 0.55rem;
  letter-spacing: 0.45em;
  color: var(--muted);
  margin-bottom: 0.4rem;
}

.picker-title {
  font-size: 1.2rem;
  font-weight: 400;
  letter-spacing: -0.01em;
}

.picker-close {
  background: none;
  border: none;
  color: var(--muted);
  cursor: pointer;
  padding: 0.25rem;
  display: flex;
  transition: color 0.2s;
}
.picker-close:hover { color: var(--text); }

.picker-search-wrap {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 1rem 1.75rem;
  border-bottom: 1px solid var(--border);
}
.picker-search-wrap:focus-within { border-bottom-color: var(--accent); }

.picker-search-icon { color: var(--muted); flex-shrink: 0; }

.picker-search {
  background: none;
  border: none;
  color: var(--text);
  font-family: 'Outfit', sans-serif;
  font-size: 0.88rem;
  font-weight: 300;
  outline: none;
  width: 100%;
}
.picker-search::placeholder { color: #444; }

.picker-apps-list {
  overflow-y: auto;
  flex: 1;
}
.picker-apps-list::-webkit-scrollbar { width: 4px; }
.picker-apps-list::-webkit-scrollbar-track { background: transparent; }
.picker-apps-list::-webkit-scrollbar-thumb { background: #222; }

.picker-row {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1.25rem 1.75rem;
  border-bottom: 1px solid var(--border);
  transition: background 0.15s;
}
.picker-row:last-child { border-bottom: none; }
.picker-row:hover { background: rgba(255,255,255,0.02); }

.picker-row-accent {
  width: 3px;
  height: 40px;
  flex-shrink: 0;
  opacity: 0.6;
  border-radius: 2px;
}

.picker-row-info { flex: 1; display: flex; flex-direction: column; gap: 0.35rem; }

.picker-row-top {
  display: flex;
  align-items: center;
  gap: 0.6rem;
}

.picker-row-name {
  font-family: 'Orbitron', sans-serif;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  color: var(--text);
}

.picker-row-desc {
  font-size: 0.82rem;
  font-weight: 300;
  color: var(--muted);
  line-height: 1.6;
}

.picker-add-btn {
  background: none;
  border: 1px solid rgba(255,255,255,0.12);
  color: var(--muted);
  font-family: 'Outfit', sans-serif;
  font-size: 0.78rem;
  font-weight: 300;
  padding: 0.45rem 0.9rem;
  cursor: pointer;
  flex-shrink: 0;
  letter-spacing: 0.03em;
  transition: border-color 0.2s, color 0.2s, background 0.2s;
  white-space: nowrap;
}
.picker-add-btn:hover {
  border-color: rgba(255,255,255,0.3);
  color: var(--text);
}
.picker-add-btn.added {
  border-color: rgba(177, 134, 56, 0.4);
  color: var(--accent);
}
.picker-add-btn.added:hover {
  border-color: rgba(255,68,68,0.5);
  color: #ff6666;
  background: rgba(255,68,68,0.05);
}

.picker-no-results {
  padding: 2rem 1.75rem;
  font-size: 0.85rem;
  font-weight: 300;
  color: var(--muted);
}

/* ── Unread badge dot on header icon ── */
.hdr-badge {
  position: absolute;
  top: 5px;
  right: 5px;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent);
  border: 1.5px solid var(--bg);
  pointer-events: none;
  display: none;
}
.hdr-badge.visible { display: block; }

/* ── Wider panels (notif / mail) ── */
.header-panel--wide { min-width: 300px; }

/* ── Notification / invite items ── */
.notif-item {
  display: flex;
  gap: 0.85rem;
  padding: 1rem 1.1rem;
  border-bottom: 1px solid var(--border);
  transition: background 0.15s;
}
.notif-item:last-child { border-bottom: none; }
.notif-item:hover { background: rgba(255,255,255,0.02); }

.notif-item-bar {
  width: 2px;
  min-height: 44px;
  align-self: stretch;
  border-radius: 2px;
  flex-shrink: 0;
  opacity: 0.5;
  transition: opacity 0.2s;
}
.notif-item--unread .notif-item-bar { opacity: 1; }

.notif-item-body { flex: 1; display: flex; flex-direction: column; gap: 0.3rem; }

.notif-item-title {
  font-size: 0.8rem;
  font-weight: 300;
  color: var(--muted);
  line-height: 1.4;
}
.notif-item--unread .notif-item-title { color: var(--text); font-weight: 400; }

.notif-item-desc {
  font-size: 0.75rem;
  font-weight: 300;
  color: var(--muted);
  line-height: 1.6;
  opacity: 0.75;
}

.notif-item-date {
  font-size: 0.65rem;
  font-weight: 300;
  color: #444;
  margin-top: 0.15rem;
  font-family: 'Orbitron', sans-serif;
  letter-spacing: 0.05em;
}

.notif-dismiss-btn {
  background: none;
  border: none;
  cursor: pointer;
  color: rgba(255,255,255,0.2);
  font-size: 1rem;
  line-height: 1;
  padding: 4px 6px;
  align-self: flex-start;
  transition: color 0.15s;
  flex-shrink: 0;
}
.notif-dismiss-btn:hover { color: rgba(255,255,255,0.6); }

.notif-panel-empty {
  padding: 1.5rem 1.1rem;
  font-size: 0.8rem;
  font-weight: 300;
  color: var(--muted);
  line-height: 1.6;
}

.forgot-actions {
  display: flex;
  align-items: center;
  gap: 1.25rem;
  flex-wrap: wrap;
}

.forgot-actions .auth-submit {
  flex-shrink: 0;
}

.auth-link {
  background: none;
  border: none;
  color: var(--muted);
  font-family: 'Outfit', sans-serif;
  font-size: 0.8rem;
  font-weight: 300;
  cursor: pointer;
  padding: 0;
  text-decoration: underline;
  transition: color 0.2s;
  display: inline;
}
.auth-link:hover { color: var(--text); }

.auth-link--right {
  display: block;
  text-align: right;
  margin-top: 0.4rem;
}

.auth-hint {
  font-size: 0.85rem;
  font-weight: 300;
  color: var(--muted);
  line-height: 1.7;
}

.auth-divider {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin: 0.75rem 0;
  color: var(--muted);
  font-size: 0.75rem;
}
.auth-divider::before,
.auth-divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: rgba(255,255,255,0.08);
}

.auth-google {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  padding: 0.65rem 1rem;
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: 6px;
  color: rgba(255,255,255,0.8);
  font-size: 0.875rem;
  font-weight: 400;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s;
}
.auth-google:hover {
  background: rgba(255,255,255,0.08);
  border-color: rgba(255,255,255,0.2);
}

/* ── Account Details modal ── */
.account-section { display: flex; flex-direction: column; gap: 0.5rem; }

.account-section-label {
  display: block;
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  color: var(--muted);
  text-transform: uppercase;
}

.account-row {
  display: flex;
  gap: 0.5rem;
  align-items: center;
}

.account-col {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.account-input {
  flex: 1;
  width: 100%;
  background: rgba(255,255,255,0.04) !important;
  border: 1px solid rgba(255,255,255,0.1) !important;
  border-radius: 6px;
  padding: 0.5rem 0.75rem;
  color: rgba(255,255,255,0.85) !important;
  font-size: 0.85rem;
  font-family: 'Outfit', sans-serif;
  outline: none;
  transition: border-color 0.15s;
  box-sizing: border-box;
}
.account-input[readonly] { opacity: 0.55; cursor: default; }
.account-input--editing { opacity: 1 !important; border-color: rgba(255,255,255,0.25) !important; }
.account-input:focus { border-color: var(--accent) !important; box-shadow: 0 0 0 3px rgba(177,134,56,0.25); }
.account-input::placeholder { color: rgba(255,255,255,0.25); }

.account-edit-btn {
  background: none;
  border: none;
  cursor: pointer;
  color: rgba(255,255,255,0.5);
  padding: 0.3rem;
  display: flex;
  align-items: center;
  transition: color 0.15s, opacity 0.15s;
  flex-shrink: 0;
}
.account-edit-btn:hover { color: rgba(255,255,255,0.9); }

.account-feedback {
  font-size: 0.78rem;
  min-height: 1rem;
  color: transparent;
}
.account-feedback.error   { color: #e74c3c; }
.account-feedback.success { color: #2ecc71; }

/* ── Password reset button font fix ── */
#ad-password-btn {
  font-family: 'Outfit', sans-serif;
  font-size: 0.8rem;
  font-weight: 400;
  letter-spacing: 0.01em;
}

/* ── Switch accounts dropdown ── */
.switch-dropdown {
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.07);
  border-radius: 6px;
  margin: 0 0 0.25rem;
  overflow: hidden;
}

.switch-account-row {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  width: 100%;
  padding: 0.55rem 0.75rem;
  background: none;
  border: none;
  cursor: pointer;
  text-align: left;
  transition: background 0.12s;
  color: rgba(255,255,255,0.75);
}
.switch-account-row:hover { background: rgba(255,255,255,0.05); }

.switch-account-row--active {
  background: rgba(255,255,255,0.07);
  cursor: default;
}

.switch-account-avatar {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: rgba(177,134,56,0.2);
  color: #B18638;
  font-size: 0.7rem;
  font-weight: 600;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  font-family: 'Outfit', sans-serif;
}

.switch-account-info {
  display: flex;
  flex-direction: column;
  gap: 0.05rem;
  flex: 1;
  min-width: 0;
}

.switch-account-name {
  font-size: 0.78rem;
  font-weight: 500;
  color: rgba(255,255,255,0.85);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  font-family: 'Outfit', sans-serif;
}

.switch-account-email {
  font-size: 0.68rem;
  color: rgba(255,255,255,0.3);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  font-family: 'Outfit', sans-serif;
}

.switch-add-btn { color: rgba(255,255,255,0.45); }
.switch-add-btn:hover { color: rgba(255,255,255,0.75); }
.switch-add-btn .switch-account-name { color: inherit; font-weight: 400; }

.switch-divider {
  height: 1px;
  background: rgba(255,255,255,0.06);
  margin: 0.15rem 0;
}

/* ── Connections modal ── */
.connections-modal {
  background: var(--surface, #111);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 12px;
  width: 100%;
  max-width: 400px;
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.connections-modal-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
}

.connections-list {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.connection-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.85rem 1rem;
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.06);
  border-radius: 8px;
}

.connection-info {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.connection-name {
  font-size: 0.875rem;
  font-weight: 500;
  color: rgba(255,255,255,0.85);
}

.connection-status {
  font-size: 0.75rem;
  color: var(--muted);
  margin-top: 0.1rem;
}

.connection-btn {
  padding: 0.35rem 0.85rem;
  border-radius: 5px;
  font-size: 0.78rem;
  font-weight: 500;
  cursor: pointer;
  border: 1px solid rgba(255,255,255,0.15);
  background: rgba(255,255,255,0.05);
  color: rgba(255,255,255,0.8);
  transition: background 0.15s;
  white-space: nowrap;
}
.connection-btn:hover:not(:disabled) { background: rgba(255,255,255,0.1); }
.connection-btn:disabled { opacity: 0.4; cursor: default; }
.connection-btn--danger { border-color: rgba(192,57,43,0.4); color: #e74c3c; }
.connection-btn--danger:hover:not(:disabled) { background: rgba(192,57,43,0.1); }

/* ── Mobile adjustments ── */
@media (max-width: 768px) {
  .picker-modal { max-height: 95vh; }
  .auth-card { padding: 1.75rem; }
  .header-panel--wide { min-width: 260px; }
}

/* ═══════════════════════════════════════
   LEGAL / POLICY PAGES
═══════════════════════════════════════ */
.legal-wrap {
  max-width: 760px;
  margin: 0 auto;
  padding: 7.5rem 2rem 6rem;
}

.legal-eyebrow {
  font-family: 'Orbitron', sans-serif;
  font-size: 0.6rem;
  letter-spacing: 0.45em;
  color: var(--muted);
  margin-bottom: 1rem;
}

.legal-title {
  font-size: 2.25rem;
  font-weight: 400;
  letter-spacing: -0.02em;
  margin-bottom: 0.75rem;
}

.legal-updated {
  font-size: 0.82rem;
  font-weight: 300;
  color: var(--muted);
  margin-bottom: 2.5rem;
  padding-bottom: 2rem;
  border-bottom: 1px solid var(--border);
}

.legal-content h2 {
  font-size: 1.3rem;
  font-weight: 400;
  letter-spacing: -0.01em;
  margin: 2.5rem 0 1rem;
}

.legal-content h3 {
  font-family: 'Orbitron', sans-serif;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--accent);
  margin: 1.75rem 0 0.85rem;
}

.legal-content p {
  font-size: 0.92rem;
  font-weight: 300;
  color: rgba(240, 240, 240, 0.85);
  line-height: 1.8;
  margin-bottom: 1rem;
}

.legal-content ul,
.legal-content ol {
  margin: 0 0 1.25rem 1.25rem;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.legal-content li {
  font-size: 0.92rem;
  font-weight: 300;
  color: rgba(240, 240, 240, 0.85);
  line-height: 1.7;
}

.legal-content a { color: var(--accent); }
.legal-content strong { font-weight: 500; color: var(--text); }

.legal-content table {
  width: 100%;
  border-collapse: collapse;
  margin: 0 0 1.5rem;
  font-size: 0.85rem;
}
.legal-content th,
.legal-content td {
  text-align: left;
  padding: 0.65rem 0.85rem;
  border: 1px solid var(--border);
  font-weight: 300;
  color: rgba(240, 240, 240, 0.85);
}
.legal-content th {
  font-family: 'Orbitron', sans-serif;
  font-size: 0.6rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
  font-weight: 400;
  background: var(--card-bg);
}

.legal-toc {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.25rem;
  margin-bottom: 2.5rem;
}
.legal-toc a {
  font-size: 0.78rem;
  font-weight: 300;
  color: var(--muted);
  text-decoration: none;
  border-bottom: 1px dotted transparent;
}
.legal-toc a:hover { color: var(--text); border-bottom-color: var(--muted); }

.legal-callout {
  background: rgba(177, 134, 56, 0.05);
  border: 1px solid rgba(177, 134, 56, 0.2);
  padding: 1rem 1.25rem;
  font-size: 0.85rem;
  font-weight: 300;
  color: rgba(240, 240, 240, 0.85);
  line-height: 1.7;
  margin-bottom: 1.5rem;
}

@media (max-width: 768px) {
  .legal-wrap { padding: 6.5rem 1.25rem 5rem; }
  .legal-title { font-size: 1.7rem; }
}

/* Cookie consent banner/modal styles now live in cookie-consent.css,
   loaded directly by cookie-consent.js on every page (site + apps). */

/* ═══════════════════════════════════════
   LIGHT THEME
   Covers: header, footer, hero, app grid/cards, auth forms, the header's
   settings/notification/mail dropdown panel (incl. the Switch Accounts
   sub-list), the App Picker modal, legal pages, and the cookie banner/modal.
   Deliberately NOT covered (stays dark regardless of theme): Account
   Details, Connections, Delete Account confirm, Redeem Code, Changelog, and
   Admin Panel modals — these are heavily inline-styled in home.html rather
   than driven by this stylesheet's variables, and reskinning them was scoped
   out as a separate, larger pass. See COMPLIANCE_CHECKLIST.md Phase 3.
═══════════════════════════════════════ */
[data-theme="light"] {
  --bg:       #f7f6f4;
  --text:     #1a1a1a;
  --accent:   #8a6323;
  --muted:    #5a5a5a;
  --card-bg:  #ffffff;
  --border:   rgba(0, 0, 0, 0.1);
}

[data-theme="light"] #site-header { background: var(--bg); }
[data-theme="light"] #site-footer { background: var(--bg); }

[data-theme="light"] .app-card:hover { background: #ffffff; }
[data-theme="light"] .badge--soon { border-color: rgba(0,0,0,0.15); }
[data-theme="light"] .badge--live { border-color: rgba(138,99,35,0.35); }
[data-theme="light"] .card-btn { border-color: rgba(0,0,0,0.15); }

[data-theme="light"] .field-group input { background: #ffffff; }
[data-theme="light"] .field-group input::placeholder { color: #999; }
[data-theme="light"] .auth-error { color: #c0392b; }
[data-theme="light"] .auth-divider::before,
[data-theme="light"] .auth-divider::after { background: rgba(0,0,0,0.1); }
[data-theme="light"] .auth-google { background: rgba(0,0,0,0.03); border-color: rgba(0,0,0,0.12); color: rgba(0,0,0,0.75); }
[data-theme="light"] .auth-google:hover { background: rgba(0,0,0,0.06); border-color: rgba(0,0,0,0.2); }

[data-theme="light"] .choose-apps-btn { border-color: rgba(138,99,35,0.4); }
[data-theme="light"] .choose-apps-btn:hover { background: rgba(138,99,35,0.06); }

[data-theme="light"] .header-panel { background: #ffffff; box-shadow: 0 8px 28px rgba(0,0,0,0.12); }
[data-theme="light"] .panel-item:hover { background: rgba(0,0,0,0.04); }
[data-theme="light"] .switch-dropdown { background: rgba(0,0,0,0.03); border-color: rgba(0,0,0,0.08); }
[data-theme="light"] .switch-account-row { color: rgba(0,0,0,0.75); }
[data-theme="light"] .switch-account-row:hover { background: rgba(0,0,0,0.05); }
[data-theme="light"] .switch-account-row--active { background: rgba(0,0,0,0.07); }
[data-theme="light"] .switch-account-avatar { color: #8a6323; }
[data-theme="light"] .switch-account-name { color: rgba(0,0,0,0.85); }
[data-theme="light"] .switch-account-email { color: rgba(0,0,0,0.4); }
[data-theme="light"] .switch-add-btn { color: rgba(0,0,0,0.5); }
[data-theme="light"] .switch-add-btn:hover { color: rgba(0,0,0,0.8); }
[data-theme="light"] .switch-divider { background: rgba(0,0,0,0.08); }

[data-theme="light"] .notif-dismiss-btn { color: rgba(0,0,0,0.3); }
[data-theme="light"] .notif-dismiss-btn:hover { color: rgba(0,0,0,0.6); }
[data-theme="light"] .notif-item:hover { background: rgba(0,0,0,0.02); }
[data-theme="light"] .notif-item-date { color: #999; }

[data-theme="light"] .picker-overlay { background: rgba(0,0,0,0.35); }
[data-theme="light"] .picker-modal { background: #ffffff; box-shadow: 0 14px 40px rgba(0,0,0,0.15); }
[data-theme="light"] .picker-search::placeholder { color: #999; }
[data-theme="light"] .picker-row:hover { background: rgba(0,0,0,0.025); }
[data-theme="light"] .picker-add-btn { border-color: rgba(0,0,0,0.15); }
[data-theme="light"] .picker-add-btn:hover { border-color: rgba(0,0,0,0.3); }
[data-theme="light"] .picker-apps-list::-webkit-scrollbar-thumb { background: #ccc; }

[data-theme="light"] .legal-content p,
[data-theme="light"] .legal-content li,
[data-theme="light"] .legal-content th,
[data-theme="light"] .legal-content td { color: rgba(20,20,20,0.85); }
[data-theme="light"] .legal-callout { background: rgba(138,99,35,0.06); border-color: rgba(138,99,35,0.25); color: rgba(20,20,20,0.85); }

/* ── Theme toggle button ── */
.theme-icon-moon { display: none; }
[data-theme="light"] .theme-icon-sun { display: none; }
[data-theme="light"] .theme-icon-moon { display: flex; }

/* ═══════════════════════════════════════
   CONTACT PAGE
═══════════════════════════════════════ */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  margin-bottom: 2.5rem;
  align-items: start;
}

.contact-info__details {
  margin-top: 1.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}
.contact-info__details span {
  display: block;
  font-size: 0.85rem;
  font-weight: 300;
  color: var(--muted);
}

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

.contact-form input,
.contact-form select,
.contact-form textarea {
  width: 100%;
  background: var(--card-bg);
  border: 1px solid var(--border);
  color: var(--text);
  font-family: 'Outfit', sans-serif;
  font-size: 0.9rem;
  font-weight: 300;
  padding: 0.75rem 1rem;
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
  box-sizing: border-box;
}
.contact-form input::placeholder,
.contact-form textarea::placeholder { color: var(--muted); opacity: 0.6; }
.contact-form input:focus,
.contact-form select:focus,
.contact-form textarea:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(177,134,56,0.2);
}
.contact-form textarea { resize: vertical; min-height: 120px; }
.contact-form select option { background: var(--card-bg); color: var(--text); }

.contact-form-msg { font-size: 0.8rem; min-height: 1.2em; }
.contact-form-msg.error { color: #e74c3c; }
.contact-form-msg.success { color: #2ecc71; }

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