
:root{font-family:"IBM Plex Mono",monospace;background:#091521;color:#eaf2fa;font-size:11px}*{box-sizing:border-box}body{margin:0}button,input,textarea{font:inherit}button{cursor:pointer}main{max-width:1120px;margin:auto;padding:14px 10px 60px}header{padding:8px 5px 15px;border-bottom:1px solid #28384a}header small{color:#9bbce0;letter-spacing:2px}h1{font-size:clamp(21px,5vw,35px);margin:3px 0;letter-spacing:1px}h1 span{color:#9dc5f5}h2{font-size:14px;margin:15px 0 8px}.top{display:grid;grid-template-columns:minmax(145px,1fr) minmax(0,2fr);gap:8px;margin-top:12px}.panel{background:#102131;border:1px solid #30465a}.heading{padding:10px;border-bottom:1px solid #33485b;font-size:13px;font-weight:700;color:#a6caff}.calendar{padding:10px}.month{font-weight:700;font-size:13px;margin-bottom:8px}.days{display:grid;grid-template-columns:repeat(7,1fr);gap:3px;text-align:center}.day{padding:4px 0;min-width:0}.muted{color:#8298af}.trained{background:#456e9d;color:white}.planning{display:grid;grid-template-columns:1fr 1fr;gap:8px}.panel table{width:100%;border-collapse:collapse;table-layout:fixed}th,td{padding:6px 4px;border-bottom:1px solid #293c50;text-align:left;overflow:hidden;text-overflow:ellipsis}th{font-weight:400;color:#a3bedb;background:#172c40}.planname{width:51%}.planlast{color:#a8cdf9;font-weight:700;text-align:right}.actualname{width:53%}.done{color:#b2dfbe}.actualval{color:#b9d8fa;text-align:right}.best{background:#365d87!important;color:white!important}.actual-head{display:flex;align-items:center;justify-content:space-between}.actual-head button{background:#2e4c68;border:1px solid #6485a5;color:white;padding:5px}.section{margin-top:12px}.section .heading{background:#1a3148}.section .inside{display:grid;grid-template-columns:1fr 1.08fr;gap:8px;padding:5px}.section .inside table{font-size:10px}.section .inside th,.section .inside td{padding:6px 3px}.history th,.history td{text-align:center}.history th:first-child,.history td:first-child{text-align:left;width:34%}.history th:nth-child(2),.history td:nth-child(2){width:14%}.latest{color:#afd3ff;font-weight:700}.trend{width:68px;height:24px}.progresscol{width:74px}.delta{color:#b5d6b7;font-weight:700}.foot{display:grid;grid-template-columns:1fr auto;gap:8px;margin-top:12px}.note{padding:12px;line-height:1.6}.speak{background:#a7a39a;color:#071522;border:0;padding:12px 18px;font-weight:700}.input-panel{padding:12px;margin-top:12px;background:#182c3f;border:1px solid #6084a8}.input-panel textarea{width:100%;min-height:70px;margin:9px 0;background:#091724;color:white;border:1px solid #537392;padding:10px}.input-panel button{background:#4d729a;color:white;border:0;padding:10px;margin-right:7px}.input-panel p{color:#b7c8d9}.tag{font-size:10px;color:#b6d8b8}.mini{font-size:10px;color:#9eb0c3}.scroll{overflow-x:auto}.scroll table{min-width:310px}.footer-actions{display:flex;gap:8px;flex-wrap:wrap;margin-top:12px}.footer-actions button{border:1px solid #45607a;color:#eaf2fa;background:#182e42;padding:9px}.status{color:#a7c8e9;margin-top:8px} @media(max-width:650px){main{padding:7px 5px 35px}.top{grid-template-columns:115px minmax(0,1fr);gap:4px}.planning{gap:4px}.heading{padding:6px;font-size:10px}.calendar{padding:5px}.month{font-size:10px}.day{font-size:9px;padding:3px 0}th,td{font-size:8px;padding:5px 2px}.section .inside{display:block}.section .inside>div+div{margin-top:5px}.section .inside table{font-size:9px}.section .inside th,.section .inside td{padding:4px 2px}.planname{width:46%}.foot{grid-template-columns:1fr auto}.speak{padding:7px;font-size:9px}.note{padding:8px;font-size:9px}.progresscol{width:65px}} 

/* V1.2: compact stacked progress/history and readable actuals */
.top{grid-template-columns:minmax(115px,1fr) minmax(0,3fr)}.planning{grid-template-columns:1fr 1fr}.planning .panel{min-width:0}.planning th,.planning td{font-size:10px;padding:9px 5px;vertical-align:top;overflow-wrap:anywhere}.planning .heading{font-size:12px}.smallbtn{float:right;background:transparent;color:#b9d8fa;border:1px solid #47617a;padding:4px;font-size:10px}.actual-head{gap:4px}.struck{text-decoration:line-through;color:#748a9f}.weights{color:#b9d8fa;line-height:1.65;font-variant-numeric:tabular-nums}.progress-table td,.progress-table th{font-size:11px;padding:9px 7px}.progress-table th:nth-child(1){width:38%}.progress-table th:nth-child(2){width:20%}.progress-table th:nth-child(3){width:17%}.progress-table th:nth-child(4){width:25%}.progress-table .trend{max-width:85px;width:100%;height:29px}.history-list td,.history-list th{padding:9px 7px;vertical-align:top;font-size:11px}.history-list th:first-child{width:39%}.histrow{display:flex;gap:14px;justify-content:space-between;border-bottom:1px solid #23384b;padding:4px 0}.histrow span:first-child{color:#8ea9c2;white-space:nowrap}.histrow span:last-child{text-align:right}.fine{font-size:10px;color:#9cb3c9;line-height:1.6;padding:0 8px}.review-head{color:#a7c9ee;font-weight:bold;margin:15px 0 8px}.review-item{border-top:1px solid #44617c;padding:10px 0}.review-item label{display:block;margin:7px 0;color:#b9d8fa}.review-item input{background:#091724;color:#fff;border:1px solid #537392;padding:7px;max-width:100%;border-radius:0}.set-editor label{display:flex;gap:7px;align-items:center}.set-editor input{width:75px}.review-item.new-ex input:not([type=checkbox]){display:block;width:100%;margin-top:3px}.input-panel button{margin-top:6px}.section{margin-top:13px}
@media(max-width:650px){.top{display:block}.calendar{margin-bottom:6px}.calendar .days{max-width:290px}.planning{grid-template-columns:1fr 1fr;gap:5px}.planning .heading{font-size:10px}.planning th,.planning td{font-size:9px;padding:7px 3px}.smallbtn{font-size:9px;padding:2px}.progress-table td,.progress-table th,.history-list td,.history-list th{font-size:9px;padding:8px 3px}.histrow{gap:5px}.progress-table .trend{height:25px}.section .heading{font-size:11px}}

/* V1.3 — iPhone compact layout; preserve readable metrics */
@media(max-width:650px){
 main{padding:7px 7px 32px} header{padding:5px 3px 9px} header small{font-size:9px;letter-spacing:1.5px}h1{font-size:24px;margin:2px 0}
 .top{display:block;margin-top:8px}.calendar{padding:6px;margin-bottom:7px}.calendar .days{max-width:none;gap:2px}.month{margin-bottom:3px}.day{padding:2px 0;font-size:10px}
 .planning{grid-template-columns:minmax(0,1fr) minmax(0,1.14fr);gap:5px}.planning .heading{padding:6px 4px;font-size:10px;line-height:1.25}.actual-head{align-items:center}.smallbtn,.actual-head button{padding:4px 3px;font-size:9px;white-space:nowrap}
 .planning th,.planning td{font-size:9px;padding:5px 3px;line-height:1.3;overflow-wrap:normal;word-break:normal;hyphens:none}.planning .planname{width:46%}.planning .actualname{width:49%}.planning td:first-child{overflow-wrap:break-word}.planning .weights{line-height:1.3}
 .section{margin-top:8px}.section .heading{padding:7px 6px;font-size:10px;line-height:1.3}.progress-table td,.progress-table th{font-size:10px;padding:5px 4px;line-height:1.25}.progress-table th{font-size:9px}.progress-table th:nth-child(1){width:39%}.progress-table th:nth-child(2){width:20%}.progress-table th:nth-child(3){width:16%}.progress-table th:nth-child(4){width:25%}.progress-table .trend{height:22px;display:block}.progress-table td:first-child{overflow-wrap:break-word}
 .history-list td,.history-list th{font-size:10px;padding:5px 4px;line-height:1.25}.histrow{padding:2px 0;gap:5px}.fine{font-size:9px;line-height:1.4;padding:0 5px}
}

/* V1.4 — dense, readable mobile dashboard */
@media(max-width:650px){
 main{padding:5px 6px 24px}header{padding:3px 2px 6px}header small{font-size:8px;letter-spacing:1px}h1{font-size:18px;line-height:1.15;margin:1px 0}
 .top{margin-top:6px}.calendar{padding:4px 7px 5px;margin-bottom:5px}.month{font-size:10px;margin-bottom:2px}.days{gap:1px 3px;line-height:1}.days>span{font-size:10px;min-height:15px;display:flex;align-items:center;justify-content:center}.day{padding:1px 0;min-height:15px}.trained{background:#456e9d}
 .planning{gap:4px;grid-template-columns:minmax(0,1fr) minmax(0,1fr)}.planning .heading{padding:5px 4px;font-size:10px;min-height:27px}.planning .smallbtn,.planning .actual-head button{font-size:8px;padding:3px 2px}.planning th,.planning td{font-size:9px;padding:5px 2px;line-height:1.25}.planning th{font-size:8px}.planning td:first-child{overflow-wrap:anywhere;word-break:normal}.planning .planname{width:48%}.planning .actualname{width:50%}.planning .weights{line-height:1.22}
 .section{margin-top:6px}.section .heading{font-size:10px;padding:6px 5px}.progress-table{table-layout:fixed}.progress-table td,.progress-table th{padding:3px 4px;font-size:10px;line-height:1.15;height:33px}.progress-table th{height:24px;font-size:8px}.progress-table th:nth-child(1){width:42%}.progress-table th:nth-child(2){width:18%}.progress-table th:nth-child(3){width:15%}.progress-table th:nth-child(4){width:25%}.progress-table .trend{height:19px;max-width:76px}.progress-table td:first-child{font-size:10px;overflow-wrap:normal;word-break:normal}
 .history-list td,.history-list th{padding:4px 4px;font-size:9px}.histrow{padding:1px 0}.fine{font-size:9px}
}

/* V1.5 — intentionally ultra-dense iPhone layout */
@media(max-width:650px){
 :root{font-size:9px}
 main{padding:3px 4px 16px}
 header{padding:1px 2px 3px}header small{font-size:7px;letter-spacing:.6px}h1{font-size:13px;line-height:1;margin:2px 0}
 .top{margin-top:3px}
 .calendar{padding:3px 5px!important;margin-bottom:3px!important}
 .month{font-size:8px;line-height:1;margin:0 0 2px}
 .calendar .days{display:grid;grid-template-columns:repeat(7,minmax(0,1fr));gap:1px 2px;max-width:none!important;line-height:1}
 .calendar .days>span{font-size:8px!important;height:13px!important;min-height:13px!important;max-height:13px!important;padding:0!important;line-height:13px!important;display:flex;align-items:center;justify-content:center}
 .planning{gap:3px;grid-template-columns:minmax(0,1fr) minmax(0,1fr)}
 .planning .heading{padding:2px 3px;min-height:21px;display:flex;align-items:center;justify-content:flex-end;border-bottom:0}
 .planning .heading.actual-head{justify-content:flex-end}
 .planning .smallbtn,.planning .actual-head button{font-size:8px;padding:2px 4px;line-height:1.2}
 .planning th,.planning td{font-size:8px!important;padding:3px 2px!important;line-height:1.12!important;vertical-align:top}
 .planning th{font-size:7px!important;letter-spacing:-.2px}
 .planning .planname{width:48%}.planning .actualname{width:52%}
 .planning td:first-child{overflow-wrap:anywhere}
 .planning .weights{line-height:1.1}
 .section{margin-top:4px}
 .section .heading{font-size:9px!important;padding:3px 4px!important;line-height:1.1}
 .progress-table td,.progress-table th{font-size:8px!important;padding:1px 3px!important;line-height:1.1!important;height:21px!important}
 .progress-table th{font-size:7px!important;height:17px!important}
 .progress-table th:nth-child(1){width:43%}.progress-table th:nth-child(2){width:18%}.progress-table th:nth-child(3){width:15%}.progress-table th:nth-child(4){width:24%}
 .progress-table .trend{height:13px!important;max-width:65px}
 .progress-table td:first-child{font-size:8px!important}
 .history-list td,.history-list th{font-size:8px!important;padding:2px 3px!important;line-height:1.1!important}
 .histrow{padding:1px 0}.fine{font-size:7px}
 .footer-actions{margin-top:5px}.footer-actions button{padding:4px;font-size:8px}.status{font-size:7px}
}

/* V1.6: structural correction — calendar is a SMALL LEFT-ALIGNED BOX, not a full-width panel. */
@media (max-width:650px) {
  .top { display:flex !important; flex-direction:column !important; align-items:flex-start !important; gap:4px !important; width:100% !important; }
  .top > .calendar { width:190px !important; max-width:52vw !important; flex:none !important; margin:0 !important; padding:3px !important; }
  .top > .calendar .days { width:100% !important; max-width:100% !important; grid-template-columns:repeat(7,minmax(0,1fr)) !important; }
  .top > .calendar .days > span { height:12px !important; min-height:12px !important; max-height:12px !important; font-size:7px !important; }
  .top > .planning { width:100% !important; align-self:stretch !important; }
  .progress-table td,.progress-table th { height:17px !important; padding:0 2px !important; line-height:1 !important; }
  .progress-table .trend { height:11px !important; }
  .history-list td,.history-list th { padding:1px 2px !important; line-height:1 !important; }
}

/* V1.7: truly miniature calendar and merged exercise history */
@media(max-width:650px){
 .top > .calendar{width:114px!important;max-width:114px!important;padding:2px!important}
 .calendar .month{font-size:6px!important;line-height:1.05!important;margin:0 0 2px!important}
 .top > .calendar .days{gap:0!important}
 .top > .calendar .days > span{height:9px!important;min-height:9px!important;max-height:9px!important;font-size:6px!important;line-height:9px!important;padding:0!important}
 .progress-table{table-layout:fixed!important}
 .progress-table th:nth-child(1){width:23%!important}
 .progress-table th:nth-child(2){width:12%!important}
 .progress-table th:nth-child(3){width:11%!important}
 .progress-table th:nth-child(4){width:16%!important}
 .progress-table th:nth-child(5){width:38%!important}
 .progress-table th,.progress-table td{font-size:8px!important;padding:2px 2px!important;height:auto!important;line-height:1.12!important;vertical-align:top!important}
 .progress-table th{font-size:7px!important}
 .progress-table .trend{width:100%!important;height:17px!important;max-width:52px!important}
 .progress-table .ex-name{overflow-wrap:break-word}
 .compact-history{display:flex;justify-content:space-between;gap:2px;border-bottom:1px solid #23384b;padding:1px 0;white-space:normal}
 .compact-history span:first-child{color:#9bb6d1;white-space:nowrap}
 .compact-history span:last-child{text-align:right;overflow-wrap:anywhere}
}

/* V1.8 - three integrated full-height category rails, same blue */
.progress-table .category-cell{background:#42658B!important;padding:0!important;position:relative;vertical-align:middle!important;border-right:1px solid #7397bb;min-width:27px}
.progress-table .category-label{display:flex;align-items:center;justify-content:center;writing-mode:vertical-rl;transform:rotate(180deg);font-family:'IBM Plex Mono',monospace;font-size:16px;font-weight:700;letter-spacing:1.4px;color:#fff;width:100%;height:100%;min-height:75px;text-align:center}
.progress-table .col-category{width:30px}
.progress-table .col-exercise{width:22%}
.progress-table .col-max{width:12%}
.progress-table .col-delta{width:11%}
.progress-table .col-trend{width:15%}
.progress-table .col-history{width:auto}
@media(max-width:650px){
 .progress-table th:nth-child(n){width:auto!important}
 .progress-table col.col-category{width:27px!important}
 .progress-table col.col-exercise{width:22%!important}
 .progress-table col.col-max{width:12%!important}
 .progress-table col.col-delta{width:11%!important}
 .progress-table col.col-trend{width:15%!important}
 .progress-table .category-label{font-size:15px!important;letter-spacing:1px!important}
 .progress-table td:first-child{font-size:inherit!important}
 .progress-table td.category-cell{padding:0!important}
}

/* V1.9 direct form entry and category spacing */
.progress-table .category-label{font-size:11px!important;letter-spacing:1px!important}
.progress-table tbody tr:has(.category-cell):not(:first-child){border-top:9px solid #091521!important}
.progress-table tbody tr:has(.category-cell):not(:first-child) td{border-top:9px solid #091521!important}
.exercise-note{font-size:7px;color:#a7c9ee;margin-top:3px;line-height:1.25;overflow-wrap:anywhere}
.editor-title{display:flex;justify-content:space-between;align-items:center;gap:10px}
.compact-editor label,.input-panel label{display:block;font-size:11px;color:#a7c9ee;margin:7px 0}
.compact-editor input,.compact-editor select,.compact-editor textarea,.input-panel input{font-family:'IBM Plex Mono',monospace;background:#091521;color:#e6f0fc;border:1px solid #46627f;border-radius:0;padding:7px;font-size:14px;max-width:100%;box-sizing:border-box}
.compact-editor select{width:100%}.compact-editor textarea{width:100%}
.entry-fields{display:flex;gap:10px}.entry-fields label{flex:1;min-width:0}.entry-fields input{width:100%}
.set-grid{display:grid;grid-template-columns:32px minmax(0,1fr) minmax(0,1fr) 26px;gap:5px;align-items:center;margin:10px 0}
.set-grid>span{font-size:9px;color:#a7c9ee}.set-grid>label{font-size:10px;margin:0}
.set-grid input{width:100%;min-width:0;padding:6px 3px;text-align:center}
.set-grid input[type=checkbox]{width:17px;height:17px;accent-color:#a7c9ee;justify-self:center}
@media(max-width:650px){.progress-table .category-label{font-size:10px!important}.progress-table tbody tr:has(.category-cell):not(:first-child) td{border-top-width:7px!important}}

/* V2.0: direct new exercise action */
#actualNew{display:inline-block;margin:5px 0 8px;border:1px solid #6c94b9;color:#d8eaff;background:#284661;padding:7px 10px;max-width:100%;font-family:inherit;font-size:11px}

/* Cloud architecture V3.0 */
.cloud-panel{border:1px solid #46627f;padding:12px;margin-top:14px;background:#102236}
.cloud-actions{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:6px}
.cloud-actions button{font:inherit;font-size:10px;padding:8px 4px;border-radius:0;background:#284661;color:#e6f0fc;border:1px solid #6c94b9}
.days .day.crossfit{background:#8064b4!important;color:#fff!important}
.progress-table .inline-history{padding-left:2px!important;padding-right:2px!important}
.progress-table .compact-history{justify-content:flex-start!important;gap:5px!important}
.heading .smallbtn{min-width:24px;min-height:24px;padding:1px 6px;border-radius:0}
