/* ui.css
   Redesign layer (October 2026). Pages with <body class="ui"> load this after app.css.
   Phone first: bottom tab bar; at 900px and wider the nav becomes a left sidebar. */

.ui { --ground: #f7f4ee; --card: #ffffff; --muted2: #5a6b7d; --goldtext: #8a6a1f; --tint: #f1ede3; --track: #ece7db;
      background: var(--ground); line-height: 1.5; padding-bottom: 92px; }
.ui .page { max-width: 1080px; margin: 0 auto; padding: 0 16px; }
.ui .apptop { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 18px 6px 4px; }
.ui .apptop .brand { color: var(--navy); font-size: 1.25rem; }
.ui .apptop .brand span { color: #a8842f; }
.ui .avatar { width: 40px; height: 40px; flex: none; border-radius: 50%; background: var(--navy); color: var(--gold-soft); display: grid; place-items: center; font-weight: 700; text-decoration: none; }
.ui .backbtn { width: 44px; height: 44px; border-radius: 50%; background: var(--card); border: 1px solid var(--line); display: grid; place-items: center; color: var(--navy); text-decoration: none; flex: none; }
.ui .eyebrow2 { font-size: 0.75rem; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; color: var(--goldtext); }
.ui .hello { font-size: 0.82rem; font-weight: 600; color: var(--muted2); }
.ui h1.title { font-family: "Fraunces", serif; font-weight: 500; font-size: 1.9rem; line-height: 1.1; letter-spacing: -0.02em; color: var(--navy); margin: 4px 0 0; }
.ui .lede { color: var(--muted2); font-size: 0.95rem; margin-top: 8px; }
.ui .seclabel { display: flex; justify-content: space-between; align-items: baseline; padding: 26px 6px 10px; font-size: 0.75rem; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; color: var(--muted2); }
.ui .seclabel a { font-size: 0.82rem; letter-spacing: 0; text-transform: none; color: var(--navy); text-decoration: none; }
.ui .card { background: var(--card); border: 1px solid rgba(15,42,67,0.1); border-radius: 18px; }
.ui .pad { padding: 16px; }
.ui .navycard { background: var(--navy); color: var(--cream); border-radius: 24px; padding: 22px; box-shadow: 0 18px 40px rgba(15,42,67,0.26); }
.ui .ring2 { width: 96px; height: 96px; flex: none; border-radius: 50%; display: grid; place-items: center; }
.ui .ring2 .in { width: 78px; height: 78px; border-radius: 50%; display: grid; place-items: center; text-align: center; }
.ui .ring2 .num { font-family: "Fraunces", serif; font-size: 1.6rem; line-height: 1; }
.ui .ring2 .lbl { font-size: 0.62rem; letter-spacing: 0.1em; text-transform: uppercase; margin-top: 3px; }
.ui .pill { display: inline-block; border-radius: 100px; padding: 4px 10px; font-size: 0.75rem; font-weight: 700; }
.ui .pill.ok { background: #e4f1e9; color: var(--ok); }
.ui .pill.mid { background: #f6ecd2; color: #7a5d18; }
.ui .pill.bad { background: #fbefec; color: var(--bad); }
.ui .pill.gold { background: rgba(201,162,75,0.18); color: var(--gold-soft); }
.ui .grid2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.ui .grid3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.ui .tile { display: flex; flex-direction: column; justify-content: space-between; gap: 12px; min-height: 92px; border-radius: 18px; padding: 16px; text-decoration: none; font-weight: 700; font-size: 0.95rem; }
.ui .tile.gold { background: var(--gold); color: var(--navy-deep); }
.ui .tile.white { background: var(--card); color: var(--navy); border: 1px solid rgba(15,42,67,0.1); }
.ui .tiletop { display: flex; justify-content: space-between; align-items: center; }
.ui .countbadge { background: var(--bad); color: #fff; border-radius: 100px; font-size: 0.75rem; font-weight: 700; padding: 3px 9px; }
.ui .rowlink { display: flex; align-items: center; gap: 14px; padding: 16px; text-decoration: none; color: var(--ink); }
.ui .rowicon { width: 44px; height: 44px; flex: none; border-radius: 14px; background: var(--navy); color: var(--gold-soft); display: grid; place-items: center; }
.ui .rowtitle { font-weight: 700; color: var(--navy); }
.ui .rowsub { font-size: 0.82rem; color: var(--muted2); margin-top: 2px; }
.ui .testcard { display: flex; flex-direction: column; gap: 8px; padding: 16px; border-radius: 18px; text-decoration: none; color: var(--ink); background: var(--card); border: 1px solid rgba(15,42,67,0.1); }
.ui .testcard.todo { border: 1.5px dashed rgba(15,42,67,0.24); }
.ui .testcard .k { font-size: 0.72rem; font-weight: 700; letter-spacing: 0.04em; color: var(--muted2); }
.ui .testcard .v { font-family: "Fraunces", serif; font-size: 1.75rem; color: var(--navy); line-height: 1; }
.ui .testcard .t { font-size: 0.95rem; font-weight: 700; color: var(--navy); line-height: 1.25; }
.ui .testcard .s { font-size: 0.75rem; color: var(--muted2); }
.ui .statnum { font-family: "Fraunces", serif; font-size: 1.75rem; color: var(--navy); line-height: 1; }
.ui .statlbl { font-size: 0.75rem; color: var(--muted2); margin-top: 6px; }
.ui .dlist { padding: 4px 16px; }
.ui .drow2 { display: flex; align-items: center; gap: 12px; padding: 12px 0; border-bottom: 1px solid rgba(15,42,67,0.07); text-decoration: none; color: var(--ink); min-height: 44px; }
.ui .drow2:last-child { border-bottom: 0; }
.ui .dnum2 { width: 28px; height: 28px; flex: none; border-radius: 50%; background: var(--tint); color: var(--navy); display: grid; place-items: center; font-family: "Fraunces", serif; font-weight: 600; font-size: 0.8rem; }
.ui .dmain { flex: 1; min-width: 0; }
.ui .dtop { display: flex; justify-content: space-between; gap: 8px; }
.ui .dtop .n { font-size: 0.88rem; font-weight: 600; line-height: 1.3; }
.ui .dtop .p { font-size: 0.88rem; font-weight: 700; color: var(--navy); }
.ui .dtop .p.none { color: var(--muted2); font-weight: 500; }
.ui .track { height: 5px; border-radius: 100px; background: var(--track); margin-top: 7px; overflow: hidden; }
.ui .track > span { display: block; height: 100%; border-radius: 100px; }
.ui .btnx { display: flex; align-items: center; justify-content: center; gap: 10px; min-height: 54px; border-radius: 16px; font: inherit; font-weight: 700; font-size: 1rem; text-decoration: none; border: 0; cursor: pointer; width: 100%; box-sizing: border-box; padding: 0 16px; text-align: center; }
.ui .btnx.gold { background: var(--gold); color: var(--navy-deep); box-shadow: 0 12px 26px rgba(201,162,75,0.35); }
.ui .btnx.navy { background: var(--navy); color: var(--cream); box-shadow: 0 12px 28px rgba(15,42,67,0.28); }
.ui .btnx.ghost { background: var(--card); color: var(--navy); border: 1px solid rgba(15,42,67,0.14); min-height: 50px; font-size: 0.95rem; }
.ui .btnx.off { background: #d9d3c5; color: var(--muted2); box-shadow: none; pointer-events: none; }
.ui .chips2 { display: flex; gap: 8px; overflow-x: auto; padding: 2px 0 4px; scrollbar-width: none; }
.ui .chips2::-webkit-scrollbar { display: none; }
.ui .chipbtn { flex: none; min-height: 40px; padding: 0 15px; border-radius: 100px; border: 1px solid rgba(15,42,67,0.16); background: var(--card); color: var(--navy); font: inherit; font-size: 0.88rem; font-weight: 600; cursor: pointer; }
.ui .chipbtn.on { background: var(--navy); color: var(--cream); border-color: var(--navy); font-weight: 700; }
.ui .stickycta { position: sticky; bottom: 76px; padding: 14px 0 6px; background: linear-gradient(rgba(247,244,238,0), var(--ground) 35%); z-index: 20; }
.ui .banner { border-radius: 14px; padding: 12px 16px; margin-top: 14px; font-size: 0.9rem; }
.ui .banner.free { background: var(--card); border: 1.5px solid var(--gold); color: var(--navy); }
.ui .banner.locked { background: var(--navy); color: var(--cream); }
.ui .banner a { color: var(--goldtext); font-weight: 700; }
.ui .banner.locked a { color: var(--gold-soft); }
.ui .empty2 { color: var(--muted2); font-size: 0.92rem; padding: 18px 16px; }
.ui .hidden { display: none !important; }

/* App navigation: bottom tab bar on phones, left sidebar on larger screens */
.appnav { position: fixed; left: 0; right: 0; bottom: 0; z-index: 60; background: #ffffff; box-shadow: 0 -6px 20px rgba(15,42,67,0.06); border-top: 1px solid rgba(15,42,67,0.1); display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); padding: 6px 6px calc(10px + env(safe-area-inset-bottom)); }
.appnav a { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; min-height: 50px; text-decoration: none; color: #5a6b7d; font-size: 0.7rem; font-weight: 600; position: relative; }
.appnav a.on { color: var(--navy); font-weight: 700; }
.appnav a .nb { position: absolute; top: 0; left: calc(50% + 6px); background: var(--bad); color: #fff; border-radius: 100px; font-size: 0.62rem; font-weight: 700; padding: 1px 6px; line-height: 1.4; }
.appnav .navbrand, .appnav .navacct { display: none; }
@media (min-width: 900px) {
  .ui { padding-bottom: 0; padding-left: 240px; }
  .appnav { top: 0; right: auto; width: 240px; background: var(--navy); border-top: 0; display: flex; flex-direction: column; gap: 4px; padding: 26px 16px; }
  .appnav .navbrand { display: block; font-family: "Fraunces", serif; font-weight: 600; font-size: 1.35rem; color: var(--cream); padding: 0 10px 22px; text-decoration: none; }
  .appnav .navbrand span { color: var(--gold); }
  .appnav a, .appnav a.navacct { flex-direction: row; justify-content: flex-start; gap: 12px; min-height: 46px; padding: 0 12px; border-radius: 12px; font-size: 0.95rem; color: #c8d2dc; display: flex; }
  .appnav a.navbrand { display: block; min-height: 0; color: var(--cream); font-size: 1.35rem; padding: 0 10px 22px; }
  .appnav a.on { background: rgba(201,162,75,0.16); color: var(--gold-soft); }
  .appnav a .nb { position: static; margin-left: auto; font-size: 0.72rem; padding: 2px 8px; }
  .ui .apptop .brand { visibility: hidden; }
  .ui .page { padding: 0 40px; }
  .ui .stickycta { bottom: 0; }
  .ui h1.title { font-size: 2.3rem; }
}

/* Sign-in and sign-up screens: navy header with a form card on phones, split screen on laptops */
.auth { min-height: 100vh; display: flex; flex-direction: column; background: var(--ground); }
.auth.ui { padding: 0; }
.authside { background: var(--navy); color: var(--cream); padding: 34px 24px 70px; border-radius: 0 0 32px 32px; }
.authbrand { font-family: "Fraunces", serif; font-weight: 600; font-size: 1.4rem; color: var(--cream); text-decoration: none; }
.authbrand span { color: var(--gold); }
.authside h1 { font-family: "Fraunces", serif; font-weight: 500; font-size: 2rem; line-height: 1.1; letter-spacing: -0.02em; color: var(--cream); margin: 30px 0 0; }
.authside .tag { margin: 10px 0 0; font-size: 0.95rem; line-height: 1.5; color: #c8d2dc; }
.authpoints { display: flex; flex-direction: column; gap: 8px; margin-top: 16px; font-size: 0.88rem; color: #c8d2dc; list-style: none; padding: 0; }
.authpoints li { display: flex; gap: 8px; align-items: center; }
.authpoints .wide { display: none; }
.authfine { display: none; }
.authmain { flex: 1; display: flex; flex-direction: column; }
.authcard { margin: -44px 16px 0; background: #fff; border-radius: 22px; padding: 22px 20px; box-shadow: 0 18px 40px rgba(15,42,67,0.14); display: flex; flex-direction: column; gap: 14px; }
.authcard h2 { display: none; }
.authcard .sub2 { display: none; }
.field { display: flex; flex-direction: column; gap: 6px; font-size: 0.82rem; font-weight: 700; color: var(--navy); margin: 0; }
.field input { min-height: 52px; box-sizing: border-box; border: 1.5px solid rgba(15,42,67,0.16); border-radius: 14px; padding: 0 14px; font: inherit; font-size: 16px; font-weight: 400; color: var(--ink); background: #fbfaf7; margin: 0; width: 100%; }
.field input:focus { border-color: var(--navy); outline: none; box-shadow: 0 0 0 3px rgba(201,162,75,0.35); }
.pwwrap { position: relative; display: block; }
.pwwrap input { padding-right: 76px; }
.pwtoggle { position: absolute; right: 6px; top: 6px; min-height: 40px; padding: 0 12px; border: 0; border-radius: 10px; background: var(--tint); color: var(--navy); font: inherit; font-size: 0.82rem; font-weight: 700; cursor: pointer; }
.authlink { align-self: flex-end; background: none; border: 0; padding: 4px 0; font: inherit; font-size: 0.88rem; font-weight: 600; color: var(--muted2); text-decoration: underline; cursor: pointer; }
.authcard .msg { margin: 0; font-size: 0.9rem; min-height: 0; }
.authcard .msg:empty { display: none; }
.authalt { text-align: center; font-size: 0.95rem; color: var(--muted2); margin: 22px 0 0; }
.authalt a { color: var(--navy); font-weight: 700; }
.authlegal { font-size: 0.8rem; line-height: 1.5; color: var(--muted2); text-align: center; margin: 0; }
.authlegal a { color: var(--navy); }
.authfoot { display: flex; justify-content: center; gap: 18px; padding: 24px 0 26px; font-size: 0.82rem; margin-top: auto; }
.authfoot a { color: var(--muted2); }
@media (min-width: 900px) {
  .auth { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .authside { border-radius: 0; padding: 56px 72px; display: flex; flex-direction: column; }
  .authside h1 { display: none; }
  .authside .tag { display: none; }
  .authside .bigtag { display: block !important; font-family: "Fraunces", serif; font-weight: 500; font-size: 2.9rem; line-height: 1.08; letter-spacing: -0.02em; margin: auto 0 0; max-width: 520px; color: var(--cream); }
  .authpoints { font-size: 1.05rem; gap: 14px; margin: 30px 0 auto; }
  .authpoints .wide { display: flex; }
  .authfine { display: block; font-size: 0.82rem; color: #8fa0b2; }
  .authmain { justify-content: center; align-items: center; padding: 40px; }
  .authcard { margin: 0; width: 100%; max-width: 420px; background: transparent; box-shadow: none; padding: 0; gap: 16px; }
  .authcard h2 { display: block; font-family: "Fraunces", serif; font-weight: 500; font-size: 2.2rem; letter-spacing: -0.02em; color: var(--navy); margin: 0; }
  .authcard .sub2 { display: block; margin: -8px 0 6px; color: var(--muted2); }
  .field input { background: #fff; }
  .authfoot { margin-top: 18px; padding-bottom: 0; }
}
