/* Sign-off round: create screens. Loaded after styles.css. */

/* ---------- (+) Create sheet ---------- */
.sheet:has(> .so-cr) { padding: 10px 16px calc(34px + env(safe-area-inset-bottom)); border-radius: 26px 26px 0 0; }
.so-cr { display: flex; flex-direction: column; gap: 10px; }
.so-cr-grip { align-self: center; width: 40px; height: 5px; border-radius: 3px; background: #D9D1C8; }
.so-cr-head { display: flex; align-items: center; gap: 8px; padding: 4px 4px 2px; }
.so-cr-head h2 { flex: 1; margin: 0; font-family: var(--font-display, 'Bricolage Grotesque', sans-serif); font-size: 24px; font-weight: 700; line-height: 1.2; color: var(--ink); }
[dir="rtl"] .so-cr-head h2 { font-family: 'Readex Pro', 'IBM Plex Sans Arabic', sans-serif; }
.so-cr-close { width: 44px; height: 44px; flex: none; border-radius: 22px; border: 0; background: #FFFFFF; color: var(--ink); display: flex; align-items: center; justify-content: center; cursor: pointer; }
.so-cr-choice { display: flex; align-items: center; gap: 14px; width: 100%; padding: 16px; border-radius: 20px; background: #FFFFFF; border: 1px solid #ECE6DF; color: var(--ink); text-decoration: none; text-align: start; font: inherit; cursor: pointer; }
.so-cr-choice:hover { color: var(--ink); border-color: var(--line-2); }
.so-cr-choice.off { opacity: 0.5; cursor: not-allowed; }
.so-cr-icon { width: 52px; height: 52px; flex: none; border-radius: 16px; display: flex; align-items: center; justify-content: center; }
.so-cr-text { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.so-cr-text strong { font-weight: 700; font-size: 17px; }
.so-cr-text > span { font-size: 14px; color: #6E655D; line-height: 1.35; }
.so-cr-choice.big { background: #CC4A14; border-color: #CC4A14; color: #FFFFFF; }
.so-cr-choice.big:hover { background: var(--accent-hover, #B8410F); color: #FFFFFF; }
.so-cr-choice.big .so-cr-icon { background: rgba(255, 255, 255, 0.18); }
.so-cr-choice.big strong { font-weight: 800; font-size: 18px; }
.so-cr-choice.big .so-cr-text > span { color: #FFE3D3; }
.so-cr-choice.video .so-cr-icon { background: #DDF2EA; color: #0D5340; }
.so-cr-choice.wish .so-cr-icon { background: #FBEFD0; color: #744F00; }
.so-cr-draft { margin-top: 4px; display: flex; align-items: center; gap: 12px; min-height: 56px; padding: 6px 14px; border-radius: 16px; background: #EFEAE4; text-decoration: none; color: var(--ink); }
.so-cr-draft:hover { color: var(--ink); }
.so-cr-draft .so-cr-text strong { font-size: 15px; }
.so-cr-draft .so-cr-text > span { font-size: 13.5px; }
.so-cr-chev { color: #8A8178; flex: none; }
[dir="rtl"] .so-cr-chev { transform: scaleX(-1); }

/* ---------- Lesson Coach: frame ---------- */
.so-co { background: #F5F3F0; }
.so-co-bar { display: flex; align-items: center; gap: 8px; padding: 12px 16px 8px; }
.so-co-bar .icon-btn { background: #FFFFFF; }
.so-co-step { flex: 1; min-width: 0; margin: 0; text-align: center; font-weight: 700; font-size: 15px; color: #6E655D; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.so-co-prog { display: grid; grid-template-columns: repeat(11, minmax(0, 1fr)); gap: 4px; padding: 0 16px; }
.so-co-prog span { height: 5px; border-radius: 3px; background: #E6DFD7; }
.so-co-prog span.on { background: #CC4A14; }
.so-co-title { padding: 22px 16px 0; display: flex; flex-direction: column; }
.so-co-title .pill { align-self: flex-start; margin-bottom: 10px; }
.so-co-title h1 { margin: 0; font-family: 'Bricolage Grotesque', sans-serif; font-size: 30px; font-weight: 700; letter-spacing: -0.015em; line-height: 1.1; color: var(--ink); }
[dir="rtl"] .so-co-title h1 { font-family: 'Readex Pro', 'IBM Plex Sans Arabic', sans-serif; letter-spacing: 0; line-height: 1.3; }
.so-co-title p { margin: 8px 0 0; font-size: 16px; line-height: 1.5; color: #4A433D; }
.so-co-main { flex: 1; padding: 16px 16px 16px; display: flex; flex-direction: column; gap: 14px; }
.so-co-s-spark, .so-co-s-why, .so-co-s-promise { gap: 16px; }
.so-co-s-flow, .so-co-s-when, .so-co-s-review { gap: 12px; }

/* footer: Back + Next (Next alone on step 1), then Save draft */
.flow-foot.so-co-foot { width: 100%; box-sizing: border-box; margin-top: auto; padding: 12px 16px calc(34px + env(safe-area-inset-bottom)); display: flex; flex-direction: column; gap: 6px; background: #F5F3F0; }
.flow-foot.so-co-foot.line { border-top: 1px solid #ECE6DF; }
.so-co-btns { display: flex; gap: 10px; }
.so-co-back, .so-co-next { height: 54px; border-radius: 16px; font: inherit; font-weight: 700; font-size: 17px; display: flex; align-items: center; justify-content: center; text-decoration: none; cursor: pointer; padding: 0 12px; text-align: center; line-height: 1.2; }
.so-co-back { flex: 1; background: #FFFFFF; border: 1.5px solid #D9D1C8; color: var(--ink); }
.so-co-back:hover { color: var(--ink); border-color: #C9BFB4; }
.so-co-next { flex: 2; width: 100%; border: 0; background: #CC4A14; color: #FFFFFF; }
.so-co-next:hover { background: var(--accent-hover, #B8410F); color: #FFFFFF; }
.so-co-next:disabled { opacity: 0.5; cursor: not-allowed; }
.so-co-draft { height: 44px; border: 0; background: transparent; font: inherit; font-weight: 700; font-size: 15px; color: #4A433D; cursor: pointer; }
.so-co-draft:hover { color: var(--ink); }
.so-co-goes { margin: 0; padding-bottom: 4px; font-size: 13px; color: #6E655D; text-align: center; }

/* ---------- shared bits ---------- */
.so-co .lc-text { background: #FFFFFF; border: 1.5px solid #D9D1C8; border-radius: 16px; padding: 14px; font: inherit; font-size: 16px; line-height: 1.5; resize: none; color: var(--ink); width: 100%; min-height: 0; }
.so-co .so-co-main > .lc-text:first-child, .so-co-s-spark > .lc-text, .so-co-s-why > .lc-text, .so-co-s-promise > .lc-text { border-radius: 18px; padding: 16px; font-size: 17px; min-height: 120px; }
.so-co .lc-text::placeholder, .so-co-part-text::placeholder, .so-co-q::placeholder { color: #8A8178; }
.so-co-label { font-size: 15px; font-weight: 700; color: var(--ink); margin: 4px 0 -6px; }
.so-co-label span { font-weight: 500; color: #6E655D; }
.so-co-hint { font-size: 13px; color: #6E655D; line-height: 1.45; margin-top: -6px; padding: 0 4px; }
.so-co-h { margin: 0; font-weight: 700; font-size: 16px; color: var(--ink); display: flex; align-items: center; gap: 8px; }
.so-co-card { background: #FFFFFF; border: 1px solid #ECE6DF; border-radius: 20px; padding: 14px; display: flex; flex-direction: column; gap: 10px; color: var(--ink); text-decoration: none; }
.so-co-note { margin: 0; font-size: 14px; color: #4A433D; line-height: 1.45; }
.so-co .lc-help .wrap { gap: 8px; }
.so-co .lc-ghost { height: 44px; padding: 0 14px; border-radius: 12px; border: 1.5px dashed #D9D1C8; font-size: 15px; font-weight: 600; color: #4A433D; }

/* coach box */
.so-co-coach { background: #E9EFF6; border-radius: 20px; padding: 14px; gap: 10px; color: #1E3A5F; }
.so-co-coach-head { display: flex; align-items: center; gap: 8px; color: #1E3A5F; }
.so-co-coach-head p { flex: 1; margin: 0; font-weight: 800; font-size: 16px; }
.so-co-coach-head > span { font-size: 13px; font-weight: 700; text-align: end; }
.so-co-coach-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.so-co-coach-grid button { min-height: 60px; border-radius: 14px; border: 0; background: #FFFFFF; font: inherit; text-align: start; padding: 10px 12px; color: #1E3A5F; cursor: pointer; display: flex; flex-direction: column; justify-content: center; }
.so-co-coach-grid button strong { font-weight: 800; font-size: 15px; }
.so-co-coach-grid button span { font-size: 13px; color: #4A5A70; margin-top: 2px; }
.so-co-coach-grid button:disabled, .so-co-coach-row button:disabled { opacity: 0.45; cursor: default; }
.so-co-coach.compact { padding: 12px 14px; }
.so-co-coach-row { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.so-co-coach-row p { flex: 1; min-width: 80px; margin: 0; font-weight: 800; font-size: 15px; }
.so-co-coach-row > .i + p { font-weight: 700; font-size: 14.5px; }
.so-co-coach-row button { height: 40px; padding: 0 12px; border-radius: 12px; border: 0; background: #FFFFFF; font: inherit; font-weight: 800; font-size: 14px; color: #1E3A5F; cursor: pointer; }
.so-co-taps { margin: 0; font-size: 13px; font-weight: 600; color: #4A5A70; }
.so-co-taps a { color: #1E3A5F; font-weight: 700; }

/* ---------- step 3: who ---------- */
.so-co-levels { display: flex; flex-direction: column; gap: 8px; }
.so-co-levels .ux-level strong { font-size: 16px; font-weight: 700; }
.so-co-levels .ux-level .small { font-size: 13.5px; color: #6E655D; }

/* ---------- step 5: format and length ---------- */
.so-co-formats { display: flex; flex-direction: column; gap: 8px; }
.so-co-format { min-height: 72px; border-radius: 18px; padding: 10px 12px; font: inherit; text-align: start; display: flex; align-items: center; gap: 12px; color: var(--ink); border: 1.5px solid #E0D8CF; background: #FFFFFF; cursor: pointer; }
.so-co-format.on { border: 2px solid #CC4A14; background: #FDF6F2; padding: 9.5px 11.5px; }
.so-co-fi { width: 48px; height: 48px; border-radius: 14px; flex: none; display: flex; align-items: center; justify-content: center; }
.so-co-ft { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.so-co-ft strong { font-weight: 700; font-size: 16px; }
.so-co-ft span { font-size: 13.5px; color: #6E655D; line-height: 1.4; margin-top: 2px; }
.so-co-len { display: flex; align-items: baseline; justify-content: space-between; margin-top: 6px; }
.so-co-len p { margin: 0; font-weight: 700; font-size: 16px; }
.so-co-len .so-co-len-val { font-family: 'Bricolage Grotesque', sans-serif; font-size: 26px; color: #A33A0E; }
[dir="rtl"] .so-co-len .so-co-len-val { font-family: 'Readex Pro', 'IBM Plex Sans Arabic', sans-serif; }
.so-co-lens { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 6px; }
.so-co-lens button { height: 50px; border-radius: 14px; font: inherit; font-weight: 700; font-size: 17px; border: 1.5px solid #D9D1C8; background: #FFFFFF; color: var(--ink); cursor: pointer; padding: 0; }
.so-co-lens button.on { border-color: #CC4A14; background: #CC4A14; color: #FFFFFF; }
.so-co-tip { margin: 0; background: #EFEAE4; border-radius: 14px; padding: 12px 14px; font-size: 14.5px; line-height: 1.5; color: #4A433D; }
.so-co-tip strong { color: var(--ink); }

/* ---------- step 6 (and 8): parts ---------- */
.so-co-part { background: #FFFFFF; border: 1px solid #ECE6DF; border-radius: 20px; padding: 14px; display: flex; flex-direction: column; gap: 10px; }
.so-co-part-head { display: flex; align-items: center; gap: 10px; }
.so-co-part-name { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.so-co-part-name strong { font-weight: 800; font-size: 17px; }
.so-co-part-name span { font-size: 13.5px; color: #6E655D; line-height: 1.3; }
.so-co-stepper { display: flex; align-items: center; gap: 2px; background: #F0ECE7; border-radius: 14px; padding: 4px; flex: none; }
.so-co-stepper .step-btn { width: 44px; height: 44px; border-radius: 11px; background: #FFFFFF; color: var(--ink); }
.so-co-stepper .step-val { width: 40px; font-weight: 800; font-size: 18px; }
.so-co-part-text, .so-co-q { width: 100%; border: 1.5px solid #E0D8CF; border-radius: 14px; padding: 12px; font: inherit; font-size: 15.5px; line-height: 1.45; resize: none; background: #FAF8F6; color: var(--ink); }
.so-co-q { font-weight: 700; background: #FFFFFF; }
.so-co-total { margin: 0; display: flex; align-items: center; gap: 10px; padding: 12px 14px; border-radius: 14px; font-weight: 700; font-size: 15px; }
.so-co-total > span:first-child { flex: 1; }
.so-co-total-hint { font-weight: 600; font-size: 13.5px; }
.so-co-total.ok { background: #DDF2EA; color: #0D5340; }
.so-co-total.off { background: #FBEFD0; color: #744F00; }

/* step 9: name */
.so-co-field .input { background: #FFFFFF; border: 1.5px solid #D9D1C8; border-radius: 16px; }
.so-co-field .field-head { font-size: 15px; font-weight: 700; }

/* ---------- step 10: when and where ---------- */
.so-co-card { gap: 10px; }
.so-co-dayhead { display: flex; align-items: center; gap: 6px; }
.so-co-dayhead .grow { flex: 1; }
.so-co-wk { width: 40px; height: 40px; border-radius: 20px; border: 0; background: #F0ECE7; color: var(--ink); display: flex; align-items: center; justify-content: center; cursor: pointer; flex: none; }
.so-co-wk:disabled { color: #B9AFA4; cursor: default; }
[dir="rtl"] .so-co-wk .i { transform: scaleX(-1); }
.so-co-range { font-size: 14px; font-weight: 600; padding: 0 4px; white-space: nowrap; }
.so-co-days { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 4px; margin-top: 2px; }
.so-co-days button { height: 60px; border-radius: 14px; font: inherit; padding: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 1px; border: 1px solid #E0D8CF; background: #FFFFFF; color: var(--ink); cursor: pointer; min-width: 0; }
.so-co-days button.on { border-color: #CC4A14; background: #CC4A14; color: #FFFFFF; }
.so-co-days .wd { font-size: 11.5px; font-weight: 700; }
.so-co-days .n { font-size: 18px; font-weight: 800; }
.so-co-daynote { margin: 2px 0 0; font-size: 13.5px; color: #6E655D; line-height: 1.4; }
.so-co-times { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.so-co-times button { height: 48px; border-radius: 14px; font: inherit; font-weight: 700; font-size: 15px; border: 1.5px solid #D9D1C8; background: #FFFFFF; color: var(--ink); cursor: pointer; padding: 0; }
.so-co-times button.on { border-color: #CC4A14; background: #FCE9DD; color: #A33A0E; }
.so-co-other { position: relative; height: 44px; border-radius: 12px; border: 1.5px dashed #D9D1C8; display: flex; align-items: center; justify-content: center; font-weight: 600; font-size: 14.5px; color: #4A433D; cursor: pointer; overflow: hidden; }
.so-co-other.on { border: 1.5px solid #CC4A14; background: #FCE9DD; color: #A33A0E; font-weight: 700; }
.so-co-other input { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; cursor: pointer; border: 0; }
.so-co-seg { display: grid; grid-auto-columns: minmax(0, 1fr); grid-auto-flow: column; gap: 4px; background: #EFEAE4; border-radius: 14px; padding: 4px; }
.so-co-seg button { min-height: 42px; border-radius: 11px; border: 0; background: transparent; font: inherit; font-size: 14px; font-weight: 600; color: #4A433D; cursor: pointer; padding: 4px 6px; line-height: 1.2; }
.so-co-seg button.on { background: #FFFFFF; font-weight: 700; color: var(--ink); box-shadow: 0 1px 2px rgba(0, 0, 0, 0.08); }
.so-co-seg button:disabled { cursor: not-allowed; }
.so-co-s-when .so-co-card:nth-of-type(3) .so-co-seg button { min-height: 44px; font-size: 15px; }
.so-co-card > .so-co-h + .so-co-seg, .so-co-card > .so-co-h + .so-co-vis-row { margin-top: 0; }
.so-co-card > .so-co-h:not(:first-child) { margin-top: 4px; }
.so-co-vis-row { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.so-co-vis { border: 1.5px solid #D9D1C8; border-radius: 16px; padding: 12px; background: #FFFFFF; font: inherit; text-align: start; color: var(--ink); display: flex; flex-direction: column; gap: 2px; cursor: pointer; }
.so-co-vis.on { border: 2px solid #CC4A14; background: #FDF6F2; padding: 11.5px; }
.so-co-vis strong { font-weight: 700; font-size: 15px; }
.so-co-vis span { font-size: 13px; color: #4A433D; line-height: 1.35; }
.so-co-ages { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.so-co-ages .input { width: auto; flex: 1; min-width: 72px; height: 42px; }
.so-co-ages.off { opacity: 0.55; }
.so-co .ux-pro-tag .i { flex: none; }

/* ---------- step 11: review ---------- */
.so-co-preview { background: #FFFFFF; border: 1px solid #ECE6DF; border-radius: 24px; overflow: hidden; }
.so-co-banner { height: 150px; position: relative; display: flex; align-items: center; justify-content: center; text-decoration: none; }
.so-co-art svg { width: 96px; height: 96px; }
.so-co-fpill { position: absolute; inset-inline-start: 12px; bottom: 12px; padding: 4px 10px; border-radius: 999px; background: #FFFFFF; font-size: 12.5px; font-weight: 800; }
.so-co-prev-text { padding: 16px; display: flex; flex-direction: column; gap: 6px; text-decoration: none; color: var(--ink); }
.so-co-prev-text:hover { color: var(--ink); }
.so-co-prev-text strong { font-family: 'Bricolage Grotesque', sans-serif; font-size: 24px; font-weight: 700; line-height: 1.15; overflow-wrap: anywhere; }
[dir="rtl"] .so-co-prev-text strong { font-family: 'Readex Pro', 'IBM Plex Sans Arabic', sans-serif; line-height: 1.35; }
.so-co-prev-text > span { font-size: 15px; color: #4A433D; line-height: 1.45; }
.so-co-prev-text .so-co-promise { font-size: 14px; }
.so-co-rows { background: #FFFFFF; border: 1px solid #ECE6DF; border-radius: 20px; overflow: hidden; }
.so-co-row { min-height: 60px; padding: 10px 14px; display: flex; align-items: center; gap: 12px; text-decoration: none; color: var(--ink); }
.so-co-row + .so-co-row { border-top: 1px solid #F0ECE7; }
.so-co-row:hover { color: var(--ink); background: #FBFAF8; }
.so-co-row-k { width: 92px; flex: none; font-size: 13.5px; font-weight: 700; color: #6E655D; }
.so-co-row-v { flex: 1; min-width: 0; font-size: 15px; font-weight: 600; line-height: 1.35; overflow-wrap: anywhere; }
.so-co-row-e { font-size: 14px; font-weight: 700; color: #A33A0E; flex: none; }
.so-co-flowcard:hover { color: var(--ink); }
.so-co-flowbar { display: flex; height: 12px; border-radius: 6px; overflow: hidden; gap: 2px; }
.so-co-flowbar span:nth-child(1) { background: #F2B48F; }
.so-co-flowbar span:nth-child(2) { background: #CC4A14; }
.so-co-flowbar span:nth-child(3) { background: #8C3210; }
.so-co-flowlab { display: flex; gap: 2px; font-size: 12.5px; font-weight: 700; color: #4A433D; }
.so-co-flowlab span { white-space: nowrap; min-width: max-content; }
.so-co-flowlab span:nth-child(2) { text-align: center; }
.so-co-flowlab span:nth-child(3) { text-align: end; }
.so-co-check { background: #E9EFF6; border-radius: 20px; padding: 14px; display: flex; flex-direction: column; gap: 10px; color: #1E3A5F; }
.so-co-check-row { display: flex; gap: 10px; align-items: flex-start; background: #FFFFFF; border-radius: 14px; padding: 10px 12px; }
.so-co-check-row p, .so-co-check-row a { flex: 1; margin: 0; font-size: 14.5px; line-height: 1.4; color: #1E3A5F; }
.so-co-check-row a { font-weight: 700; text-decoration: underline; }
.so-co-mark { width: 22px; height: 22px; border-radius: 11px; flex: none; display: flex; align-items: center; justify-content: center; font-size: 13px; font-weight: 800; background: #FBEFD0; color: #744F00; }
.so-co-mark.ok { background: #DDF2EA; color: #0D5340; }
.so-co-check-hint { margin: 0; font-size: 13px; color: #4A5A70; }
.so-co-s-review .extra-row { border-top: 1px solid #F0ECE7; padding-top: 10px; }

/* ---------- share a video ---------- */
.so-nv-row { display: flex; gap: 8px; }
.so-nv-input { flex: 1; min-width: 0; height: 52px; border: 1.5px solid #D9D1C8; border-radius: 16px; padding: 0 14px; font: inherit; font-size: 16px; background: #FFFFFF; color: var(--ink); }
.so-nv-input::placeholder { color: #8A8178; }
.so-nv-check { height: 52px; padding: 0 16px; border-radius: 16px; border: 0; background: #FCE9DD; color: #A33A0E; font: inherit; font-weight: 700; font-size: 15px; cursor: pointer; flex: none; }
.so-nv .so-co-card .input { background: #FFFFFF; border: 1.5px solid #D9D1C8; border-radius: 16px; }
.so-nv .so-co-card .field { font-weight: 700; font-size: 15px; }
.so-nv .so-co-next { flex: none; margin-top: 4px; }

@media (max-width: 359px) {
  .so-co-stepper .step-btn { width: 36px; }
  .so-co-stepper .step-val { width: 32px; }
  .so-co-row-k { width: 76px; }
}
.so-co-foot > .so-co-next, .so-nv .so-co-next { flex: none; }
.so-co-else { align-self: flex-start; min-height: 44px; padding: 0 4px; border: 0; background: transparent; font: inherit; font-weight: 700; font-size: 15px; color: var(--accent-ink); text-decoration: underline; cursor: pointer; }

/* ---------- Recording a video in the app ---------- */
.rec-tabs { grid-template-columns: 1fr 1fr; }
.rec-card { display: flex; flex-direction: column; gap: 12px; }
.rec-stage { position: relative; aspect-ratio: 16 / 9; max-height: 60vh; width: 100%; border-radius: 18px; background: #221D19; overflow: hidden; display: flex; align-items: center; justify-content: center; }
.rec-stage.tall { aspect-ratio: 9 / 16; max-width: 340px; margin: 0 auto; }
.rec-video { width: 100%; height: 100%; object-fit: contain; background: #221D19; display: block; }
.rec-video.mirror { transform: scaleX(-1); }
.rec-empty { display: flex; flex-direction: column; align-items: center; gap: 10px; color: #CFC8C0; font-size: 14.5px; padding: 16px; text-align: center; }
.rec-timer { position: absolute; top: 12px; inset-inline-start: 12px; display: inline-flex; align-items: center; gap: 8px; padding: 5px 11px; border-radius: 999px; background: rgba(0, 0, 0, 0.55); color: #FFFFFF; font-size: 13.5px; font-weight: 700; font-variant-numeric: tabular-nums; direction: ltr; }
.rec-dot { width: 9px; height: 9px; border-radius: 5px; background: #E5484D; animation: rec-blink 1s steps(2) infinite; }
@keyframes rec-blink { 50% { opacity: 0.2; } }
@media (prefers-reduced-motion: reduce) { .rec-dot { animation: none; } }
.rec-actions { display: flex; align-items: center; justify-content: center; gap: 24px; }
.rec-actions .so-co-next { width: 100%; display: flex; align-items: center; justify-content: center; gap: 8px; }
.rec-go { width: 72px; height: 72px; border-radius: 36px; border: 4px solid #E0D8CF; background: #FFFFFF; display: flex; align-items: center; justify-content: center; cursor: pointer; padding: 0; }
.rec-go span { width: 52px; height: 52px; border-radius: 26px; background: #E5484D; transition: all 0.15s; }
.rec-go.stop span { width: 28px; height: 28px; border-radius: 6px; }
.rec-flip, .rec-flip-space { width: 48px; height: 48px; border-radius: 24px; flex: none; }
.rec-flip { border: 0; background: var(--bg); color: var(--ink); display: flex; align-items: center; justify-content: center; cursor: pointer; }
.rec-progress { height: 8px; border-radius: 4px; background: #F0ECE7; overflow: hidden; }
.rec-progress span { display: block; height: 100%; background: var(--accent); transition: width 0.2s; }
.v-own .v-native { width: 100%; max-height: 70vh; border-radius: 16px; background: #221D19; display: block; }
.v-own .v-native.tall { max-width: 360px; margin: 0 auto; aspect-ratio: 9 / 16; }
.v-thumb .v-frame { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.rec-again { flex: none; width: 100%; gap: 8px; }

/* ---------- The camera: full screen, Instagram-style ---------- */
body:has(.cam) { overflow: hidden; background: #000; }
.cam { position: fixed; inset: 0; z-index: 80; background: #000; color: #FFFFFF; display: flex; flex-direction: column; justify-content: space-between; overflow: hidden; }
.cam-feed { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; background: #000; }
.cam-feed.contain { object-fit: contain; }
.cam-feed.mirror { transform: scaleX(-1); }
.cam-top, .cam-bottom, .cam-hint, .cam-msg, .cam-count, .cam-err { position: relative; z-index: 2; }
.cam-top { display: flex; align-items: center; gap: 10px; padding: calc(12px + env(safe-area-inset-top)) 14px 12px; background: linear-gradient(rgba(0, 0, 0, 0.45), transparent); }
.cam-icon { position: relative; width: 44px; height: 44px; border-radius: 22px; border: 0; background: rgba(0, 0, 0, 0.35); color: #FFFFFF; display: flex; align-items: center; justify-content: center; cursor: pointer; }
.cam-icon.on { background: #FFFFFF; color: #000; }
.cam-badge { position: absolute; bottom: -2px; inset-inline-end: -2px; min-width: 18px; height: 18px; border-radius: 9px; background: var(--accent); color: #FFFFFF; font-size: 11px; font-weight: 800; display: flex; align-items: center; justify-content: center; }
.cam-time { display: inline-flex; align-items: center; gap: 8px; padding: 6px 12px; border-radius: 999px; background: rgba(0, 0, 0, 0.5); font-weight: 700; font-size: 15px; font-variant-numeric: tabular-nums; direction: ltr; }
.cam-count { position: absolute; inset: 0; z-index: 3; display: flex; align-items: center; justify-content: center; font-family: var(--display); font-size: 120px; font-weight: 800; text-shadow: 0 4px 30px rgba(0, 0, 0, 0.5); pointer-events: none; }
.cam-msg { margin: auto 24px; text-align: center; display: flex; flex-direction: column; align-items: center; gap: 14px; font-size: 16px; }
.cam-bottom { margin-top: auto; display: flex; align-items: center; justify-content: space-between; padding: 12px 28px 6px; background: linear-gradient(transparent, rgba(0, 0, 0, 0.5)); }
.cam-side { width: 52px; height: 52px; flex: none; }
.cam-gallery { border-radius: 14px; border: 2px solid #FFFFFF; display: flex; align-items: center; justify-content: center; cursor: pointer; background: rgba(0, 0, 0, 0.3); }
.cam-linkbtn { border: 0; border-radius: 26px; background: rgba(0, 0, 0, 0.35); color: #FFFFFF; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 1px; font: inherit; font-size: 11px; font-weight: 700; cursor: pointer; }
.cam-shutter { position: relative; width: 84px; height: 84px; border: 0; background: transparent; padding: 0; cursor: pointer; touch-action: none; -webkit-user-select: none; user-select: none; -webkit-touch-callout: none; }
.cam-shutter:disabled { opacity: 0.5; cursor: default; }
.cam-shutter svg { position: absolute; inset: 0; width: 100%; height: 100%; transform: rotate(-90deg); }
.cam-ring-bg { fill: none; stroke: rgba(255, 255, 255, 0.9); stroke-width: 6; }
.cam-ring { fill: none; stroke: #E5484D; stroke-width: 6; stroke-linecap: round; transition: stroke-dashoffset 0.1s linear; }
.cam:not(.rec) .cam-ring { stroke: transparent; }
.cam-dot { position: absolute; inset: 12px; border-radius: 50%; background: #FFFFFF; transition: all 0.15s; }
.cam.rec .cam-dot { inset: 26px; border-radius: 8px; background: #E5484D; }
.cam-hint { text-align: center; font-size: 13px; color: rgba(255, 255, 255, 0.85); margin: 0; padding: 0 16px calc(18px + env(safe-area-inset-bottom)); text-shadow: 0 1px 4px rgba(0, 0, 0, 0.6); }
.cam-pill { min-height: 48px; padding: 0 22px; border-radius: 24px; border: 0; background: #FFFFFF; color: #000; font: inherit; font-weight: 700; font-size: 16px; display: inline-flex; align-items: center; gap: 6px; cursor: pointer; }
.cam-pill.ghost { background: rgba(0, 0, 0, 0.5); color: #FFFFFF; border: 1.5px solid rgba(255, 255, 255, 0.6); }
.cam-pill.go { background: var(--accent); color: #FFFFFF; }
.review-btns { padding-bottom: calc(22px + env(safe-area-inset-bottom)); }
.cam-err { margin: 0 16px; }
.post-head { display: flex; align-items: center; gap: 14px; }
.post-thumb { width: 96px; aspect-ratio: 1; object-fit: cover; border-radius: 14px; background: #221D19; flex: none; }
.post-thumb.tall { aspect-ratio: 9 / 16; width: 72px; }
@media (min-width: 900px) { .cam { inset-inline-start: 0; } .cam-feed { object-fit: contain; } }
