/* Roundhouse app UI kit — local styles on top of design tokens. */

* { box-sizing: border-box; }

.rh-app {
  font-family: var(--font-body);
  color: var(--fg-2);
  background: var(--rh-obsidian);
  min-height: 100%;
  width: 100%;
}

/* Phone frame ----------------------------------------------- */
.phone {
  width: 390px;
  height: 844px;
  margin: 0 auto;
  background: var(--rh-obsidian);
  position: relative;
  border: 1px solid var(--border-default);
  border-radius: 36px;
  overflow: hidden;
  box-shadow: 0 30px 80px rgba(0,0,0,0.7), 0 0 0 8px #07070a;
}
.phone-status {
  height: 44px;
  display: flex; justify-content: space-between; align-items: center;
  padding: 0 22px;
  font-family: var(--font-ui);
  font-size: 14px;
  font-weight: 600;
  color: var(--fg-1);
  letter-spacing: 0.04em;
}
.phone-status .dots { display:flex; gap:4px; align-items:center; }
.phone-status .dot { width:14px; height:9px; border-radius:2px; background:var(--rh-bone-100); }
.phone-screen {
  position: absolute;
  top: 44px; bottom: 0; left: 0; right: 0;
  overflow-y: auto;
  background: var(--rh-obsidian);
}
.phone-screen::-webkit-scrollbar { width: 0; }

/* Top bar ---------------------------------------------------- */
.topbar {
  display: flex; justify-content: space-between; align-items: center;
  padding: 14px 18px 12px;
  border-bottom: 1px solid var(--border-hairline);
  background: var(--rh-obsidian);
  position: sticky; top: 0; z-index: 10;
}
.topbar-logo { display: flex; align-items: center; gap: 10px; }
.topbar-logo img { height: 26px; width: auto; }
.topbar-name { font-family: var(--font-display); font-size: 18px; color: var(--fg-1); letter-spacing: 0.04em; text-transform: uppercase; line-height: 1; }
.topbar-actions { display: flex; gap: 4px; }
.icon-btn {
  width: 36px; height: 36px;
  background: transparent; border: 1px solid transparent;
  border-radius: 2px;
  display: inline-flex; align-items: center; justify-content: center;
  color: var(--rh-bone-300);
  cursor: pointer; transition: all 120ms ease;
}
.icon-btn:hover { background: var(--rh-brass-tint-08); color: var(--rh-bone-100); border-color: var(--border-default); }
.icon-btn:active { background: var(--bg-pressed); }

/* Bottom tabs ----------------------------------------------- */
.bottom-tabs {
  position: absolute; bottom: 0; left: 0; right: 0;
  height: 72px;
  background: var(--rh-obsidian-900);
  border-top: 1px solid var(--rh-brass-tint-32);
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  padding-bottom: 12px;
  padding-top: 8px;
}
.tab {
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 4px;
  background: transparent; border: 0;
  color: var(--rh-bone-500);
  font-family: var(--font-ui);
  font-size: 9px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  cursor: pointer;
  position: relative;
  font-weight: 600;
}
.tab.active { color: var(--rh-bone-100); }
.tab.active::before {
  content: '';
  position: absolute;
  top: -8px;
  left: 50%; transform: translateX(-50%);
  width: 28px; height: 2px;
  background: var(--rh-brass);
}
.tab svg { color: currentColor; }

/* Screen content -------------------------------------------- */
.screen { padding: 12px 16px 96px; }
.screen-hero {
  padding: 6px 0 14px;
}
.eyebrow {
  font-family: var(--font-ui);
  font-size: 10px;
  letter-spacing: 0.24em;
  color: var(--rh-brass-400);
  text-transform: uppercase;
  font-weight: 600;
}
.hero-title {
  font-family: var(--font-display);
  font-size: 48px;
  line-height: 0.95;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  color: var(--fg-1);
  margin: 6px 0 4px;
}
.hero-title .red { color: var(--rh-dusty-red); }
.hero-sub {
  font-family: var(--font-body);
  font-size: 13px;
  color: var(--rh-bone-300);
}

.section-head {
  display: flex; justify-content: space-between; align-items: baseline;
  margin: 22px 4px 10px;
}
.section-head .h {
  font-family: var(--font-ui);
  font-size: 11px;
  letter-spacing: 0.22em;
  color: var(--rh-bone-300);
  text-transform: uppercase;
  font-weight: 600;
}
.section-head .more {
  font-family: var(--font-ui);
  font-size: 10px;
  letter-spacing: 0.2em;
  color: var(--rh-brass-400);
  text-transform: uppercase;
  font-weight: 600;
  cursor: pointer;
}

/* Cards ------------------------------------------------------
   v3.5: cards lift more deliberately off the page. Deeper outer shadow
   for the "lifting" feel, brighter inset highlight at the top edge so
   cards read as gently illuminated surfaces. */
.card {
  background: var(--bg-elevated-1);
  border: 1px solid var(--border-default);
  border-radius: 4px;
  padding: 14px;
  box-shadow:
    0 1px 0 rgba(230,225,214,0.07) inset,
    0 1px 2px rgba(0,0,0,0.4),
    0 10px 28px rgba(0,0,0,0.45);
}
.card.brass {
  border-color: var(--rh-brass-tint-32);
  box-shadow:
    0 1px 0 rgba(230,225,214,0.08) inset,
    0 1px 2px rgba(0,0,0,0.4),
    0 12px 36px rgba(0,0,0,0.55),
    0 0 0 1px var(--rh-brass-tint-08);
}
.card + .card { margin-top: 14px; }

/* Buttons --------------------------------------------------- */
.btn {
  font-family: var(--font-ui);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  font-size: 12px;
  cursor: pointer;
  border: none;
  border-radius: 2px;
  padding: 13px 18px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  line-height: 1;
  transition: all 120ms ease;
}
.btn-primary { background: var(--rh-dusty-red); color: var(--rh-bone-100); }
.btn-primary:hover { background: var(--rh-red-400); }
.btn-primary:active { background: var(--rh-red-700); transform: scale(0.98); }
.btn-secondary { background: transparent; color: var(--rh-bone-100); border: 1px solid var(--rh-brass); }
.btn-secondary:hover { background: var(--rh-brass-tint-08); border-color: var(--rh-brass-400); }
.btn-ghost { background: transparent; color: var(--rh-bone); padding: 13px 8px; }
.btn-block { width: 100%; }

/* Badges ---------------------------------------------------- */
.badge {
  font-family: var(--font-ui);
  font-size: 9px;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  padding: 5px 8px;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  border-radius: 2px;
  line-height: 1;
  border: 1px solid var(--border-default);
}
.badge .dot { width: 5px; height: 5px; border-radius: 50%; }
.badge.ready   { background: rgba(107,142,90,0.15); color: #A6C293; border-color: rgba(107,142,90,0.35); }
.badge.due     { background: var(--rh-brass-tint-08); color: var(--rh-brass-200); border-color: var(--rh-brass-tint-32); }
.badge.attention { background: rgba(195,58,46,0.14); color: #E48A82; border-color: rgba(195,58,46,0.4); }
.badge.low     { background: rgba(199,122,59,0.14); color: #E5B07E; border-color: rgba(199,122,59,0.35); }
.badge.verified { background: transparent; color: #A6C293; border-color: rgba(138,163,122,0.45); }

/* Chips ----------------------------------------------------- */
.chip {
  font-family: var(--font-ui);
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 5px 9px;
  display: inline-flex; align-items: center; gap: 5px;
  border-radius: 999px;
  line-height: 1;
  border: 1px solid var(--border-default);
  background: var(--bg-elevated-2);
  color: var(--rh-bone-300);
  cursor: pointer;
}
.chip.on { background: var(--rh-brass); border-color: var(--rh-brass); color: var(--rh-obsidian); }

/* Misc ------------------------------------------------------ */
.wedge {
  width: 0; height: 0;
  border-left: 5px solid transparent;
  border-right: 5px solid transparent;
  border-top: 6px solid var(--rh-dusty-red);
  display: inline-block;
}
.divider {
  height: 1px; background: var(--border-hairline); margin: 12px 0;
}
.numeric { font-family: var(--font-display); font-variant-numeric: tabular-nums; letter-spacing: 0.02em; color: var(--fg-1); }
.label-md { font-family: var(--font-ui); font-size: 10px; letter-spacing: 0.2em; color: var(--rh-bone-500); text-transform: uppercase; font-weight: 600; }
.label-lg { font-family: var(--font-ui); font-size: 12px; letter-spacing: 0.2em; color: var(--rh-bone-300); text-transform: uppercase; font-weight: 600; }

/* Stat tile grid ------------------------------------------- */
.stat-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.stat-tile {
  background: var(--bg-elevated-1);
  border: 1px solid var(--border-default);
  border-radius: 4px;
  padding: 12px;
  display: flex; flex-direction: column; gap: 4px;
}
.stat-tile .k { font-family: var(--font-ui); font-size: 9px; letter-spacing: 0.22em; color: var(--rh-bone-500); text-transform: uppercase; font-weight: 600; }
.stat-tile .v { font-family: var(--font-display); font-size: 28px; line-height: 1; color: var(--fg-1); letter-spacing: 0.02em; font-variant-numeric: tabular-nums; }
.stat-tile .sub { font-family: var(--font-ui); font-size: 9px; letter-spacing: 0.18em; color: var(--rh-brass-400); text-transform: uppercase; font-weight: 600; }
