/* Gmail replicas for the landing page (web + iPhone), built in HTML/CSS so no real
   inbox is ever shown. Everything is scoped under .gm. The webfaCe Inbox card
   (.gm-card) mirrors worker/src/cards/message.ts: keep labels and order in step. */

.gm-stage { position: relative; width: 100%; overflow: hidden; }
.gm-stage > .gm { position: absolute; top: 0; left: 0; transform-origin: 0 0; transform: scale(var(--gm-scale, 1)); }
.gm-stage-desktop { aspect-ratio: 1280 / 800; border-radius: 18px; box-shadow: 0 24px 60px rgba(14, 23, 45, .16), 0 0 0 1px rgba(14, 23, 45, .06); }
.gm-stage-phone { aspect-ratio: 410 / 864; max-width: 330px; margin: 0 auto; filter: drop-shadow(0 30px 50px rgba(14, 23, 45, .22)); }

.gm { font-family: Roboto, Arial, sans-serif; color: #1f1f1f; font-size: 14px; line-height: 1.4; -webkit-font-smoothing: antialiased; text-align: left; }
.gm * { box-sizing: border-box; margin: 0; padding: 0; }
.gm svg { display: block; flex: none; }
.gm .ic { width: 20px; height: 20px; fill: #444746; }
.gm .av { border-radius: 50%; display: flex; align-items: center; justify-content: center; color: #fff; font-weight: 500; flex: none; }

/* ---------- desktop Gmail ---------- */
.gm-desktop { width: 1280px; height: 800px; background: #f6f8fc; display: grid; grid-template-columns: 256px 1fr 320px 56px; grid-template-rows: 64px 1fr; }
.gm-top { grid-column: 1 / -1; display: flex; align-items: center; padding: 0 12px 0 8px; }
.gm-menu { width: 48px; height: 48px; display: flex; align-items: center; justify-content: center; }
.gm-menu .ic { width: 24px; height: 24px; }
.gm-logo { display: flex; align-items: center; gap: 6px; width: 190px; padding-left: 4px; }
.gm-logo span { font-size: 22px; color: #444746; letter-spacing: -.2px; }
.gm-search { width: 720px; height: 48px; border-radius: 24px; background: #e9eef6; display: flex; align-items: center; gap: 16px; padding: 0 16px; color: #444746; font-size: 16px; }
.gm-search .ic { width: 24px; height: 24px; }
.gm-top-r { margin-left: auto; display: flex; align-items: center; gap: 8px; }
.gm-top-r .ic { width: 24px; height: 24px; margin: 0 8px; }
.gm-acct { width: 32px; height: 32px; background: #1a6d9b; font-size: 15px; margin-left: 10px; }

.gm-nav { padding: 8px 12px 0 8px; }
.gm-compose { display: inline-flex; align-items: center; gap: 12px; height: 56px; padding: 0 24px 0 16px; border-radius: 16px; background: #c2e7ff; font-size: 14px; font-weight: 500; color: #001d35; margin-bottom: 16px; }
.gm-compose .ic { width: 24px; height: 24px; fill: #001d35; }
.gm-folder { display: flex; align-items: center; gap: 18px; height: 32px; padding: 0 12px 0 20px; border-radius: 16px; color: #1f1f1f; font-size: 14px; }
.gm-folder .ic { width: 20px; height: 20px; }
.gm-folder b { margin-left: auto; font-size: 12px; font-weight: 700; }
.gm-folder.on { background: #d3e3fd; font-weight: 700; color: #001d35; }

.gm-main { background: #fff; border-radius: 16px; margin: 0 16px 16px 0; display: flex; flex-direction: column; overflow: hidden; }
.gm-tools { height: 48px; display: flex; align-items: center; gap: 4px; padding: 0 12px; border-bottom: 1px solid #f1f3f4; }
.gm-tools .ic { margin: 0 10px; }
.gm-tools .sep { width: 1px; height: 20px; background: #dadce0; margin: 0 4px; }
.gm-msg { padding: 20px 24px 0 72px; position: relative; }
.gm-subject { font-size: 22px; font-weight: 400; color: #1f1f1f; display: flex; align-items: center; gap: 12px; margin-bottom: 20px; }
.gm-chip { font-size: 12px; background: #e8eaed; color: #444746; padding: 1px 6px; border-radius: 4px; }
.gm-from { display: flex; align-items: flex-start; gap: 12px; margin-left: -56px; }
.gm-from .av { width: 40px; height: 40px; background: #0b8043; font-size: 17px; }
.gm-from-who { flex: 1; }
.gm-from-who b { font-weight: 700; font-size: 14px; }
.gm-from-who em { font-style: normal; color: #5e5e5e; font-size: 12px; }
.gm-from-who div { color: #5e5e5e; font-size: 12px; margin-top: 2px; }
.gm-from time { color: #5e5e5e; font-size: 12px; white-space: nowrap; }
.gm-body { font-size: 14px; line-height: 1.6; color: #222; padding: 18px 0 0; max-width: 560px; }
.gm-body p + p { margin-top: 12px; }
.gm-actions { display: flex; gap: 12px; margin: 28px 0 0; }
.gm-pill { display: inline-flex; align-items: center; gap: 8px; height: 40px; padding: 0 22px 0 16px; border: 1px solid #747775; border-radius: 20px; font-size: 14px; font-weight: 500; color: #444746; }
.gm-pill .ic { width: 18px; height: 18px; }

.gm-side { background: #fff; border-radius: 16px; margin: 0 8px 16px 0; overflow: hidden; display: flex; flex-direction: column; }
.gm-rail { display: flex; flex-direction: column; align-items: center; gap: 14px; padding-top: 8px; }
.gm-rail i { width: 40px; height: 40px; border-radius: 50%; display: flex; align-items: center; justify-content: center; }
.gm-rail i.on { background: #d3e3fd; }
.gm-rail hr { width: 20px; border: 0; border-top: 1px solid #c4c7c5; }
.gm-rail img { width: 22px; height: 22px; }

/* ---------- the webfaCe Inbox card (both replicas) ---------- */
.gm-card { background: #fff; display: flex; flex-direction: column; min-height: 0; }
.gm-bar { height: 64px; background: #1a6d9b; color: #fff; display: flex; align-items: center; gap: 22px; padding: 0 18px; flex: none; }
.gm-bar b { font-size: 18px; font-weight: 700; letter-spacing: -.1px; }
.gm-bar .ic { fill: #fff; width: 22px; height: 22px; }
.gm-bar .gm-bar-r { margin-left: auto; display: flex; gap: 20px; }
.gm-card-head { padding: 16px 16px 14px; border-bottom: 1px solid #c4c7c5; }
.gm-card-head div { font-size: 15px; color: #1f1f1f; }
.gm-card-head span { display: block; font-size: 14px; color: #444746; margin-top: 4px; }
.gm-sec { padding: 12px 16px 14px; border-bottom: 1px solid #c4c7c5; }
.gm-sec:last-child { border-bottom: 0; }
.gm-sec h5 { font-size: 15px; font-weight: 400; color: #444746; margin-bottom: 8px; }
.gm-fact { margin-bottom: 8px; }
.gm-fact small { display: block; font-size: 11.5px; color: #444746; }
.gm-fact span { font-size: 15px; color: #1f1f1f; }
.gm-p { font-size: 14px; color: #1f1f1f; line-height: 1.45; margin-bottom: 10px; }
.gm-p a { color: #1a6d9b; text-decoration: none; }
.gm-btns { display: flex; flex-wrap: wrap; gap: 8px; }
.gm-btn { display: inline-flex; align-items: center; height: 34px; padding: 0 22px; border-radius: 17px; font-size: 14px; border: 1px solid #747775; color: #1a6d9b; background: #fff; white-space: nowrap; }
.gm-btn.fill { background: #1a6d9b; border-color: #1a6d9b; color: #fff; }

/* ---------- iPhone Gmail ---------- */
.gm-phone { width: 410px; height: 864px; padding: 10px; border-radius: 64px; background: #1c1c1e; }
.gm-screen { width: 390px; height: 844px; border-radius: 54px; overflow: hidden; background: #fff; position: relative; display: flex; flex-direction: column; }
.gm-status { height: 54px; flex: none; display: flex; align-items: center; justify-content: space-between; padding: 6px 34px 0 44px; font-size: 16px; font-weight: 600; font-family: -apple-system, "SF Pro Text", Roboto, sans-serif; }
.gm-island { position: absolute; top: 11px; left: 50%; width: 124px; height: 36px; margin-left: -62px; border-radius: 20px; background: #000; }
.gm-status-r { display: flex; gap: 6px; align-items: center; }
.gm-status-r svg { fill: #000; }
.gm-appbar { height: 52px; flex: none; display: flex; align-items: center; padding: 0 8px 0 12px; gap: 6px; }
.gm-appbar .ic { width: 24px; height: 24px; margin: 0 8px; }
.gm-appbar .gm-bar-r { margin-left: auto; display: flex; }
.gm-p-subject { font-size: 21px; line-height: 1.3; padding: 4px 20px 14px; }
.gm-p-from { display: flex; gap: 12px; align-items: center; padding: 0 20px 12px; }
.gm-p-from .av { width: 40px; height: 40px; background: #0b8043; font-size: 17px; }
.gm-p-from b { font-size: 15px; font-weight: 500; }
.gm-p-from div div { font-size: 13px; color: #5e5e5e; }
.gm-p-body { padding: 0 20px 16px; font-size: 15px; line-height: 1.5; color: #222; }
.gm-p-addon { margin: 0 12px; border-radius: 16px; overflow: hidden; border: 1px solid #dadce0; flex: 1; min-height: 0; display: flex; }
.gm-p-addon .gm-card { flex: 1; }
.gm-p-addon .gm-bar { height: 52px; }
.gm-home { height: 34px; flex: none; display: flex; align-items: center; justify-content: center; }
.gm-home i { width: 134px; height: 5px; border-radius: 3px; background: #000; }
