/* 1.3.3 (Nov 12, 2026): Release 1.1, Guideline Addendum 1: close card CD2 to CD6, folder tabs CD8, sort row CD9 and CD10, delete screen CD11 to CD14. */
/* 1.3.2 (Nov 12, 2026): Messages, the new-message notice and Tappy(AI), Release 1. Creative Director C0 to C24 and the Release 1 mockup
(Version 6), built to the live look: Work Sans, black, gold #f2b705, 20 px gutter, 17 px body, 48 px targets. Red text #f04a5e (live --red
#c8102e is too low for text on black). No bold in reader-facing text here (C23): bold means a Key Lesson. Nothing closes or fades by itself (C3). */
.ifgm-top { position: relative; margin-left: -8px; /* glyph sits 12 px after the last link's text, like the gaps between links; wrapped at 320 px its visible left edge is on the 20 px text line */ display: inline-flex; align-items: center; justify-content: center; min-width: 44px; min-height: 44px; padding: 0 !important; color: var(--gold) !important; }
.ifgm-top[aria-current="page"] svg { fill: currentColor; }
.ifgm-badge { position: absolute; top: 4px; right: 2px; min-width: 18px; height: 18px; border-radius: 999px; background: var(--gold); color: #000; font: 700 12px/18px var(--font); text-align: center; padding: 0 4px; display: none; }
.ifgm-badge.on { display: block; }

.ifgm-notice { position: fixed; left: var(--gutter); right: var(--gutter); bottom: calc(16px + env(safe-area-inset-bottom, 0px)); z-index: 90; max-width: 720px; margin: 0 auto; background: #1a1a1a; border: 2px solid var(--gold); border-radius: 16px; padding: 14px 0 16px; box-shadow: 0 8px 30px rgba(0,0,0,.6); }
.ifgm-x, .apx { position: absolute; top: 4px; right: 4px; width: 48px; height: 48px; border: 0; border-radius: 999px; background: transparent; color: var(--white); display: grid; place-items: center; cursor: pointer; padding: 0; }
.ifgm-x:focus-visible, .apx:focus-visible { outline: 2px solid var(--gold); outline-offset: -4px; }
.ifgm-nrow { display: flex; gap: 10px; align-items: flex-start; padding: 0 56px 0 14px; }
.ifgm-nicon { flex: none; color: var(--gold); margin-top: 2px; }
.ifgm-ntxt { font-size: 17px; line-height: 1.45; color: var(--white); }
.ifgm-tag { display: inline-block; border: 1px solid var(--dim); color: var(--dim); border-radius: 6px; font-size: 13px; font-weight: 500; line-height: 1; padding: 5px 7px; margin-bottom: 6px; }
.ifgm-pill { display: flex; align-items: center; justify-content: center; box-sizing: border-box; width: calc(100% - 28px); margin: 12px 14px 0; min-height: 48px; border-radius: 999px; border: 2px solid var(--gold); background: transparent; color: var(--gold); font: 700 16px var(--font); text-decoration: none; cursor: pointer; }

body.msgs main#mview { max-width: 760px; margin: 0 auto; padding: 8px 0 80px; font-size: 17px; line-height: 1.45; }
.ifgm-head { display: flex; align-items: center; gap: 4px; padding: 12px var(--gutter) 8px; }
.ifgm-head h1 { flex: 1; min-width: 0; margin: 0; font-size: 24px; font-weight: 700; line-height: 1.25; overflow-wrap: anywhere; }
.ifgm-back { flex: none; width: 48px; height: 48px; margin-left: -19px; /* arrow drawn on the 20 px text line */ color: var(--gold); display: grid; place-items: center; }
.ifgm-switchrow { display: flex; align-items: center; gap: 12px; margin: 4px var(--gutter) 16px; padding: 12px 16px; border: 1px solid var(--line); border-radius: 14px; background: var(--panel); padding-left: 15px; /* text at 36 px, like the quote and cards */ }
.ifgm-st { flex: 1; min-width: 0; }
.ifgm-st div { font-size: 15px; color: var(--dim); }
.ifgm-switch { flex: none; width: 56px; height: 48px; border: 0; background: transparent; cursor: pointer; display: grid; place-items: center; padding: 0; }
.ifgm-track { width: 52px; height: 30px; border-radius: 999px; background: var(--line); position: relative; display: block; }
.ifgm-knob { position: absolute; top: 3px; left: 3px; width: 24px; height: 24px; border-radius: 999px; background: var(--white); transition: left .15s; }
.ifgm-switch[aria-checked="true"] .ifgm-track { background: var(--gold); }
.ifgm-switch[aria-checked="true"] .ifgm-knob { left: 25px; background: #000; }
.ifgm-label { margin: 8px var(--gutter) 6px; font-size: 14px; color: var(--muted); letter-spacing: .5px; }
.ifgm-threads { border-top: 1px solid var(--line); margin-bottom: 16px; }
.ifgm-thread { position: relative; display: block; min-height: 64px; padding: 12px var(--gutter); border-bottom: 1px solid var(--line); color: var(--white); text-decoration: none; box-sizing: border-box; }
.ifgm-dot { position: absolute; left: 6px; top: 20px; width: 8px; height: 8px; border-radius: 999px; background: var(--gold); }
.ifgm-ttop { display: flex; gap: 8px; align-items: baseline; }
.ifgm-item { flex: 1; min-width: 0; font-weight: 500; /* not bold: bold means a Key Lesson (C23) */ overflow-wrap: anywhere; }
.ifgm-status { flex: none; max-width: 50%; text-align: right; font-size: 14px; color: var(--gold); }
.ifgm-status.grey, .ifgm-v.grey { color: var(--muted); }
.ifgm-line1 { font-size: 15px; color: var(--dim); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ifgm-empty { margin: 12px var(--gutter); color: var(--dim); }
.ifgm-quote { margin: 0 var(--gutter) 16px; border-left: 4px solid var(--gold); background: var(--ink); border-radius: 0 10px 10px 0; padding: 12px 16px 12px 12px; color: var(--white); max-height: 40vh; overflow: auto; white-space: pre-wrap; overflow-wrap: anywhere; }
.ifgm-quote mark, .ifgm-msg mark { background: var(--gold); color: #000; border-radius: 3px; padding: 0 2px; }
.ifgm-senton { margin: -8px var(--gutter) 16px; font-size: 14px; color: var(--muted); }
.ifgm-msg { padding: 14px var(--gutter); border-top: 1px solid var(--line); }
.ifgm-msg p { margin: 0 0 8px; overflow-wrap: anywhere; }
.ifgm-who { font-size: 14px; color: var(--muted); margin-bottom: 4px; }
.ifgm-q { margin-top: 12px !important; }
.ifgm-choices { display: flex; flex-direction: column; gap: 12px; margin-top: 12px; }
.ifgm-choice { display: flex; align-items: center; gap: 10px; width: 100%; min-height: 56px; padding: 8px 16px 8px 14px; border: 2px solid var(--line); border-radius: 14px; background: transparent; color: var(--white); text-align: left; font: 400 17px/1.35 var(--font); cursor: pointer; box-sizing: border-box; }
.ifgm-choice .ifgm-ck { flex: none; display: none; color: var(--gold); }
.ifgm-choice.sel { border-color: var(--gold); background: var(--gold-soft); color: var(--gold); }
.ifgm-choice.sel .ifgm-ck { display: block; }
.ifgm-choice:disabled { cursor: default; }
.ifgm-choice.faded { opacity: .45; }
.ifgm-done { width: 100%; min-height: 48px; border: 0; border-radius: 999px; background: transparent; color: var(--muted); font: 400 16px var(--font); cursor: pointer; }
.ifgm-yours { color: var(--dim); font-size: 15px; }
.ifgm-other { margin-top: 4px; }
.ifgm-ol { display: block; font-size: 15px; font-weight: 400; color: var(--dim); }
.ifgm-ol textarea { display: block; width: 100%; box-sizing: border-box; margin-top: 6px; min-height: 96px; background: var(--ink); color: var(--white); border: 2px solid var(--line); border-radius: 12px; padding: 12px 16px 12px 14px; font: 17px var(--font); resize: vertical; }
.ifgm-other .ifgm-pill { width: 100%; margin: 8px 0 0; }
.ifgm-fine { font-size: 14px; color: var(--dim); margin: 8px 0; }
.ifgm-err { color: var(--gold); min-height: 1.2em; margin: 4px 0; }
.ifgm-wait { color: var(--dim); }
.ifgm-status-line { margin: 16px var(--gutter); font-size: 15px; color: var(--muted); }
.ifgm-safety { margin: 12px 0; border-left: 4px solid var(--red); background: var(--panel); border-radius: 0 12px 12px 0; padding: 12px 16px 8px 12px; }
.ifgm-safety p { margin: 8px 0 6px; }
.ifgm-big { font-size: 19px; color: var(--white); margin-top: 0 !important; }
.ifgm-call { display: flex; align-items: center; gap: 10px; min-height: 48px; color: var(--white); text-decoration: none; border-top: 1px solid var(--line); }
.ifgm-call.first { border-top: 0; }
.ifgm-call svg { flex: none; color: var(--gold); }
.ifgm-call em { font-style: normal; color: var(--gold); }
.ifgm-card { margin: 0 var(--gutter) 16px; background: var(--panel); border: 1px solid var(--line); border-radius: 14px; padding: 14px 16px 16px 15px; overflow-wrap: anywhere; }
.ifgm-card.ifgm-flag { border-left: 4px solid var(--red); }
.ifgm-card h3 { margin: 0 0 4px; font-size: 17px; font-weight: 600; }
.ifgm-sub { font-size: 14px; color: var(--muted); margin-bottom: 12px; }
.ifgm-vlabel { font-size: 14px; color: var(--muted); margin: 10px 0 2px; }
.ifgm-added { background: rgba(242,183,5,.22); border-bottom: 2px solid var(--gold); padding: 0 1px; }
.ifgm-red { color: #f04a5e; }
.ifgm-verdicts { margin: 14px 0 0; border-top: 1px solid var(--line); }
.ifgm-vrow { display: flex; align-items: center; gap: 8px; min-height: 44px; border-bottom: 1px solid var(--line); font-size: 15px; }
.ifgm-m { flex: 1 0 auto; }
.ifgm-v { flex: none; display: flex; align-items: center; gap: 6px; color: var(--gold); }
.ifgm-v.red { color: #f04a5e; }
.ifgm-actions { display: flex; gap: 12px; margin-top: 16px; }
.ifgm-hold { flex: 1; position: relative; overflow: hidden; height: 48px; border-radius: 999px; border: 2px solid var(--gold); background: transparent; color: var(--gold); font: 700 16px var(--font); cursor: pointer; touch-action: none; -webkit-user-select: none; user-select: none; -webkit-touch-callout: none; }
.ifgm-fill { position: absolute; inset: 0; background: var(--gold-soft); transform: scaleX(0); transform-origin: left; }
.ifgm-hold.holding .ifgm-fill { transform: scaleX(1); transition: transform 2000ms linear; }
.ifgm-ht { position: relative; }
.ifgm-hold.done { background: var(--gold); color: #000; }
.ifgm-qbtn { flex: none; width: 48px; height: 48px; border-radius: 999px; border: 2px solid var(--line); background: transparent; color: var(--dim); font: 700 18px var(--font); cursor: pointer; }
.ifgm-okline { margin: 10px 0 0; font-size: 15px; color: var(--gold); min-height: 1em; }
.ifgm-rv { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; }
.ifgm-sel, .ifgm-in { min-height: 44px; background: #000; color: var(--white); border: 1px solid var(--line); border-radius: 8px; padding: 0 10px; font: 15px var(--font); max-width: 100%; margin: 0; }
.ifgm-in { flex: 1 1 160px; width: auto; }
/* every Field Guide pop-up gets its X in the same spot, top right (C4) */
.apin { position: relative; }
.apin > .apx { position: sticky; top: -14px; right: auto; float: right; margin: -14px -12px 0 8px; background: #111; z-index: 2; } /* stays top right while the box scrolls (tested at 360 px: same spot scrolled or not) */
/* ---- 1.3.3 Addendum 1 ---- */
.ifgm-tabs { display: flex; margin: 0 var(--gutter) 8px; border-bottom: 1px solid var(--line); } /* CD8: after the switch row, Inbox, Archive, Trash */
.ifgm-tab { flex: 1; display: flex; align-items: center; justify-content: center; gap: 6px; min-height: 48px; color: var(--dim); text-decoration: none; font-size: 16px; border-bottom: 3px solid transparent; margin-bottom: -1px; box-sizing: border-box; }
.ifgm-tab[aria-selected="true"] { color: var(--white); border-bottom-color: var(--gold); }
.ifgm-count { color: var(--muted); font-size: 14px; }
.ifgm-fold { margin: 8px var(--gutter) 12px; font-size: 15px; color: var(--dim); }
.ifgm-app p { color: var(--dim); }
.ifgm-cc { background: #1A1A1A; border: 2px solid var(--gold); border-radius: 14px; padding: 14px 16px 12px 14px; } /* CD2 */
.ifgm-cc .ifgm-vlabel { margin-top: 4px; }
.ifgm-on { display: grid; grid-template-columns: 1fr; gap: 8px; margin: 4px 0 12px; } /* Old over New on phones */
@media (min-width: 600px) { .ifgm-on { grid-template-columns: 1fr 1fr; gap: 16px; } } /* side by side at 600 px+ */
.ifgm-old { color: var(--dim); }
.ifgm-ccr { margin-top: 4px; } /* CD3: the book-item check and ?, same order and spot (approve.css .apr) */
.ifgm-ccr.ifgm-off .apb { cursor: default; }
.ifgm-ed9 { margin: 16px var(--gutter) 0; color: var(--dim); }
.ifgm-sort { display: flex; gap: 12px; margin: 8px var(--gutter) 0; align-items: center; flex-wrap: wrap; } /* CD9: very end of the thread, below the Status line */
.ifgm-sbtn { flex: 1 1 0; min-width: 0; min-height: 48px; border-radius: 999px; border: 2px solid var(--line); background: transparent; color: var(--dim); font: 400 16px var(--font); cursor: pointer; padding: 0 12px; }
.ifgm-moved { flex: 1 1 100%; margin: 0; color: var(--white); }
.ifgm-sort .ifgm-moved + .ifgm-sbtn { flex: 0 1 50%; }
/* CD11 to CD14: Delete my account (sync.js) */
.ifg12-card.ifg133-del { position: relative; max-height: 90vh; overflow: auto; } /* CD11: scrolls at 320 px and 130% text */
.ifg133-del h3 { margin-top: 0; padding-right: 48px; }
.ifg133-gone, .ifg133-kept { margin: 12px 0; padding: 10px 14px; background: var(--panel); border-radius: 0 10px 10px 0; } /* no bold (CD12) */
.ifg133-gone { border-left: 4px solid #8A8A8A; } .ifg133-kept { border-left: 4px solid var(--gold); }
.ifg133-gone p, .ifg133-kept p { margin: 0 0 6px; }
.ifg133-ch { display: grid; grid-auto-rows: 1fr; gap: 12px; margin: 12px 0; } /* 1.3.3 Creative Director, Nov 12: both choices the same height when one wraps */
.ifg133-ch button { width: 100%; min-height: 56px; border: 2px solid var(--line); border-radius: 14px; background: transparent; color: var(--white); font: 400 17px/1.35 var(--font); text-align: left; padding: 8px 16px 8px 14px; cursor: pointer; } /* CD13: none picked */
.ifg133-ch button[aria-pressed="true"] { border-color: var(--gold); background: var(--gold-soft); color: var(--gold); }
.ifg133-btns { display: flex; flex-direction: column; gap: 12px; margin-top: 16px; } /* CD14 */
.ifg133-btns button { width: 100%; min-height: 48px; border-radius: 999px; font: 700 16px var(--font); cursor: pointer; }
.ifg133-keep { background: var(--gold); color: #000; border: 2px solid var(--gold); }
.ifg133-go { background: transparent; color: #F04A5E; border: 2px solid #8A8A8A; }
.ifg133-set fieldset { border: 0; padding: 0; margin: 12px 0 0; } .ifg133-set label { display: flex; gap: 10px; align-items: center; min-height: 44px; }
@media (prefers-reduced-motion: reduce) { .ifgm-knob, .ifgm-hold.holding .ifgm-fill { transition: none; } }

/* 1.3.3c (Nov 12, 2026): the test close reads as a button (Creative Director) */
.ifgm-testrow .ifgm-fine { margin: 0 0 8px; }
.ifgm-test { display: block; width: 100%; min-height: 48px; }

/* 1.3.3d (Nov 12, 2026): status up top and your own steps (Creative Director) */
.ifgm-where { margin: 12px 20px 16px; padding: 12px 14px; border: 2px solid var(--gold); border-radius: 14px; }
.ifgm-whh { font-weight: 700; font-size: 20px; color: var(--gold); }
.ifgm-where p { margin: 6px 0 0; }
.ifgm-you { margin: 8px 20px 8px 68px; padding: 12px 14px; background: #1A1A1A; border-radius: 14px; border-top: 0; }

/* 1.3.3f (Nov 12, 2026): an open thread looks like a message app (Billy: "Need the creative director to help this whole situation LOOK like a message. Right now it looks like a web page"). Creative Director: chat header with the topic and status, the next step right under it, Tappy on the left, you on the right in gold, times and day lines, quick-reply chips. Nothing hides in a menu (C3). */
body.ifgm-chatting header.top { display: none; }
body.ifgm-chatting main#mview { padding-top: 0; }
.ifgm-chead { position: sticky; top: 0; z-index: 20; display: flex; align-items: center; gap: 10px; padding: 8px 100px 8px 20px; min-height: 56px; background: #111; border-bottom: 1px solid var(--line); } /* right side kept clear for Quick exit */
.ifgm-chead .ifgm-back { margin-left: -14px; }
.ifgm-av { flex: none; width: 40px; height: 40px; border-radius: 999px; background: var(--gold); color: #000; display: grid; place-items: center; }
.ifgm-av svg { width: 22px; height: 22px; }
.ifgm-cwho { flex: 1; min-width: 0; }
.ifgm-cname { margin: 0; font-size: 18px; font-weight: 600; line-height: 1.25; overflow-wrap: anywhere; } /* wraps, never cut off */
.ifgm-cst { font-size: 14px; line-height: 1.3; color: var(--gold); }
.ifgm-cnext { margin: 12px 20px 4px; padding: 8px 14px; background: #1A1A1A; border-radius: 12px; font-size: 15px; line-height: 1.4; color: var(--dim); text-align: center; }
.ifgm-day { margin: 16px 20px 8px; text-align: center; font-size: 13px; color: var(--muted); }
body.ifgm-chatting .ifgm-msg { border-top: 0; }
body.ifgm-chatting .ifgm-ai, body.ifgm-chatting .ifgm-staff { position: relative; box-sizing: border-box; width: fit-content; max-width: calc(100% - 80px); margin: 6px 20px 6px 60px; padding: 10px 14px 8px; background: #1A1A1A; border-radius: 18px 18px 18px 6px; }
body.ifgm-chatting .ifgm-ai::before, body.ifgm-chatting .ifgm-staff::before { content: 'T'; position: absolute; left: -40px; bottom: 0; width: 32px; height: 32px; border-radius: 999px; background: var(--gold); color: #000; font: 600 15px/32px var(--font); text-align: center; }
body.ifgm-chatting .ifgm-staff::before { content: 'R'; background: var(--white); }
body.ifgm-chatting .ifgm-ai .ifgm-tag, body.ifgm-chatting .ifgm-staff .ifgm-tag, body.ifgm-chatting .ifgm-staff .ifgm-who { display: block; border: 0; padding: 0; margin: 0 0 4px; font-size: 13px; line-height: 1.3; color: var(--gold); }
body.ifgm-chatting .ifgm-staff .ifgm-who { color: var(--dim); }
body.ifgm-chatting .ifgm-you { box-sizing: border-box; width: fit-content; max-width: calc(100% - 80px); margin: 6px 20px 6px auto; padding: 10px 14px 8px; background: var(--gold); color: #000; border-radius: 18px 18px 6px 18px; }
body.ifgm-chatting .ifgm-you .ifgm-who { display: none; }
body.ifgm-chatting .ifgm-you p { color: #000; margin: 0 0 4px; }
body.ifgm-chatting .ifgm-you .ifgm-quote { margin: 2px 0 8px; background: #000; color: var(--white); border-left: 4px solid #000; border-radius: 10px; font-size: 15px; max-height: 30vh; }
.ifgm-time { margin-top: 2px; text-align: right; font-size: 12px; color: var(--muted); }
body.ifgm-chatting .ifgm-you .ifgm-time { color: #3a2c00; }
body.ifgm-chatting .ifgm-choices { flex-direction: row; flex-wrap: wrap; gap: 8px; }
body.ifgm-chatting .ifgm-choice { width: auto; max-width: 100%; min-height: 44px; padding: 8px 14px; border-radius: 999px; border-color: var(--gold); color: var(--gold); font-size: 16px; }
body.ifgm-chatting .ifgm-choice.sel { background: var(--gold); color: #000; }
body.ifgm-chatting .ifgm-choice.sel .ifgm-ck { color: #000; }
body.ifgm-chatting .ifgm-done { width: auto; min-height: 44px; padding: 0 14px; border: 2px solid var(--line); }
body.ifgm-chatting .ifgm-typing .ifgm-wait { margin: 0; }
body.ifgm-chatting .ifgm-app { margin: 8px 20px; padding: 0; text-align: center; font-size: 14px; }
body.ifgm-chatting .ifgm-testrow { margin: 20px 20px 0; padding: 12px 0 0; border-top: 1px solid var(--line); text-align: center; }
body.ifgm-chatting .ifgm-test { display: inline-block; width: auto; min-height: 44px; padding: 0 18px; }
body.ifgm-chatting .ifgm-sort .ifgm-sbtn { min-height: 44px; font-size: 15px; }
/* 1.3.4b (A#490, Billy: "These items are so close together I can't tell which is connected to which"): each box sits with its own button in its own panel */
.ifgm-grp{border:1px solid #3A3A3A;border-radius:12px;padding:12px;margin:20px 0 0}
.ifgm-grp .ifgm-rv{margin:8px 0 0}
.ifgm-grp .ifgm-rv:first-of-type{margin-top:6px}
.ifgm-glabel{font-size:14px;font-weight:700;color:#F2B705;letter-spacing:.02em}
.ifgm-grp .ifgm-okline{margin:8px 0 0;min-height:0}
.ifgm-grp .ifgm-okline:empty{display:none}
