/* ===== Offline Dictionary = owner's mockup layout and type sizes, calm theme colours (Claude Code 2026-11-12) =====
   gold = calm champagne #C9AE76 / #E4D2A0 lines (no glow), cards = the theme colour (--one), title / headings Cormorant.
   Loaded after settings-lux.css. Remove the <link> in index.html to go back to the earlier look. */
dialog.offpack-dlg.op-mock { --g: #C9AE76; --g2: #E4D2A0; --ink: #F4EEDF; --sub: rgba(244, 238, 223, .74); box-shadow: inset 0 0 0 1.5px var(--g), 0 18px 50px rgba(0, 0, 0, .45) !important; border: 0 !important; border-radius: 26px !important; }
dialog.op-mock .dlg-head { position: relative; display: flex; align-items: center; justify-content: center; gap: 12px; padding: 18px 56px 2px; }
dialog.op-mock .dlg-title { margin: 0; font: italic 700 1.75rem/1.1 'Cormorant Garamond', var(--serif); color: var(--g2); letter-spacing: .01em; text-align: center; }
dialog.op-mock .op-medal { position: absolute; left: 14px; top: 12px; width: 44px; height: 44px; display: grid; place-items: center; border-radius: 50%; color: var(--g2);
  background: color-mix(in srgb, var(--btn-a, #1B3155) 70%, #000); box-shadow: inset 0 0 0 1.5px var(--g); }
dialog.op-mock .op-medal .ic { width: 21px; height: 21px; }
dialog.op-mock .dlg-x { position: absolute; right: 14px; top: 12px; width: 40px; height: 40px; border-radius: 50%; color: var(--g2); background: color-mix(in srgb, var(--btn-a, #1B3155) 70%, #000) !important; box-shadow: inset 0 0 0 1.5px var(--g) !important; }
dialog.op-mock .op-head { text-align: center; margin: 0 0 14px; }
dialog.op-mock .op-sub { margin: 4px 0 0; font: italic 500 .98rem/1.3 var(--sans); color: var(--ink); }
dialog.op-mock .op-sub b { color: var(--g2); font-weight: 700; }
dialog.op-mock .op-orn { display: block; width: 180px; height: 12px; margin: 6px auto 0; color: var(--g); fill: var(--g); }
dialog.op-mock .op-orn-gem { fill: #7FB2E5; stroke: var(--g); stroke-width: .8; }
/* cards */
dialog.op-mock .op-card { margin: 0 0 10px !important; padding: 12px 14px !important; border-radius: 16px !important; background: color-mix(in srgb, var(--one) 92%, transparent) !important; box-shadow: inset 0 0 0 1.5px var(--g), 0 8px 20px rgba(0, 0, 0, .25) !important; }
/* language bar */
dialog.op-mock .op-lang { display: flex; align-items: center; gap: 12px; width: 100%; min-height: 54px; color: var(--ink); cursor: pointer; text-align: left; border: 0; }
dialog.op-mock .op-lang-l { display: inline-flex; align-items: center; gap: 8px; font: 700 1.12rem/1 'Cormorant Garamond', var(--serif); color: var(--g2); }
dialog.op-mock .op-lang-l .ic { width: 20px; height: 20px; color: var(--g2); }
dialog.op-mock .op-lang-div { width: 1px; align-self: stretch; margin: 6px 2px; background: color-mix(in srgb, var(--g) 60%, transparent); }
dialog.op-mock .op-lang .op-flag { font-size: 1.55rem; }
dialog.op-mock .op-lang-t { flex: 1; min-width: 0; }
dialog.op-mock .op-lang-t b { font: 700 1.22rem/1.2 var(--sans); color: var(--ink); white-space: normal; }
dialog.op-mock .op-lang-c .ic { width: 18px; height: 18px; color: var(--g2); }
/* Text / Voice cards */
dialog.op-mock .op-part { position: relative; display: flex !important; align-items: center; gap: 12px; overflow: hidden; cursor: pointer; }
dialog.op-mock .op-part.op-part-fixed { cursor: default; }
dialog.op-mock .op-cb { position: absolute; opacity: 0; width: 1px; height: 1px; }
dialog.op-mock .op-box { width: 22px; height: 22px; flex: none; display: grid; place-items: center; border-radius: 5px; box-shadow: inset 0 0 0 1.5px var(--g); color: transparent; }
dialog.op-mock .op-box .ic { width: 15px; height: 15px; }
dialog.op-mock .op-box.on { background: linear-gradient(180deg, #E4D2A0, #BFA060); color: #2A2112; box-shadow: none; }
dialog.op-mock .op-cb:focus-visible + .op-box { outline: 2px solid var(--g2); outline-offset: 2px; }
dialog.op-mock .op-pi { flex: none; color: var(--g2); display: grid; }
dialog.op-mock .op-pi .ic { width: 26px; height: 26px; }
dialog.op-mock .op-part-t { position: relative; z-index: 1; display: grid; gap: 3px; min-width: 0; }
dialog.op-mock .op-part-t b { display: inline-flex; align-items: center; gap: 10px; font: 700 1.3rem/1.1 'Cormorant Garamond', var(--serif); color: var(--ink); }
dialog.op-mock .op-part-t b em { font: 700 .66rem/1 var(--sans); font-style: normal; letter-spacing: .06em; text-transform: uppercase; padding: 4px 8px; border-radius: 999px; color: #2A3A12; background: #DCE9A8; }
dialog.op-mock .op-part-t small { font: 500 .84rem/1.35 var(--sans); color: var(--sub); opacity: 1; }
dialog.op-mock .op-wave { position: absolute; right: 10px; top: 50%; width: 110px; height: 30px; transform: translateY(-50%); fill: #7FB2E5; opacity: .4; pointer-events: none; }
/* Word Pack */
dialog.op-mock .op-size { padding: 10px 14px 12px !important; }
dialog.op-mock .op-size-tog { min-height: 0; padding: 0; row-gap: 4px; }
dialog.op-mock .op-size-h { display: inline-flex !important; align-items: center; gap: 8px; font: 700 1.2rem/1.1 'Cormorant Garamond', var(--serif); letter-spacing: 0; text-transform: none; color: var(--g2); }
dialog.op-mock .op-size-h .ic { width: 20px; height: 20px; }
dialog.op-mock .op-size-now { display: grid !important; gap: 2px; }
dialog.op-mock .op-size.is-open .op-size-now { display: none !important; }
dialog.op-mock .op-size-now b { font: 700 1.5rem/1.15 'Cormorant Garamond', var(--serif); color: var(--ink); }
dialog.op-mock .op-size-now small { display: inline-flex; align-items: center; gap: 6px; font: 500 .9rem/1.3 var(--sans); color: var(--sub); opacity: 1; }
dialog.op-mock .op-size-now small .ic { width: 16px; height: 16px; color: var(--g2); }
dialog.op-mock .op-saved-chev { width: 32px; height: 32px; box-shadow: inset 0 0 0 1.5px var(--g) !important; }
dialog.op-mock .op-saved-chev .ic { color: var(--g2) !important; }
dialog.op-mock .op-size .offpack-status { margin: 10px 0 0; display: block; }
dialog.op-mock .op-halves { display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; border-radius: 12px; box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--g) 70%, transparent); overflow: hidden; }
dialog.op-mock .op-half { display: inline-flex; align-items: center; justify-content: center; gap: 6px; padding: 8px; font: 500 .84rem/1.2 var(--sans); color: var(--sub); text-align: center; }
dialog.op-mock .op-half + .op-half { box-shadow: inset 1px 0 0 color-mix(in srgb, var(--g) 55%, transparent); font-style: italic; }
dialog.op-mock .op-half.ok { color: #9FE0B6; font-style: normal; }
dialog.op-mock .op-half .ic { width: 15px; height: 15px; flex: none; }
dialog.op-mock .op-clock { width: 15px; height: 15px; flex: none; border-radius: 50%; box-shadow: inset 0 0 0 1.5px var(--g2); position: relative; }
dialog.op-mock .op-clock::after { content: ""; position: absolute; left: 6.5px; top: 3px; width: 1.5px; height: 5px; background: var(--g2); }
/* Saved on This Device */
dialog.op-mock .op-saved { padding: 10px 14px !important; }
dialog.op-mock .op-saved .op-saved-h { display: inline-flex !important; align-items: center; gap: 8px; font: 700 1.2rem/1.1 'Cormorant Garamond', var(--serif) !important; letter-spacing: 0 !important; text-transform: none !important; color: var(--g2) !important; }
dialog.op-mock .op-saved .op-saved-h .ic { width: 20px; height: 20px; }
dialog.op-mock .op-saved-list { border-top: 0; }
dialog.op-mock .op-saved-row { min-height: 56px; border-top: 1px solid color-mix(in srgb, var(--g) 30%, transparent); }
dialog.op-mock .op-saved-row .op-flag { font-size: 1.5rem; }
dialog.op-mock .op-saved-n { font: 700 1.22rem/1.2 'Cormorant Garamond', var(--serif); color: var(--ink); }
dialog.op-mock .op-saved-n small { font: 500 .84rem/1.3 var(--sans); color: var(--sub); opacity: 1; }
dialog.op-mock .op-tk { width: 40px; height: 40px; background: none !important; color: color-mix(in srgb, var(--g2) 45%, transparent) !important; box-shadow: inset 0 0 0 1.5px color-mix(in srgb, var(--g) 45%, transparent) !important; }
dialog.op-mock .op-tk.ok { color: var(--g2) !important; box-shadow: inset 0 0 0 1.5px var(--g) !important; background: color-mix(in srgb, var(--g) 12%, transparent) !important; }
dialog.op-mock .op-tk .ic { width: 19px; height: 19px; }
/* footer */
dialog.op-mock .offpack-note { justify-content: center; gap: 8px; text-align: center; font: italic 500 .86rem/1.35 var(--sans); color: var(--sub); opacity: 1; }
dialog.op-mock .offpack-note > .ic { width: 17px; height: 17px; color: var(--g2); flex: none; }
dialog.op-mock .offpack-note .op-rmall { flex-basis: 100%; font-style: normal; }
/* phone fit: title on one line, subtitle one line, the wave never under the words */
dialog.op-mock .dlg-head { padding: 16px 50px 2px; }
dialog.op-mock .dlg-title { font-size: min(1.75rem, 7.4vw); white-space: nowrap; }
dialog.op-mock .op-medal { left: 12px; width: 40px; height: 40px; }
dialog.op-mock .dlg-x { right: 12px; }
dialog.op-mock .op-sub { font-size: min(.98rem, 4.1vw); }
dialog.op-mock .op-part:has(.op-wave) .op-part-t { padding-right: 64px; }
dialog.op-mock .op-wave { width: 70px; right: 8px; opacity: .3; }
dialog.op-mock .op-size-now small { font-size: .86rem; flex-wrap: wrap; }
/* ---- 9.5 pass (owner "yes fix", 2026-11-12) ---- */
/* 1. footer: the ⓘ sits inline with the note */
dialog.op-mock .offpack-note { display: block; text-align: center; margin: 4px 0 0; }
dialog.op-mock .op-note-t .ic { width: 16px; height: 16px; vertical-align: -3px; margin-right: 4px; color: var(--g2); }
dialog.op-mock .offpack-note .op-rmall { display: block; margin: 6px auto 0; }
/* 2. tighter so Download shows without scrolling on most phones */
dialog.op-mock .dlg-head { padding-top: 12px; }
dialog.op-mock .op-head { margin-bottom: 10px; }
dialog.op-mock .op-orn { margin-top: 4px; }
dialog.op-mock .op-card { margin-bottom: 8px !important; padding: 9px 12px !important; }
dialog.op-mock .op-lang { min-height: 44px; }
dialog.op-mock .op-part-t b { font-size: 1.2rem; }
dialog.op-mock .op-part-t small { font-size: .8rem; line-height: 1.3; }
dialog.op-mock .op-pi .ic { width: 23px; height: 23px; }
dialog.op-mock .op-size-now b { font-size: 1.35rem; }
dialog.op-mock .op-size .offpack-status { margin-top: 8px; }
dialog.op-mock .op-half { padding: 6px; }
dialog.op-mock .op-saved-row { min-height: 50px; }
dialog.op-mock .op-tk { width: 36px; height: 36px; }
dialog.op-mock .dlg-actions { padding-top: 6px; }
/* 3. Text is always included: a round, filled mark — not a square checkbox */
dialog.op-mock .op-box.op-always { border-radius: 50%; background: color-mix(in srgb, #9FE0B6 22%, transparent); color: #9FE0B6; box-shadow: inset 0 0 0 1.5px rgba(159, 224, 182, .6); }
dialog.op-mock .op-box.op-always .ic { width: 13px; height: 13px; }
/* 4. the header emblem is a plain gold symbol, not a button */
dialog.op-mock .op-medal { background: none !important; box-shadow: none !important; width: 30px; height: 30px; left: 16px; top: 16px; }
dialog.op-mock .op-medal .ic { width: 24px; height: 24px; opacity: .9; }
/* 5. one-line status */
dialog.op-mock .op-half { white-space: nowrap; font-size: .82rem; }
/* 6. the sound wave only where there is room */
@media (max-width: 479px) { dialog.op-mock .op-wave { display: none; } dialog.op-mock .op-part:has(.op-wave) .op-part-t { padding-right: 0; } }
/* iPad / tablet (owner photo 2026-11-12: the window stayed 410 px wide and the bigger tablet text overlapped the
   title, the × and the symbols): wider window on big screens, and the title sized from the window's own width */
dialog.offpack-dlg.op-mock { container-type: inline-size; }
dialog.op-mock .dlg-title { font-size: min(7.2cqi, 2.4rem) !important; }
dialog.op-mock .dlg-head { padding-left: 54px; padding-right: 54px; min-height: 44px; }
@media (min-width: 600px) {
  dialog.offpack-dlg.op-mock { width: min(600px, calc(100vw - 48px)); max-height: calc(100dvh - 48px); padding: 20px 22px; }
  dialog.op-mock .op-medal { left: 20px; top: 20px; }
  dialog.op-mock .dlg-x { right: 18px; top: 16px; }
  dialog.op-mock .op-sub { font-size: 1.02rem; }
  dialog.op-mock .op-card { padding: 12px 16px !important; }
}
/* a long name or label never runs under a key: text columns may shrink and wrap */
dialog.op-mock .op-size-tog, dialog.op-mock .op-saved-tog { grid-template-columns: minmax(0, 1fr) auto !important; }
dialog.op-mock .op-size-h, dialog.op-mock .op-saved .op-saved-h { min-width: 0; flex-wrap: wrap; }
dialog.op-mock .op-saved-row { gap: 10px; }
dialog.op-mock .op-saved-n { min-width: 0; }
/* tablets: one step larger type and keys so the wider window is filled and easy to read */
@media (min-width: 600px) {
  dialog.op-mock .op-sub { font-size: 1.1rem; }
  dialog.op-mock .op-lang { min-height: 56px; }
  dialog.op-mock .op-lang-l { font-size: 1.3rem; }
  dialog.op-mock .op-lang-l .ic, dialog.op-mock .op-size-h .ic, dialog.op-mock .op-saved .op-saved-h .ic { width: 22px; height: 22px; }
  dialog.op-mock .op-lang-t b { font-size: 1.35rem; }
  dialog.op-mock .op-lang .op-flag { font-size: 1.8rem; }
  dialog.op-mock .op-part-t b { font-size: 1.45rem; }
  dialog.op-mock .op-part-t small { font-size: .95rem; }
  dialog.op-mock .op-pi .ic { width: 28px; height: 28px; }
  dialog.op-mock .op-box { width: 26px; height: 26px; }
  dialog.op-mock .op-size-h, dialog.op-mock .op-saved .op-saved-h { font-size: 1.4rem !important; }
  dialog.op-mock .op-size-now b { font-size: 1.7rem; }
  dialog.op-mock .op-size-now small { font-size: 1rem; }
  dialog.op-mock .op-half { font-size: .95rem; padding: 9px; }
  dialog.op-mock .op-saved-n { font-size: 1.4rem; }
  dialog.op-mock .op-saved-n small { font-size: .95rem; }
  dialog.op-mock .op-saved-row .op-flag { font-size: 1.8rem; }
  dialog.op-mock .op-tk { width: 44px; height: 44px; }
  dialog.op-mock .op-tk .ic { width: 21px; height: 21px; }
  dialog.op-mock .op-saved-chev { width: 38px; height: 38px; }
  dialog.op-mock .offpack-note { font-size: .98rem; }
  dialog.op-mock #offGo { min-height: 56px; font-size: 1.1rem; }
}
/* owner 2026-11-12 "hide this": no "Remove all downloads" link (delete this rule to bring it back) */
dialog.op-mock .op-rmall { display: none !important; }
/* owner 2026-11-12: the internet note is joined into the subtitle ("Works with no internet — except Writing & Voice Translator.") */
dialog.op-mock .offpack-note { display: none !important; }
/* update view fixes: title a size up again (still fits beside the × and emblem); coin icon stays on the words line */
dialog.op-mock .dlg-title { font-size: clamp(1.4rem, 8cqi, 2.4rem) !important; }
dialog.op-mock .op-size-now small { display: block !important; }
dialog.op-mock .op-size-now small .ic { display: inline-block; vertical-align: -3px; margin-right: 5px; }
/* ===== one type rule (owner "yes all fix", 2026-11-12) =====
   Title: serif italic (only large text) · Labels: serif gold, one size · Values: sans white bold, one size ·
   Details + subtitle: sans grey, small, no italic */
dialog.op-mock { --t-label: 1.25rem; --t-value: 1.08rem; --t-detail: .84rem; }
/* subtitle: small, calm, not italic */
dialog.op-mock .op-sub { font: 500 var(--t-detail)/1.4 var(--sans) !important; font-style: normal !important; color: var(--sub); }
dialog.op-mock .op-sub b { color: var(--g2); font-weight: 700; }
/* labels — serif, gold, one size */
dialog.op-mock .op-lang-l,
dialog.op-mock .op-part-t b,
dialog.op-mock .op-size-h,
dialog.op-mock .op-saved .op-saved-h { font: 700 var(--t-label)/1.15 'Cormorant Garamond', var(--serif) !important; color: var(--g2) !important; letter-spacing: 0 !important; text-transform: none !important; }
dialog.op-mock .op-part-t b em { font-family: var(--sans); }
/* values — sans, white, bold, one size */
dialog.op-mock .op-lang-t b,
dialog.op-mock .op-size-now b,
dialog.op-mock .op-saved-n { font: 700 var(--t-value)/1.25 var(--sans) !important; color: var(--ink) !important; }
/* details — sans, grey, small, never italic */
dialog.op-mock .op-part-t small,
dialog.op-mock .op-size-now small,
dialog.op-mock .op-saved-n small,
dialog.op-mock .op-half,
dialog.op-mock .op-half + .op-half { font: 500 var(--t-detail)/1.35 var(--sans) !important; font-style: normal !important; }
dialog.op-mock .op-part-t small, dialog.op-mock .op-size-now small, dialog.op-mock .op-saved-n small { color: var(--sub) !important; }
dialog.op-mock .op-half { color: var(--sub); }
dialog.op-mock .op-half.ok { color: #9FE0B6; }
dialog.op-mock #offGo { font: 700 var(--t-value)/1 var(--sans) !important; }
/* tablets: the same rule, one step larger */
@media (min-width: 600px) { dialog.op-mock { --t-label: 1.42rem; --t-value: 1.22rem; --t-detail: .95rem; } }

/* 2026-11-12 owner: Word Pack = all headwords in downloads of max 500 MB — long list scrolls, later packs wait their turn */
.offpack-tiers:not([hidden]) { max-height: min(52vh, 460px); overflow-y: auto; overscroll-behavior: contain; scrollbar-width: thin; }
.offpack-tier.is-locked { opacity: .5; cursor: not-allowed; }
.offpack-tier.is-locked input { pointer-events: none; }

/* 2026-11-12 "Download all words" (every pack in order): full width, quiet outline under the gold Download */
.op-mock #offAll {
  width: 100%; margin-top: 8px; min-height: 46px; border-radius: 14px;
  background: color-mix(in srgb, var(--btn-a, #1B3155) 70%, #000); color: #F4EEDF;
  box-shadow: inset 0 0 0 1.5px #C9AE76; border: 0; font: 600 .95rem/1.2 Manrope, system-ui, sans-serif;
}
.op-mock #offAll:disabled { opacity: .7; }

/* 2026-11-12 owner: finished packs fold into one total line */
.op-mock .op-tier-sum {
  display: flex; align-items: center; gap: 8px; margin: 2px 0 8px; padding: 10px 14px; border-radius: 14px;
  background: color-mix(in srgb, #2E7D5B 22%, transparent); box-shadow: inset 0 0 0 1.5px rgba(111, 211, 160, .55);
  color: #E9F7EF; font: 700 1rem/1.25 Manrope, system-ui, sans-serif;
}
.op-mock .op-tier-sum[hidden] { display: none; }
.op-mock .op-tier-sum .ic { width: 18px; height: 18px; color: #6FD3A0; flex: none; }
.op-mock .op-tier-sum small { font-weight: 500; opacity: .8; margin-left: 2px; }
.op-mock .offpack-tier[hidden] { display: none !important; }
.op-mock .op-tier-sum > span { display: block; min-width: 0; }
.op-mock .op-tier-sum small { display: block; margin: 2px 0 0; font: 500 .82rem/1.2 Manrope, system-ui, sans-serif; opacity: .8; }

/* 2026-11-12 Check saved words */
.op-mock .op-check { margin-top: 10px; padding-top: 10px; border-top: 1px solid rgba(201, 174, 118, .35); }
.op-mock .op-check-h { font: 700 .84rem/1.3 Manrope, system-ui, sans-serif; color: #E4D2A0; margin-bottom: 8px; }
.op-mock .op-check-btns { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.op-mock .op-check-btns button, .op-mock .op-ck-fix {
  min-height: 42px; border: 0; border-radius: 12px; cursor: pointer; color: #F4EEDF;
  background: color-mix(in srgb, var(--btn-a, #1B3155) 70%, #000); box-shadow: inset 0 0 0 1.5px #C9AE76;
  font: 600 .9rem/1.2 Manrope, system-ui, sans-serif;
}
.op-mock .op-ck-fix { width: 100%; margin-top: 8px; background: #8A5A12; box-shadow: inset 0 0 0 1.5px #E4D2A0; }
.op-mock .op-check-out { margin-top: 8px; font: 500 .9rem/1.35 Manrope, system-ui, sans-serif; color: #F4EEDF; }
.op-mock .op-check-out:empty { display: none; }
.op-mock .op-ck-note { font-size: .8rem; opacity: .8; margin-bottom: 4px; }
.op-mock .op-ck-row { display: flex; align-items: center; gap: 8px; padding: 3px 0; }
.op-mock .op-ck-row .ic { width: 17px; height: 17px; flex: none; color: #6FD3A0; }
.op-mock .op-ck-row.bad { color: #F3C27A; }
.op-mock .op-ck-row.all { color: #9BE3BF; font-weight: 700; }
