*{box-sizing:border-box}html{font-size:var(--app-font-base)}body{margin:0;background:var(--app-bg);color:var(--app-text);font-family:Arial,Helvetica,sans-serif;min-height:100vh}a{color:var(--app-primary);text-decoration:none}button,input,select,textarea{font:inherit}.app-shell{min-height:100vh;padding-bottom:88px}.topbar{position:sticky;top:0;z-index:20;display:flex;align-items:center;justify-content:space-between;gap:16px;padding:16px 20px;background:rgba(16,16,16,.94);border-bottom:1px solid var(--app-border);backdrop-filter:blur(12px)}.brand{display:flex;align-items:center;gap:12px;color:var(--app-text);font-weight:900;letter-spacing:.03em;text-transform:uppercase}.brand img{height:36px;max-width:170px;object-fit:contain}.user-pill{display:inline-flex;border:1px solid var(--app-border);border-radius:999px;padding:8px 12px;color:var(--app-muted);font-size:.85rem}.main-content{width:min(1080px,100%);margin:0 auto;padding:24px 18px 48px}.page-title{font-size:var(--app-font-heading);line-height:1;margin:0 0 8px;text-transform:uppercase;letter-spacing:.04em}.page-subtitle{margin:0 0 28px;color:var(--app-muted)}.card{background:var(--app-card);border:1px solid var(--app-border);border-radius:var(--app-radius);padding:20px;margin-bottom:18px}.card-title{font-weight:800;text-transform:uppercase;margin:0 0 12px;color:var(--app-primary);letter-spacing:.04em}.grid{display:grid;gap:16px}.grid-2{grid-template-columns:repeat(2,minmax(0,1fr))}.grid-3{grid-template-columns:repeat(3,minmax(0,1fr))}.grid-4{grid-template-columns:repeat(4,minmax(0,1fr))}.stack-card,.product-card{background:var(--app-surface);border:1px solid var(--app-border);border-radius:var(--app-radius);padding:16px}.muted{color:var(--app-muted)}.small{font-size:.85rem}.btn{display:inline-flex;align-items:center;justify-content:center;gap:8px;border:1px solid var(--app-primary);background:var(--app-primary);color:var(--app-primary-contrast);border-radius:10px;padding:12px 16px;min-height:44px;font-weight:800;text-transform:uppercase;letter-spacing:.05em;cursor:pointer}.btn:hover{filter:brightness(1.05)}.btn-secondary{background:transparent;color:var(--app-primary)}.btn-danger{border-color:var(--app-danger);background:var(--app-danger);color:#fff}.btn-block{width:100%}.form-row{display:grid;gap:8px;margin-bottom:16px}.form-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:16px}.form-row label{font-weight:700}.input,select,textarea{width:100%;background:#111;border:1px solid var(--app-border);color:var(--app-text);border-radius:10px;padding:12px 14px;outline:none}.input:focus,select:focus,textarea:focus{border-color:var(--app-primary)}textarea{min-height:120px;resize:vertical}.notice{width:min(1080px,calc(100% - 36px));margin:16px auto 0;border-radius:12px;padding:12px 16px;border:1px solid var(--app-border)}.notice-success{background:rgba(214,178,94,.12);border-color:var(--app-primary)}.notice-error{background:rgba(255,41,61,.12);border-color:var(--app-danger)}.bottom-nav{position:fixed;left:0;right:0;bottom:0;z-index:30;background:rgba(24,24,24,.97);border-top:1px solid var(--app-border);display:grid;grid-template-columns:repeat(4,1fr);padding:8px 6px env(safe-area-inset-bottom)}.bottom-nav a{display:flex;flex-direction:column;align-items:center;gap:4px;color:var(--app-muted);padding:6px;border-radius:12px;text-transform:uppercase}.bottom-nav a span{font-size:1.35rem;line-height:1}.bottom-nav a small{font-size:.7rem;letter-spacing:.05em}.bottom-nav a.is-active{color:var(--app-primary);background:rgba(214,178,94,.1)}.auth-wrap{min-height:100vh;display:grid;place-items:center;padding:22px}.auth-card{width:min(460px,100%);background:var(--app-card);border:1px solid var(--app-border);border-radius:18px;padding:28px}.calc-options{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px;margin:12px 0 22px}.option-button{position:relative;border:1px solid var(--app-border);background:var(--app-card);color:var(--app-text);border-radius:12px;min-height:78px;padding:14px;cursor:pointer;font-weight:800;text-align:center}.option-button.is-selected{border-color:var(--app-primary);color:var(--app-primary);box-shadow:0 0 0 1px var(--app-primary) inset;background:rgba(214,178,94,.08)}.result-panel{border:1px solid var(--app-primary);background:linear-gradient(180deg,rgba(214,178,94,.12),rgba(255,255,255,.02));border-radius:var(--app-radius);padding:20px;margin-top:24px}.result-main{font-size:1.8rem;font-weight:900;text-transform:uppercase}.result-main strong{color:var(--app-primary)}.syringe{position:relative;height:70px;border:1px solid var(--app-border);border-radius:999px;background:#292929;margin:24px 0 14px;overflow:hidden}.syringe-fill{height:100%;width:0;background:linear-gradient(90deg,rgba(214,178,94,.4),var(--app-primary));transition:width .2s}.syringe-marker{position:absolute;top:0;bottom:0;width:4px;background:var(--app-primary);left:0}.metric-list{display:grid;gap:8px;background:rgba(0,0,0,.18);border:1px solid var(--app-border);border-radius:12px;padding:14px}.metric{display:flex;justify-content:space-between;gap:12px}.history-table,.admin-table{width:100%;border-collapse:collapse;background:var(--app-card);border:1px solid var(--app-border);border-radius:12px;overflow:hidden}.history-table th,.history-table td,.admin-table th,.admin-table td{border-bottom:1px solid var(--app-border);padding:12px;text-align:left;vertical-align:top}.history-table th,.admin-table th{color:var(--app-primary);font-size:.84rem;text-transform:uppercase}.admin-body{padding:0}.admin-layout{display:grid;grid-template-columns:260px 1fr;min-height:100vh}.admin-sidebar{background:#0d0d0d;border-right:1px solid var(--app-border);padding:20px;position:sticky;top:0;height:100vh;overflow:auto}.admin-sidebar h2{margin:0 0 18px;color:var(--app-primary);text-transform:uppercase}.admin-sidebar a{display:block;color:var(--app-muted);padding:10px 12px;border-radius:10px;margin-bottom:4px}.admin-sidebar a:hover{background:var(--app-card);color:var(--app-primary)}.admin-main{padding:28px;max-width:1220px;width:100%}.admin-main h1{margin-top:0;text-transform:uppercase}.badge{display:inline-flex;align-items:center;border-radius:999px;border:1px solid var(--app-border);padding:4px 8px;font-size:.75rem;color:var(--app-muted)}.kbd{font-family:monospace;background:#111;border:1px solid var(--app-border);border-radius:6px;padding:2px 6px}.install-prompt{display:none}.install-prompt.is-visible{display:block}@media(max-width:800px){.grid-2,.grid-3,.form-grid,.calc-options{grid-template-columns:1fr}.admin-layout{grid-template-columns:1fr}.admin-sidebar{position:relative;height:auto}.main-content{padding:20px 14px 44px}.topbar{padding:14px}.page-title{font-size:2rem}.auth-wrap{align-items:start}.admin-main{padding:18px}.history-table,.admin-table{display:block;overflow-x:auto;white-space:nowrap}}

/* Calculator v0.2 */
.calc-shell{display:block}.calc-layout{display:grid;grid-template-columns:minmax(280px,.92fr) minmax(340px,1.08fr);gap:20px;align-items:start}.calc-card{position:relative;overflow:hidden}.calc-controls-card{display:grid;gap:18px}.calc-section{border-top:1px solid var(--app-border);padding-top:18px}.calc-section h3{margin:0 0 4px}.calc-product-summary{border:1px solid var(--app-border);border-radius:var(--app-radius);background:rgba(255,255,255,.025);padding:16px;display:grid;gap:14px}.calc-product-main{display:grid;grid-template-columns:auto 1fr;gap:14px;align-items:center}.product-avatar{width:54px;height:54px;border-radius:16px;background:linear-gradient(135deg,rgba(214,178,94,.95),rgba(214,178,94,.32));color:#111;display:grid;place-items:center;font-weight:900;letter-spacing:.04em}.calc-product-main h2{margin:0 0 4px;font-size:1.15rem}.calc-product-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}.calc-product-grid div{border:1px solid var(--app-border);border-radius:12px;padding:10px;background:rgba(0,0,0,.18);min-width:0}.calc-product-grid span,.breakdown-card span,.eyebrow{display:block;color:var(--app-muted);font-size:.72rem;text-transform:uppercase;letter-spacing:.06em;margin-bottom:4px}.calc-product-grid strong,.breakdown-card strong{font-size:.94rem;word-break:break-word}.calc-warning-text{border:1px solid rgba(214,178,94,.45);background:rgba(214,178,94,.08);border-radius:12px;padding:10px;margin:0;color:var(--app-text)}.calc-options-syringe{grid-template-columns:repeat(3,minmax(0,1fr))}.calc-options-dose{grid-template-columns:repeat(3,minmax(0,1fr))}.option-button small{display:block;color:var(--app-muted);font-weight:700;margin-top:5px}.option-button.is-selected small{color:var(--app-primary)}.result-panel-enhanced{margin:0 0 18px;display:flex;justify-content:space-between;gap:18px;align-items:center}.result-dose-pill{min-width:86px;height:86px;border-radius:24px;display:grid;place-items:center;background:var(--app-primary);color:var(--app-primary-contrast);font-weight:900;font-size:1.5rem;box-shadow:0 18px 36px rgba(0,0,0,.25)}.syringe-illustration{border:1px solid var(--app-border);background:linear-gradient(180deg,rgba(255,255,255,.035),rgba(0,0,0,.12));border-radius:18px;padding:18px;margin:18px 0 18px}.syringe-meta,.syringe-axis{display:flex;justify-content:space-between;gap:12px;align-items:center;color:var(--app-muted);font-size:.84rem}.syringe-meta strong{color:var(--app-text)}.syringe-callout,.syringe-meta span{color:var(--app-primary);font-weight:900}.syringe-drawing{display:grid;grid-template-columns:44px 1fr 54px;align-items:center;gap:0;margin:22px 0 30px}.syringe-plunger{height:44px;border:2px solid var(--app-border);border-right:0;border-radius:14px 0 0 14px;position:relative;background:#121212}.syringe-plunger span{position:absolute;left:8px;top:50%;width:28px;height:8px;transform:translateY(-50%);background:var(--app-border);border-radius:999px}.syringe-barrel{position:relative;height:76px;border:2px solid var(--app-border);border-radius:14px;background:linear-gradient(180deg,#f5f5f5,#cfcfcf);box-shadow:inset 0 1px 0 rgba(255,255,255,.45),inset 0 -10px 16px rgba(0,0,0,.15);overflow:visible}.syringe-liquid{position:absolute;left:0;top:0;bottom:0;width:0;background:linear-gradient(90deg,rgba(214,178,94,.25),rgba(214,178,94,.88));border-radius:10px 0 0 10px;transition:width .2s ease}.syringe-marker{position:absolute;top:-11px;bottom:-11px;width:3px;background:var(--app-primary);left:0;z-index:5;box-shadow:0 0 0 1px rgba(0,0,0,.25);transition:left .2s ease}.syringe-marker span{position:absolute;top:-28px;left:50%;transform:translateX(-50%);width:12px;height:12px;background:var(--app-primary);border-radius:999px}.syringe-ticks{position:absolute;left:0;right:0;top:0;bottom:0;z-index:4}.syringe-ticks .tick{position:absolute;bottom:0;width:1px;background:#111;opacity:.5;transform:translateX(-50%)}.syringe-ticks .tick-minor{height:22px}.syringe-ticks .tick-major{height:38px;width:2px;opacity:.78}.syringe-ticks .tick em{position:absolute;bottom:-25px;left:50%;transform:translateX(-50%);font-style:normal;font-size:.68rem;color:var(--app-muted);white-space:nowrap}.syringe-needle{height:22px;display:flex;align-items:center}.syringe-needle:before{content:"";display:block;width:22px;height:34px;border:2px solid var(--app-border);border-left:0;background:#171717;border-radius:0 10px 10px 0}.syringe-needle span{display:block;height:2px;flex:1;background:linear-gradient(90deg,var(--app-border),transparent);position:relative}.syringe-needle span:after{content:"";position:absolute;right:-1px;top:50%;transform:translateY(-50%);border-left:10px solid var(--app-border);border-top:4px solid transparent;border-bottom:4px solid transparent}.syringe-axis{margin-top:4px}.syringe-illustration.has-warning{border-color:var(--app-danger)}.syringe-illustration.has-warning .syringe-marker{background:var(--app-danger)}.calculator-breakdown{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}.breakdown-card{border:1px solid var(--app-border);border-radius:14px;background:rgba(0,0,0,.18);padding:14px;min-height:76px}.calc-formula{border:1px solid var(--app-border);border-radius:14px;padding:14px;margin:18px 0;background:rgba(0,0,0,.14)}.calc-formula h3{margin:0 0 10px}.calc-formula ol{margin:0;padding-left:20px;color:var(--app-muted)}.calc-formula li{margin:6px 0}.calc-formula [data-calc-warning]{color:var(--app-danger);font-weight:800;margin:12px 0 0}.small{font-size:.84rem}.form-row[style*="display: none"]{margin:0}@media(max-width:980px){.calc-layout{grid-template-columns:1fr}.calc-product-grid,.calculator-breakdown{grid-template-columns:1fr 1fr}}@media(max-width:640px){.calc-options-syringe,.calc-options-dose,.calc-product-grid,.calculator-breakdown{grid-template-columns:1fr}.result-panel-enhanced{display:grid}.result-dose-pill{width:82px;height:82px}.syringe-drawing{grid-template-columns:30px 1fr 34px}.syringe-barrel{height:66px}.syringe-ticks .tick em{font-size:.62rem}.syringe-plunger{height:38px}.syringe-illustration{padding:14px}.result-main{font-size:1.45rem}}

/* v0.3 calculator syringe icon refinements */
.syringe-option{display:flex;align-items:center;justify-content:flex-start;gap:12px;text-align:left;min-height:66px}
.syringe-option .fa-syringe{font-size:1.55rem;color:var(--app-primary);filter:drop-shadow(0 0 10px rgba(214,178,94,.18))}
.syringe-option span{display:flex;flex-direction:column;gap:2px}
.syringe-option strong{display:block}
.syringe-option small{display:block;color:var(--app-muted);font-weight:700}
.syringe-illustration:before{content:"\f48e";font-family:"Font Awesome 6 Free";font-weight:900;position:absolute;right:18px;top:16px;color:var(--app-primary);opacity:.18;font-size:2rem;pointer-events:none}
.syringe-illustration{position:relative}

/* v0.4 tracking, product directory, and calendar updates */
.today-actions{display:flex;gap:10px;flex-wrap:wrap;margin:0 0 18px}.today-list{display:grid;gap:14px}.intake-card{position:relative}.intake-card.is-overdue{border-color:rgba(255,107,107,.55);background:linear-gradient(180deg,rgba(255,107,107,.06),var(--app-card))}.intake-actions{display:flex;gap:10px;flex-wrap:wrap;align-items:center}.empty-state{text-align:left}.tracked-product-list,.product-directory,.calendar-list{display:grid;gap:12px}.tracked-product-row{display:flex;align-items:center;justify-content:space-between;gap:12px;border:1px solid var(--app-border);background:rgba(0,0,0,.16);border-radius:12px;padding:12px}.tracked-product-row span{display:block;margin-top:3px}.product-directory{grid-template-columns:repeat(2,minmax(0,1fr))}.product-directory-card{border:1px solid var(--app-border);border-radius:var(--app-radius);background:var(--app-surface);padding:16px;display:flex;flex-direction:column;justify-content:space-between;gap:14px;min-height:210px}.product-directory-head{display:flex;justify-content:space-between;gap:10px;align-items:flex-start}.product-directory-head h3{margin:0;line-height:1.2}.product-directory-actions{display:flex;gap:8px;flex-wrap:wrap;align-items:center}.product-directory-actions form{margin:0}.calendar-row{display:grid;grid-template-columns:150px 1fr auto;gap:14px;align-items:center;border:1px solid var(--app-border);border-radius:12px;background:rgba(0,0,0,.16);padding:12px}.calendar-row>div:first-child strong,.calendar-row>div:first-child span{display:block}.calendar-row>div:first-child span{color:var(--app-muted);font-size:.85rem;margin-top:3px}.calendar-date-heading{margin:18px 0 10px;color:var(--app-primary);text-transform:uppercase;letter-spacing:.04em;font-size:.96rem}.calendar-day-group{display:grid;gap:10px}.status-pending{border-color:rgba(214,178,94,.35)}.status-taken{border-color:rgba(72,211,138,.45)}.status-missed{border-color:rgba(255,107,107,.55)}.status-skipped{border-color:rgba(150,150,150,.45)}.status-taken .badge{color:#48d38a;border-color:rgba(72,211,138,.55)}.status-missed .badge{color:#ff6b6b;border-color:rgba(255,107,107,.6)}.status-skipped .badge{color:#b8b8b8}.calc-add-form{display:grid;gap:10px;margin-top:16px}@media(max-width:800px){.product-directory{grid-template-columns:1fr}.tracked-product-row,.calendar-row{grid-template-columns:1fr}.intake-actions .btn,.product-directory-actions .btn{width:100%}.product-directory-actions form{width:100%}.today-actions .btn{flex:1 1 180px}}

/* v0.5 stack metadata, templates, and product detail updates */
.section-head{display:flex;justify-content:space-between;align-items:flex-start;gap:16px;margin-bottom:14px}.section-head h2{margin:0 0 4px}.nested-card{background:rgba(0,0,0,.14);margin:18px 0;padding:16px}.nested-card h2{margin-top:0}.tracked-product-row-rich{align-items:flex-start}.tracked-product-row-rich>div:first-child{flex:1;min-width:0}.stack-actions{display:flex;gap:8px;flex-wrap:wrap;align-items:center;justify-content:flex-end}.stack-actions form,.detail-actions form{margin:0}.product-meta-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px;margin-top:12px}.product-meta-grid div{border:1px solid var(--app-border);border-radius:12px;padding:9px 10px;background:rgba(0,0,0,.18);min-width:0}.product-meta-grid span{display:block;color:var(--app-muted);font-size:.68rem;text-transform:uppercase;letter-spacing:.06em;margin-bottom:4px}.product-meta-grid strong{display:block;font-size:.86rem;line-height:1.25;word-break:break-word}.template-grid{align-items:start}.stack-template-card{display:grid;gap:12px}.stack-template-card h3{margin:0}.template-product-list{display:grid;gap:8px;margin:8px 0 10px}.template-product-item{border:1px solid var(--app-border);border-radius:12px;background:rgba(0,0,0,.18);padding:10px;display:grid;gap:5px}.template-product-item>div{display:flex;justify-content:space-between;gap:8px;align-items:flex-start}.template-product-item span,.template-product-item small{color:var(--app-muted);font-size:.8rem}.product-detail-hero{display:grid;grid-template-columns:220px 1fr;gap:22px;align-items:start}.product-detail-image{width:100%;max-height:220px;object-fit:contain;border:1px solid var(--app-border);border-radius:var(--app-radius);background:rgba(0,0,0,.2);padding:10px}.detail-actions{margin-top:16px}.taxonomy-chip-list{display:flex;flex-wrap:wrap;gap:10px}.taxonomy-chip{display:inline-flex;flex-direction:column;gap:3px;border:1px solid var(--app-border);border-radius:999px;padding:7px 12px;background:rgba(0,0,0,.18);font-weight:800}.taxonomy-chip small{font-size:.66rem;text-transform:uppercase;letter-spacing:.06em;color:var(--app-muted);font-weight:700}.safety-card{border-color:rgba(255,107,107,.35);background:linear-gradient(180deg,rgba(255,107,107,.06),var(--app-card))}@media(max-width:800px){.product-meta-grid{grid-template-columns:1fr}.product-detail-hero{grid-template-columns:1fr}.product-detail-image{max-height:180px}.stack-actions,.detail-actions{justify-content:flex-start}.stack-actions .btn,.stack-actions form,.detail-actions .btn,.detail-actions form{width:100%}.template-product-item>div{display:grid}}

/* v0.6 display cleanup, product media library, and responsive product cards */
.product-directory{grid-template-columns:repeat(auto-fit,minmax(300px,1fr));gap:18px;align-items:stretch}
.product-directory-card{display:grid;grid-template-rows:auto 1fr auto;gap:14px;padding:0;overflow:hidden;background:linear-gradient(180deg,rgba(255,255,255,.035),var(--app-surface));border:1px solid var(--app-border);box-shadow:0 12px 26px rgba(0,0,0,.16)}
.product-card-media{background:rgba(0,0,0,.22);border-bottom:1px solid var(--app-border);min-height:150px;display:grid;place-items:center;padding:14px}
.product-card-image{width:100%;height:150px;object-fit:contain;border-radius:12px}
.product-card-body{padding:16px 16px 0;min-width:0}
.product-directory-actions{padding:0 16px 16px;gap:10px;align-items:stretch}
.product-directory-actions .btn,.stack-actions .btn,.detail-actions .btn{white-space:normal;text-align:center;line-height:1.2}
.product-directory-actions form,.stack-actions form,.detail-actions form{display:inline-flex;margin:0}.product-directory-actions form .btn,.stack-actions form .btn,.detail-actions form .btn{width:100%}
.product-thumb-placeholder{display:grid;place-items:center;border:1px dashed var(--app-border);background:rgba(0,0,0,.2);color:var(--app-primary)}
.product-thumb-placeholder i{font-size:2rem;opacity:.82}.product-card-image.product-thumb-placeholder{height:150px;width:100%}
.tracked-product-row-rich{display:grid;grid-template-columns:84px 1fr auto;align-items:start;gap:14px;padding:14px;border-radius:16px;background:linear-gradient(180deg,rgba(255,255,255,.03),rgba(0,0,0,.14))}
.tracked-product-image{width:84px;height:84px;object-fit:contain;border-radius:14px;border:1px solid var(--app-border);background:rgba(0,0,0,.25);padding:6px}.tracked-product-image.product-thumb-placeholder{width:84px;height:84px}.tracked-product-content{min-width:0}.tracked-product-content>a,.tracked-product-content strong{display:block;margin-bottom:8px}
.product-meta-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px;margin:12px 0 0;padding:0}
.product-meta-item{border:1px solid var(--app-border);border-radius:12px;background:rgba(0,0,0,.22);padding:10px 11px;min-width:0}
.product-meta-item dt{margin:0 0 4px;color:var(--app-muted);font-size:.68rem;text-transform:uppercase;letter-spacing:.07em;line-height:1.1}.product-meta-item dt:after{content:':'}.product-meta-item dd{margin:0;color:var(--app-text);font-weight:800;font-size:.88rem;line-height:1.28;word-break:break-word}
.template-product-item{display:grid;grid-template-columns:52px 1fr;align-items:center;gap:10px}.template-product-image{width:52px;height:52px;object-fit:contain;border-radius:10px;border:1px solid var(--app-border);background:rgba(0,0,0,.25);padding:4px}.template-product-image.product-thumb-placeholder{width:52px;height:52px}.template-product-copy>div{display:flex;justify-content:space-between;gap:10px;align-items:flex-start}.template-product-copy span{white-space:nowrap}
.product-detail-hero{grid-template-columns:minmax(190px,260px) 1fr}.product-detail-media{display:grid;place-items:center}.product-detail-image{width:100%;height:240px;max-height:none;object-fit:contain;border:1px solid var(--app-border);border-radius:var(--app-radius);background:rgba(0,0,0,.22);padding:12px}.product-detail-image.product-thumb-placeholder{height:240px}.admin-product-preview{width:160px;height:160px;object-fit:contain;border:1px solid var(--app-border);border-radius:12px;background:rgba(0,0,0,.22);padding:8px}.admin-product-preview.product-thumb-placeholder{display:grid;place-items:center}
.product-description{line-height:1.62}.product-description h2,.product-description h3,.product-description h4{margin:18px 0 8px;color:var(--app-primary);letter-spacing:.02em}.product-description h2:first-child,.product-description h3:first-child{margin-top:0}.product-description p{margin:0 0 12px}.product-description ul,.product-description ol{margin:8px 0 14px 1.2rem;padding:0}.product-description li{margin:5px 0}.product-description strong{font-weight:900}.product-description a{color:var(--app-primary);text-decoration:underline;text-underline-offset:3px}
.taxonomy-chip-list{display:grid;grid-template-columns:repeat(auto-fit,minmax(170px,1fr));gap:10px}.taxonomy-chip{display:grid;gap:4px;border:1px solid var(--app-border);border-radius:14px;padding:10px 12px;background:rgba(0,0,0,.2);font-weight:800;min-width:0}.taxonomy-chip-label{font-size:.68rem;text-transform:uppercase;letter-spacing:.07em;color:var(--app-muted);font-weight:700}.taxonomy-chip-label:after{content:':'}.taxonomy-chip strong{font-size:.9rem;line-height:1.25;word-break:break-word}
.media-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(250px,1fr));gap:16px}.media-card{border:1px solid var(--app-border);border-radius:14px;background:rgba(0,0,0,.18);padding:12px;display:grid;gap:10px}.media-card img{width:100%;height:150px;object-fit:contain;background:rgba(0,0,0,.24);border-radius:10px;border:1px solid var(--app-border);padding:8px}.media-path-input{font-size:.82rem;margin:8px 0 4px;font-family:monospace}.btn-small{min-height:38px;padding:9px 12px;font-size:.78rem}
@media(max-width:900px){.tracked-product-row-rich{grid-template-columns:72px 1fr}.tracked-product-row-rich .stack-actions{grid-column:1/-1;justify-content:flex-start}.tracked-product-image,.tracked-product-image.product-thumb-placeholder{width:72px;height:72px}.product-detail-hero{grid-template-columns:1fr}.product-detail-image,.product-detail-image.product-thumb-placeholder{height:210px}.product-directory-actions form,.product-directory-actions .btn{flex:1 1 150px}.template-product-copy>div{display:grid;gap:4px}.template-product-copy span{white-space:normal}}
@media(max-width:640px){.product-directory{grid-template-columns:1fr}.product-meta-grid{grid-template-columns:1fr}.product-card-media{min-height:130px}.product-card-image{height:130px}.tracked-product-row-rich{grid-template-columns:1fr}.tracked-product-media{display:none}.stack-actions,.detail-actions,.product-directory-actions{display:grid;grid-template-columns:1fr}.stack-actions form,.detail-actions form,.product-directory-actions form{width:100%}.taxonomy-chip-list,.media-grid{grid-template-columns:1fr}.section-head{display:grid}.template-product-item{grid-template-columns:46px 1fr}.template-product-image,.template-product-image.product-thumb-placeholder{width:46px;height:46px}}

/* v0.7 archive layout, cleaner metadata, and template subpage refinements */
.product-directory{
  display:grid;
  grid-template-columns:repeat(var(--archive-columns,3), minmax(0,1fr));
  gap:18px;
  align-items:stretch;
}
.product-directory-card{
  min-width:0;
  height:100%;
  border-radius:18px;
}
.product-directory-head{
  display:flex;
  justify-content:space-between;
  align-items:flex-start;
  gap:10px;
  margin-bottom:8px;
}
.product-directory-head h3{
  margin:0;
  line-height:1.22;
  font-size:1rem;
}
.product-directory-head h3 a{
  color:var(--app-primary);
  text-decoration:none;
}
.product-meta-grid,
.product-meta-grid.product-meta-grid--archive,
.product-meta-grid.product-meta-grid--full{
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:10px;
  margin:14px 0 0;
  padding:0;
}
.product-directory-card .product-meta-grid,
.tracked-product-row-rich .product-meta-grid{
  grid-template-columns:1fr;
}
.product-meta-grid .product-meta-item{
  display:grid;
  grid-template-columns:minmax(84px,.42fr) minmax(0,1fr);
  align-items:start;
  gap:8px;
  border:1px solid var(--app-border);
  border-radius:12px;
  background:rgba(0,0,0,.2);
  padding:10px 11px;
  min-width:0;
}
.product-meta-grid .product-meta-item dt,
.product-meta-grid .product-meta-item dd{
  display:block;
  margin:0;
  padding:0;
  line-height:1.28;
}
.product-meta-grid .product-meta-item dt{
  color:var(--app-muted);
  font-size:.68rem;
  text-transform:uppercase;
  letter-spacing:.07em;
  font-weight:800;
}
.product-meta-grid .product-meta-item dt:after{content:':'}.product-meta-grid .product-meta-item dd{
  color:var(--app-text);
  font-weight:850;
  font-size:.88rem;
  word-break:normal;
  overflow-wrap:anywhere;
}
.product-detail-hero .product-meta-grid{
  grid-template-columns:repeat(2,minmax(0,1fr));
  max-width:780px;
}
.product-directory-actions,
.detail-actions,
.stack-actions{
  display:flex;
  flex-wrap:wrap;
  gap:10px;
  align-items:stretch;
}
.product-directory-actions .btn,
.detail-actions .btn,
.stack-actions .btn{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  gap:8px;
  min-width:0;
}
.stack-template-teaser .section-head{margin-bottom:0}.goal-template-section{display:grid;gap:14px}.goal-template-section .template-grid{margin-top:4px}.template-product-list{max-height:none}.template-product-item{border-radius:14px}.template-product-copy a{color:var(--app-text);text-decoration:none}.template-product-copy a:hover{color:var(--app-primary)}
.check-line{display:flex;align-items:center;gap:9px;border:1px solid var(--app-border);background:rgba(0,0,0,.16);border-radius:12px;padding:10px 12px}.checkbox-grid{align-items:stretch}.nested-card{border:1px solid var(--app-border)}
.product-description :is(h2,h3,h4,strong){letter-spacing:normal}.product-description h3 strong{color:inherit}.taxonomy-chip-list{display:grid;grid-template-columns:repeat(auto-fit,minmax(190px,1fr));gap:10px}.taxonomy-chip{white-space:normal}.taxonomy-chip strong{overflow-wrap:anywhere}
@media(max-width:1250px){.product-directory{grid-template-columns:repeat(min(var(--archive-columns,3),3),minmax(0,1fr))}}
@media(max-width:980px){.product-directory{grid-template-columns:repeat(2,minmax(0,1fr))}.product-detail-hero .product-meta-grid{grid-template-columns:1fr}}
@media(max-width:640px){.product-directory{grid-template-columns:1fr}.product-meta-grid,.product-meta-grid.product-meta-grid--archive,.product-meta-grid.product-meta-grid--full{grid-template-columns:1fr}.product-meta-grid .product-meta-item{grid-template-columns:1fr;gap:3px}.product-directory-head{display:grid}.product-directory-actions,.detail-actions,.stack-actions{display:grid;grid-template-columns:1fr}.product-directory-actions form,.detail-actions form,.stack-actions form{width:100%}}
.product-directory.product-directory-cols-2{grid-template-columns:repeat(2,minmax(0,1fr))}
.product-directory.product-directory-cols-3{grid-template-columns:repeat(3,minmax(0,1fr))}
.product-directory.product-directory-cols-4{grid-template-columns:repeat(4,minmax(0,1fr))}
@media(max-width:1250px){.product-directory.product-directory-cols-4{grid-template-columns:repeat(3,minmax(0,1fr))}}
@media(max-width:980px){.product-directory.product-directory-cols-2,.product-directory.product-directory-cols-3,.product-directory.product-directory-cols-4{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:640px){.product-directory.product-directory-cols-2,.product-directory.product-directory-cols-3,.product-directory.product-directory-cols-4{grid-template-columns:1fr}}

/* v0.8 Media Library update */
.media-toolbar{display:flex;align-items:center;justify-content:space-between;gap:16px}
.media-toolbar h2,.media-upload-card h2{margin-top:0}
.media-upload-form{display:grid;gap:12px}
.media-library-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(280px,1fr));gap:18px;align-items:stretch}
.media-library-card{border:1px solid var(--app-border);border-radius:var(--app-radius);background:linear-gradient(180deg,rgba(255,255,255,.035),var(--app-surface));overflow:hidden;display:grid;grid-template-rows:auto 1fr;min-width:0}
.media-preview-wrap{background:rgba(0,0,0,.25);border-bottom:1px solid var(--app-border);display:grid;place-items:center;height:190px;padding:12px}
.media-preview-wrap img{width:100%;height:100%;object-fit:contain;border-radius:10px}
.media-library-copy{padding:14px;display:grid;gap:10px;min-width:0}
.media-library-copy h3{font-size:1rem;line-height:1.25;margin:0;word-break:break-word}
.media-meta-line{display:flex;gap:8px;flex-wrap:wrap;color:var(--app-muted);font-size:.78rem}
.media-meta-line span{border:1px solid var(--app-border);border-radius:999px;padding:3px 8px}
.media-usage{display:grid;gap:8px;border-top:1px solid var(--app-border);padding-top:10px}
.media-usage strong{font-size:.78rem;text-transform:uppercase;letter-spacing:.06em;color:var(--app-primary)}
.media-attached-list{display:grid;gap:6px}
.media-attached-row{display:flex;align-items:center;justify-content:space-between;gap:8px;border:1px solid var(--app-border);border-radius:10px;padding:8px;background:rgba(0,0,0,.18)}
.media-attached-row span{min-width:0;word-break:break-word}
.media-attached-row form{margin:0;flex:0 0 auto}
.media-unattached{margin:0;display:flex;align-items:center;gap:6px}
.media-attach-form{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:8px;align-items:center}
.media-card-actions{display:flex;gap:8px;flex-wrap:wrap;align-items:center}
.media-card-actions form{margin:0}.btn-mini{min-height:32px;padding:6px 10px;font-size:.7rem;border-radius:8px}.media-path-input{font-family:monospace;font-size:.78rem}
@media(max-width:760px){.media-toolbar{display:grid}.media-library-grid{grid-template-columns:1fr}.media-attach-form{grid-template-columns:1fr}.media-attach-form .btn,.media-card-actions .btn,.media-card-actions form{width:100%}.media-attached-row{display:grid}.media-attached-row form{width:100%}.media-attached-row .btn{width:100%}}

/* v0.9 media bulk attachment update */
.media-toolbar-sticky{
  position:sticky;
  top:12px;
  z-index:20;
  backdrop-filter:blur(12px);
  background:linear-gradient(180deg,rgba(31,31,31,.96),rgba(24,24,24,.94));
}
.media-bulk-update-form{margin:0;display:flex;align-items:center;gap:10px;flex:0 0 auto}
.media-attach-bulk-row{grid-template-columns:1fr;border-top:1px solid var(--app-border);padding-top:10px}
.media-attach-select-wrap{display:grid;gap:6px;width:100%}
.media-attach-select-wrap select{width:100%}
.media-bulk-footer{margin-top:18px;padding-top:16px;border-top:1px solid var(--app-border);display:flex;align-items:center;gap:12px;flex-wrap:wrap}
@media(max-width:760px){
  .media-toolbar-sticky{position:static}
  .media-bulk-update-form,.media-bulk-update-form .btn,.media-bulk-footer .btn{width:100%}
  .media-bulk-footer{display:grid}
}

/* v1.0 backend ordering and goal-based stack management */
.admin-toolbar{
  display:flex;
  flex-wrap:wrap;
  gap:10px;
  align-items:center;
  margin:0 0 18px;
}
.table-responsive{
  width:100%;
  overflow-x:auto;
  -webkit-overflow-scrolling:touch;
}
.admin-order-card .section-head,
.admin-order-footer{
  display:flex;
  justify-content:space-between;
  align-items:center;
  gap:14px;
  flex-wrap:wrap;
}
.admin-order-footer{
  padding-top:14px;
  border-top:1px solid var(--app-border);
  margin-top:14px;
}
.sort-order-input{
  width:92px;
  max-width:100%;
  text-align:center;
  font-weight:800;
}
.admin-order-table th,
.admin-order-table td,
.admin-stack-product-table th,
.admin-stack-product-table td{
  vertical-align:top;
}
.admin-actions{
  display:flex;
  flex-wrap:wrap;
  gap:8px;
  align-items:center;
}
.admin-actions form{
  margin:0;
}
.media-sort-card{
  margin-top:14px;
}
.media-sort-form{
  display:flex;
  align-items:end;
  gap:12px;
  flex-wrap:wrap;
}
.media-sort-form .form-row{
  margin:0;
  min-width:240px;
}
@media(max-width:760px){
  .admin-order-card .section-head,
  .admin-order-footer,
  .media-sort-form{
    display:grid;
  }
  .admin-order-card .btn,
  .admin-order-footer .btn,
  .media-sort-form .btn{
    width:100%;
  }
  .sort-order-input{
    width:76px;
  }
}

/* v1.1 login styling and real tracking calendar */
body.auth-page{
  background:radial-gradient(circle at 18% 10%,rgba(214,178,94,.16),transparent 32%),linear-gradient(180deg,#111,#070707);
}
.auth-wrap{
  min-height:calc(100vh - 110px);
  display:grid;
  place-items:center;
  padding:30px 0;
}
.auth-card{
  width:min(470px,100%);
  position:relative;
  overflow:hidden;
  background:linear-gradient(180deg,rgba(255,255,255,.05),rgba(32,32,32,.96));
  border:1px solid rgba(214,178,94,.42);
  border-radius:24px;
  padding:30px;
  box-shadow:0 24px 80px rgba(0,0,0,.48);
}
.auth-card:before{
  content:"";
  position:absolute;
  inset:-1px;
  pointer-events:none;
  background:radial-gradient(circle at top right,rgba(214,178,94,.14),transparent 35%);
}
.auth-card > *{position:relative;z-index:1}.auth-card .page-title{font-size:clamp(2.1rem,8vw,3.35rem);letter-spacing:.08em;margin-bottom:24px;color:var(--app-text)}.auth-card .form-row label{font-size:.76rem;text-transform:uppercase;letter-spacing:.08em;color:var(--app-primary)}.auth-card .input{min-height:48px}.auth-card .btn{min-height:48px}.auth-card p.small{margin:18px 0 0;text-align:center}.auth-card p.small a{display:inline-block;padding:5px 4px}.settings-cards{margin-bottom:18px}.button-row{display:flex;flex-wrap:wrap;gap:10px}.calendar-card{overflow:hidden}.tracking-calendar{margin-top:18px;border:1px solid var(--app-border);border-radius:18px;overflow:hidden;background:rgba(0,0,0,.18)}.tracking-calendar-head{display:grid;grid-template-columns:auto minmax(0,1fr) auto;align-items:center;gap:14px;padding:16px;border-bottom:1px solid var(--app-border);background:linear-gradient(180deg,rgba(255,255,255,.035),rgba(0,0,0,.12))}.tracking-calendar-head h2{margin:0;text-align:center;text-transform:uppercase;letter-spacing:.06em}.tracking-calendar-head p{text-align:center;margin:4px 0 0}.calendar-status-legend{display:flex;flex-wrap:wrap;gap:8px;padding:12px 16px;border-bottom:1px solid var(--app-border)}.legend-dot{display:inline-flex;align-items:center;gap:7px;border:1px solid var(--app-border);border-radius:999px;padding:6px 10px;font-size:.75rem;text-transform:uppercase;letter-spacing:.05em;color:var(--app-muted)}.legend-dot:before{content:"";width:8px;height:8px;border-radius:999px;background:var(--app-muted)}.legend-dot.status-pending:before{background:var(--app-primary)}.legend-dot.status-taken:before{background:#34d399}.legend-dot.status-missed:before{background:var(--app-danger)}.legend-dot.status-skipped:before{background:#93a4b8}.calendar-grid{display:grid;grid-template-columns:repeat(7,minmax(0,1fr))}.calendar-weekdays{border-bottom:1px solid var(--app-border);background:rgba(255,255,255,.035)}.calendar-weekdays div{padding:10px;text-align:center;color:var(--app-muted);font-size:.74rem;font-weight:900;text-transform:uppercase;letter-spacing:.08em}.calendar-month-grid{background:var(--app-border);gap:1px}.calendar-day{min-height:128px;background:var(--app-card);padding:10px;display:flex;flex-direction:column;gap:7px;min-width:0}.calendar-day.is-outside{background:rgba(255,255,255,.025);color:var(--app-muted)}.calendar-day.is-today{outline:2px solid rgba(214,178,94,.65);outline-offset:-2px}.calendar-day.has-items{background:linear-gradient(180deg,rgba(214,178,94,.055),var(--app-card))}.calendar-day-number{display:flex;justify-content:space-between;align-items:center}.calendar-day-number span{display:inline-grid;place-items:center;min-width:28px;height:28px;border-radius:999px;font-weight:900}.is-today .calendar-day-number span{background:var(--app-primary);color:var(--app-primary-contrast)}.calendar-event{display:grid;grid-template-columns:auto minmax(0,1fr);gap:7px;align-items:center;border:1px solid var(--app-border);border-left-width:4px;border-radius:10px;padding:7px;background:rgba(0,0,0,.18);font-size:.78rem;line-height:1.2}.calendar-event strong{color:var(--app-text)}.calendar-event span{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;color:var(--app-muted)}.calendar-event.status-pending{border-left-color:var(--app-primary)}.calendar-event.status-taken{border-left-color:#34d399}.calendar-event.status-missed{border-left-color:var(--app-danger)}.calendar-event.status-skipped{border-left-color:#93a4b8}.calendar-more{font-size:.75rem;color:var(--app-primary);font-weight:900;text-transform:uppercase;letter-spacing:.05em}.calendar-empty-note{margin:14px 0 0}.calendar-details-list{margin-top:16px;border-top:1px solid var(--app-border);padding-top:14px}.calendar-details-list summary{cursor:pointer;color:var(--app-primary);font-weight:900;text-transform:uppercase;letter-spacing:.05em}.calendar-details-list .calendar-list{margin-top:14px}
@media(max-width:900px){.tracking-calendar-head{grid-template-columns:1fr}.tracking-calendar-head .btn{width:100%}.calendar-day{min-height:110px;padding:8px}.calendar-event{grid-template-columns:1fr;gap:3px}.calendar-event span{white-space:normal;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical}.calendar-weekdays div{font-size:.65rem;padding:8px 2px}}
@media(max-width:640px){.auth-card{padding:24px 18px;border-radius:20px}.settings-cards{grid-template-columns:1fr}.button-row{display:grid}.calendar-grid{grid-template-columns:repeat(7,minmax(36px,1fr))}.calendar-day{min-height:92px;padding:6px;gap:5px}.calendar-day-number span{min-width:24px;height:24px;font-size:.78rem}.calendar-event{border-left-width:3px;padding:5px;font-size:.68rem}.calendar-event strong{font-size:.65rem}.calendar-status-legend{display:grid;grid-template-columns:repeat(2,minmax(0,1fr))}.tracking-calendar{margin-left:-10px;margin-right:-10px;border-radius:14px}.calendar-weekdays div{font-size:.58rem}}

/* v1.2 goal-based stack product picker */
.stack-template-editor-form{
  display:grid;
  gap:18px;
}
.stack-products-heading{
  align-items:center;
  margin-top:10px;
}
.admin-product-picker-grid{
  display:grid;
  grid-template-columns:repeat(auto-fit,minmax(260px,1fr));
  gap:12px;
  margin-top:8px;
}
.admin-product-picker-card{
  border:1px solid var(--app-border);
  border-radius:16px;
  background:rgba(0,0,0,.16);
  padding:12px;
  display:grid;
  gap:12px;
  min-width:0;
  transition:border-color .18s ease, background .18s ease, transform .18s ease;
}
.admin-product-picker-card.is-selected,
.admin-product-picker-card:has(input[type="checkbox"][name="template_products[]"]:checked){
  border-color:var(--app-primary);
  background:rgba(218,184,82,.08);
}
.admin-product-picker-main{
  display:grid;
  grid-template-columns:auto 1fr;
  align-items:flex-start;
  gap:10px;
  cursor:pointer;
}
.admin-product-picker-main input{
  margin-top:4px;
}
.admin-product-picker-main strong,
.admin-product-picker-main small{
  display:block;
  min-width:0;
}
.admin-product-picker-main small{
  color:var(--app-muted);
  margin-top:4px;
  font-size:.78rem;
  line-height:1.35;
}
.admin-product-picker-controls{
  display:grid;
  grid-template-columns:1fr auto 86px;
  gap:8px;
  align-items:end;
}
.admin-product-picker-controls label{
  display:grid;
  gap:4px;
  font-size:.72rem;
  color:var(--app-muted);
  text-transform:uppercase;
  letter-spacing:.06em;
}
.admin-product-picker-controls select,
.admin-product-picker-controls input[type="number"]{
  min-height:38px;
}
.admin-product-check{
  align-self:center;
  display:flex!important;
  grid-template-columns:none!important;
  flex-direction:row!important;
  gap:6px!important;
  align-items:center!important;
  color:var(--app-text)!important;
  text-transform:none!important;
  letter-spacing:0!important;
  font-size:.82rem!important;
  white-space:nowrap;
}
.template-product-list{
  display:grid;
  gap:10px;
}
.stack-template-card .template-product-item{
  border:1px solid var(--app-border);
  background:rgba(0,0,0,.18);
  border-radius:14px;
  padding:10px;
}
.stack-template-card .template-product-copy a{
  color:var(--app-text);
  text-decoration:none;
}
.stack-template-card .template-product-copy a:hover{
  color:var(--app-primary);
}
@media(max-width:760px){
  .admin-product-picker-grid{
    grid-template-columns:1fr;
  }
  .admin-product-picker-controls{
    grid-template-columns:1fr;
  }
  .admin-product-check{
    justify-content:flex-start;
  }
}

/* v1.3 tracking schedule controls */
.tracking-progress{
  display:flex;
  flex-wrap:wrap;
  gap:8px;
  margin-top:12px;
}
.tracking-progress span{
  display:inline-grid;
  place-items:center;
  gap:2px;
  min-width:74px;
  min-height:50px;
  padding:8px 10px;
  border:1px solid rgba(224,192,105,.28);
  border-radius:18px;
  background:rgba(224,192,105,.08);
  text-align:center;
  line-height:1.1;
  font-size:.74rem;
  color:var(--muted,#c8c8c8);
}
.tracking-progress strong{
  display:block;
  color:var(--gold,#e0c069);
  font-size:1rem;
  line-height:1;
}
.tracking-progress em{
  display:block;
  font-style:normal;
  text-transform:none;
}
.tracked-product-more{
  margin-top:4px;
}
.tracked-product-more summary{
  display:inline-flex;
  align-items:center;
  gap:8px;
  width:max-content;
  max-width:100%;
  border:1px solid rgba(224,192,105,.35);
  border-radius:999px;
  padding:8px 11px;
  color:var(--gold,#e0c069);
  background:rgba(224,192,105,.06);
  cursor:pointer;
  font-size:.78rem;
  font-weight:900;
  text-transform:uppercase;
  letter-spacing:.05em;
}
.tracked-product-more summary::marker{content:""}
.tracked-product-more summary::-webkit-details-marker{display:none}
.tracked-product-more summary:before{
  content:"+";
  font-weight:900;
  font-size:1rem;
  line-height:1;
}
.tracked-product-more[open] summary:before{
  content:"-";
}
.tracked-product-more[open] summary{
  margin-bottom:10px;
}
.product-card-more{
  margin-top:10px;
}
.product-card-more .product-meta-grid{
  margin-top:0;
}
.missed-reschedule-row{
  display:grid;
  grid-template-columns:1fr 160px;
  gap:12px;
  margin:12px 0;
  padding:12px;
  border:1px dashed rgba(224,192,105,.3);
  border-radius:14px;
  background:rgba(255,255,255,.025);
}
.missed-reschedule-row label,
.manual-dose-row label{display:block;font-size:.75rem;text-transform:uppercase;letter-spacing:.08em;color:var(--muted,#bdbdbd);margin-bottom:5px}
.manual-dose-table{display:grid;gap:10px;margin:16px 0}
.manual-dose-row{
  display:grid;
  grid-template-columns:minmax(145px,1fr) minmax(110px,.75fr) minmax(120px,.75fr) minmax(95px,.65fr) auto;
  gap:10px;
  align-items:end;
  padding:12px;
  border:1px solid rgba(255,255,255,.1);
  border-radius:16px;
  background:rgba(0,0,0,.18);
}
.checkbox-row{
  display:flex;
  align-items:center;
  gap:8px;
  margin:14px 0;
  color:var(--muted,#c8c8c8);
}
.delete-dose{margin:0 0 8px 0;white-space:nowrap}
.tracked-product-row-rich .tracked-product-content{display:grid;gap:10px}
@media (max-width: 760px){
  .missed-reschedule-row{grid-template-columns:1fr}
  .manual-dose-row{grid-template-columns:1fr 1fr}
  .manual-dose-row .delete-dose{grid-column:1 / -1}
}

/* v1.7 Today welcome introduction */
.today-welcome{
  display:grid;
  grid-template-columns:minmax(0,1fr) 280px;
  gap:22px;
  align-items:stretch;
  border-color:rgba(214,178,94,.38);
  background:
    radial-gradient(circle at 100% 0, rgba(214,178,94,.16), transparent 34%),
    linear-gradient(180deg, rgba(255,255,255,.035), var(--app-card));
  overflow:hidden;
  position:relative;
}
.today-welcome:before{
  content:"";
  position:absolute;
  inset:0;
  pointer-events:none;
  background:linear-gradient(90deg, rgba(214,178,94,.08), transparent 42%);
}
.today-welcome-copy,
.today-welcome-panel{position:relative;z-index:1}
.today-welcome h1{
  margin:0 0 12px;
  font-size:clamp(2rem,4.5vw,4rem);
  line-height:.96;
  text-transform:uppercase;
  letter-spacing:.08em;
}
.today-welcome p{margin:0 0 12px;color:var(--app-muted);max-width:760px;line-height:1.6}
.today-welcome .today-welcome-lead{color:var(--app-text);font-size:1.08rem}
.today-welcome-panel{
  border:1px solid rgba(214,178,94,.4);
  border-radius:18px;
  padding:18px;
  display:flex;
  flex-direction:column;
  justify-content:center;
  gap:12px;
  background:rgba(0,0,0,.22);
  min-height:200px;
}
.today-welcome-panel span{
  width:58px;
  height:58px;
  border-radius:18px;
  display:grid;
  place-items:center;
  background:var(--app-primary);
  color:var(--app-primary-contrast);
  font-size:1.35rem;
}
.today-welcome-panel strong{
  display:block;
  font-size:1.25rem;
  line-height:1.2;
  text-transform:uppercase;
  letter-spacing:.05em;
}
.today-welcome-panel small{color:var(--app-muted);line-height:1.5}
@media(max-width:760px){
  .today-welcome{grid-template-columns:1fr;padding:18px}
  .today-welcome-panel{min-height:auto}
  .today-welcome h1{font-size:2.2rem}
}

/* v1.8 Today goal-based stack browser, remove confirm, and stock warnings */
.today-template-browser{
  display:grid;
  gap:18px;
  border-color:rgba(214,178,94,.28);
}
.today-template-browser .section-head{
  align-items:flex-start;
}
.today-template-grid{
  display:grid;
  grid-template-columns:repeat(3,minmax(0,1fr));
  gap:14px;
}
.today-template-card{
  display:flex;
  flex-direction:column;
  gap:14px;
  min-width:0;
  border:1px solid var(--app-border);
  border-radius:var(--app-radius);
  padding:16px;
  background:linear-gradient(180deg,rgba(255,255,255,.035),rgba(0,0,0,.12));
}
.template-card-top{
  display:flex;
  justify-content:space-between;
  gap:12px;
  align-items:flex-start;
}
.template-card-top h3{
  margin:0 0 6px;
  color:var(--app-primary);
  text-transform:uppercase;
  letter-spacing:.05em;
  line-height:1.25;
}
.today-template-products{
  display:flex;
  flex-wrap:wrap;
  gap:7px;
  margin-top:auto;
}
.today-template-products span{
  display:inline-flex;
  align-items:center;
  max-width:100%;
  border:1px solid rgba(214,178,94,.26);
  background:rgba(214,178,94,.07);
  color:var(--app-muted);
  border-radius:999px;
  padding:6px 9px;
  font-size:.75rem;
  line-height:1.2;
}
.stock-warning{
  display:grid;
  grid-template-columns:auto minmax(0,1fr);
  gap:10px;
  align-items:start;
  margin-top:12px;
  border-radius:14px;
  padding:12px 13px;
  border:1px solid rgba(214,178,94,.65);
  background:rgba(214,178,94,.11);
  color:var(--app-text);
}
.stock-warning i{
  margin-top:2px;
  color:var(--app-primary);
}
.stock-warning strong,
.stock-warning span{
  display:block;
}
.stock-warning strong{
  text-transform:uppercase;
  letter-spacing:.06em;
  font-size:.8rem;
  color:var(--app-primary);
  margin-bottom:3px;
}
.stock-warning span{
  color:var(--app-muted);
  line-height:1.4;
}
.stock-warning-critical{
  border-color:rgba(255,41,61,.75);
  background:rgba(255,41,61,.12);
}
.stock-warning-critical i,
.stock-warning-critical strong{
  color:var(--app-danger);
}
.tracking-remove-inline{
  margin-top:12px;
  padding-top:12px;
  border-top:1px solid var(--app-border);
}
.tracking-remove-inline .btn{
  width:auto;
}
.intake-card .stock-warning{
  margin-bottom:12px;
}
@media(max-width:980px){
  .today-template-grid{grid-template-columns:repeat(2,minmax(0,1fr))}
}
@media(max-width:640px){
  .today-template-browser .section-head{
    display:grid;
    gap:12px;
  }
  .today-template-browser .section-head .btn,
  .today-template-grid,
  .tracking-remove-inline .btn{
    width:100%;
  }
  .today-template-grid{grid-template-columns:1fr}
  .template-card-top{display:grid}
}

/* v2.0 login username/email and welcome copy update */
.auth-card{
  width:min(560px,100%);
}
.auth-intro{
  border:1px solid rgba(214,178,94,.34);
  background:linear-gradient(180deg,rgba(214,178,94,.12),rgba(255,255,255,.025));
  border-radius:16px;
  padding:16px;
  margin:0 0 20px;
}
.auth-kicker{
  color:var(--app-primary);
  font-weight:900;
  text-transform:uppercase;
  letter-spacing:.08em;
  font-size:.78rem;
  margin-bottom:8px;
}
.auth-intro p{
  margin:0 0 10px;
  line-height:1.45;
}
.auth-intro p:last-child{margin-bottom:0}.auth-form{margin-top:6px}
@media(max-width:640px){.auth-card{width:100%;padding:22px 18px}.auth-intro{padding:14px}}

/* v2.4 calculator syringe image settings */
.syringe-option{min-height:88px;overflow:hidden}
.syringe-option .syringe-image-wrap{display:flex;align-items:center;justify-content:center;width:min(150px,42%);max-width:100%;aspect-ratio:4.2/1;flex:0 0 min(150px,42%);background:rgba(255,255,255,.025);border:1px solid rgba(255,255,255,.06);border-radius:10px;padding:6px}
.syringe-option .syringe-option-image{display:block;width:100%;height:100%;object-fit:contain;object-position:center}
.syringe-option .syringe-option-copy{display:flex;flex-direction:column;gap:2px;min-width:0}
.syringe-setting-preview{border:1px solid var(--app-border);background:rgba(0,0,0,.18);border-radius:12px;padding:10px;display:flex;align-items:center;justify-content:center;min-height:72px;margin-bottom:10px}
.syringe-setting-preview img{display:block;width:100%;max-width:360px;aspect-ratio:4.2/1;object-fit:contain;object-position:center}
.media-setting-row .input[type=file]{padding:9px;background:#111}
@media(max-width:640px){.syringe-option{align-items:center;min-height:92px}.syringe-option .syringe-image-wrap{width:100%;flex-basis:100%;max-width:230px;margin:0 auto}.syringe-option .syringe-option-copy{text-align:center;align-items:center}.calc-options-syringe .syringe-option{flex-direction:column;justify-content:center}}

/* v2.5 calculator syringe option layout update
   Makes syringe choices stack vertically and gives assigned images a wide responsive display area. */
.calc-options-syringe{
  display:grid !important;
  grid-template-columns:1fr !important;
  gap:14px !important;
  margin-top:14px;
}
.calc-options-syringe .syringe-option{
  width:100%;
  min-height:118px;
  display:grid !important;
  grid-template-columns:minmax(170px, 48%) 1fr;
  align-items:center;
  justify-content:stretch;
  gap:16px;
  padding:14px 16px;
  text-align:left;
}
.calc-options-syringe .syringe-option .syringe-image-wrap{
  width:100% !important;
  max-width:360px !important;
  min-height:70px;
  aspect-ratio:5 / 1;
  flex:none !important;
  display:flex !important;
  align-items:center;
  justify-content:center;
  background:rgba(255,255,255,.035);
  border:1px solid rgba(255,255,255,.08);
  border-radius:12px;
  padding:7px 10px;
  overflow:hidden;
}
.calc-options-syringe .syringe-option .syringe-option-image{
  display:block !important;
  width:100% !important;
  height:100% !important;
  max-height:86px;
  object-fit:contain;
  object-position:center;
}
.calc-options-syringe .syringe-option .fa-syringe{
  width:100%;
  max-width:360px;
  min-height:70px;
  display:flex;
  align-items:center;
  justify-content:center;
  border:1px solid rgba(255,255,255,.08);
  border-radius:12px;
  background:rgba(255,255,255,.035);
  font-size:2.35rem;
  color:var(--app-primary);
}
.calc-options-syringe .syringe-option .syringe-option-copy{
  display:flex;
  flex-direction:column;
  justify-content:center;
  gap:4px;
  min-width:0;
}
.calc-options-syringe .syringe-option .syringe-option-copy strong{
  font-size:1.1rem;
  line-height:1.15;
}
.calc-options-syringe .syringe-option .syringe-option-copy small{
  font-size:.88rem;
}
@media(max-width:700px){
  .calc-options-syringe .syringe-option{
    grid-template-columns:1fr;
    text-align:center;
    gap:10px;
    min-height:132px;
  }
  .calc-options-syringe .syringe-option .syringe-image-wrap,
  .calc-options-syringe .syringe-option .fa-syringe{
    max-width:100% !important;
    min-height:74px;
    margin:0 auto;
  }
  .calc-options-syringe .syringe-option .syringe-option-copy{
    align-items:center;
  }
}

/* v2.6 calculator product image placement */
.calc-product-main-no-avatar{
  display:block;
}
.calc-result-product-image{
  width:100%;
  margin:0 0 18px;
  border:1px solid var(--app-border);
  border-radius:18px;
  overflow:hidden;
  background:linear-gradient(180deg,rgba(255,255,255,.035),rgba(0,0,0,.18));
  min-height:160px;
  display:grid;
  place-items:center;
}
.calc-result-product-image img{
  display:block;
  width:100%;
  max-height:280px;
  object-fit:contain;
  padding:18px;
}
@media(max-width:700px){
  .calc-result-product-image{
    display:none !important;
  }
}


/* v2.7 global medical disclaimer footer */
.medical-disclaimer-footer{
  width:min(1180px, calc(100% - 32px));
  margin:22px auto calc(92px + env(safe-area-inset-bottom, 0px));
  color:var(--app-muted);
}
.medical-disclaimer-inner{
  border:1px solid rgba(214,178,94,.26);
  background:linear-gradient(180deg, rgba(214,178,94,.08), rgba(255,255,255,.025));
  border-radius:var(--app-radius);
  padding:14px 16px;
  font-size:.86rem;
  line-height:1.55;
  letter-spacing:.01em;
}
.medical-disclaimer-inner strong{
  color:var(--app-primary);
  font-weight:900;
  text-transform:uppercase;
  letter-spacing:.06em;
  margin-right:4px;
}
.auth-page .medical-disclaimer-footer{
  width:min(720px, calc(100% - 32px));
  margin:0 auto 28px;
}
.admin-body .medical-disclaimer-footer{
  width:100%;
  margin:28px 0 0;
}
.admin-body .medical-disclaimer-inner{
  font-size:.82rem;
}
@media(max-width:700px){
  .medical-disclaimer-footer{
    width:calc(100% - 24px);
    margin-top:18px;
  }
  .medical-disclaimer-inner{
    font-size:.8rem;
    padding:12px 13px;
  }
}

/* v2.8 order list, historical order exports, and low-stock modal */
.order-inline-form{margin:0;display:inline-flex}.order-manager,.order-history{scroll-margin-top:24px}.order-list{display:grid;gap:14px}.order-item-row{display:grid;grid-template-columns:86px minmax(0,1fr) auto;gap:14px;align-items:center;border:1px solid var(--app-border);border-radius:16px;background:rgba(0,0,0,.18);padding:12px}.order-item-media{width:86px;height:86px;border:1px solid var(--app-border);border-radius:14px;background:rgba(0,0,0,.25);display:grid;place-items:center;overflow:hidden}.order-item-image,.order-item-image.product-thumb-placeholder{width:100%;height:100%;object-fit:contain;padding:6px}.order-item-copy{display:grid;gap:6px;min-width:0}.order-item-copy strong{font-size:1.05rem}.order-item-fields{display:grid;grid-template-columns:120px minmax(0,1fr);gap:10px}.order-item-fields label{display:grid;gap:4px;font-size:.72rem;text-transform:uppercase;letter-spacing:.07em;color:var(--app-muted);font-weight:800}.order-item-actions,.order-actions,.order-history-actions{display:flex;flex-wrap:wrap;gap:10px;align-items:center}.order-actions{margin-top:16px}.order-history-list{display:grid;gap:12px}.order-history-row{display:flex;align-items:center;justify-content:space-between;gap:14px;border:1px solid var(--app-border);border-radius:14px;background:rgba(0,0,0,.18);padding:14px}.order-history-row>div:first-child{display:grid;gap:4px}.stock-warning-actions{display:flex;flex-wrap:wrap;gap:8px;margin-top:10px}.stock-warning-actions .btn{min-height:34px}.order-modal-backdrop{position:fixed;inset:0;z-index:1000;background:rgba(0,0,0,.72);display:none;align-items:center;justify-content:center;padding:18px;backdrop-filter:blur(6px)}.order-modal-backdrop.is-open{display:flex}.order-modal{width:min(760px,100%);max-height:min(86vh,760px);overflow:auto;position:relative;box-shadow:0 24px 90px rgba(0,0,0,.55)}.modal-close{position:absolute;top:12px;right:12px;width:38px;height:38px;border-radius:999px;border:1px solid var(--app-border);background:rgba(0,0,0,.35);color:var(--app-text);font-size:1.5rem;line-height:1;cursor:pointer}.low-stock-modal-list{display:grid;gap:12px;margin:18px 0}.low-stock-modal-item{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:12px;align-items:center;border:1px solid var(--app-border);border-radius:14px;padding:13px;background:rgba(0,0,0,.22)}.low-stock-modal-item-low{border-color:rgba(214,178,94,.55)}.low-stock-modal-item-critical{border-color:rgba(255,41,61,.72);background:rgba(255,41,61,.08)}.low-stock-modal-copy{display:grid;gap:4px}.low-stock-modal-copy strong{color:var(--app-text)}.low-stock-modal-copy span{color:var(--app-muted)}.low-stock-modal-actions{display:flex;flex-wrap:wrap;gap:8px;justify-content:flex-end}.order-empty{padding:18px;border:1px dashed var(--app-border);border-radius:16px;background:rgba(0,0,0,.14)}
@media(max-width:760px){.order-item-row{grid-template-columns:64px minmax(0,1fr)}.order-item-actions{grid-column:1/-1}.order-item-media{width:64px;height:64px}.order-item-fields{grid-template-columns:1fr}.order-actions,.order-history-actions,.low-stock-modal-actions,.stock-warning-actions{display:grid;grid-template-columns:1fr}.order-actions form,.order-actions .btn,.order-history-actions form,.order-history-actions .btn,.low-stock-modal-actions form,.low-stock-modal-actions .btn,.stock-warning-actions form,.stock-warning-actions .btn{width:100%}.order-history-row,.low-stock-modal-item{display:grid}.order-modal{max-height:88vh}}

/* v3.0 goal-based stack categories */
.stack-category-section{
  scroll-margin-top:24px;
}
.stack-category-section .section-head h2{
  margin-bottom:4px;
}
.admin-order-table td .admin-product-check{
  justify-content:flex-start;
  min-width:max-content;
}
.stack-category-chip-list{
  display:flex;
  flex-wrap:wrap;
  gap:8px;
  margin:12px 0 0;
}
.stack-category-chip{
  display:inline-flex;
  align-items:center;
  gap:7px;
  border:1px solid rgba(214,178,94,.35);
  background:rgba(214,178,94,.08);
  color:var(--app-text);
  border-radius:999px;
  padding:7px 10px;
  font-size:.84rem;
  font-weight:800;
}
.stack-category-chip small{
  color:var(--app-muted);
  font-weight:700;
}
.goal-stack-grid{
  grid-template-columns:repeat(3,minmax(0,1fr));
}
.goal-stack-card{
  display:flex;
  flex-direction:column;
  gap:14px;
  min-width:0;
}
.goal-stack-card .product-directory-head{
  align-items:flex-start;
}
.goal-stack-card h3{
  line-height:1.25;
}
.goal-stack-card form{
  margin-top:auto;
}
.template-product-chips{
  margin-top:0;
}
@media(max-width:760px){
  .stack-category-section .section-head{
    align-items:flex-start;
  }
}
@media(max-width:1000px){
  .goal-stack-grid{
    grid-template-columns:repeat(2,minmax(0,1fr));
  }
}
@media(max-width:700px){
  .goal-stack-grid{
    grid-template-columns:1fr;
  }
}

/* v3.1 stack cart and confirmation scheduler */
.stack-cart-summary{
  border-color:rgba(214,178,94,.45);
  background:linear-gradient(180deg,rgba(214,178,94,.08),rgba(0,0,0,.12));
}
.stack-cart-actions{
  display:flex;
  flex-wrap:wrap;
  gap:10px;
  justify-content:flex-end;
  align-items:center;
}
.stack-cart-actions form{margin:0}
.stack-cart-list{
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:12px;
  margin-top:14px;
}
.stack-cart-item{
  display:grid;
  grid-template-columns:64px minmax(0,1fr) auto;
  gap:12px;
  align-items:center;
  border:1px solid var(--app-border);
  background:rgba(0,0,0,.2);
  border-radius:16px;
  padding:10px;
}
.stack-cart-media,.confirm-product-media{
  border:1px solid var(--app-border);
  background:rgba(0,0,0,.26);
  border-radius:14px;
  overflow:hidden;
  display:grid;
  place-items:center;
}
.stack-cart-media{width:64px;height:64px}
.stack-cart-image,.stack-cart-image.product-thumb-placeholder,
.confirm-product-image,.confirm-product-image.product-thumb-placeholder{
  width:100%;height:100%;object-fit:contain;padding:6px;
}
.stack-cart-copy{display:grid;gap:4px;min-width:0}
.stack-cart-copy strong{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.confirm-stack-toolbar{
  display:flex;
  justify-content:space-between;
  gap:16px;
  align-items:center;
  border-color:rgba(214,178,94,.35);
}
.confirm-product-list{display:grid;gap:18px;margin-top:18px}
.confirm-product-card{display:grid;gap:18px}
.confirm-product-head{
  display:grid;
  grid-template-columns:110px minmax(0,1fr) auto;
  gap:16px;
  align-items:start;
}
.confirm-product-media{width:110px;height:110px}
.confirm-include{
  margin-bottom:8px;
  font-weight:900;
  color:var(--app-primary);
}
.confirm-rule-grid{align-items:end}
.schedule-preview{
  border:1px solid var(--app-border);
  background:rgba(0,0,0,.16);
  border-radius:16px;
  padding:12px;
  display:grid;
  gap:10px;
}
.schedule-preview-list{
  display:flex;
  flex-wrap:wrap;
  gap:8px;
}
.schedule-preview-list span{
  display:inline-flex;
  border:1px solid rgba(214,178,94,.28);
  background:rgba(214,178,94,.08);
  border-radius:999px;
  padding:7px 10px;
  font-size:.82rem;
  font-weight:800;
}
.manual-schedule-editor{
  border:1px solid var(--app-border);
  border-radius:16px;
  background:rgba(0,0,0,.14);
  padding:12px;
}
.manual-schedule-editor summary{
  cursor:pointer;
  font-weight:900;
  color:var(--app-primary);
}
.manual-schedule-editor textarea{
  width:100%;
  min-height:120px;
  margin-top:10px;
  background:#111;
  color:var(--app-text);
  border:1px solid var(--app-border);
  border-radius:12px;
  padding:12px;
  font-family:ui-monospace,SFMono-Regular,Menlo,monospace;
}
.confirm-stack-footer{
  margin-top:18px;
  text-align:center;
}
@media(max-width:860px){
  .stack-cart-list{grid-template-columns:1fr}
  .confirm-stack-toolbar{display:grid}
  .stack-cart-actions{display:grid;grid-template-columns:1fr;width:100%}
  .stack-cart-actions .btn,.stack-cart-actions form,.stack-cart-actions button{width:100%}
  .confirm-product-head{grid-template-columns:84px minmax(0,1fr)}
  .confirm-product-head>.badge{grid-column:1/-1;justify-self:start}
  .confirm-product-media{width:84px;height:84px}
}
@media(max-width:560px){
  .stack-cart-item{grid-template-columns:54px minmax(0,1fr)}
  .stack-cart-item form{grid-column:1/-1}
  .stack-cart-media{width:54px;height:54px}
  .confirm-product-head{grid-template-columns:1fr}
  .confirm-product-media{width:100%;height:150px}
  .confirm-rule-grid{grid-template-columns:1fr}
}

/* v3.2 notification centre */
.topbar-actions{display:flex;align-items:center;gap:10px;position:relative}.notification-menu{position:relative;display:inline-flex}.notification-button{position:relative;width:42px;height:42px;border-radius:999px;border:1px solid var(--app-border);background:rgba(255,255,255,.035);color:var(--app-text);display:grid;place-items:center;cursor:pointer}.notification-button:hover,.notification-menu.is-open .notification-button{border-color:var(--app-primary);color:var(--app-primary);background:rgba(214,178,94,.09)}.notification-badge{position:absolute;right:-4px;top:-5px;min-width:19px;height:19px;border-radius:999px;background:var(--app-danger);color:#fff;display:grid;place-items:center;font-size:.68rem;font-weight:900;border:2px solid var(--app-bg)}.notification-popover{position:absolute;right:0;top:calc(100% + 12px);width:min(390px,calc(100vw - 28px));max-height:min(70vh,560px);overflow:auto;background:linear-gradient(180deg,rgba(255,255,255,.045),var(--app-card));border:1px solid rgba(214,178,94,.42);border-radius:18px;box-shadow:0 20px 70px rgba(0,0,0,.55);padding:0;display:none;z-index:80}.notification-menu.is-open .notification-popover{display:block}.notification-popover:before{content:"";position:absolute;right:15px;top:-7px;width:12px;height:12px;transform:rotate(45deg);background:var(--app-card);border-left:1px solid rgba(214,178,94,.42);border-top:1px solid rgba(214,178,94,.42)}.notification-popover-head{position:sticky;top:0;z-index:2;display:flex;align-items:center;justify-content:space-between;gap:10px;padding:14px 16px;border-bottom:1px solid var(--app-border);background:rgba(20,20,20,.96);backdrop-filter:blur(10px)}.notification-popover-head strong{display:block;text-transform:uppercase;letter-spacing:.05em}.notification-popover-head span{display:block;color:var(--app-muted);font-size:.8rem;margin-top:2px}.link-button{border:0;background:transparent;color:var(--app-primary);font-weight:900;text-transform:uppercase;letter-spacing:.05em;cursor:pointer;padding:4px}.notification-empty{padding:18px 16px;color:var(--app-muted);margin:0}.notification-list,.notification-history-list{display:grid;gap:10px}.notification-list{padding:12px}.notification-item,.notification-history-item{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:12px;border:1px solid var(--app-border);border-radius:14px;padding:12px;background:rgba(0,0,0,.2)}.notification-history-item{grid-template-columns:1fr;margin-bottom:10px}.notification-item.is-unread,.notification-history-item.is-unread{border-color:rgba(214,178,94,.65);background:rgba(214,178,94,.075)}.notification-type{display:inline-flex;margin-bottom:7px;border:1px solid var(--app-border);border-radius:999px;padding:3px 8px;color:var(--app-primary);font-size:.67rem;font-weight:900;text-transform:uppercase;letter-spacing:.06em}.notification-item strong,.notification-history-item strong{display:block;margin-bottom:5px}.notification-item p,.notification-history-item p{margin:0 0 7px;color:var(--app-muted);font-size:.86rem;line-height:1.35}.notification-item small,.notification-history-item small{color:var(--app-muted);font-size:.73rem}.icon-button{width:34px;height:34px;border-radius:999px;border:1px solid var(--app-border);background:transparent;color:var(--app-primary);display:grid;place-items:center;cursor:pointer}.icon-button:hover{border-color:var(--app-primary);background:rgba(214,178,94,.08)}.notification-popover-foot{padding:12px 16px;border-top:1px solid var(--app-border);text-align:center}.notification-popover-foot a{font-weight:900;text-transform:uppercase;letter-spacing:.05em;font-size:.78rem}#notification-history{scroll-margin-top:90px}.notification-rule-hint{border:1px dashed rgba(214,178,94,.45);background:rgba(214,178,94,.06);border-radius:12px;padding:12px}.admin-table .button-row{gap:8px}
@media(max-width:640px){.topbar-actions{gap:7px}.notification-button{width:38px;height:38px}.user-pill{max-width:42vw;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.notification-popover{right:-82px;top:calc(100% + 10px);width:calc(100vw - 18px);max-height:72vh}.notification-popover:before{right:96px}.notification-popover-head{padding:12px}.notification-item{grid-template-columns:1fr}.notification-item form{justify-self:start}.notification-history-item{padding:12px}}


/* v3.3 notification popup desktop readability and click fix */
.notification-menu{z-index:10000!important}.notification-button{z-index:10001!important}.notification-menu .notification-popover{background:#171717!important;background-image:linear-gradient(180deg,#24211b 0%,#171717 68%)!important;color:var(--app-text)!important;opacity:1!important;backdrop-filter:none!important;-webkit-backdrop-filter:none!important;border-color:rgba(214,178,94,.72)!important;box-shadow:0 22px 80px rgba(0,0,0,.78),0 0 0 1px rgba(255,255,255,.045) inset!important}.notification-menu.is-open .notification-popover{display:block!important;visibility:visible!important;pointer-events:auto!important}.notification-popover-head{background:#161616!important}.notification-popover:before{background:#24211b!important}.notification-item,.notification-history-item{background:#111!important}.notification-item.is-unread,.notification-history-item.is-unread{background:#221d12!important}.notification-list{background:#171717!important}.notification-popover-foot{background:#171717!important}
@media(min-width:641px){.notification-menu .notification-popover{position:fixed!important;top:66px!important;right:18px!important;width:390px!important;max-width:calc(100vw - 36px)!important;max-height:calc(100vh - 92px)!important}.notification-popover:before{right:78px!important}}
@media(max-width:640px){.notification-menu .notification-popover{position:fixed!important;top:64px!important;left:9px!important;right:9px!important;width:auto!important;max-height:calc(100vh - 94px)!important}.notification-popover:before{right:96px!important}}

/* ATP v3.5 profile and referrer updates */
.user-pill-link {
  text-decoration: none;
  color: var(--text, #f7f1e4);
}
.user-pill-link:hover,
.user-pill-link:focus {
  color: var(--gold, #d6b25e);
  border-color: rgba(214,178,94,.55);
}
.profile-summary-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin: 16px 0;
}
.profile-summary-grid > div {
  border: 1px solid rgba(255,255,255,.1);
  background: rgba(0,0,0,.18);
  border-radius: 14px;
  padding: 14px;
  min-width: 0;
}
.profile-summary-grid span {
  display: block;
  color: var(--muted, #b8b1a2);
  font-size: 12px;
  letter-spacing: .08em;
  text-transform: uppercase;
  margin-bottom: 5px;
}
.profile-summary-grid strong {
  display: block;
  overflow-wrap: anywhere;
}
.profile-edit-card {
  max-width: 900px;
}
@media (max-width: 640px) {
  .profile-summary-grid {
    grid-template-columns: 1fr;
  }
  .topbar-actions {
    gap: 8px;
  }
  .user-pill-link {
    max-width: 120px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }
}

/* v3.6 calculator timeline */
.calc-timeline-card{
  margin-top:18px;
  border:1px solid rgba(224,188,94,.45);
  border-radius:18px;
  padding:20px;
  background:linear-gradient(135deg,rgba(224,188,94,.12),rgba(255,255,255,.025));
  box-shadow:0 18px 38px rgba(0,0,0,.18);
}
.calc-timeline-card h3{
  margin:6px 0 8px;
  font-size:22px;
  line-height:1.15;
  color:var(--text,#f5f2e9);
}
.calc-timeline-card p{
  margin:0;
  max-width:720px;
}
@media (max-width: 640px){
  .calc-timeline-card{padding:16px;border-radius:15px;}
  .calc-timeline-card h3{font-size:18px;}
}


/* v3.7 calculator intake period details */
.calc-intake-card{
  margin-top:18px;
  border:1px solid rgba(255,255,255,.12);
  border-radius:18px;
  padding:20px;
  background:rgba(255,255,255,.035);
  box-shadow:0 18px 38px rgba(0,0,0,.14);
}
.calc-intake-card h3{
  margin:6px 0 14px;
  font-size:22px;
  line-height:1.15;
  color:var(--text,#f5f2e9);
}
.calc-intake-grid{
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:12px;
}
.calc-intake-grid > div{
  border:1px solid rgba(255,255,255,.12);
  border-radius:14px;
  padding:12px 14px;
  background:rgba(0,0,0,.18);
}
.calc-intake-grid span{
  display:block;
  margin-bottom:5px;
  font-size:11px;
  letter-spacing:.1em;
  text-transform:uppercase;
  color:var(--muted,#aaa);
}
.calc-intake-grid strong{
  display:block;
  color:var(--text,#f5f2e9);
  line-height:1.25;
}
.calc-intake-notes{
  margin-top:12px;
  border-left:3px solid var(--gold,#d9b95b);
  padding-left:12px;
}
@media (max-width: 640px){
  .calc-intake-card{padding:16px;border-radius:15px;}
  .calc-intake-card h3{font-size:18px;}
  .calc-intake-grid{grid-template-columns:1fr;gap:10px;}
}

/* v3.8 Today intake status compaction and re-update controls */
.intake-card-compact{
  padding:18px;
  border-style:solid;
}
.intake-card-compact .metric{
  gap:14px;
  align-items:center;
}
.status-pill{
  display:inline-flex;
  align-items:center;
  gap:7px;
  font-weight:800;
}
.status-taken.intake-card-compact{
  border-color:rgba(72,211,138,.45);
  background:linear-gradient(180deg,rgba(72,211,138,.08),var(--app-card));
}
.status-missed.intake-card-compact{
  border-color:rgba(255,107,107,.55);
  background:linear-gradient(180deg,rgba(255,107,107,.08),var(--app-card));
}
.status-skipped.intake-card-compact{
  border-color:rgba(190,190,190,.35);
  background:linear-gradient(180deg,rgba(255,255,255,.04),var(--app-card));
}
.compact-note{
  margin:8px 0 0;
  padding:10px 12px;
  border:1px solid rgba(255,255,255,.08);
  border-radius:12px;
  background:rgba(0,0,0,.16);
}
.compact-status-actions{
  margin-top:12px;
}
@media(max-width:760px){
  .intake-card-compact .metric{
    grid-template-columns:1fr;
  }
  .intake-card-compact .status-pill,
  .compact-status-actions .btn{
    width:100%;
    justify-content:center;
  }
}

/* v3.9 calendar intake edit + update history */
.calendar-event {
  text-decoration: none;
  color: inherit;
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 4px 6px;
  align-items: center;
}
.calendar-event em {
  grid-column: 1 / -1;
  font-style: normal;
  font-size: 10px;
  opacity: .78;
  text-transform: uppercase;
  letter-spacing: .08em;
}
.calendar-event:hover {
  border-color: var(--atp-gold, #d6b25e);
  transform: translateY(-1px);
}
.calendar-row-actions {
  display: flex;
  gap: 8px;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap;
}
.dose-edit-card .section-head {
  align-items: flex-start;
}
.dose-replacement-box {
  margin-top: 18px;
  padding: 16px;
  border: 1px dashed rgba(214,178,94,.45);
  background: rgba(214,178,94,.07);
  border-radius: 14px;
}
.checkbox-line {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  margin-bottom: 14px;
}
.checkbox-line input {
  width: 18px;
  height: 18px;
  accent-color: var(--atp-gold, #d6b25e);
}
.dose-update-history {
  display: grid;
  gap: 12px;
  margin-top: 14px;
}
.dose-update-history-item {
  border: 1px solid rgba(255,255,255,.12);
  background: rgba(0,0,0,.18);
  border-radius: 14px;
  padding: 14px;
}
.dose-update-history-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
  margin-bottom: 10px;
}
.dose-update-history-head strong {
  color: var(--atp-gold, #d6b25e);
  text-transform: uppercase;
  letter-spacing: .08em;
  font-size: 12px;
}
.dose-update-history-head span,
.dose-update-history-grid span {
  color: rgba(255,255,255,.68);
  font-size: 12px;
}
.dose-update-history-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}
.dose-update-history-grid > div {
  padding: 10px;
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 10px;
  background: rgba(255,255,255,.03);
}
.dose-update-history-grid strong {
  display: block;
  margin-top: 4px;
  font-size: 13px;
}
.dose-update-history-notes {
  grid-column: 1 / -1;
}
.dose-update-history-notes p {
  margin: 6px 0 0;
}
.dose-history-empty {
  padding: 12px;
  border: 1px dashed rgba(255,255,255,.16);
  border-radius: 12px;
  margin-top: 12px;
}
@media (max-width: 700px) {
  .dose-update-history-grid {
    grid-template-columns: 1fr;
  }
  .calendar-row-actions {
    justify-content: flex-start;
  }
}

/* v4.0 Today compact status editor */
.compact-status-editor{
  margin-top:16px;
  padding-top:16px;
  border-top:1px solid rgba(255,255,255,.1);
}
.compact-status-editor[hidden]{
  display:none !important;
}
.intake-card-compact.is-editing{
  border-color:rgba(214,178,94,.55);
  box-shadow:0 0 0 1px rgba(214,178,94,.16), 0 18px 50px rgba(0,0,0,.22);
}
.intake-card-compact.is-editing .compact-status-actions{
  margin-bottom:4px;
}
.compact-status-editor .intake-actions{
  margin-top:14px;
}
@media(max-width:760px){
  .compact-status-editor .intake-actions .btn{
    width:100%;
    justify-content:center;
  }
}

/* v4.1 calendar edit lock for today and future dates */
.calendar-event.is-locked{
  cursor: not-allowed;
  opacity: .72;
  text-decoration: none;
  background: rgba(255,255,255,.035);
}
.calendar-event.is-locked:hover{
  transform: none;
  border-color: var(--app-border, rgba(255,255,255,.14));
}
.calendar-event.is-locked small{
  grid-column: 1 / -1;
  display: inline-flex;
  align-items: center;
  width: max-content;
  max-width: 100%;
  padding: 2px 7px;
  border-radius: 999px;
  border: 1px solid rgba(214,178,94,.35);
  color: var(--app-primary, #d6b25e);
  font-size: .62rem;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: .08em;
}
.badge-locked{
  border-color: rgba(214,178,94,.35)!important;
  color: var(--app-primary, #d6b25e)!important;
  background: rgba(214,178,94,.08)!important;
}

/* v4.2 referrer review and user assignment visibility */
.badge-danger{
  border-color:rgba(255,65,80,.45)!important;
  color:#ff6b78!important;
  background:rgba(255,65,80,.12)!important;
}
.referrer-source-alert{
  display:flex;
  align-items:center;
  gap:10px;
  padding:12px 14px;
  margin:12px 0 18px;
  border:1px solid rgba(255,65,80,.45);
  border-radius:14px;
  color:#ff6b78;
  background:rgba(255,65,80,.1);
  font-weight:800;
}
.referrer-user-submitted-row{
  background:rgba(255,65,80,.045);
}
.referrer-user-submitted-note{
  display:inline-block;
  margin-top:4px;
  color:#ff6b78;
  font-size:.78rem;
  font-weight:800;
  text-transform:uppercase;
  letter-spacing:.08em;
}
.referrer-users-card .badge{
  margin-left:4px;
}
.referrer-users-list{
  display:grid;
  gap:10px;
  margin-top:14px;
}
.referrer-user-row{
  display:grid;
  grid-template-columns:minmax(0,1fr) auto;
  gap:14px;
  align-items:center;
  padding:12px 14px;
  border:1px solid rgba(255,255,255,.12);
  border-radius:14px;
  background:rgba(0,0,0,.18);
}
.referrer-user-row span,
.referrer-user-row small{
  display:block;
  color:var(--app-muted,#b8b3a7);
  font-size:.82rem;
  margin-top:2px;
}
.referrer-user-row > div:last-child{
  text-align:right;
}
.referrer-users-empty{
  padding:12px 14px;
  margin-top:12px;
  border:1px dashed rgba(255,255,255,.14);
  border-radius:14px;
}
@media(max-width:700px){
  .referrer-user-row{
    grid-template-columns:1fr;
  }
  .referrer-user-row > div:last-child{
    text-align:left;
  }
}

/* v4.3 admin user access management */
.user-admin-table td{
  vertical-align:top;
}
.admin-user-actions{
  display:flex;
  flex-wrap:wrap;
  gap:8px;
  align-items:center;
  min-width:260px;
}
.inline-action-form{
  display:inline-flex;
  margin:0;
}
.user-status-pills{
  display:flex;
  flex-wrap:wrap;
  gap:6px;
}
.status-pill{
  display:inline-flex;
  align-items:center;
  padding:5px 9px;
  border-radius:999px;
  border:1px solid rgba(255,255,255,.14);
  font-size:.72rem;
  font-weight:800;
  line-height:1;
  letter-spacing:.06em;
  text-transform:uppercase;
}
.status-ok{
  color:#8ff0a4;
  border-color:rgba(143,240,164,.35);
  background:rgba(143,240,164,.09);
}
.status-warn{
  color:#e7c15b;
  border-color:rgba(231,193,91,.38);
  background:rgba(231,193,91,.1);
}
.status-danger{
  color:#ff6b78;
  border-color:rgba(255,107,120,.42);
  background:rgba(255,107,120,.12);
}
.user-row-disabled{
  opacity:.72;
  background:rgba(255,255,255,.025);
}
.self-user-note{
  display:inline-flex;
  align-items:center;
  padding:6px 8px;
}
@media(max-width:760px){
  .admin-user-actions{
    min-width:0;
  }
  .user-admin-table .btn-small{
    width:auto;
  }
}

/* ATP v4.4 Admin user deletion/disable reason UI */
.user-admin-tabs {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 18px;
}
.admin-user-reason-text {
  max-width: 420px;
  white-space: normal;
  line-height: 1.45;
}
.user-status-reason {
  margin-top: 10px;
  padding: 10px 12px;
  border: 1px solid rgba(226, 190, 96, 0.32);
  border-radius: 12px;
  background: rgba(226, 190, 96, 0.08);
  color: var(--text, #f7f1e5);
  font-size: 0.88rem;
  line-height: 1.45;
}
.user-status-reason span {
  color: var(--muted, #b8b0a2);
}
.user-status-reason-deleted {
  border-color: rgba(248, 93, 93, 0.38);
  background: rgba(248, 93, 93, 0.08);
}
.user-row-deleted {
  opacity: 0.92;
  background: rgba(248, 93, 93, 0.035);
}
.reason-action-form .btn-danger {
  border-color: rgba(248, 93, 93, 0.7);
}
@media (max-width: 760px) {
  .user-admin-tabs .btn {
    width: 100%;
    justify-content: center;
  }
  .admin-user-reason-text {
    max-width: none;
  }
}

.atp-hp{position:absolute!important;left:-99999px!important;width:1px!important;height:1px!important;overflow:hidden!important;opacity:0!important;pointer-events:none!important}

/* ATP v4.7 Admin user profile tools */
.admin-user-edit-layout {
  align-items: start;
}
.admin-user-edit-form .input[readonly] {
  opacity: .76;
  cursor: not-allowed;
  background: rgba(255,255,255,.045);
  border-style: dashed;
}
.admin-user-tool-actions {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin: 16px 0;
}
.admin-user-tool-actions form,
.admin-user-tool-actions button {
  width: 100%;
}
.compact-profile-summary {
  margin-top: 14px;
}
.email-history-table td,
.email-history-table th {
  vertical-align: top;
  white-space: normal;
}
.admin-user-actions .btn i {
  margin-right: 4px;
}
@media (max-width: 720px) {
  .admin-user-edit-layout {
    grid-template-columns: 1fr !important;
  }
  .admin-user-actions {
    align-items: stretch;
  }
  .admin-user-actions .btn,
  .admin-user-actions form,
  .admin-user-actions button {
    width: 100%;
  }
}

/* Subscription and billing module v4.9 */
.subscription-summary-card{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:12px;margin:14px 0}.subscription-summary-card>div{background:rgba(255,255,255,.035);border:1px solid var(--app-border);border-radius:14px;padding:12px;min-width:0}.subscription-summary-card span{display:block;color:var(--app-muted);font-size:.74rem;text-transform:uppercase;letter-spacing:.06em;margin-bottom:5px}.subscription-summary-card strong{display:block;color:var(--app-text);font-size:1rem;word-break:break-word}.billing-status .button-row,.billing-settings-card .button-row{margin-top:14px}.pricing-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:14px;margin-top:18px}.pricing-card{background:linear-gradient(180deg,rgba(255,255,255,.045),rgba(0,0,0,.18));border:1px solid var(--app-border);border-radius:18px;padding:18px;display:flex;flex-direction:column;gap:10px}.pricing-card h3{margin:0;font-size:1.2rem}.price-line{display:flex;align-items:flex-end;gap:4px;color:var(--app-primary)}.price-line strong{font-size:1.8rem;line-height:1}.discount-applied{border:1px solid rgba(214,178,94,.55);background:rgba(214,178,94,.1);border-radius:12px;padding:9px 10px;margin:0;font-size:.85rem}.notice-inline-error{border:1px solid rgba(255,41,61,.55);background:rgba(255,41,61,.1);border-radius:12px;padding:9px 10px;margin:0;font-size:.85rem;color:#ffd0d5}.billing-discount-form{margin-bottom:8px}.inline-field{display:flex;gap:10px;align-items:center}.inline-field .input{flex:1}.billing-gate{text-align:center;max-width:720px;margin:42px auto}.check-row{display:flex;align-items:center;gap:10px;margin:8px 0;color:var(--app-text)}.check-row input[type=checkbox]{width:auto}.check-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px;border:1px solid var(--app-border);border-radius:12px;padding:10px;background:rgba(0,0,0,.16)}.admin-user-edit-layout+.card{margin-top:18px}.admin-table .link-button,.link-button{background:none;border:0;color:var(--app-primary);padding:0;cursor:pointer;text-decoration:underline}.payment-diagnostic-payload{max-height:260px;overflow:auto;white-space:pre-wrap;background:#080808;border:1px solid var(--app-border);border-radius:12px;padding:12px}.billing-lock-notice{margin-top:12px;width:100%}@media(max-width:1000px){.pricing-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.subscription-summary-card{grid-template-columns:repeat(2,minmax(0,1fr))}}@media(max-width:700px){.pricing-grid,.subscription-summary-card,.check-grid{grid-template-columns:1fr}.inline-field{flex-direction:column;align-items:stretch}.pricing-card{padding:16px}.price-line strong{font-size:1.55rem}}

/* ATP v5.0 public landing page */
body.landing-public {
  background:
    radial-gradient(circle at top left, rgba(212, 175, 55, 0.16), transparent 32rem),
    radial-gradient(circle at bottom right, rgba(255, 255, 255, 0.06), transparent 26rem),
    var(--app-bg, #101010);
}
body.landing-public .app-shell {
  max-width: none;
  padding-bottom: 0;
}
body.landing-public .main-content {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 18px 0 48px;
}
.landing-page-wrap {
  display: grid;
  gap: 34px;
}
.landing-header {
  position: sticky;
  top: 12px;
  z-index: 60;
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 18px;
  padding: 14px 16px;
  border: 1px solid rgba(212, 175, 55, 0.25);
  border-radius: 22px;
  background: rgba(15, 15, 15, 0.94);
  box-shadow: 0 18px 46px rgba(0, 0, 0, 0.34);
  backdrop-filter: blur(14px);
}
.landing-brand {
  color: #fff;
  text-decoration: none;
  font-weight: 900;
  letter-spacing: 0.02em;
  white-space: nowrap;
}
.landing-nav-panel {
  display: contents;
}
.landing-menu-toggle-input {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}
.landing-menu-toggle {
  display: none;
  width: 44px;
  height: 44px;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 5px;
  border: 1px solid rgba(212, 175, 55, 0.35);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.045);
  cursor: pointer;
}
.landing-menu-toggle span {
  display: block;
  width: 20px;
  height: 2px;
  border-radius: 999px;
  background: #fff;
}
.landing-menu {
  display: flex;
  justify-content: center;
  gap: 10px;
  flex-wrap: wrap;
}
.landing-menu a {
  color: var(--muted, #b8b8b8);
  text-decoration: none;
  font-size: 0.92rem;
  padding: 8px 10px;
  border-radius: 999px;
}
.landing-menu a:hover,
.landing-menu a:focus-visible {
  color: #fff;
  background: rgba(212, 175, 55, 0.12);
}
.landing-login-btn {
  white-space: nowrap;
}
.landing-hero {
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(280px, 0.55fr);
  gap: 22px;
  align-items: stretch;
  padding-top: 18px;
}
.landing-hero-copy,
.landing-hero-panel,
.landing-section,
.landing-register {
  border: 1px solid rgba(212, 175, 55, 0.18);
  border-radius: 28px;
  background: linear-gradient(145deg, rgba(28, 28, 28, 0.96), rgba(13, 13, 13, 0.96));
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.32);
}
.landing-hero-copy {
  padding: clamp(28px, 5vw, 62px);
}
.landing-hero-copy h1 {
  max-width: 780px;
  margin: 10px 0 16px;
  font-size: clamp(2.35rem, 6vw, 5.4rem);
  line-height: 0.95;
  letter-spacing: -0.055em;
}
.landing-hero-copy p {
  max-width: 760px;
  color: var(--muted, #b8b8b8);
  font-size: clamp(1rem, 1.55vw, 1.2rem);
}
.landing-hero-actions,
.landing-register-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 24px;
}
.landing-hero-panel {
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 28px;
  min-height: 320px;
  position: relative;
  overflow: hidden;
}
.landing-hero-panel::before {
  content: "";
  position: absolute;
  inset: -30% -20% auto auto;
  width: 260px;
  height: 260px;
  border-radius: 999px;
  background: rgba(212, 175, 55, 0.16);
  filter: blur(8px);
}
.landing-panel-icon {
  position: relative;
  display: inline-grid;
  place-items: center;
  width: 72px;
  height: 72px;
  margin-bottom: 18px;
  border-radius: 22px;
  background: rgba(212, 175, 55, 0.14);
  color: var(--accent, #d4af37);
  font-size: 2rem;
}
.landing-hero-panel h2,
.landing-section h2,
.landing-register h2 {
  margin: 0 0 10px;
}
.landing-hero-panel p,
.landing-wide-text,
.landing-register p {
  color: var(--muted, #b8b8b8);
}
.landing-section {
  padding: clamp(24px, 4vw, 42px);
  scroll-margin-top: 110px;
}
.landing-section-head {
  margin-bottom: 22px;
}
.landing-section-head h2 {
  max-width: 820px;
  font-size: clamp(1.55rem, 3.2vw, 2.65rem);
  letter-spacing: -0.035em;
}
.landing-wide-text {
  max-width: 980px;
  font-size: 1.06rem;
  line-height: 1.75;
}
.landing-feature-grid,
.landing-pricing-grid {
  display: grid;
  gap: 16px;
}
.landing-feature-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}
.landing-feature-card,
.landing-price-card {
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.045);
  padding: 20px;
}
.landing-feature-icon {
  display: inline-grid;
  place-items: center;
  width: 46px;
  height: 46px;
  margin-bottom: 14px;
  border-radius: 16px;
  color: var(--accent, #d4af37);
  background: rgba(212, 175, 55, 0.12);
}
.landing-feature-card h3,
.landing-price-card h3 {
  margin: 0 0 8px;
}
.landing-feature-card p,
.landing-price-note {
  margin: 0;
  color: var(--muted, #b8b8b8);
  line-height: 1.6;
}
.landing-pricing-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}
.landing-price-card {
  display: flex;
  flex-direction: column;
  gap: 10px;
  position: relative;
}
.landing-save-badge {
  align-self: flex-start;
  display: inline-flex;
  padding: 5px 10px;
  border-radius: 999px;
  background: rgba(212, 175, 55, 0.18);
  color: var(--accent, #d4af37);
  font-size: 0.78rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.landing-save-badge.is-neutral {
  color: #fff;
  background: rgba(255, 255, 255, 0.08);
}
.landing-price {
  font-size: clamp(1.8rem, 3vw, 2.45rem);
  font-weight: 900;
  color: #fff;
  letter-spacing: -0.04em;
}
.landing-price-card .btn {
  margin-top: auto;
}
.landing-register {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: clamp(24px, 4vw, 38px);
}
.auth-page .auth-intro,
.login-intro {
  display: none !important;
}
@media (max-width: 980px) {
  .landing-header {
    grid-template-columns: auto 1fr auto;
  }
  .landing-hero {
    grid-template-columns: 1fr;
  }
  .landing-feature-grid,
  .landing-pricing-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
@media (max-width: 760px) {
  .landing-header {
    grid-template-columns: 1fr auto;
    gap: 12px;
  }
  .landing-menu-toggle {
    display: inline-flex;
    justify-self: end;
  }
  .landing-nav-panel {
    display: none;
    grid-column: 1 / -1;
    gap: 12px;
    padding-top: 10px;
    border-top: 1px solid rgba(212, 175, 55, 0.18);
  }
  .landing-menu-toggle-input:checked ~ .landing-nav-panel {
    display: grid;
  }
  .landing-menu {
    display: grid;
    grid-template-columns: 1fr;
    gap: 6px;
  }
  .landing-menu a {
    display: block;
    width: 100%;
    padding: 12px 14px;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.035);
  }
  .landing-login-btn {
    width: 100%;
  }
}
@media (max-width: 640px) {
  body.landing-public .main-content {
    width: min(100% - 18px, 1180px);
    padding-top: 8px;
  }
  .landing-header {
    top: 8px;
    border-radius: 18px;
    padding: 12px;
  }
  .landing-brand {
    font-size: 0.95rem;
  }
  .landing-hero-copy,
  .landing-hero-panel,
  .landing-section,
  .landing-register {
    border-radius: 22px;
  }
  .landing-hero-copy {
    padding: 26px 20px;
  }
  .landing-hero-panel {
    min-height: 230px;
  }
  .landing-feature-grid,
  .landing-pricing-grid {
    grid-template-columns: 1fr;
  }
  .landing-register {
    flex-direction: column;
    align-items: flex-start;
  }
  .landing-hero-actions .btn,
  .landing-register-actions .btn {
    width: 100%;
  }
}

/* ATP v5.6 compact Cycle product cards */
.product-directory-card{
  gap:10px;
  position:relative;
}
.product-directory-card .product-card-media{
  min-height:118px;
  padding:10px;
}
.product-directory-card .product-card-image,
.product-directory-card .product-card-image.product-thumb-placeholder{
  height:118px;
}
.product-directory-card .product-card-body{
  padding:12px 14px 0;
}
.product-directory-card .product-directory-head{
  gap:8px;
  margin-bottom:6px;
}
.product-directory-card .product-directory-head h3{
  font-size:.92rem;
  line-height:1.18;
}
.product-directory-card .badge{
  font-size:.68rem;
  padding:4px 7px;
}
.product-directory-card .muted.small{
  font-size:.76rem;
  line-height:1.35;
  margin:0 0 6px;
}
.product-directory-card .product-card-more{
  margin-top:8px;
}
.product-directory-card .tracked-product-more summary{
  padding:7px 10px;
  font-size:.68rem;
  letter-spacing:.05em;
}
.product-directory-card .product-directory-actions{
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:8px;
  padding:0 14px 14px;
}
.product-directory-card .product-directory-actions .btn,
.product-directory-card .product-directory-actions button{
  width:100%;
  min-height:34px;
  padding:7px 9px;
  font-size:.68rem;
  letter-spacing:.045em;
  border-radius:10px;
  line-height:1.15;
}
.product-directory-card .product-directory-actions form{
  width:100%;
  min-width:0;
}
.product-directory-card .product-directory-actions form:last-child:nth-child(odd),
.product-directory-card .product-directory-actions > .btn:last-child:nth-child(odd){
  grid-column:1 / -1;
}
.product-stock-card{
  border-width:1px;
}
.product-stock-good{
  border-color:rgba(52,211,153,.72);
  box-shadow:0 0 0 1px rgba(52,211,153,.14) inset,0 0 24px rgba(52,211,153,.18),0 12px 26px rgba(0,0,0,.16);
}
.product-stock-low{
  border-color:rgba(245,158,11,.78);
  box-shadow:0 0 0 1px rgba(245,158,11,.15) inset,0 0 22px rgba(245,158,11,.16),0 12px 26px rgba(0,0,0,.16);
}
.product-stock-critical{
  border-color:rgba(255,41,61,.82);
  box-shadow:0 0 0 1px rgba(255,41,61,.18) inset,0 0 24px rgba(255,41,61,.2),0 12px 26px rgba(0,0,0,.16);
}
.product-dose-badge{
  position:absolute;
  top:9px;
  right:9px;
  z-index:3;
  display:grid;
  place-items:center;
  min-width:48px;
  min-height:42px;
  padding:6px 8px;
  border-radius:14px;
  border:1px solid currentColor;
  background:rgba(12,12,12,.9);
  color:var(--app-primary);
  text-align:center;
  line-height:1;
  box-shadow:0 12px 24px rgba(0,0,0,.28);
}
.product-dose-badge strong{
  display:block;
  font-size:1rem;
  line-height:1;
}
.product-dose-badge small{
  display:block;
  margin-top:3px;
  font-size:.55rem;
  line-height:1;
  text-transform:uppercase;
  letter-spacing:.05em;
}
.product-dose-badge-good{
  color:#34d399;
}
.product-dose-badge-low{
  color:#f59e0b;
}
.product-dose-badge-critical{
  color:#ff293d;
}
@media(max-width:980px){
  .product-directory-card .product-card-media{
    min-height:110px;
  }
  .product-directory-card .product-card-image,
  .product-directory-card .product-card-image.product-thumb-placeholder{
    height:110px;
  }
}
@media(max-width:640px){
  .product-directory-card .product-card-media{
    min-height:120px;
  }
  .product-directory-card .product-card-image,
  .product-directory-card .product-card-image.product-thumb-placeholder{
    height:120px;
  }
  .product-directory-card .product-directory-actions{
    grid-template-columns:1fr;
  }
  .product-directory-card .product-directory-actions .btn,
  .product-directory-card .product-directory-actions button{
    min-height:40px;
    font-size:.74rem;
  }
}

/* ATP v5.8 mobile horizontal overflow guard */
html,
body{
  width:100%;
  max-width:100%;
  overflow-x:hidden;
}
.app-shell,
.topbar,
.main-content,
.card,
.auth-wrap,
.auth-card,
.admin-main,
.landing-page-wrap,
.product-directory,
.product-directory-card,
.tracked-product-row-rich,
.stack-cart-summary,
.today-template-browser,
.calendar-card,
.settings-cards{
  max-width:100%;
  min-width:0;
}
img,
video,
canvas,
svg{
  max-width:100%;
}
.btn,
.badge,
.user-pill,
.product-directory-head,
.section-head,
.metric{
  min-width:0;
}
.btn,
.badge,
.user-pill,
.product-directory-head h3,
.tracked-product-content strong,
.stack-cart-copy strong{
  overflow-wrap:anywhere;
}
@media(max-width:800px){
  body{
    position:relative;
  }
  .main-content{
    width:100%;
    max-width:100vw;
    overflow-x:hidden;
  }
  .card,
  .product-directory-card,
  .tracked-product-row-rich,
  .stack-cart-item,
  .today-template-card,
  .calendar-row,
  .profile-edit-card{
    width:100%;
  }
  .button-row,
  .stack-actions,
  .detail-actions,
  .product-directory-actions,
  .today-actions,
  .intake-actions{
    max-width:100%;
  }
}

/* ATP v5.9 mobile Today status and square Cycle product media */
.compact-status-copy{
  display:grid;
  gap:10px;
  min-width:0;
}
.compact-status-copy h2,
.compact-status-copy p{
  margin:0;
}
.compact-status-copy .status-pill{
  width:max-content;
  max-width:100%;
  justify-content:flex-start;
  padding:7px 10px;
}
.product-directory-card .product-card-media{
  position:relative;
  width:100%;
  aspect-ratio:1 / 1;
  min-height:0;
  padding:12px;
  align-items:stretch;
  justify-items:stretch;
}
.product-directory-card .product-card-image,
.product-directory-card .product-card-image.product-thumb-placeholder{
  width:100%;
  height:100%;
  min-height:0;
  object-fit:contain;
}
.product-directory-card .product-card-body,
.product-directory-card .product-directory-actions{
  width:100%;
}
.product-directory-card .product-dose-badge{
  top:10px;
  right:10px;
}
@media(max-width:760px){
  .intake-card-compact .metric{
    display:grid;
    grid-template-columns:1fr;
  }
  .intake-card-compact .status-pill{
    width:max-content;
    justify-content:flex-start;
  }
  .compact-note{
    margin-top:12px;
  }
}
@media(max-width:640px){
  .product-directory-card .product-card-media{
    aspect-ratio:1 / 1;
    min-height:0;
  }
  .product-directory-card .product-card-image,
  .product-directory-card .product-card-image.product-thumb-placeholder{
    height:100%;
  }
  .product-directory-card .product-dose-badge{
    top:8px;
    right:8px;
  }
}

/* ATP v5.10 centered Cycle product card headings */
.product-directory-card .product-directory-head{
  display:grid;
  grid-template-columns:1fr;
  justify-items:center;
  text-align:center;
}
.product-directory-card .product-directory-head h3{
  width:100%;
}
.product-directory-card .product-directory-head .badge{
  justify-self:center;
  max-width:100%;
  white-space:nowrap;
  word-break:normal;
  overflow-wrap:normal;
  text-align:center;
}
.product-directory-card .product-intake-method{
  text-align:center;
  margin:4px 0 8px;
}

/* ATP v5.14 install app platform options */
.install-app-card{
  min-width:0;
}
.install-app-card .section-head{
  align-items:flex-start;
}
.install-app-note{
  border:1px solid rgba(214,178,94,.36);
  background:rgba(214,178,94,.08);
  border-radius:12px;
  padding:11px 12px;
  color:var(--app-muted);
  font-size:.9rem;
  line-height:1.45;
  margin:12px 0 16px;
}
.install-app-note strong{
  color:var(--app-primary);
}
.install-platform-grid{
  display:grid;
  grid-template-columns:repeat(3,minmax(0,1fr));
  gap:12px;
}
.install-platform-card{
  display:flex;
  flex-direction:column;
  gap:10px;
  min-width:0;
  border:1px solid var(--app-border);
  border-radius:12px;
  padding:14px;
  background:rgba(0,0,0,.16);
}
.install-platform-icon{
  width:40px;
  height:40px;
  display:grid;
  place-items:center;
  border:1px solid rgba(214,178,94,.42);
  border-radius:10px;
  color:var(--app-primary);
  font-size:1.25rem;
}
.install-platform-card h3{
  margin:0;
  color:var(--app-text);
  font-size:1rem;
}
.install-platform-card p{
  margin:0;
  color:var(--app-muted);
  line-height:1.45;
  font-size:.88rem;
  flex:1;
}
.ios-install-steps{
  margin:0;
  padding-left:20px;
  color:var(--app-text);
  font-size:.88rem;
  line-height:1.45;
}
.ios-install-steps li{
  margin:0 0 5px;
}
.install-platform-card .btn{
  padding:10px 11px;
  min-height:40px;
  font-size:.78rem;
  white-space:normal;
  line-height:1.2;
  text-align:center;
}
@media(max-width:1050px){
  .install-platform-grid{
    grid-template-columns:1fr;
  }
}
@media(max-width:640px){
  .install-app-card .section-head{
    display:grid;
    grid-template-columns:1fr;
  }
  .install-platform-card{
    padding:12px;
  }
}

/* ATP v5.16 Safari installed-app clipping fixes */
html,
body,
.app-shell{
  min-width:0;
  -webkit-text-size-adjust:100%;
}
body{
  overscroll-behavior-x:none;
}
.main-content,
.card,
.settings-cards,
.install-app-card,
.install-platform-grid,
.install-platform-card,
.section-head,
.button-row,
.metric,
.product-directory-card,
.tracked-product-row-rich,
.intake-card,
.calendar-card,
.billing-settings-card{
  min-width:0;
  max-width:100%;
}
.install-platform-card,
.install-platform-card *,
.card,
.card *{
  overflow-wrap:anywhere;
}
.btn{
  max-width:100%;
  min-width:0;
}
@media(max-width:700px){
  .main-content{
    width:100%;
    max-width:100%;
    padding-left:max(14px, env(safe-area-inset-left));
    padding-right:max(14px, env(safe-area-inset-right));
  }
  .settings-cards,
  .install-platform-grid{
    grid-template-columns:minmax(0,1fr);
  }
  .install-app-card,
  .install-platform-card{
    overflow:hidden;
  }
  .install-platform-card .btn{
    letter-spacing:.04em;
    padding-left:9px;
    padding-right:9px;
  }
}

/* ATP v5.17 install reminder and app update prompts */
.pwa-modal-backdrop[hidden]{
  display:none !important;
}
.pwa-modal-backdrop{
  position:fixed;
  inset:0;
  z-index:1000;
  display:grid;
  place-items:center;
  padding:18px;
  background:rgba(0,0,0,.72);
  backdrop-filter:blur(8px);
}
.pwa-modal{
  position:relative;
  width:min(460px,100%);
  margin:0;
  border-color:rgba(214,178,94,.52);
  box-shadow:0 24px 80px rgba(0,0,0,.62);
}
.pwa-modal h2{
  margin:0 0 10px;
  text-transform:uppercase;
  letter-spacing:.04em;
}
.pwa-modal p{
  line-height:1.5;
}
.pwa-install-actions{
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:10px;
  margin-top:16px;
}
.pwa-install-help{
  margin-top:13px;
  padding:10px 11px;
  border:1px solid rgba(214,178,94,.32);
  border-radius:10px;
  background:rgba(214,178,94,.08);
  color:var(--app-muted);
  font-size:.88rem;
  line-height:1.45;
}
.pwa-install-help strong{
  color:var(--app-primary);
}
.is-standalone-app .install-app-card,
body.is-standalone-app .install-app-card,
html.is-native-app .install-app-card,
html.is-capacitor-app .install-app-card,
html.is-native-app [data-hide-in-native-app],
html.is-capacitor-app [data-hide-in-native-app]{
  display:none !important;
}
@media(display-mode:standalone){
  .install-app-card{
    display:none !important;
  }
}
@media(max-width:520px){
  .pwa-modal-backdrop{
    align-items:end;
    padding:12px;
  }
  .pwa-modal{
    width:100%;
    border-radius:16px;
    padding:18px;
  }
  .pwa-install-actions{
    grid-template-columns:1fr;
  }
}

/* ATP v5.18 calendar reminder sync */
.calendar-sync-card .input[readonly]{
  cursor:text;
}
.calendar-sync-checks{
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:8px 12px;
  border:1px solid var(--app-border);
  border-radius:12px;
  padding:12px;
  background:rgba(0,0,0,.14);
}
.calendar-sync-actions{
  display:flex;
  flex-wrap:wrap;
  gap:10px;
  margin-top:6px;
}
.calendar-sync-platforms{
  display:grid;
  grid-template-columns:repeat(3,minmax(0,1fr));
  gap:12px;
  margin:16px 0;
}
.calendar-sync-platforms div{
  min-width:0;
  border:1px solid var(--app-border);
  border-radius:12px;
  padding:12px;
  background:rgba(0,0,0,.14);
}
.calendar-sync-platforms strong{
  display:block;
  margin-bottom:6px;
  color:var(--app-primary);
  text-transform:uppercase;
  letter-spacing:.05em;
}
.calendar-sync-platforms span{
  display:block;
  color:var(--app-muted);
  font-size:.88rem;
  line-height:1.45;
}
@media(max-width:760px){
  .calendar-sync-checks,
  .calendar-sync-platforms{
    grid-template-columns:1fr;
  }
  .calendar-sync-actions{
    display:grid;
  }
  .calendar-sync-card .input[readonly]{
    font-size:.78rem;
  }
}

/* ATP v5.19 scheduled dose details */
.dose-line{
  margin:.28rem 0;
  line-height:1.35;
}
.dose-line strong{
  color:var(--app-primary);
}
.calendar-event .calendar-event-dose{
  grid-column:1 / -1;
  color:var(--app-muted);
  font-size:.7rem;
  line-height:1.25;
  white-space:normal;
}
.calendar-event .calendar-event-product{
  min-width:0;
}
@media(max-width:640px){
  .dose-line{
    font-size:.82rem;
  }
  .calendar-event .calendar-event-dose{
    font-size:.62rem;
  }
}

/* ATP v5.20 mobile title wrapping, title case labels, and dose form copy */
h1,
h2,
h3,
.page-title,
.card-title,
.brand span,
.today-welcome h1,
.product-directory-head h3,
.product-directory-head h3 a,
.tracked-product-content strong,
.tracked-product-content a,
.compact-status-copy h2,
.intake-card h2,
.stack-template-card h3,
.today-template-card h3,
.btn,
.badge,
.tracking-progress em{
  overflow-wrap:normal;
  word-break:normal;
  hyphens:none;
}
.today-welcome h1,
.page-title,
.product-directory-head h3,
.tracked-product-content strong,
.intake-card h2,
.stack-template-card h3,
.today-template-card h3{
  text-wrap:balance;
}
.tracking-progress em{
  text-align:center;
  line-height:1.12;
}
@media(max-width:760px){
  .today-welcome h1{
    font-size:clamp(2rem,9vw,2.85rem);
    letter-spacing:.045em;
    line-height:1;
  }
  .page-title{
    font-size:clamp(2rem,10vw,3rem);
    letter-spacing:.035em;
  }
  .card h2,
  .section-head h2{
    font-size:clamp(1.35rem,6.2vw,2rem);
    line-height:1.08;
  }
  .product-directory-head h3,
  .tracked-product-content strong,
  .tracked-product-content a,
  .compact-status-copy h2,
  .intake-card h2,
  .stack-template-card h3,
  .today-template-card h3{
    font-size:clamp(1rem,5.4vw,1.45rem);
    line-height:1.14;
    letter-spacing:.02em;
  }
  .topbar{
    gap:10px;
  }
  .brand span{
    font-size:clamp(1rem,4.5vw,1.5rem);
    letter-spacing:.025em;
    line-height:1.05;
  }
  .tracking-progress{
    display:grid;
    grid-template-columns:repeat(3,minmax(0,1fr));
    gap:10px;
  }
  .tracking-progress span{
    min-width:0;
    width:100%;
    padding:9px 7px;
  }
  .tracking-progress strong{
    font-size:1.08rem;
  }
  .tracking-progress em{
    font-size:.72rem;
  }
}
@media(max-width:420px){
  .today-welcome h1{
    font-size:clamp(1.9rem,8.1vw,2.35rem);
    letter-spacing:.035em;
  }
  .tracking-progress{
    grid-template-columns:repeat(2,minmax(0,1fr));
  }
}

/* ATP v5.21 mobile readable labels and dose display cleanup */
.page-title,
.card h2,
.section-head h2,
.product-directory-head h3,
.product-directory-head h3 a,
.tracked-product-content strong,
.tracked-product-content a,
.compact-status-copy h2,
.intake-card h2,
.stack-template-card h3,
.today-template-card h3,
.template-card-top h3,
.calendar-row strong,
.calendar-event strong,
.calendar-event span,
.calendar-event .calendar-event-product,
.calendar-event .calendar-event-dose,
.stack-cart-copy strong,
.product-meta-grid .product-meta-item dd,
.product-meta-item dd,
.taxonomy-chip strong,
.media-library-copy h3,
.media-attached-row span,
.subscription-summary-card strong{
  white-space:normal;
  word-break:normal;
  overflow-wrap:normal;
  hyphens:none;
}
.calendar-event span,
.calendar-event .calendar-event-product,
.stack-cart-copy strong{
  overflow:visible;
  text-overflow:clip;
}
.tracking-progress em,
.goal-stack-card .badge,
.today-template-card .badge,
.stack-template-card .badge{
  text-transform:none;
}
.calendar-event .calendar-event-dose{
  display:block;
}
@media(max-width:760px){
  .page-title{
    font-size:clamp(1.85rem,8vw,2.55rem);
  }
  .card h2,
  .section-head h2{
    font-size:clamp(1.22rem,5.4vw,1.75rem);
  }
  .product-directory-head h3,
  .product-directory-head h3 a,
  .tracked-product-content strong,
  .tracked-product-content a,
  .compact-status-copy h2,
  .intake-card h2,
  .stack-template-card h3,
  .today-template-card h3,
  .template-card-top h3{
    font-size:clamp(.95rem,4.7vw,1.22rem);
    line-height:1.18;
  }
  .badge,
  .tracking-progress em{
    letter-spacing:.02em;
  }
  .calendar-event{
    font-size:.66rem;
  }
  .calendar-event strong{
    font-size:.62rem;
  }
}

/* ATP v5.23 title-case labels and stronger mobile wrapping */
.tracking-progress em,
.goal-stack-card .badge,
.today-template-card .badge,
.stack-template-card .badge,
.product-directory-card .badge,
.calendar-row .badge,
.compact-status-copy .badge,
.subscription-summary-card span{
  text-transform:none;
}
.page-title,
.card h2,
.section-head h2,
.product-directory-head h3,
.product-directory-head h3 a,
.tracked-product-content strong,
.tracked-product-content a,
.compact-status-copy h2,
.intake-card h2,
.stack-template-card h3,
.today-template-card h3,
.template-card-top h3,
.calendar-row strong,
.calendar-event strong,
.calendar-event span,
.calendar-event .calendar-event-product,
.calendar-event .calendar-event-dose,
.stack-cart-copy strong,
.template-product-copy span,
.product-meta-grid strong,
.product-meta-grid .product-meta-item dd,
.product-meta-item dd,
.taxonomy-chip strong,
.media-library-copy h3,
.media-attached-row span,
.subscription-summary-card strong,
.dose-line{
  white-space:normal;
  word-break:normal;
  overflow-wrap:normal;
  hyphens:none;
  max-width:100%;
}
.calendar-event span,
.calendar-event .calendar-event-product,
.calendar-event .calendar-event-dose,
.stack-cart-copy strong,
.template-product-copy span{
  overflow:visible;
  text-overflow:clip;
}
@media(max-width:760px){
  .page-title{
    font-size:clamp(1.65rem,7.3vw,2.3rem);
    line-height:1.06;
  }
  .tracking-progress em{
    font-size:clamp(.66rem,3vw,.78rem);
    line-height:1.12;
  }
  .badge{
    line-height:1.18;
  }
  .dose-line{
    font-size:clamp(.82rem,3.8vw,.95rem);
    line-height:1.3;
  }
}

/* ATP v5.25 event timing and As Needed form controls */
.timing-offset-field{
  display:grid;
  grid-template-columns:minmax(132px,220px) minmax(180px,1fr);
  gap:10px;
  align-items:center;
}
.timing-offset-field .input{
  min-width:132px;
}
.timing-offset-field select{
  min-width:180px;
  width:100%;
}
.form-row.is-disabled{
  opacity:.62;
}
.form-row.is-disabled label{
  color:var(--app-muted);
}
.form-row.is-disabled input{
  cursor:not-allowed;
}
@media(max-width:700px){
  .inline-field.timing-offset-field{
    display:grid;
    grid-template-columns:1fr;
  }
  .timing-offset-field .input,
  .timing-offset-field select{
    min-width:0;
  }
}

/* ATP v5.27 structured manual schedule editor */
.manual-schedule-builder{
  margin-top:18px;
}
.manual-schedule-builder summary{
  cursor:pointer;
}
.manual-schedule-builder .manual-dose-table{
  gap:12px;
}
.manual-schedule-row .manual-row-remove{
  align-self:end;
  min-height:42px;
  white-space:nowrap;
}
.manual-dose-new-block{
  display:grid;
  gap:8px;
  padding:12px;
  border:1px dashed rgba(224,192,105,.28);
  border-radius:16px;
  background:rgba(224,192,105,.035);
}
.manual-dose-new-block .manual-dose-row{
  margin:0;
}
.manual-dose-empty{
  padding:12px 14px;
  border:1px dashed rgba(255,255,255,.14);
  border-radius:14px;
  background:rgba(255,255,255,.025);
}
.manual-schedule-builder:not(.is-manual-enabled) .manual-dose-table,
.manual-schedule-builder:not(.is-manual-enabled) [data-add-manual-schedule-row]{
  opacity:.72;
}
.manual-schedule-builder.is-manual-enabled{
  border-color:rgba(224,192,105,.42);
}
.manual-dose-row select.input,
.manual-dose-row select{
  width:100%;
  min-height:42px;
}
@media(max-width:760px){
  .manual-dose-row{
    grid-template-columns:1fr;
  }
  .manual-dose-row .manual-row-remove,
  .manual-dose-row .delete-dose{
    grid-column:auto;
    width:100%;
    justify-content:center;
  }
}

/* ATP v5.28 locked dose and calculated planned-dose fields */
.readonly-field,
.input.readonly-field{
  background:rgba(255,255,255,.035);
  color:var(--app-muted);
  border-color:rgba(255,255,255,.16);
  cursor:not-allowed;
}
.dose-unit-readonly,
.planned-doses-readonly{
  font-weight:700;
  letter-spacing:.01em;
}
.form-row .readonly-field + .muted,
.form-row .planned-doses-readonly + input + .muted{
  display:block;
  margin-top:6px;
}
.manual-dose-row .dose-unit-readonly{
  width:100%;
  min-height:42px;
}

/* ATP v5.29 admin product conditional fields */
.admin-product-edit-form{
  display:grid;
  gap:18px;
}
.admin-product-edit-form .nested-card{
  margin:0;
}
.admin-product-section .section-head{
  align-items:flex-start;
}
.admin-product-edit-form [hidden],
.admin-product-edit-form .is-hidden{
  display:none !important;
}
.admin-product-edit-form select[name="product_type"],
.admin-product-edit-form select[name="route"],
.admin-product-edit-form select[name="strength_unit"],
.admin-product-edit-form select[name="reconstitution_unit"],
.admin-product-edit-form select[name="dose_unit"]{
  width:100%;
  min-height:42px;
}
.admin-product-custom-dose{
  padding:14px 16px;
  border:1px solid rgba(255,255,255,.12);
  border-radius:16px;
  background:rgba(255,255,255,.035);
}
@media(max-width:760px){
  .admin-product-edit-form{
    gap:14px;
  }
  .admin-product-section .section-head{
    gap:10px;
  }
}

/* ATP v5.30 admin menu and product list cleanup */
.admin-sidebar-nav{display:grid;gap:8px}.admin-sidebar .admin-sidebar-nav a,.admin-sidebar .admin-nav-link{display:block;color:var(--app-muted);padding:10px 12px;border-radius:10px;margin:0}.admin-sidebar .admin-sidebar-nav a:hover,.admin-sidebar .admin-nav-link:hover,.admin-sidebar .admin-nav-link.is-active{background:var(--app-card);color:var(--app-primary)}.admin-menu-group{border:1px solid rgba(255,255,255,.08);border-radius:12px;background:rgba(255,255,255,.02);overflow:hidden}.admin-menu-group summary{list-style:none;cursor:pointer;padding:11px 12px;font-weight:900;color:var(--app-text);text-transform:uppercase;letter-spacing:.05em;font-size:.82rem;display:flex;align-items:center;justify-content:space-between}.admin-menu-group summary::-webkit-details-marker{display:none}.admin-menu-group summary:after{content:"+";color:var(--app-primary);font-size:1rem}.admin-menu-group[open] summary{color:var(--app-primary);border-bottom:1px solid var(--app-border);background:rgba(214,178,94,.06)}.admin-menu-group[open] summary:after{content:"−"}.admin-submenu{display:grid;gap:3px;padding:7px}.admin-submenu .admin-nav-link{font-size:.9rem;padding:9px 10px}.admin-filter-card .section-head{align-items:flex-start}.admin-product-filter-grid{grid-template-columns:repeat(3,minmax(0,1fr))}.admin-sort-link{color:var(--app-primary);font-weight:900;white-space:nowrap}.admin-product-list-table td:first-child strong{display:block;min-width:180px}.admin-products-card .badge{text-transform:none}.admin-product-list-table th,.admin-product-list-table td{vertical-align:middle}@media(max-width:900px){.admin-product-filter-grid{grid-template-columns:1fr}.admin-sidebar-nav{gap:6px}.admin-menu-group summary{padding:10px}.admin-submenu{padding:6px}.admin-product-list-table td:first-child strong{min-width:0}}

/* ATP v5.31 frontend dose/frequency cleanup */
.dose-combo-field{
  display:grid;
  grid-template-columns:minmax(0,1fr) auto;
  align-items:center;
  gap:8px;
}
.dose-combo-field span{
  min-height:42px;
  display:flex;
  align-items:center;
  padding:0 14px;
  border:1px solid rgba(255,255,255,.14);
  border-radius:12px;
  background:rgba(255,255,255,.04);
  color:var(--app-muted);
  font-weight:900;
}
.manual-dose-row--combined{
  grid-template-columns:minmax(150px,1fr) minmax(120px,.7fr) minmax(170px,1fr) auto;
}
.schedule-preview--as-needed .schedule-preview-list span{
  white-space:normal;
}
.form-row .readonly-field[aria-readonly="true"]{
  opacity:.95;
}
@media(max-width:760px){
  .manual-dose-row--combined{
    grid-template-columns:1fr;
  }
  .dose-combo-field{
    grid-template-columns:1fr;
  }
  .dose-combo-field span{
    justify-content:center;
  }
}

/* ATP v5.3.6 admin dashboard and version footer */
.app-version-footer{
  width:min(1080px,100%);
  margin:8px auto 92px;
  padding:0 18px;
  display:flex;
  justify-content:center;
  gap:10px;
  color:var(--app-muted);
  font-size:.72rem;
  letter-spacing:.06em;
  text-transform:uppercase;
  opacity:.68;
}
.app-version-footer--admin{
  width:100%;
  margin:24px 0 0;
  padding:18px 0 0;
  border-top:1px solid rgba(255,255,255,.08);
  justify-content:flex-start;
}
.admin-dashboard-grid{
  display:grid;
  grid-template-columns:repeat(4,minmax(0,1fr));
  gap:16px;
  margin-bottom:18px;
}
.admin-stat-card{
  display:block;
  text-decoration:none;
  color:inherit;
  min-height:128px;
  transition:transform .16s ease,border-color .16s ease,background .16s ease;
}
.admin-stat-card:hover{
  transform:translateY(-2px);
  border-color:rgba(214,178,94,.55);
  background:linear-gradient(180deg,rgba(214,178,94,.08),rgba(255,255,255,.025));
}
.admin-stat-card .result-main{
  margin:10px 0 4px;
}
.admin-stat-card .muted{
  margin:0;
}
.admin-dashboard-alerts,
.admin-shortcuts-card,
.admin-dashboard-version{
  margin-top:18px;
}
.admin-shortcut-grid{
  display:grid;
  grid-template-columns:repeat(3,minmax(0,1fr));
  gap:12px;
}
.admin-shortcut{
  display:flex;
  align-items:flex-start;
  gap:12px;
  padding:14px;
  border:1px solid rgba(255,255,255,.12);
  border-radius:14px;
  background:rgba(255,255,255,.03);
  color:var(--app-text);
  text-decoration:none;
}
.admin-shortcut:hover{
  border-color:rgba(214,178,94,.5);
  background:rgba(214,178,94,.07);
}
.admin-shortcut i{
  width:24px;
  color:var(--app-primary);
  margin-top:2px;
}
.admin-shortcut strong,
.admin-shortcut small{
  display:block;
}
.admin-shortcut small{
  margin-top:4px;
  color:var(--app-muted);
  line-height:1.35;
}
.admin-dashboard-version{
  display:flex;
  justify-content:space-between;
  gap:18px;
  align-items:center;
}
.admin-dashboard-version strong{
  display:block;
  margin-top:4px;
  font-size:1.35rem;
  color:var(--app-primary);
}
.admin-body .medical-disclaimer-footer{
  display:none !important;
}
@media(max-width:1100px){
  .admin-dashboard-grid{grid-template-columns:repeat(2,minmax(0,1fr));}
  .admin-shortcut-grid{grid-template-columns:repeat(2,minmax(0,1fr));}
}
@media(max-width:720px){
  .admin-dashboard-grid,
  .admin-shortcut-grid{grid-template-columns:1fr;}
  .admin-dashboard-version{align-items:flex-start;flex-direction:column;}
  .app-version-footer{margin-bottom:100px;}
  .app-version-footer--admin{margin-bottom:0;}
}

/* ATP v5.3.5 oral count and event timing controls */
.oral-count-dose-field{
  display:grid;
  grid-template-columns:minmax(140px,1fr) auto;
  gap:10px;
  align-items:center;
}
.oral-count-dose-preview{
  min-height:44px;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  padding:0 14px;
  border:1px solid rgba(214,178,94,.45);
  border-radius:12px;
  background:rgba(214,178,94,.08);
  color:var(--app-primary);
  font-weight:800;
  white-space:nowrap;
}
.timing-allowed-grid{
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:8px 12px;
}
.timing-allowed-panel{
  padding:12px;
  border:1px solid rgba(255,255,255,.1);
  border-radius:14px;
  background:rgba(255,255,255,.025);
}
.timing-offset-disabled input,
.timing-offset-disabled .input{
  opacity:.55;
  cursor:not-allowed;
}
.schedule-preview--as-needed .schedule-preview-list span:first-child{
  border-color:rgba(214,178,94,.55);
}
@media(max-width:720px){
  .oral-count-dose-field,
  .timing-allowed-grid{
    grid-template-columns:1fr;
  }
  .oral-count-dose-preview{
    justify-content:flex-start;
  }
}

/* ATP v5.3.8 smart push notification settings */
.push-settings-card .button-row {
  align-items: center;
}
.push-device-list {
  margin-top: 20px;
}
.push-device-list h3 {
  margin: 0 0 12px;
}
.push-checks {
  margin: 12px 0 18px;
}
.push-not-supported [data-push-enable],
.push-not-supported [data-push-test] {
  opacity: .55;
  pointer-events: none;
}
.admin-dashboard-grid .admin-stat-card[href*="push-delivery"] .card-title,
.push-settings-card .eyebrow {
  color: var(--app-primary);
}
@media (max-width: 760px) {
  .push-settings-card .button-row {
    display: grid;
    grid-template-columns: 1fr;
  }
  .push-settings-card .button-row .btn {
    width: 100%;
  }
}

/* ATP v5.3.8 smart push reminders */
.push-history-card .admin-table td{vertical-align:top}.push-history-table strong{color:var(--app-text)}.push-preferences-form select[name=push_reminder_minutes],.admin-product-edit-form select[name=push_reminder_minutes]{min-width:220px}

/* ATP v5.3.9 native alarm mode */
.native-alarm-card .button-row {
  gap: 0.65rem;
  flex-wrap: wrap;
}
.native-alarm-card .native-alarm-note {
  margin-top: 1rem;
  padding: 0.85rem 1rem;
  border: 1px solid rgba(214,178,94,.22);
  border-radius: 14px;
  background: rgba(255,255,255,.035);
}
.native-alarm-sync-history {
  margin-top: 1rem;
}
.native-alarms-unavailable .native-alarm-card [data-native-alarm-sync],
.native-alarms-unavailable .native-alarm-card [data-native-alarm-exact-settings],
.native-alarms-unavailable .native-alarm-card [data-native-alarm-test],
.native-alarms-unavailable .native-alarm-card [data-native-alarm-clear] {
  opacity: .55;
}
.native-alarm-card .is-disabled-preview {
  cursor: not-allowed;
}
@media (max-width: 640px) {
  .native-alarm-card .button-row .btn {
    width: 100%;
    justify-content: center;
  }
}

/* ATP v5.4.0 reminder consent popups and admin monitoring */
.reminder-consent-modal .pwa-modal {
  max-width: 520px;
}
.reminder-consent-modal .pwa-install-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 18px;
}
.reminder-consent-modal .pwa-install-actions .btn {
  flex: 1 1 190px;
}
.admin-reminder-status {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  min-width: 240px;
}
.admin-reminder-status > div,
.reminder-decision-grid > div {
  display: grid;
  gap: 5px;
  padding: 10px;
  border: 1px solid rgba(255,255,255,.1);
  border-radius: 12px;
  background: rgba(255,255,255,.025);
}
.admin-reminder-status span:first-child,
.reminder-decision-grid span:first-child {
  color: var(--app-muted);
  font-size: .74rem;
  font-weight: 800;
  letter-spacing: .06em;
  text-transform: uppercase;
}
.admin-reminder-status small,
.reminder-decision-grid small {
  color: var(--app-muted);
  font-size: .78rem;
  line-height: 1.3;
}
.admin-user-reminder-card {
  margin-top: 18px;
}
.reminder-decision-grid {
  margin-top: 14px;
}
.admin-reminder-details {
  margin-top: 16px;
}
.admin-reminder-details summary {
  cursor: pointer;
  font-weight: 800;
  color: var(--app-primary);
}
.admin-reminder-details h3 {
  margin: 18px 0 10px;
}
.user-admin-table .admin-reminder-status {
  grid-template-columns: 1fr;
  min-width: 210px;
}
.user-admin-table .admin-reminder-status > div {
  padding: 8px;
}
.admin-dashboard-alerts .admin-reminder-status {
  grid-template-columns: 1fr;
  min-width: 220px;
}
@media (max-width: 860px) {
  .admin-reminder-status {
    grid-template-columns: 1fr;
  }
  .reminder-consent-modal .pwa-install-actions {
    display: grid;
    grid-template-columns: 1fr;
  }
}

/* ATP v5.4.1 frontend settings subpages */
.settings-subnav {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 16px 0 22px;
}
.settings-subnav-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 13px;
  border: 1px solid rgba(255,255,255,.12);
  border-radius: 999px;
  color: var(--app-text);
  background: rgba(255,255,255,.035);
  text-decoration: none;
  font-weight: 800;
  font-size: .88rem;
  line-height: 1.15;
}
.settings-subnav-link:hover,
.settings-subnav-link.is-active {
  border-color: rgba(214,178,94,.55);
  color: var(--app-primary);
  background: rgba(214,178,94,.1);
}
.settings-overview-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  margin-bottom: 18px;
}
.settings-overview-card {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 13px;
  align-items: flex-start;
  color: inherit;
  text-decoration: none;
  min-height: 138px;
}
.settings-overview-card h2 {
  margin: 0 0 6px;
  font-size: 1.06rem;
}
.settings-overview-card p {
  margin: 0 0 10px;
}
.settings-overview-icon {
  width: 42px;
  height: 42px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  color: var(--app-primary);
  background: rgba(214,178,94,.1);
  border: 1px solid rgba(214,178,94,.24);
}
.settings-section-stack {
  display: grid;
  gap: 18px;
}
.settings-safety-card {
  margin-top: 18px;
}
@media (max-width: 980px) {
  .settings-overview-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
@media (max-width: 640px) {
  .settings-subnav {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .settings-subnav-link {
    justify-content: center;
    border-radius: 14px;
    text-align: center;
    padding: 11px 10px;
  }
  .settings-overview-grid {
    grid-template-columns: 1fr;
  }
  .settings-overview-card {
    min-height: unset;
  }
}

/* ATP v5.4.3 frontend reminder testing */
.reminder-test-help {
  margin: 10px 0 0;
}
.atp-test-preview-backdrop {
  position: fixed;
  inset: 0;
  z-index: 10010;
  display: grid;
  place-items: center;
  padding: 18px;
  background: rgba(0, 0, 0, .72);
  backdrop-filter: blur(10px);
}
.atp-test-preview-backdrop[hidden] {
  display: none !important;
}
.atp-test-preview-card {
  width: min(460px, 100%);
  position: relative;
  box-shadow: 0 22px 80px rgba(0, 0, 0, .45);
}
.atp-test-preview-card h2 {
  margin-top: 0;
}
.atp-test-preview-demo {
  display: grid;
  gap: 4px;
  margin: 16px 0;
  padding: 14px 16px;
  border: 1px solid rgba(214,178,94,.28);
  border-radius: 18px;
  background: rgba(255,255,255,.07);
}
.atp-test-preview-demo strong {
  color: var(--app-primary);
  font-size: .98rem;
}
.atp-test-preview-demo span {
  color: var(--app-muted);
  line-height: 1.35;
}
@media (max-width: 640px) {
  .push-settings-card .button-row,
  .native-alarm-card .button-row {
    display: grid;
    grid-template-columns: 1fr;
  }
}

/* ATP v5.4.3 intake period restrictions */
.intake-period-grid .check-line{align-items:flex-start}.intake-period-help{display:block;margin-top:5px}.is-invalid-intake-time{border-color:rgba(255,41,61,.85)!important;box-shadow:0 0 0 3px rgba(255,41,61,.16)!important}.manual-dose-row .intake-period-help{font-size:.68rem;line-height:1.25}.admin-product-edit-form .intake-period-grid{grid-template-columns:repeat(auto-fit,minmax(190px,1fr))}

/* ATP v5.5.1 calculator PDF export and Today anchor restore */
.install-platform-grid--native{
  grid-template-columns:1.25fr 1fr 1fr;
}

.install-platform-grid--two{
  grid-template-columns:repeat(2,minmax(0,1fr));
}
.ios-home-screen-steps{
  border:1px solid rgba(214,178,94,.30);
  background:rgba(214,178,94,.07);
  border-radius:10px;
  padding:10px 12px;
}
.ios-home-screen-steps ol{
  margin:0 0 8px 18px;
  padding:0;
  color:var(--app-text);
  line-height:1.45;
}
.ios-home-screen-steps li+li{
  margin-top:4px;
}
.install-platform-card--featured{
  border-color:rgba(214,178,94,.48);
  background:linear-gradient(135deg, rgba(214,178,94,.10), rgba(0,0,0,.18));
}
.install-platform-card code{
  color:var(--app-primary);
  font-size:.84em;
  word-break:break-word;
}
.install-platform-card small{
  display:block;
  line-height:1.45;
}
.install-platform-card a.btn{
  text-decoration:none;
}
@media(max-width:1050px){
  .install-platform-grid--native,
  .install-platform-grid--two{
    grid-template-columns:1fr;
  }
}

/* ATP v5.5.1 Today anchor restore and calculator PDF export */
.intake-card[id],
.intake-card-compact[id] {
  scroll-margin-top: 110px;
}

.calc-export-actions {
  margin-top: 1rem;
  display: grid;
  gap: .55rem;
}

.calc-export-actions .btn {
  justify-content: center;
}

@media print {
  .calc-export-actions {
    display: none !important;
  }
}

/* v5.5.4 IU calculation notices should be informational, not danger warnings */
.calc-formula [data-calc-warning].is-info,
[data-calc-warning].is-info{
  color:var(--app-primary) !important;
}
.calc-warning-text.is-info{
  border-color:rgba(214,178,94,.45);
  background:rgba(214,178,94,.08);
  color:var(--app-text) !important;
}
.product-extra-info{
  display:grid;
  gap:14px;
}
.product-extra-info-item{
  border:1px solid var(--app-border);
  border-radius:14px;
  background:rgba(0,0,0,.14);
  padding:14px;
}
.product-extra-info-item h3{
  margin:0 0 8px;
  color:var(--app-primary);
  font-size:1rem;
}
.product-extra-info-item p:last-child{
  margin-bottom:0;
}


/* v5.5.5 Peptide injectable vial guide */
.peptide-vial-guide{
  overflow:hidden;
}
.peptide-vial-guide .section-head{
  align-items:flex-start;
}
.peptide-vial-grid{
  display:grid;
  grid-template-columns:repeat(4,minmax(0,1fr));
  gap:18px;
}
.peptide-vial-step{
  border:1px solid var(--app-border);
  border-radius:18px;
  background:rgba(0,0,0,.22);
  overflow:hidden;
  display:flex;
  flex-direction:column;
  min-height:100%;
}
.peptide-vial-step.is-important{
  border-color:rgba(214,178,94,.42);
  background:rgba(214,178,94,.06);
}
.peptide-vial-image-wrap{
  aspect-ratio:1/1;
  background:rgba(255,255,255,.04);
  overflow:hidden;
}
.peptide-vial-image-wrap img{
  width:100%;
  height:100%;
  display:block;
  object-fit:cover;
}
.peptide-vial-copy{
  padding:14px 14px 16px;
  display:flex;
  flex-direction:column;
  gap:6px;
  flex:1;
}
.peptide-vial-label{
  color:var(--app-primary);
  font-size:.72rem;
  font-weight:800;
  text-transform:uppercase;
  letter-spacing:.12em;
}
.peptide-vial-step.is-important .peptide-vial-label{
  color:#ff4b4b;
}
.peptide-vial-copy h3{
  margin:0;
  font-size:.98rem;
  line-height:1.15;
  text-transform:uppercase;
  letter-spacing:.035em;
}
.peptide-vial-copy p{
  margin:0;
  color:var(--app-muted);
  font-size:.9rem;
  line-height:1.45;
}

@media (max-width:1100px){
  .peptide-vial-grid{
    grid-template-columns:repeat(2,minmax(0,1fr));
  }
}
@media (max-width:640px){
  .peptide-vial-grid{
    grid-template-columns:1fr;
  }
  .peptide-vial-copy{
    padding:12px;
  }
}

/* v5.5.6 Peptide vial guide admin image settings */
.peptide-vial-settings-grid {
    align-items: start;
}
.peptide-vial-setting-row {
    min-width: 0;
}
.peptide-vial-setting-preview {
    width: 100%;
    max-width: 220px;
    aspect-ratio: 1 / 1;
    border-radius: 16px;
    border: 1px solid var(--border, rgba(255,255,255,.12));
    overflow: hidden;
    background: rgba(255,255,255,.04);
    margin: 8px 0 10px;
}
.peptide-vial-setting-preview img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}


/* ATP v5.5.9 upcoming calendar accordion */
.upcoming-calendar-card .section-head{margin-bottom:14px}
.upcoming-calendar-card .section-head h2{margin:0 0 6px}
.upcoming-calendar-accordion{display:grid;gap:10px;margin-top:8px}
.upcoming-accordion-item{border:1px solid var(--app-border);border-radius:14px;background:rgba(0,0,0,.18);overflow:hidden}
.upcoming-accordion-summary{list-style:none;display:flex;align-items:center;justify-content:space-between;gap:14px;padding:15px 16px;cursor:pointer;user-select:none}
.upcoming-accordion-summary::-webkit-details-marker{display:none}
.upcoming-accordion-summary strong{display:block;font-size:1rem;line-height:1.2;color:var(--app-text)}
.upcoming-accordion-summary span{display:block;margin-top:4px;color:var(--app-muted);font-size:.84rem;line-height:1.2}
.upcoming-accordion-summary i{color:var(--app-primary);transition:transform .18s ease}
.upcoming-accordion-item[open] .upcoming-accordion-summary{border-bottom:1px solid var(--app-border);background:rgba(255,255,255,.025)}
.upcoming-accordion-item[open] .upcoming-accordion-summary i{transform:rotate(180deg)}
.upcoming-accordion-body{display:grid;gap:8px;padding:12px}
.upcoming-dose-row{display:grid;grid-template-columns:112px 1fr;gap:12px;align-items:start;padding:12px;border:1px solid var(--app-border);border-radius:12px;background:rgba(255,255,255,.025)}
.upcoming-dose-time{display:grid;gap:8px;align-content:start}
.upcoming-dose-time strong{font-size:.95rem;color:var(--app-primary)}
.upcoming-dose-copy strong{display:block;margin-bottom:5px;color:var(--app-text)}
.upcoming-dose-copy p{margin:0}
@media(max-width:640px){.upcoming-dose-row{grid-template-columns:1fr}.upcoming-dose-time{display:flex;align-items:center;justify-content:space-between;gap:12px}.upcoming-accordion-summary{padding:14px}.upcoming-accordion-body{padding:10px}}


/* ATP v5.6.0 calendar summary upgrade */
.upcoming-calendar-footer{display:flex;justify-content:flex-end;margin-top:14px}
.upcoming-calendar-footer .btn{min-width:190px}
.tracking-calendar--summary .calendar-day{position:relative}
.tracking-calendar--summary details.calendar-day{display:block;border:0;cursor:pointer}
.tracking-calendar--summary details.calendar-day[open]{z-index:3;box-shadow:0 12px 32px rgba(0,0,0,.35)}
.calendar-day-summary{display:flex;flex-direction:column;gap:7px;min-height:100%;list-style:none;cursor:pointer}
.calendar-day-summary::-webkit-details-marker{display:none}
.calendar-day-summary .calendar-day-number i{font-size:.72rem;color:var(--app-primary);transition:transform .18s ease}
details.calendar-day[open] .calendar-day-summary .calendar-day-number i{transform:rotate(180deg)}
.calendar-day-summary-counts{display:grid;gap:5px;align-content:start}
.calendar-count-pill{display:inline-flex;align-items:center;justify-content:center;min-height:23px;border:1px solid var(--app-border);border-radius:999px;background:rgba(0,0,0,.2);padding:4px 7px;font-size:.68rem;font-weight:900;line-height:1;text-transform:uppercase;letter-spacing:.045em;color:var(--app-muted);text-align:center}
.calendar-count-pill.calendar-count-total{color:var(--app-text);border-color:rgba(255,255,255,.18);background:rgba(255,255,255,.055)}
.calendar-count-pill.status-pending{color:var(--app-primary);border-color:rgba(214,178,94,.55)}
.calendar-count-pill.status-taken{color:#34d399;border-color:rgba(52,211,153,.5)}
.calendar-count-pill.status-missed{color:var(--app-danger);border-color:rgba(255,107,107,.55)}
.calendar-count-pill.status-skipped{color:#93a4b8;border-color:rgba(147,164,184,.45)}
.calendar-day-detail-panel{display:grid;gap:7px;margin-top:8px;padding-top:8px;border-top:1px solid var(--app-border)}
.calendar-date-detail-link,.calendar-date-detail-static{display:block;text-decoration:none;color:inherit}
.calendar-date-detail-row{display:grid;grid-template-columns:48px minmax(0,1fr);gap:7px;align-items:start;border:1px solid var(--app-border);border-left-width:4px;border-radius:10px;background:rgba(0,0,0,.22);padding:7px;font-size:.75rem;line-height:1.2}
.calendar-date-detail-row.status-pending{border-left-color:var(--app-primary)}
.calendar-date-detail-row.status-taken{border-left-color:#34d399}
.calendar-date-detail-row.status-missed{border-left-color:var(--app-danger)}
.calendar-date-detail-row.status-skipped{border-left-color:#93a4b8}
.calendar-date-detail-time strong,.calendar-date-detail-copy strong{display:block;color:var(--app-text)}
.calendar-date-detail-time .badge{font-size:.58rem;padding:3px 5px;margin-top:4px;white-space:nowrap}
.calendar-date-detail-copy{min-width:0}
.calendar-date-detail-copy strong,.calendar-date-detail-copy .dose-line{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.calendar-date-detail-copy .dose-line{margin:3px 0 0}
@media(max-width:900px){.calendar-count-pill{font-size:.62rem;padding:3px 5px}.calendar-date-detail-row{grid-template-columns:1fr}.calendar-date-detail-copy strong,.calendar-date-detail-copy .dose-line{white-space:normal}.upcoming-calendar-footer .btn{width:100%}}
@media(max-width:640px){.calendar-day-summary{gap:5px}.calendar-day-summary-counts{gap:4px}.calendar-count-pill{font-size:.55rem;letter-spacing:.02em;min-height:20px}.calendar-day-detail-panel{position:absolute;left:4px;right:4px;top:100%;z-index:10;background:var(--app-card);border:1px solid var(--app-border);border-radius:12px;padding:8px;box-shadow:0 14px 30px rgba(0,0,0,.45)}.tracking-calendar--summary details.calendar-day[open]{min-height:120px}.calendar-date-detail-row{font-size:.68rem;padding:6px}}

/* ATP v5.6.1 calendar jump and monthly PDF export */
.calendar-page-actions{display:flex;flex-wrap:wrap;gap:10px;justify-content:flex-end;align-items:center}
.calendar-day-jump{color:inherit;text-decoration:none;transition:border-color .16s ease,transform .16s ease,box-shadow .16s ease}
.calendar-day-jump:hover,.calendar-day-jump:focus-visible{border-color:rgba(214,178,94,.7);box-shadow:inset 0 0 0 1px rgba(214,178,94,.25);transform:translateY(-1px);outline:none}
.calendar-day-jump .calendar-day-summary{min-height:100%}
.calendar-day-jump .calendar-day-number i{font-size:.7rem;color:var(--app-primary);opacity:.85}
.calendar-details-list{scroll-margin-top:92px;margin-top:20px;border-top:1px solid var(--app-border);padding-top:16px}
.calendar-details-list .section-head{margin-bottom:12px}
.calendar-day-detail-section{scroll-margin-top:92px;margin-bottom:18px;border:1px solid var(--app-border);border-radius:16px;background:rgba(0,0,0,.12);padding:12px}
.calendar-day-detail-section:target{border-color:rgba(214,178,94,.72);box-shadow:0 0 0 2px rgba(214,178,94,.16)}
.calendar-day-detail-section .calendar-date-heading{margin:0 0 10px}
@media(max-width:900px){.calendar-page-actions{justify-content:stretch}.calendar-page-actions .btn{width:100%}}
@media(max-width:640px){.calendar-day-jump .calendar-day-number i{display:none}.calendar-day-detail-section{padding:10px;border-radius:14px}.calendar-details-list{scroll-margin-top:72px}.calendar-day-detail-section{scroll-margin-top:72px}}

/* ATP v5.6.2 Today As Needed cleanup */
.today-dose-line{
  display:flex;
  align-items:center;
  gap:.5rem;
  flex-wrap:wrap;
}
.today-as-needed-label{
  display:inline-flex;
  align-items:center;
  gap:.35rem;
  border:1px solid rgba(214,178,94,.5);
  color:var(--app-primary);
  background:rgba(214,178,94,.08);
  border-radius:999px;
  padding:.18rem .58rem;
  font-size:.74rem;
  line-height:1.2;
  text-transform:uppercase;
  letter-spacing:.06em;
  white-space:nowrap;
}
.today-as-needed-label span{
  color:var(--app-muted);
  letter-spacing:.04em;
}
.today-card-meta{
  margin:.2rem 0 .45rem;
}
@media(max-width:640px){
  .today-dose-line{
    display:block;
  }
  .today-as-needed-label{
    margin-top:.45rem;
    width:max-content;
    max-width:100%;
    display:flex;
  }
}


/* ATP v5.6.3 Cycle product card cleanup */
.product-directory-card .product-directory-head{
  margin-bottom:4px;
}
.product-directory-card .product-class-line{
  text-align:center;
  margin:2px 0 8px;
}
.product-directory-card .product-class-line strong{
  color:var(--app-primary);
  font-weight:700;
}
.product-directory-card .product-card-body{
  padding-bottom:0;
}


/* ATP v5.6.4 topbar icons, user menu, and AJAX order feedback */
.sr-only{
  position:absolute!important;
  width:1px!important;
  height:1px!important;
  padding:0!important;
  margin:-1px!important;
  overflow:hidden!important;
  clip:rect(0,0,0,0)!important;
  white-space:nowrap!important;
  border:0!important;
}
.topbar-icon-button{
  position:relative;
  width:42px;
  height:42px;
  border-radius:999px;
  border:1px solid var(--app-border);
  background:rgba(255,255,255,.035);
  color:var(--app-text);
  display:grid;
  place-items:center;
  cursor:pointer;
  text-decoration:none;
}
.topbar-icon-button:hover,
.topbar-icon-button:focus,
.user-menu.is-open .topbar-icon-button{
  border-color:var(--app-primary);
  color:var(--app-primary);
  background:rgba(214,178,94,.09);
}
.topbar-count{
  position:absolute;
  top:-6px;
  right:-6px;
  min-width:20px;
  height:20px;
  padding:0 5px;
  border-radius:999px;
  display:grid;
  place-items:center;
  background:var(--app-primary);
  color:var(--app-primary-contrast);
  border:2px solid var(--app-bg);
  font-size:.66rem;
  line-height:1;
  font-weight:900;
}
.topbar-count.is-hidden{display:none}
.user-menu{position:relative;display:inline-flex;z-index:10000}
.user-menu-popover{
  position:absolute;
  right:0;
  top:calc(100% + 12px);
  width:min(260px,calc(100vw - 28px));
  background:#171717;
  background-image:linear-gradient(180deg,#24211b 0%,#171717 68%);
  border:1px solid rgba(214,178,94,.72);
  border-radius:18px;
  box-shadow:0 22px 80px rgba(0,0,0,.78),0 0 0 1px rgba(255,255,255,.045) inset;
  overflow:hidden;
  z-index:10002;
}
.user-menu-popover:before{
  content:"";
  position:absolute;
  right:15px;
  top:-7px;
  width:12px;
  height:12px;
  transform:rotate(45deg);
  background:#24211b;
  border-left:1px solid rgba(214,178,94,.72);
  border-top:1px solid rgba(214,178,94,.72);
}
.user-menu-head{
  display:grid;
  gap:3px;
  padding:14px 16px;
  border-bottom:1px solid var(--app-border);
  background:#161616;
}
.user-menu-head strong{
  text-transform:uppercase;
  letter-spacing:.05em;
  color:var(--app-text);
  overflow-wrap:anywhere;
}
.user-menu-head span{
  color:var(--app-muted);
  font-size:.78rem;
  overflow-wrap:anywhere;
}
.user-menu-popover a{
  display:flex;
  align-items:center;
  gap:10px;
  padding:12px 16px;
  color:var(--app-text);
  border-bottom:1px solid rgba(255,255,255,.06);
}
.user-menu-popover a:hover,
.user-menu-popover a:focus{
  background:rgba(214,178,94,.09);
  color:var(--app-primary);
}
.ajax-order-form .btn.is-added,
.ajax-restock-form .btn.is-added{
  border-color:rgba(72,211,138,.7);
  color:#48d38a;
  background:rgba(72,211,138,.08);
}
.ajax-order-form .btn.is-busy,
.ajax-restock-form .btn.is-busy{
  opacity:.68;
  pointer-events:none;
}
.ajax-inline-message{
  grid-column:1 / -1;
  width:100%;
  margin-top:6px;
  color:#48d38a;
  font-size:.74rem;
  font-weight:800;
  text-transform:uppercase;
  letter-spacing:.05em;
}
.ajax-inline-message.is-error{color:var(--app-danger)}
@media(max-width:640px){
  .topbar-icon-button{width:38px;height:38px}
  .topbar-actions{gap:7px}
  .user-menu-popover{position:fixed;top:64px;left:9px;right:9px;width:auto}
  .user-menu-popover:before{right:18px}
}

/* ATP v5.6.7 order autosave and order history subpage */
.order-autosave-status{font-size:.72rem;letter-spacing:.06em;text-transform:uppercase;color:var(--app-muted)}
.order-autosave-status.is-error{color:#ff5368}.order-history-edit{margin-bottom:16px;padding:14px;border:1px solid var(--app-border);border-radius:16px;background:rgba(0,0,0,.16)}
.order-history-actions form{margin:0;display:inline-flex}.order-actions .btn{min-height:44px}.order-item-copy>.muted.small{display:none}
@media(max-width:760px){.order-history-actions form{display:block}.order-history-edit .button-row{display:grid;grid-template-columns:1fr}.order-history-edit .button-row .btn{width:100%}}


/* ATP v5.7.3 logo, favicon, and app icon polish */
.brand img{height:42px;max-width:220px;width:auto;object-fit:contain;display:block}
.landing-brand{display:inline-flex;align-items:center;min-height:42px}
.landing-brand img{height:44px;max-width:230px;width:auto;object-fit:contain;display:block}
@media(max-width:640px){.brand img{height:36px;max-width:170px}.landing-brand img{height:36px;max-width:175px}}

/* ATP v5.7.4 Admin media picker */
.media-picker-row{display:grid;gap:10px}
.admin-media-picker-preview,.peptide-vial-setting-preview{width:100%;min-height:92px;border:1px solid var(--app-border);border-radius:14px;background:rgba(0,0,0,.24);display:flex;align-items:center;justify-content:center;overflow:hidden;padding:10px}
.admin-media-picker-preview img,.peptide-vial-setting-preview img{max-width:100%;max-height:160px;object-fit:contain;display:block}
.admin-media-picker-preview span{font-size:.8rem;color:var(--app-muted);letter-spacing:.04em;text-transform:uppercase}
.media-picker-clear-line{margin-top:-4px}
.admin-media-picker-select{min-height:44px}
@media(max-width:760px){.admin-media-picker-preview,.peptide-vial-setting-preview{min-height:86px}.admin-media-picker-preview img,.peptide-vial-setting-preview img{max-height:130px}}

/* v5.7.6 Today peptide injectable needle selector */
.today-dose-wrap{
  display:flex;
  align-items:flex-start;
  flex-wrap:wrap;
  gap:10px 14px;
  margin-top:6px;
}
.today-dose-wrap .today-dose-line{
  margin:0;
  min-width:0;
}
.today-needle-tool{
  display:inline-flex;
  flex-direction:column;
  align-items:flex-start;
  gap:10px;
  min-width:min(100%, 560px);
}
.today-needle-toggle{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  gap:7px;
  border:1px solid rgba(214,178,94,.72);
  background:rgba(214,178,94,.08);
  color:var(--app-primary);
  border-radius:999px;
  padding:6px 10px;
  font-size:.72rem;
  line-height:1.1;
  font-weight:900;
  letter-spacing:.08em;
  text-transform:uppercase;
  cursor:pointer;
}
.today-needle-panel{
  width:min(100%, 620px);
  border:1px solid rgba(214,178,94,.34);
  border-radius:16px;
  background:rgba(0,0,0,.22);
  padding:12px;
}
.today-needle-options{
  display:grid;
  grid-template-columns:repeat(3,minmax(0,1fr));
  gap:10px;
}
.today-needle-option{
  display:grid;
  grid-template-columns:72px 1fr;
  align-items:center;
  gap:10px;
  border:1px solid var(--app-border);
  background:rgba(255,255,255,.025);
  color:var(--app-text);
  border-radius:13px;
  padding:9px;
  cursor:pointer;
  text-align:left;
}
.today-needle-option.is-selected{
  border-color:var(--app-primary);
  box-shadow:0 0 0 1px rgba(214,178,94,.75) inset;
  background:rgba(214,178,94,.08);
}
.today-needle-option strong,
.today-needle-option small{
  display:block;
}
.today-needle-option strong{
  color:var(--app-primary);
  font-size:.85rem;
  letter-spacing:.03em;
}
.today-needle-option small{
  color:var(--app-muted);
  font-size:.72rem;
  margin-top:2px;
}
.today-needle-image{
  display:flex;
  align-items:center;
  justify-content:center;
  width:72px;
  height:38px;
  border:1px solid rgba(255,255,255,.08);
  background:rgba(255,255,255,.035);
  border-radius:10px;
  color:var(--app-primary);
  overflow:hidden;
}
.today-needle-image img{
  width:100%;
  height:100%;
  object-fit:contain;
  display:block;
}
.today-needle-chart{
  margin-top:12px;
  border:1px solid var(--app-border);
  border-radius:16px;
  background:linear-gradient(180deg,rgba(255,255,255,.035),rgba(0,0,0,.16));
  padding:12px;
}
.today-needle-chart.has-warning{
  border-color:rgba(255,41,61,.75);
}
.today-needle-chart-head,
.today-needle-axis{
  display:flex;
  justify-content:space-between;
  gap:12px;
  align-items:center;
  color:var(--app-muted);
  font-size:.82rem;
}
.today-needle-chart-head strong{
  color:var(--app-text);
}
.today-needle-chart-head span{
  color:var(--app-primary);
  font-weight:900;
}
.today-syringe-drawing{
  display:grid;
  grid-template-columns:36px 1fr 42px;
  align-items:center;
  margin:18px 0 24px;
}
.today-syringe-plunger{
  height:36px;
  border:2px solid var(--app-border);
  border-right:0;
  border-radius:12px 0 0 12px;
  position:relative;
  background:#121212;
}
.today-syringe-plunger span{
  position:absolute;
  left:7px;
  top:50%;
  width:22px;
  height:7px;
  transform:translateY(-50%);
  background:var(--app-border);
  border-radius:999px;
}
.today-syringe-barrel{
  position:relative;
  height:58px;
  border:2px solid var(--app-border);
  border-radius:13px;
  background:linear-gradient(180deg,#f5f5f5,#cfcfcf);
  box-shadow:inset 0 1px 0 rgba(255,255,255,.45),inset 0 -9px 14px rgba(0,0,0,.15);
  overflow:visible;
}
.today-syringe-liquid{
  position:absolute;
  left:0;
  top:0;
  bottom:0;
  width:0;
  background:linear-gradient(90deg,rgba(214,178,94,.28),rgba(214,178,94,.88));
  border-radius:11px 0 0 11px;
  transition:width .2s ease;
}
.today-syringe-marker{
  position:absolute;
  top:-10px;
  bottom:-10px;
  width:3px;
  background:var(--app-primary);
  left:0;
  z-index:5;
  transition:left .2s ease;
}
.today-syringe-marker span{
  position:absolute;
  top:-20px;
  left:50%;
  transform:translateX(-50%);
  width:10px;
  height:10px;
  background:var(--app-primary);
  border-radius:999px;
}
.today-needle-chart.has-warning .today-syringe-marker,
.today-needle-chart.has-warning .today-syringe-marker span{
  background:var(--app-danger);
}
.today-syringe-ticks{
  position:absolute;
  inset:0;
  z-index:4;
}
.today-syringe-ticks .tick{
  position:absolute;
  bottom:0;
  width:1px;
  background:#111;
  opacity:.55;
  transform:translateX(-50%);
}
.today-syringe-ticks .tick-minor{height:17px;}
.today-syringe-ticks .tick-major{height:32px;width:2px;opacity:.82;}
.today-syringe-ticks .tick em{
  position:absolute;
  bottom:-24px;
  left:50%;
  transform:translateX(-50%);
  font-style:normal;
  font-size:.64rem;
  color:var(--app-muted);
  white-space:nowrap;
}
.today-syringe-needle{
  height:18px;
  display:flex;
  align-items:center;
}
.today-syringe-needle:before{
  content:"";
  display:block;
  width:18px;
  height:28px;
  border:2px solid var(--app-border);
  border-left:0;
  background:#171717;
  border-radius:0 10px 10px 0;
}
.today-syringe-needle span{
  display:block;
  height:2px;
  flex:1;
  background:linear-gradient(90deg,var(--app-border),transparent);
  position:relative;
}
.today-syringe-needle span:after{
  content:"";
  position:absolute;
  right:-1px;
  top:50%;
  transform:translateY(-50%);
  border-left:9px solid var(--app-border);
  border-top:4px solid transparent;
  border-bottom:4px solid transparent;
}
.today-needle-note{
  margin:8px 0 0;
}
@media(max-width:720px){
  .today-dose-wrap{
    display:grid;
    gap:8px;
  }
  .today-needle-tool,
  .today-needle-panel{
    width:100%;
  }
  .today-needle-options{
    grid-template-columns:1fr;
  }
  .today-needle-option{
    grid-template-columns:96px 1fr;
  }
  .today-needle-image{
    width:96px;
    height:42px;
  }
  .today-syringe-drawing{
    grid-template-columns:26px 1fr 30px;
  }
  .today-syringe-barrel{
    height:52px;
  }
  .today-syringe-ticks .tick em{
    font-size:.58rem;
  }
}


.today-selected-syringe-image{
  margin:12px 0 2px;
  padding:8px 10px;
  border:1px solid rgba(255,255,255,.08);
  background:rgba(255,255,255,.025);
  border-radius:12px;
  text-align:center;
}
.today-selected-syringe-image img{
  width:min(100%, 420px);
  max-height:110px;
  object-fit:contain;
  display:inline-block;
}
.today-needle-chart:not([hidden]){
  display:block;
}


/* ATP v5.7.8 Today needle chart visibility and stable type badge */
.today-needle-chart.is-visible,
.today-needle-chart:not([hidden]){
  display:block !important;
}
.today-selected-syringe-image:not([hidden]){
  display:block !important;
}
.intake-card > .metric{
  align-items:flex-start;
  gap:18px;
}
.intake-card > .metric > div:first-child{
  min-width:0;
  flex:1 1 auto;
}
.today-product-type-badge{
  flex:0 0 136px;
  width:136px;
  min-height:116px;
  align-self:flex-start;
  display:grid;
  place-items:center;
  text-align:center;
  white-space:normal;
  line-height:1.25;
  padding:12px 10px;
  border-radius:999px;
  overflow-wrap:normal;
  word-break:normal;
}
.today-product-type-badge span{
  display:block;
}
@media(max-width:720px){
  .intake-card > .metric{
    display:grid;
    grid-template-columns:1fr auto;
    align-items:flex-start;
  }
  .today-product-type-badge{
    width:82px;
    flex-basis:82px;
    min-height:92px;
    font-size:.74rem;
    padding:10px 7px;
  }
}
@media(max-width:460px){
  .intake-card > .metric{
    grid-template-columns:1fr;
  }
  .today-product-type-badge{
    width:auto;
    min-height:0;
    border-radius:999px;
    display:inline-flex;
    gap:4px;
    place-items:initial;
    justify-self:start;
  }
  .today-product-type-badge span{
    display:inline;
  }
}

/* ATP v5.8.0 injectable liquid dose planning */
.injectable-liquid-dose-field{
  display:grid;
  grid-template-columns:minmax(120px, 1fr) minmax(92px, 140px);
  gap:10px;
  align-items:center;
}
.injectable-liquid-dose-field .injectable-liquid-dose-preview{
  grid-column:1 / -1;
  display:inline-flex;
  width:max-content;
  max-width:100%;
  align-items:center;
  border:1px solid rgba(218,180,88,.45);
  border-radius:999px;
  padding:7px 12px;
  color:#e7c769;
  font-size:.86rem;
  letter-spacing:.02em;
  background:rgba(218,180,88,.08);
}
.injectable-liquid-unit-select{
  min-width:90px;
}
@media(max-width:640px){
  .injectable-liquid-dose-field{
    grid-template-columns:1fr;
  }
  .injectable-liquid-dose-field .injectable-liquid-dose-preview{
    width:100%;
    justify-content:center;
  }
}

/* ATP v5.8.7 Today goal-stack accordion */
.today-goal-accordion .section-head{
  align-items:flex-start;
}
.today-goal-category-accordion{
  display:grid;
  gap:14px;
}
.today-goal-category-item{
  border:1px solid rgba(255,255,255,.11);
  border-radius:18px;
  background:linear-gradient(145deg, rgba(255,255,255,.045), rgba(255,255,255,.018));
  overflow:hidden;
}
.today-goal-category-summary{
  cursor:pointer;
  list-style:none;
  display:grid;
  grid-template-columns:minmax(0, 1fr) auto auto;
  align-items:center;
  gap:14px;
  padding:18px 20px;
}
.today-goal-category-summary::-webkit-details-marker{
  display:none;
}
.today-goal-category-summary strong{
  display:block;
  color:#f7f3e8;
  font-size:1.05rem;
  letter-spacing:.03em;
  text-transform:uppercase;
}
.today-goal-category-summary span:not(.badge){
  display:block;
  margin-top:4px;
  color:rgba(255,255,255,.68);
  font-size:.9rem;
  line-height:1.35;
}
.today-goal-category-summary .fa-chevron-down{
  color:#d8b85d;
  transition:transform .18s ease;
}
.today-goal-category-item[open] .today-goal-category-summary .fa-chevron-down{
  transform:rotate(180deg);
}
.today-goal-stack-grid{
  display:grid;
  grid-template-columns:repeat(3, minmax(0, 1fr));
  gap:14px;
  padding:0 18px 18px;
}
.today-goal-stack-card{
  min-height:100%;
}
.today-goal-more{
  padding:0 18px 18px;
}
.stack-category-display-checks{
  margin-top:14px;
}
@media(max-width:980px){
  .today-goal-stack-grid{
    grid-template-columns:1fr;
  }
}
@media(max-width:640px){
  .today-goal-category-summary{
    grid-template-columns:minmax(0, 1fr) auto;
  }
  .today-goal-category-summary .badge{
    grid-column:1 / -1;
    justify-self:start;
  }
}

/* ATP v5.9.1 notification history grouping */
.notification-compiled-list{
  display:flex;
  flex-direction:column;
  gap:14px;
}
.notification-compiled-section,
.notification-compact-month,
.notification-compact-day{
  border:1px solid rgba(255,255,255,.12);
  border-radius:18px;
  background:rgba(255,255,255,.025);
  overflow:hidden;
}
.notification-compiled-section > summary,
.notification-compact-month > summary,
.notification-compact-day > summary{
  cursor:pointer;
  list-style:none;
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:14px;
  padding:16px 18px;
}
.notification-compiled-section > summary::-webkit-details-marker,
.notification-compact-month > summary::-webkit-details-marker,
.notification-compact-day > summary::-webkit-details-marker{
  display:none;
}
.notification-compiled-section > summary::after,
.notification-compact-month > summary::after,
.notification-compact-day > summary::after{
  content:'\f107';
  font-family:'Font Awesome 6 Free';
  font-weight:900;
  color:var(--gold);
  transition:transform .18s ease;
}
.notification-compiled-section[open] > summary::after,
.notification-compact-month[open] > summary::after,
.notification-compact-day[open] > summary::after{
  transform:rotate(180deg);
}
.notification-compiled-section > summary > div{
  display:flex;
  flex-direction:column;
  gap:4px;
  min-width:0;
}
.notification-compiled-section > summary strong,
.notification-compact-month > summary span:first-child,
.notification-compact-day > summary span:first-child{
  color:var(--text);
  font-weight:800;
}
.notification-compiled-section > summary span:not(.badge){
  color:var(--muted);
  font-size:.88rem;
}
.notification-compact-month,
.notification-compact-day{
  margin:0 16px 12px;
  background:rgba(0,0,0,.18);
}
.notification-compact-month > summary,
.notification-compact-day > summary{
  padding:13px 15px;
}
.notification-history-list--compact{
  padding:0 14px 14px;
}
.notification-history-list--compact .notification-history-item{
  margin-bottom:10px;
}
.notification-compiled-empty{
  padding:0 18px 16px;
  margin:0;
}
@media(max-width:640px){
  .notification-compiled-section > summary,
  .notification-compact-month > summary,
  .notification-compact-day > summary{
    align-items:flex-start;
    flex-wrap:wrap;
  }
  .notification-compiled-section > summary .badge,
  .notification-compact-month > summary .badge,
  .notification-compact-day > summary .badge{
    margin-right:28px;
  }
}


/* v5.9.8 native app safe-area spacing */
html.is-native-app{--atp-native-safe-top:24px;--atp-native-safe-top:max(24px, env(safe-area-inset-top));}
html.is-native-app body{background:var(--app-bg);}
html.is-native-app .topbar{padding-top:calc(16px + var(--atp-native-safe-top));}
html.is-native-app .auth-page .topbar{padding-top:calc(16px + var(--atp-native-safe-top));}
@media(max-width:800px){
  html.is-native-app .topbar{padding-top:calc(14px + var(--atp-native-safe-top));}
  html.is-native-app .auth-page .topbar{padding-top:calc(14px + var(--atp-native-safe-top));}
}


/* v5.9.9 hide install section inside native app */
html.is-native-app .install-app-card,
html.is-capacitor-app .install-app-card,
html.is-native-app [data-hide-in-native-app],
html.is-capacitor-app [data-hide-in-native-app]{display:none!important;}
