/* Layouts: what makes Coral, Lime and Indigo different from Classic beyond their colours (styles.css has the colours).
   Each lays out the same screens in its own way: how the top bar and the tab bar are built, how the summary on Home is
   composed, and how a list of phones is drawn. Nothing here changes what a screen shows or does. */

/* ---------- shared by the three: plainer sections, the selection never refracts, equal tiles on Home ---------- */
html[data-style]:not([data-style='classic']) .lens-glass { -webkit-backdrop-filter: none !important; backdrop-filter: none !important; }
html[data-style]:not([data-style='classic']) .section-title { font-size: 20px; font-weight: 800; letter-spacing: -0.02em; text-transform: none; color: var(--ink); margin: 30px 2px 0; }
html[data-style]:not([data-style='classic']) .stats .stat:nth-child(n) { grid-column: auto; order: 0; min-height: 118px; background: var(--surface); color: var(--ink); border: 1px solid var(--line); }
html[data-style]:not([data-style='classic']) .stats .stat:nth-child(n) .lbl,
html[data-style]:not([data-style='classic']) .stats .stat:nth-child(n) .hint { color: var(--ink-3); }
html[data-style]:not([data-style='classic']) .stats .stat:nth-child(n) .val { font-size: clamp(20px, 17cqi, 30px); letter-spacing: -0.04em; color: var(--ink); }
html[data-style]:not([data-style='classic']) .stat .lbl .go { display: none; }
html[data-style]:not([data-style='classic']) .stat .lbl svg { width: 28px; height: 28px; padding: 6px; border-radius: 10px; background: var(--brand-soft); color: var(--brand-text); box-sizing: border-box; }
html[data-style]:not([data-style='classic']) .greet { padding: 4px 2px 0; }
html[data-style]:not([data-style='classic']) .greet .title { font-size: 30px; }
html[data-style]:not([data-style='classic']) .greet .sub { margin-top: 4px; }
html[data-style]:not([data-style='classic']) .greet .sub.tight { margin: 0; }
html[data-style]:not([data-style='classic']) .chg { font-style: normal; font-size: 12px; font-weight: 800; }
html[data-style]:not([data-style='classic']) .chg.up { color: var(--good); }
html[data-style]:not([data-style='classic']) .chg.down { color: var(--bad); }
html[data-style]:not([data-style='classic']) .bigmoney { display: block; font-size: clamp(32px, 11vw, 46px); font-weight: 800; letter-spacing: -0.04em; line-height: 1.05; }
html[data-style]:not([data-style='classic']) .bigmoney i { font-style: normal; font-size: 0.6em; letter-spacing: -0.02em; opacity: 0.55; }
html[data-style]:not([data-style='classic']) .hero { text-align: left; }
html[data-style]:not([data-style='classic']) .hero > .heroart { display: none; }

/* a phone in Stock and Sales starts with a tile: the glyph is drawn here, so every row keeps the same markup */
html[data-style]:not([data-style='classic']) .phone::before { content: ''; flex: none; width: 44px; height: 44px; border-radius: 14px; background: var(--brand) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2311130a' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='7' y='2.5' width='10' height='19' rx='2.6'/%3E%3Cpath d='M11 18.5h2'/%3E%3C/svg%3E") center / 24px no-repeat; }
html[data-style]:not([data-style='classic']) .picking .phone::before { display: none; }

/* ---------- the top bar: the person's picture first, round buttons ---------- */
html[data-style='coral'] .topright, html[data-style='lime'] .topright { display: contents; }
html[data-style='coral'] .topbar .userchip, html[data-style='lime'] .topbar .userchip { order: -1; }
html[data-style='coral'] .topbar .brand, html[data-style='lime'] .topbar .brand { order: 0; flex: 1; }
html[data-style='coral'] .topbar .askbtn, html[data-style='lime'] .topbar .askbtn { order: 1; }
html[data-style='coral'] .topbar .syncchip, html[data-style='lime'] .topbar .syncchip { order: 2; }
html[data-style='coral'] .topbar .brandmark, html[data-style='lime'] .topbar .brandmark { display: none; }
html[data-style='coral'] .topbar, html[data-style='lime'] .topbar { justify-content: flex-start; }
html[data-style='coral'] .askbtn span, html[data-style='lime'] .askbtn span { display: none; }
html[data-style='coral'] .askbtn, html[data-style='lime'] .askbtn { width: 44px; height: 44px; padding: 0; background: var(--surface); color: var(--ink); border-color: var(--line); }
html[data-style='indigo'] .askbtn, html[data-style='pulse'] .askbtn { width: 44px; height: 44px; padding: 0; background: var(--surface); color: var(--ink); border-color: var(--line); }
html[data-style='indigo'] .askbtn span, html[data-style='pulse'] .askbtn span { display: none; }
html[data-style='indigo'] .brandmark { border-radius: 50%; }
html[data-style='lime'] .brandtext b, html[data-style='coral'] .brandtext b { font-size: 15px; }

/* ---------- the tab bar ---------- */
html[data-style='lime'] .tab span, html[data-style='coral'] .tab:not([aria-current='page']) span, html[data-style='pulse'] .tab:not([aria-current='page']) span, html[data-tabbar='icons'] .tab span, html[data-tabbar='pill'] .tab:not([aria-current='page']) span { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; } /* named for a screen reader, not drawn */
html[data-style='lime'] .tab svg, html[data-tabbar='icons'] .tab svg { width: 26px; height: 26px; }
/* Lime: icons only, the open tab is a filled circle */
html[data-style='lime'] .nav-bar, html[data-tabbar='icons'] .nav-bar { --d: calc(var(--nav-h) - 12px); --m: calc((var(--colw, 64px) - var(--d)) / 2); }
html[data-style='lime'] .nav-bar > .glass-lens, html[data-tabbar='icons'] .nav-bar > .glass-lens { top: 50%; bottom: auto; height: var(--d); width: var(--d) !important; margin: calc(var(--d) / -2) 0 0 var(--m); border-radius: 50%; }
html[data-style='lime'] .nav-bar .lens-mag, html[data-tabbar='icons'] .nav-bar .lens-mag { margin: calc(4px - (var(--nav-h) - var(--d)) / 2) 0 0 calc(-1 * var(--m)); }
/* Coral: the open tab is a low accent pill with its name beside the icon, the others are bare icons */
html[data-style='coral'] .nav-bar, html[data-style='pulse'] .nav-bar, html[data-tabbar='pill'] .nav-bar { --d: 42px; container: navbar / inline-size; }
html[data-style='coral'] .nav-bar > .glass-lens, html[data-style='pulse'] .nav-bar > .glass-lens, html[data-tabbar='pill'] .nav-bar > .glass-lens { top: 50%; bottom: auto; height: var(--d); width: calc(var(--colw, 64px) - 4px) !important; margin: calc(var(--d) / -2) 0 0 2px; border-radius: 999px; }
html[data-style='coral'] .nav-bar .lens-mag, html[data-style='pulse'] .nav-bar .lens-mag, html[data-tabbar='pill'] .nav-bar .lens-mag { margin: calc(4px - (var(--nav-h) - var(--d)) / 2) 0 0 -2px; }
html[data-style='coral'] .nav-bar .tab[aria-current='page'], html[data-style='pulse'] .nav-bar .tab[aria-current='page'], html[data-tabbar='pill'] .nav-bar .tab[aria-current='page'] { flex-direction: row; gap: 5px; }
html[data-style='coral'] .nav-bar .tab[aria-current='page'] svg, html[data-style='pulse'] .nav-bar .tab[aria-current='page'] svg, html[data-tabbar='pill'] .nav-bar .tab[aria-current='page'] svg { width: 22px; height: 22px; }
html[data-style='coral'] .nav-bar .tab[aria-current='page'] span, html[data-style='pulse'] .nav-bar .tab[aria-current='page'] span, html[data-tabbar='pill'] .nav-bar .tab[aria-current='page'] span { animation: tablabel calc(var(--t-med) * 0.8) var(--ease) both; } /* the name fades in as the pill arrives */
@keyframes tablabel { from { opacity: 0; } to { opacity: 1; } }
@container navbar (max-width: 329px) { /* too narrow for the name: just the icon in the pill */
  html[data-style='coral'] .tab[aria-current='page'] span, html[data-style='pulse'] .tab[aria-current='page'] span, html[data-tabbar='pill'] .tab[aria-current='page'] span { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
}
/* Indigo: a soft rounded square behind the open tab, in a dock with softer corners */
html[data-style='indigo'] .nav-bar, html[data-style='indigo'] .nav-surface { border-radius: 26px; }
html[data-style='indigo'] .nav-bar > .glass-lens { width: calc(var(--colw, 64px) - 6px) !important; margin-left: 3px; border-radius: 18px; }
html[data-style='indigo'] .nav-bar .lens-mag { margin-left: -3px; }
html[data-style='indigo'] .nav-add { border-radius: 20px; }
html[data-style='indigo']:not([data-style='classic']) { --plate-bg: var(--brand-soft); --lens-tint: var(--brand-soft); --tab-ink-on: var(--brand-text); --plate-hi: transparent; }

/* ---------- Coral: a ring and three numbers; phones as separate cards ---------- */
html[data-style='coral']:not([data-style='classic']) { --r-l: 24px; --r-xl: 28px; }
html[data-style='coral'] .hero.ringhero { display: flex; align-items: center; gap: 18px; padding: 18px; background: var(--surface); border: 1px solid var(--line); }
html[data-style='coral'] .ringhero::before { display: none; }
html[data-style='coral'] .ring { position: relative; flex: none; width: 128px; height: 128px; }
html[data-style='coral'] .ring > span:first-child, html[data-style='coral'] .ring svg { display: block; width: 128px; height: 128px; }
html[data-style='coral'] .ringtext { position: absolute; inset: 0; display: grid; place-content: center; text-align: center; gap: 0; }
html[data-style='coral'] .ringtext b { font-size: 26px; font-weight: 800; letter-spacing: -0.04em; line-height: 1.1; }
html[data-style='coral'] .ringtext span { font-size: 11px; font-weight: 600; color: var(--ink-3); max-width: 80px; line-height: 1.2; }
html[data-style='coral'] .legends { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 10px; }
html[data-style='coral'] .legend { display: grid; grid-template-columns: 10px 1fr; column-gap: 8px; align-items: center; }
html[data-style='coral'] .legend i { width: 8px; height: 8px; border-radius: 50%; background: var(--brand); }
html[data-style='coral'] .legend i.d2 { background: var(--teal); }
html[data-style='coral'] .legend i.d3 { background: var(--ink-3); }
html[data-style='coral'] .legend span { font-size: 12px; font-weight: 600; color: var(--ink-3); }
html[data-style='coral'] .legend b { grid-column: 2; font-size: 20px; font-weight: 800; letter-spacing: -0.03em; line-height: 1.15; }
html[data-style='coral'] .cards { display: flex; flex-direction: column; gap: 10px; background: none; border: 0; box-shadow: none; overflow: visible; border-radius: 0; }
html[data-style='coral'] .cards > .phone { background: var(--surface); border: 1px solid var(--line); border-radius: 22px; padding: 12px 14px; box-shadow: var(--shadow-1); }
html[data-style='coral'] .cards > .phone + .phone { border-top: 1px solid var(--line); }
html[data-style='coral'] .cards > .phone[aria-pressed='true'] { background: color-mix(in srgb, var(--brand) 12%, var(--surface)); border-color: var(--brand); }

/* ---------- Lime: one big number on a dark card; flat rows with a lime tile and a round arrow ---------- */
html[data-style='lime']:not([data-style='classic']) { --r-l: 20px; --r-xl: 26px; }
html[data-style='lime'] .hero.darkhero { display: flex; flex-direction: column; align-items: flex-start; gap: 4px; padding: 22px; background: var(--tile-dark); color: var(--tile-dark-ink); border: 0; }
html[data-style='lime'] .darkhero .kicker { color: var(--tile-dark-dim); }
html[data-style='lime'] .darkhero .fullline { color: var(--tile-dark-dim); }
html[data-style='lime'] .darkhero .fullline b { color: var(--tile-dark-ink); }
html[data-style='lime'] .darkhero .chg.up { color: var(--brand); }
html[data-style='lime'] .darkhero .chg.down { color: #ff9b8a; }
html[data-style='lime'] .darkhero .herowk { width: 100%; margin-top: 14px; }
html[data-style='lime'] .darkhero .herobars { max-width: none; }
html[data-style='lime'] .darkhero .herobar span { color: var(--tile-dark-dim); }
html[data-style='lime'] .darkhero .herobar.today span { color: var(--tile-dark-ink); }
html[data-style='lime'] .darkhero .herobar i { background: color-mix(in srgb, var(--brand) 55%, transparent); }
html[data-style='lime'] .darkhero .herobar.today i { background: var(--brand); }
html[data-style='lime'] .darkhero .herobar.none i { background: rgba(255, 255, 255, 0.14); }
html[data-style='lime'] .darkhero .seeall { display: flex; align-items: center; gap: 4px; margin-top: 12px; font-size: 13px; font-weight: 700; color: var(--brand); }
html[data-style='lime']:not([data-style='classic']) .stats .stat:nth-child(1) { background: var(--brand); color: var(--btn-ink); border-color: transparent; }
html[data-style='lime']:not([data-style='classic']) .stats .stat:nth-child(1) .lbl, html[data-style='lime']:not([data-style='classic']) .stats .stat:nth-child(1) .hint, html[data-style='lime']:not([data-style='classic']) .stats .stat:nth-child(1) .val { color: var(--btn-ink); }
html[data-style='lime']:not([data-style='classic']) .stats .stat:nth-child(1) .lbl svg { background: rgba(17, 19, 10, 0.12); color: var(--btn-ink); }
html[data-style='lime'] .cards { background: none; border: 0; box-shadow: none; overflow: visible; border-radius: 0; }
html[data-style='lime'] .cards > .phone { padding: 10px 2px; gap: 11px; }
html[data-style='lime'] .cards > .phone + .phone { border-top: 0; }
html[data-style='lime'] .phone::before { width: 48px; height: 48px; border-radius: 15px; }
html[data-style='lime'] .cards > .phone::after { content: ''; flex: none; width: 32px; height: 32px; border-radius: 50%; border: 1px solid var(--line); background: var(--surface) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%238a8a90' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m9 6 6 6-6 6'/%3E%3C/svg%3E") center / 18px no-repeat; }
html[data-style='lime'] .picking .phone::after { display: none; }
html[data-style='lime'] .cards > .phone[aria-pressed='true'] { background: color-mix(in srgb, var(--brand) 14%, transparent); border-radius: 16px; }

/* ---------- Indigo: a gradient card with a line and four buttons; one grouped list with round tiles ---------- */
html[data-style='indigo']:not([data-style='classic']) { --r-btn: 16px; --r-l: 22px; --r-xl: 26px; }
html[data-style='indigo'] .hero.gradhero { padding: 20px 18px 16px; color: var(--btn-ink); border: 0; background: linear-gradient(150deg, var(--btn-bg), color-mix(in srgb, var(--btn-bg) 66%, #000000)); }
html[data-style='indigo'] .gradhero::before { background: radial-gradient(closest-side, rgba(255, 255, 255, 0.18), transparent); }
html[data-style='indigo'] .gradhero .kicker { color: color-mix(in srgb, var(--btn-ink) 85%, transparent); letter-spacing: 0.02em; text-transform: none; font-size: 13px; }
html[data-style='indigo'] .gradhero .fullline, html[data-style='indigo'] .gradhero .fullline b { color: var(--btn-ink); }
html[data-style='indigo'] .herotap { display: flex; flex-direction: column; align-items: flex-start; gap: 4px; width: 100%; text-align: left; color: inherit; }
html[data-style='indigo'] .gradhero .chg, html[data-style='indigo'] .gradhero .chg.up, html[data-style='indigo'] .gradhero .chg.down { color: var(--btn-ink); background: rgba(255, 255, 255, 0.18); padding: 3px 9px; border-radius: 999px; }
html[data-style='indigo'] .spark { position: relative; display: block; width: 100%; height: 64px; margin-top: 8px; color: var(--btn-ink); }
html[data-style='indigo'] .spark svg { display: block; width: 100%; height: 100%; }
html[data-style='indigo'] .spark i { position: absolute; width: 9px; height: 9px; margin: -4.5px 0 0 -4.5px; border-radius: 50%; background: var(--btn-ink); }
html[data-style='indigo'] .quickrow4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; margin-top: 14px; }
html[data-style='indigo'] .quick { display: flex; flex-direction: column; align-items: center; gap: 6px; min-height: 44px; font-size: 12px; font-weight: 700; color: var(--btn-ink); }
html[data-style='indigo'] .qico { width: 48px; height: 48px; border-radius: 16px; display: grid; place-items: center; background: rgba(255, 255, 255, 0.18); }
html[data-style='indigo'] .quick:active .qico { background: rgba(255, 255, 255, 0.3); }
html[data-style='indigo'] .stat .lbl svg { border-radius: 50%; }
html[data-style='indigo'] .phone::before { border-radius: 50%; background: var(--brand) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23ffffff' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='7' y='2.5' width='10' height='19' rx='2.6'/%3E%3Cpath d='M11 18.5h2'/%3E%3C/svg%3E") center / 22px no-repeat; }
html[data-style='indigo'] .cards > .phone .money b { color: var(--ink); }

