/* 0.35: fonts served from Gayap itself (works offline, no calls to Google). Inter and Bricolage Grotesque, SIL Open Font Licence */
@font-face{font-family:'Inter';font-style:normal;font-weight:400;font-display:swap;src:url(fonts/inter-regular.woff) format('woff')}
@font-face{font-family:'Inter';font-style:normal;font-weight:500;font-display:swap;src:url(fonts/inter-medium.woff) format('woff')}
@font-face{font-family:'Inter';font-style:normal;font-weight:600;font-display:swap;src:url(fonts/inter-semibold.woff) format('woff')}
@font-face{font-family:'Inter';font-style:normal;font-weight:700;font-display:swap;src:url(fonts/inter-bold.woff) format('woff')}
@font-face{font-family:'Bricolage Grotesque';font-style:normal;font-weight:600 800;font-display:swap;src:url(fonts/bricolage-bold.woff) format('woff')}
:root{
  --green:#0F6B4F;--green-dark:#0A4F3A;--green-tint:#E3F1EB;
  --ink:#16201C;--ink-2:#26332D;--muted:#5B6660;--bg:#F4F5F0;--card:#FFFFFF;
  --line:#E3E5DF;--line-2:#DADDD6;--amber:#F2B84B;--amber-tint:#FBEBC8;--amber-ink:#8A5A00;
  --red:#B3401F;--red-tint:#F8E3DC;--blue-tint:#E4EDF7;--blue-ink:#1F4E7A;
  --radius:16px;--radius-sm:12px;
  --display:'Bricolage Grotesque',system-ui,sans-serif;
  --body:Inter,system-ui,-apple-system,'Segoe UI',Roboto,sans-serif;
  --shadow:0 1px 2px rgba(22,32,28,.06),0 4px 16px rgba(22,32,28,.05);
  --nav-h:68px;
}
*{box-sizing:border-box}
html,body{margin:0;padding:0}
body{background:var(--bg);color:var(--ink);font-family:var(--body);font-size:15px;line-height:1.45;-webkit-font-smoothing:antialiased;-webkit-tap-highlight-color:transparent}
img{max-width:100%;display:block}
a{color:var(--green)}
button,input,select,textarea{font:inherit;color:inherit}
h1,h2,h3{font-family:var(--display);margin:0;line-height:1.15;letter-spacing:-.01em}
h1{font-size:28px}h2{font-size:20px}h3{font-size:17px}
p{margin:0}
.muted{color:var(--muted)}
.small{font-size:13px}
.xs{font-size:12px}
.bold{font-weight:600}
.num{font-variant-numeric:tabular-nums}
.display{font-family:var(--display);font-weight:700}
.sr-only{position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(0 0 0 0);white-space:nowrap}

/* ---------- shell ---------- */
.shell{min-height:100vh;min-height:100dvh}
.topbar{position:sticky;top:0;z-index:20;background:rgba(244,245,240,.92);backdrop-filter:saturate(1.4) blur(10px);-webkit-backdrop-filter:saturate(1.4) blur(10px);border-bottom:1px solid transparent;display:flex;align-items:center;gap:10px;padding:10px 16px;padding-top:max(10px,env(safe-area-inset-top));min-height:60px}
.topbar.scrolled{border-bottom-color:var(--line)}
.topbar .title{flex:1;min-width:0;font-family:var(--display);font-weight:700;font-size:20px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.main{padding:8px 16px calc(var(--nav-h) + 32px + env(safe-area-inset-bottom));max-width:760px;margin:0 auto}
.main.wide{max-width:1080px}
.bottomnav{position:fixed;left:0;right:0;bottom:0;z-index:30;background:#fff;border-top:1px solid var(--line);display:flex;justify-content:space-around;align-items:stretch;height:calc(var(--nav-h) + env(safe-area-inset-bottom));padding-bottom:env(safe-area-inset-bottom)}
.bottomnav a,.bottomnav button{flex:1;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:3px;font-size:11.5px;font-weight:600;color:var(--muted);text-decoration:none;background:none;border:0;padding:0;cursor:pointer;min-width:0}
.bottomnav .active{color:var(--green)}
.bottomnav .plus{flex:0 0 auto;width:72px}
.bottomnav .plus span.disc{width:48px;height:48px;border-radius:24px;background:var(--green);color:#fff;display:flex;align-items:center;justify-content:center;box-shadow:0 6px 16px rgba(15,107,79,.3);margin-top:-14px}
.badge-dot{position:absolute;top:-4px;right:-8px;min-width:18px;height:18px;border-radius:9px;background:var(--red);color:#fff;font-size:11px;display:flex;align-items:center;justify-content:center;padding:0 5px}
.navicon{position:relative;display:inline-flex}
.sidebar{display:none}

@media (min-width:960px){
  .shell.with-side{display:grid;grid-template-columns:248px minmax(0,1fr)}
  .sidebar{display:flex;flex-direction:column;gap:4px;position:sticky;top:0;height:100vh;padding:20px 14px;background:#fff;border-right:1px solid var(--line);overflow-y:auto}
  .sidebar .brand{padding:4px 10px 18px}
  .sidebar a,.sidebar button.navbtn{display:flex;align-items:center;gap:12px;padding:10px 12px;border-radius:12px;color:var(--ink);text-decoration:none;font-weight:500;background:none;border:0;cursor:pointer;text-align:left;width:100%}
  .sidebar a:hover,.sidebar button.navbtn:hover{background:var(--bg)}
  .sidebar a.active{background:var(--green-tint);color:var(--green-dark);font-weight:600}
  .sidebar .sep{height:1px;background:var(--line);margin:10px 8px}
  .sidebar .grow{flex:1}
  .bottomnav{display:none}
  .main{padding:8px 32px 48px}
  .topbar{padding:16px 32px}
  .hide-desktop{display:none!important}
}
@media (max-width:959px){.hide-mobile{display:none!important}}

/* ---------- brand ---------- */
.brand{display:flex;align-items:center;gap:10px;text-decoration:none;color:var(--ink)}
.brand .logo{width:36px;height:36px;border-radius:10px;flex:0 0 auto}
.brand .word{font-family:var(--display);font-weight:700;font-size:22px;letter-spacing:-.02em;text-transform:lowercase}
.brand .tag{font-size:11.5px;color:var(--muted);display:block;margin-top:-2px}

/* ---------- cards & lists ---------- */
.stack{display:flex;flex-direction:column;gap:12px}
.stack-lg{display:flex;flex-direction:column;gap:20px}
.row{display:flex;align-items:center;gap:10px}
.row.wrap{flex-wrap:wrap}
.row.between{justify-content:space-between}
.row.top{align-items:flex-start}
.grow{flex:1;min-width:0}
.grid2{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}
.grid3{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:10px}
@media (min-width:700px){.grid-auto{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}}
@media (min-width:1100px){.grid-auto.three{grid-template-columns:repeat(3,minmax(0,1fr))}}
@media (max-width:699px){.grid-auto{display:flex;flex-direction:column;gap:12px}}
.card{background:var(--card);border-radius:var(--radius);padding:16px;box-shadow:var(--shadow)}
.card.flat{box-shadow:none;border:1px solid var(--line)}
.card.dark{background:var(--ink);color:#fff}
.card.dark .muted{color:#C9D2CD}
.card.tint{background:var(--green-tint);box-shadow:none}
.card.amber{background:var(--amber-tint);box-shadow:none}
.card.link{text-decoration:none;color:inherit;display:block;transition:transform .12s ease,box-shadow .12s ease;cursor:pointer;border:0;width:100%;text-align:left}
.card.link:hover{box-shadow:0 2px 4px rgba(22,32,28,.08),0 10px 24px rgba(22,32,28,.08)}
.card.link:active{transform:scale(.99)}
.list{background:#fff;border-radius:var(--radius);box-shadow:var(--shadow);overflow:hidden}
.list .item{display:flex;align-items:center;gap:12px;padding:14px 16px;border-bottom:1px solid var(--line);text-decoration:none;color:inherit;background:none;border-left:0;border-right:0;border-top:0;width:100%;text-align:left;cursor:pointer}
.list .item:last-child{border-bottom:0}
.list .item:hover{background:#FAFBF8}
.list .item.static{cursor:default}
.list .item.static:hover{background:none}
.section-title{display:flex;align-items:baseline;justify-content:space-between;gap:8px;margin:8px 2px 2px}
.section-title h2{font-size:18px}
.kicker{font-size:12px;font-weight:600;letter-spacing:.06em;text-transform:uppercase;color:var(--muted)}
.divider{height:1px;background:var(--line);margin:4px 0}

/* ---------- buttons ---------- */
.btn{display:inline-flex;align-items:center;justify-content:center;gap:8px;min-height:44px;padding:0 18px;border-radius:12px;border:1px solid var(--line-2);background:#fff;color:var(--ink);font-weight:600;font-size:15px;cursor:pointer;text-decoration:none;white-space:nowrap;transition:background .12s ease,transform .1s ease}
.btn:hover{background:#F7F8F5}
.btn:active{transform:scale(.98)}
.btn:disabled{opacity:.5;cursor:not-allowed}
.btn.primary{background:var(--green);border-color:var(--green);color:#fff}
.btn.primary:hover{background:var(--green-dark)}
.btn.dark{background:var(--ink);border-color:var(--ink);color:#fff}
.btn.amber{background:var(--amber);border-color:var(--amber);color:var(--ink)}
.btn.ghost{background:transparent;border-color:transparent;color:var(--green)}
.btn.ghost:hover{background:var(--green-tint)}
.btn.danger{color:var(--red);border-color:#EBC9BD}
.btn.lg{min-height:54px;font-size:16.5px;border-radius:16px;padding:0 22px}
.btn.sm{min-height:36px;padding:0 12px;font-size:13.5px;border-radius:10px}
.btn.block{width:100%}
.btn.wa{background:#1E9E57;border-color:#1E9E57;color:#fff}
.btn.wa:hover{background:#178048}
.iconbtn{width:44px;height:44px;border-radius:12px;border:0;background:transparent;display:inline-flex;align-items:center;justify-content:center;color:var(--ink);cursor:pointer;flex:0 0 auto;text-decoration:none}
.iconbtn:hover{background:rgba(22,32,28,.06)}
.actions{display:flex;flex-wrap:wrap;gap:10px}
.actions .btn{flex:1 1 auto}
.stickybar{position:sticky;bottom:calc(var(--nav-h) + env(safe-area-inset-bottom) + 8px);z-index:10;background:#fff;border-radius:18px;box-shadow:0 8px 30px rgba(22,32,28,.14);padding:12px;display:flex;flex-direction:column;gap:10px;margin-top:8px}
@media (min-width:960px){.stickybar{bottom:16px}}

/* ---------- chips & badges ---------- */
.chip{display:inline-flex;align-items:center;gap:6px;border-radius:999px;padding:4px 10px;font-size:12.5px;font-weight:600;white-space:nowrap;background:#ECEEE9;color:var(--ink)}
.chip.green{background:var(--green-tint);color:var(--green-dark)}
.chip.amber{background:var(--amber-tint);color:#5F3E00}
.chip.red{background:var(--red-tint);color:#8A2E13}
.chip.blue{background:var(--blue-tint);color:var(--blue-ink)}
.chip.dark{background:var(--ink);color:#fff}
.chip.outline{background:#fff;border:1px solid var(--line-2)}
.chips{display:flex;gap:8px;overflow-x:auto;padding:2px 0 6px;scrollbar-width:none}
.chips::-webkit-scrollbar{display:none}
.filter{min-height:38px;border-radius:999px;border:1px solid var(--line-2);background:#fff;padding:0 14px;font-weight:600;font-size:13.5px;cursor:pointer;white-space:nowrap;display:inline-flex;align-items:center;gap:6px}
.filter.on{background:var(--ink);border-color:var(--ink);color:#fff}
.stars{display:inline-flex;gap:1px;color:var(--amber-ink)}
.stars svg{display:block}
.avatar{border-radius:30%;background:var(--green);color:#fff;display:flex;align-items:center;justify-content:center;font-family:var(--display);font-weight:700;flex:0 0 auto}
.avatar.soft{background:var(--green-tint);color:var(--green-dark)}

/* ---------- forms ---------- */
.field{display:flex;flex-direction:column;gap:6px}
.field label,.label{font-size:12.5px;font-weight:600;color:var(--muted);letter-spacing:.02em}
.input,.select,.textarea{width:100%;min-height:46px;border:1px solid var(--line-2);border-radius:12px;padding:10px 12px;background:#fff;font-size:15.5px}
.textarea{min-height:88px;resize:vertical;line-height:1.45}
.input:focus,.select:focus,.textarea:focus{outline:2px solid var(--green);outline-offset:-1px;border-color:var(--green)}
.btn:focus-visible,.iconbtn:focus-visible,.filter:focus-visible,a:focus-visible,.card.link:focus-visible{outline:2px solid var(--green);outline-offset:2px}
.seg{display:grid;grid-auto-flow:column;grid-auto-columns:1fr;gap:6px;background:#ECEEE9;padding:4px;border-radius:14px}
.seg button{min-height:40px;border:0;border-radius:10px;background:transparent;font-weight:600;font-size:14px;cursor:pointer;color:var(--muted)}
.seg button.on{background:#fff;color:var(--ink);box-shadow:var(--shadow)}
.check{display:flex;align-items:center;justify-content:space-between;gap:12px;min-height:44px}
.check input{width:22px;height:22px;accent-color:var(--green)}
.qty{display:inline-flex;align-items:center;border:1px solid var(--line-2);border-radius:10px;overflow:hidden;background:#fff}
.qty button{width:36px;height:36px;border:0;background:#fff;font-size:18px;cursor:pointer}
.qty span{min-width:32px;text-align:center;font-weight:600}

/* ---------- money & totals ---------- */
.big{font-family:var(--display);font-weight:700;font-size:38px;line-height:1;letter-spacing:-.02em}
.mid{font-family:var(--display);font-weight:700;font-size:26px;line-height:1.05}
.lines .ln{display:flex;justify-content:space-between;gap:12px;padding:11px 0;border-bottom:1px solid var(--line)}
.lines .ln:last-child{border-bottom:0}
.lines .ln .d{min-width:0}
.total-row{display:flex;justify-content:space-between;align-items:baseline;padding-top:12px}

/* ---------- hero / landing ---------- */
.landing{min-height:100vh;min-height:100dvh;display:flex;flex-direction:column;background:var(--ink);color:#fff}
.landing .inner{max-width:1080px;margin:0 auto;padding:28px 20px 40px;width:100%;flex:1;display:flex;flex-direction:column;gap:28px}
.landing h1{font-size:40px;color:#fff}
.landing .lead{font-size:17px;color:#C9D2CD;max-width:560px}
.landing .choice{display:grid;gap:14px}
@media (min-width:760px){.landing .choice{grid-template-columns:1fr 1fr}.landing h1{font-size:56px}}
.choice-card{background:#fff;color:var(--ink);border-radius:22px;padding:22px;text-decoration:none;display:flex;flex-direction:column;gap:10px;min-height:180px;border:0;text-align:left;cursor:pointer;transition:transform .12s ease}
.choice-card:hover{transform:translateY(-2px)}
.choice-card.green{background:var(--green);color:#fff}
.choice-card.green .muted{color:#D6EBE2}
.choice-card .go{margin-top:auto;font-weight:700;display:flex;align-items:center;gap:8px}
.story{border-top:1px solid #3A4842;padding-top:18px;color:#C9D2CD;font-size:14px;max-width:640px}
.demo-note{background:#26332D;border-radius:12px;padding:10px 14px;font-size:13px;color:#E4EAE6;display:flex;gap:10px;align-items:flex-start}

.hero-c{background:var(--green);color:#fff;border-radius:22px;padding:22px;display:flex;flex-direction:column;gap:14px}
.hero-c h1{color:#fff}
.search{display:flex;align-items:center;gap:10px;background:#fff;border-radius:14px;padding:0 6px 0 14px;min-height:52px;color:var(--ink)}
.search input{border:0;outline:0;flex:1;min-width:0;font-size:15.5px;background:transparent;min-height:50px}
.trade-tile{border-radius:16px;background:#fff;min-height:92px;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:8px;font-size:14px;font-weight:600;color:var(--ink);text-decoration:none;box-shadow:var(--shadow);border:0;cursor:pointer;padding:8px;text-align:center}
.trade-tile:hover{background:#FAFBF8}
.trade-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:10px}
@media (min-width:760px){.trade-grid{grid-template-columns:repeat(6,minmax(0,1fr))}}

.spot{border-radius:20px;background:var(--ink);color:#fff;padding:18px;display:flex;flex-direction:column;gap:12px;text-decoration:none;position:relative;overflow:hidden}
.spot .ribbon{display:inline-flex;align-items:center;gap:6px;color:var(--amber);font-size:12px;font-weight:700;letter-spacing:.06em;text-transform:uppercase}
.spot .muted{color:#C9D2CD}

/* ---------- gallery ---------- */
.gallery{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}
@media (min-width:700px){.gallery{grid-template-columns:repeat(3,minmax(0,1fr))}}
.ph{position:relative;border-radius:14px;overflow:hidden;background:#D7DDD8;aspect-ratio:4/3;border:0;padding:0;cursor:pointer;display:block;width:100%}
.ph img{width:100%;height:100%;object-fit:cover}
.ph .cap{position:absolute;left:0;right:0;bottom:0;padding:22px 10px 8px;background:linear-gradient(transparent,rgba(0,0,0,.62));color:#fff;font-size:12.5px;font-weight:600;text-align:left}
.ph .vtag{position:absolute;top:8px;left:8px;background:rgba(255,255,255,.94);color:var(--green-dark);border-radius:999px;font-size:11px;font-weight:700;padding:3px 8px;display:flex;gap:4px;align-items:center}
.ph-add{aspect-ratio:4/3;border-radius:14px;border:1.5px dashed #9AA49E;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:6px;color:var(--ink);font-weight:600;font-size:13.5px;cursor:pointer;background:transparent}
.thumbs{display:flex;gap:8px;flex-wrap:wrap}
.thumbs .t{width:72px;height:72px;border-radius:12px;overflow:hidden;position:relative;background:#D7DDD8}
.thumbs .t img{width:100%;height:100%;object-fit:cover}
.thumbs .t button{position:absolute;top:2px;right:2px;width:24px;height:24px;border-radius:12px;border:0;background:rgba(0,0,0,.6);color:#fff;cursor:pointer;font-size:14px;line-height:1}
.thumbs .add{width:72px;height:72px;border-radius:12px;border:1.5px dashed #9AA49E;display:flex;align-items:center;justify-content:center;cursor:pointer;background:transparent}

/* ---------- tracker ---------- */
.tracker{display:flex;flex-direction:column;gap:0}
.tracker .st{display:flex;gap:12px;align-items:flex-start;position:relative;padding-bottom:16px}
.tracker .st:last-child{padding-bottom:0}
.tracker .dot{width:22px;height:22px;border-radius:11px;border:2px solid var(--line-2);background:#fff;flex:0 0 auto;display:flex;align-items:center;justify-content:center;z-index:1}
.tracker .st.done .dot{background:var(--green);border-color:var(--green);color:#fff}
.tracker .st.now .dot{border-color:var(--green);box-shadow:0 0 0 4px var(--green-tint)}
.tracker .st:not(:last-child)::before{content:'';position:absolute;left:10px;top:22px;bottom:0;width:2px;background:var(--line-2)}
.tracker .st.done:not(:last-child)::before{background:var(--green)}

/* ---------- overlays ---------- */
.overlay{position:fixed;inset:0;background:rgba(22,32,28,.45);z-index:50;display:flex;align-items:flex-end;justify-content:center;animation:fade .15s ease}
.sheet{background:#fff;width:100%;max-width:560px;max-height:92vh;max-height:92dvh;overflow-y:auto;border-radius:22px 22px 0 0;padding:18px 18px calc(18px + env(safe-area-inset-bottom));animation:up .2s ease}
@media (min-width:700px){.overlay{align-items:center}.sheet{border-radius:22px;padding:22px}}
.sheet .grab{width:40px;height:4px;border-radius:2px;background:var(--line-2);margin:-6px auto 12px}
.sheet-head{display:flex;align-items:center;justify-content:space-between;gap:10px;margin-bottom:12px}
.lightbox{position:fixed;inset:0;background:rgba(0,0,0,.92);z-index:60;display:flex;flex-direction:column;align-items:center;justify-content:center;padding:16px;gap:12px}
.lightbox img{max-height:78vh;border-radius:12px}
.lightbox .cap{color:#fff;text-align:center}
.toast-wrap{position:fixed;left:0;right:0;top:calc(env(safe-area-inset-top) + 66px);display:flex;flex-direction:column;align-items:center;gap:8px;z-index:70;pointer-events:none;padding:0 16px}
@media (min-width:960px){.toast-wrap{top:auto;bottom:24px}}
.toast{background:var(--ink);color:#fff;border-radius:14px;padding:12px 16px;font-size:14px;font-weight:500;box-shadow:0 10px 30px rgba(0,0,0,.2);max-width:440px;display:flex;gap:10px;align-items:center;animation:up .2s ease;pointer-events:none}
.toast.err{background:var(--red)}
@keyframes up{from{transform:translateY(16px);opacity:0}to{transform:none;opacity:1}}
@keyframes fade{from{opacity:0}to{opacity:1}}

.empty{text-align:center;padding:32px 16px;color:var(--muted);display:flex;flex-direction:column;align-items:center;gap:10px}
.notice{display:flex;gap:10px;align-items:flex-start;background:var(--amber-tint);border-radius:12px;padding:12px 14px;font-size:14px}
.notice.green{background:var(--green-tint)}
.notice.blue{background:var(--blue-tint)}
.kpis{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}
@media (min-width:960px){.kpis{grid-template-columns:repeat(4,minmax(0,1fr))}}
.kpi{background:#fff;border-radius:var(--radius);padding:14px 16px;box-shadow:var(--shadow);display:flex;flex-direction:column;gap:4px}
.kpi .v{font-family:var(--display);font-weight:700;font-size:24px}
.bar{height:8px;border-radius:4px;background:#ECEEE9;overflow:hidden}
.bar span{display:block;height:100%;background:var(--green);border-radius:4px}
table.tbl{width:100%;border-collapse:collapse;font-size:14px}
table.tbl th{text-align:left;font-size:12px;color:var(--muted);font-weight:600;padding:8px 6px;border-bottom:1px solid var(--line)}
table.tbl td{padding:10px 6px;border-bottom:1px solid var(--line);vertical-align:top}
table.tbl td.r,table.tbl th.r{text-align:right}
.tbl-wrap{overflow-x:auto}

/* print: earnings statement */
@media print{
  body{background:#fff}
  .sidebar,.bottomnav,.topbar,.no-print,.toast-wrap{display:none!important}
  .shell.with-side{display:block}
  .main{padding:0;max-width:none}
  .card{box-shadow:none;border:1px solid #ccc}
}

/* keep wide rows (chips, tables) from stretching the page on phones */
.grid-auto>*{max-width:100%;width:100%}
.stack>*,.stack-lg>*,.grid2>*,.grid3>*{min-width:0}
.chips{max-width:100%}
.main{overflow-wrap:anywhere}

.btn svg,.iconbtn svg,.filter svg,.chip svg{flex:0 0 auto}
.kpi .v{white-space:nowrap;font-size:clamp(18px,5.4vw,24px)}
.num{white-space:nowrap}
.tbl-wrap .tbl{min-width:520px}
.notice.red{background:#FCE8E5;color:#7A1F12}
/* easy-read mode: larger text and touch targets */
html.easy { font-size: 19px; }
html.easy body { font-size: 19px; line-height: 1.55; }
html.easy .small { font-size: 17px; }
html.easy .xs { font-size: 15px; }
html.easy .btn { min-height: 54px; font-size: 18px; }
html.easy .btn.sm { min-height: 44px; font-size: 16px; }
html.easy .input, html.easy .select, html.easy .textarea { font-size: 19px; min-height: 54px; }
html.easy .item { min-height: 64px; }
html.easy .bottomnav a { font-size: 13px; }
