*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --bg: #0d1117;
  --surface: #161b22;
  --surface-2: #21262d;
  --border: #30363d;
  --text: #e6edf3;
  --text-muted: #8b949e;
  --accent: #38bdf8;
  --success: #3fb950;
  --warning: #d29922;
  --danger: #f85149;
  --radius: 6px;
  --mono: 'Cascadia Code', 'Fira Code', 'JetBrains Mono', 'Consolas', monospace;
  --ui: -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--ui);
  font-size: 14px;
  height: 100vh;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

/* ── TOPBAR ── */
.topbar {
  height: 52px;
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 0 14px;
  flex-shrink: 0;
}

.brand {
  font-weight: 700;
  font-size: 15px;
  white-space: nowrap;
  margin-right: 6px;
}

.brand-wordmark {
  display: inline-flex;
  align-items: baseline;
}

.brand-pre {
  color: var(--accent);
}

.brand-code {
  color: var(--success);
}

.space-controls { display: flex; gap: 7px; align-items: center; flex: 1; }

.space-controls input {
  background: var(--surface-2);
  border: 1px solid var(--border);
  color: var(--text);
  padding: 5px 9px;
  border-radius: var(--radius);
  font-size: 13px;
  font-family: var(--mono);
  outline: none;
  transition: border-color 0.15s;
}
.space-controls input:focus { border-color: var(--accent); }
#spaceCode { width: 120px; text-transform: uppercase; letter-spacing: 2px; }
#spacePassword { width: 130px; }

.status { display: flex; align-items: center; gap: 6px; color: var(--text-muted); font-size: 12px; white-space: nowrap; }
.status-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--text-muted); flex-shrink: 0; }
.status-dot.online  { background: var(--success); }
.status-dot.syncing { background: var(--warning); animation: pulse 1s infinite; }
.status-dot.offline { background: var(--text-muted); }

@keyframes pulse { 0%,100%{opacity:1} 50%{opacity:.3} }
@keyframes sweep { 0%{background-position:200% 0} 100%{background-position:-200% 0} }

.hidden { display: none !important; }

.mode-switch {
  display: inline-grid;
  grid-template-columns: repeat(3, minmax(72px, auto));
  gap: 1px;
  background: var(--border);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  flex-shrink: 0;
}

.mode-switch-btn {
  border: 0;
  border-radius: 0;
  height: 30px;
  background: var(--surface-2);
  color: var(--text-muted);
  font-size: 12px;
  padding: 0 12px;
}

.mode-switch-btn.active {
  background: rgba(56,189,248,.12);
  color: var(--accent);
  font-weight: 700;
}

.convert-bar {
  min-height: 45px;
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  flex-shrink: 0;
}

.support-strip {
  min-height: 30px;
  background: #101820;
  border-bottom: 1px solid var(--border);
  color: var(--text-muted);
  display: flex;
  align-items: center;
  padding: 6px 14px;
  font-size: 11px;
  line-height: 1.35;
  flex-shrink: 0;
}

.support-strip strong {
  color: var(--text);
  font-weight: 600;
}

.convert-label {
  color: var(--text-muted);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 1px;
  text-transform: uppercase;
}

.convert-bar select {
  min-width: 140px;
}

.prepare-controls,
.sync-controls {
  display: flex;
  align-items: center;
  gap: 6px;
}

/* ── PANEL PROGRESS BAR ── */
.panel-progress {
  height: 2px;
  flex-shrink: 0;
  background: linear-gradient(90deg, transparent 0%, var(--accent) 50%, transparent 100%);
  background-size: 200% 100%;
  animation: sweep 1.2s linear infinite;
}
.panel-progress.hidden { display: none; }

/* ── PANELS ── */
.panels {
  display: flex;
  flex: 1;
  overflow: hidden;
  gap: 1px;
  background: var(--border);
  min-height: 0;
}

.panel { flex: 1; display: flex; flex-direction: column; background: var(--bg); overflow: hidden; }

.panel-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 7px 12px;
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 1px;
  color: var(--text-muted);
  flex-shrink: 0;
}

.panel-actions { display: flex; align-items: center; gap: 7px; }

.badge {
  background: var(--surface-2);
  border: 1px solid var(--border);
  color: var(--text-muted);
  padding: 2px 8px;
  border-radius: 99px;
  font-size: 11px;
  font-family: var(--mono);
  white-space: nowrap;
}
.badge.detected { border-color: var(--accent); color: var(--accent); }
.badge.synced   { border-color: var(--success); color: var(--success); }

textarea {
  flex: 1;
  background: var(--bg);
  color: var(--text);
  border: none;
  outline: none;
  resize: none;
  padding: 12px;
  font-family: var(--mono);
  font-size: 13px;
  line-height: 1.65;
  tab-size: 2;
  width: 100%;
}
textarea::placeholder { color: var(--text-muted); opacity: 0.5; }
#outputCode { color: #adbac7; }

.panel-toolbar {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 7px 12px;
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  flex-shrink: 0;
}

.hint {
  font-size: 10px;
  color: var(--text-muted);
  opacity: 0.7;
  white-space: nowrap;
}

.spacer { flex: 1; }

/* ── PANEL FOOTER (connection controls) ── */
.panel-footer {
  border-top: 1px solid var(--border);
  border-bottom: none;
}

.panel-toolbar input {
  background: var(--surface-2);
  border: 1px solid var(--border);
  color: var(--text);
  padding: 5px 9px;
  border-radius: var(--radius);
  font-size: 13px;
  font-family: var(--mono);
  outline: none;
  transition: border-color 0.15s;
}
.panel-toolbar input:focus { border-color: var(--accent); }
#spaceCode { width: 110px; text-transform: uppercase; letter-spacing: 2px; }
#spacePassword { width: 168px; }

/* ── AI PANEL ── */
.ai-panel {
  background: var(--surface);
  border-top: 2px solid var(--border);
  display: none;          /* shown via .visible after decryption */
  flex-direction: column;
  flex-shrink: 0;
}
.ai-panel.visible { display: flex; }

.ai-header {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 7px 14px;
  border-bottom: 1px solid var(--border);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 1px;
  color: var(--text-muted);
}

.ai-body { display: flex; gap: 10px; padding: 10px 14px; align-items: stretch; }

#aiCustomPrompt {
  flex: 1;
  background: var(--surface-2);
  border: 1px solid var(--border);
  color: var(--text);
  border-radius: var(--radius);
  padding: 8px 10px;
  font-family: var(--ui);
  font-size: 13px;
  resize: none;
  height: 60px;
  max-height: 80px;
}
#aiCustomPrompt:focus { border-color: var(--accent); outline: none; }

.ai-actions { display: flex; flex-direction: column; gap: 5px; justify-content: center; }

/* ── BUTTONS ── */
button {
  background: var(--surface-2);
  border: 1px solid var(--border);
  color: var(--text);
  padding: 5px 11px;
  border-radius: var(--radius);
  font-size: 12px;
  cursor: pointer;
  white-space: nowrap;
  font-family: var(--ui);
  transition: background 0.12s, border-color 0.12s;
}
button:hover { background: var(--border); }
button:disabled { opacity: 0.55; cursor: not-allowed; pointer-events: none; }
button:active { opacity: 0.8; }

button.primary { background: var(--accent); border-color: var(--accent); color: #0d1117; font-weight: 600; }
button.primary:hover { filter: brightness(1.1); }

button.success { background: var(--success); border-color: var(--success); color: #0d1117; font-weight: 600; }

button.toggle { color: var(--text-muted); border-color: var(--border); }
button.toggle.active { color: var(--accent); border-color: var(--accent); background: rgba(56,189,248,.08); }

.toolbar-sep { width: 1px; height: 18px; background: var(--border); flex-shrink: 0; margin: 0 2px; }

button.btn-icon {
  padding: 0;
  width: 28px;
  height: 28px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
button.btn-icon svg { width: 14px; height: 14px; stroke: var(--text-muted); transition: stroke 0.12s; }
button.btn-icon:hover svg { stroke: var(--text); }

button.ai-btn { font-size: 12px; padding: 6px 12px; }
button.ia { background: #cc785c18; border-color: #cc785c80; color: #cc785c; }
button.ia:hover { background: #cc785c30; }
button.gpt   { background: #74aa9c18; border-color: #74aa9c80; color: #74aa9c; }
button.gpt:hover { background: #74aa9c30; }

select {
  background: var(--surface-2);
  border: 1px solid var(--border);
  color: var(--text);
  padding: 4px 7px;
  border-radius: var(--radius);
  font-size: 12px;
  font-family: var(--ui);
  cursor: pointer;
  outline: none;
}
select:focus { border-color: var(--accent); }

/* ── MODAL (encrypted output) ── */
.modal-overlay {
  position: fixed; inset: 0;
  background: rgba(0,0,0,0.7);
  display: flex; align-items: center; justify-content: center;
  z-index: 200;
}
.modal-overlay.hidden { display: none; }

.modal {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 20px;
  width: 600px;
  max-width: 90vw;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.modal-title { font-weight: 700; font-size: 14px; }
.modal-desc  { font-size: 12px; color: var(--text-muted); }
.modal-code  { font-family: var(--mono); font-size: 12px; background: var(--bg); border: 1px solid var(--border); border-radius: var(--radius); padding: 10px; word-break: break-all; max-height: 200px; overflow-y: auto; user-select: all; }
.modal-footer { display: flex; gap: 8px; justify-content: flex-end; }

/* ── FREE ACCESS CAPTURE ── */
.access-overlay {
  position: fixed;
  inset: 0;
  z-index: 400;
  display: grid;
  place-items: center;
  padding: 18px;
  background: rgba(13,17,23,.88);
  backdrop-filter: blur(10px);
}

.access-overlay.hidden {
  display: none;
}

.access-modal {
  width: min(420px, 100%);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 22px;
  box-shadow: 0 18px 54px rgba(0,0,0,.34);
}

.access-brand {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 18px;
  color: var(--text-muted);
  font-size: 12px;
  font-weight: 700;
}

.access-modal h2 {
  margin-bottom: 8px;
  color: var(--text);
  font-size: 22px;
  line-height: 1.2;
}

.access-modal p {
  color: var(--text-muted);
  font-size: 13px;
  line-height: 1.55;
}

.access-modal label {
  display: grid;
  gap: 6px;
  margin-top: 14px;
  color: var(--text);
  font-size: 12px;
  font-weight: 700;
}

.access-modal input {
  min-height: 40px;
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--text);
  font: 14px var(--ui);
  outline: none;
  padding: 8px 10px;
}

.access-modal input:focus {
  border-color: var(--accent);
}

.access-modal button {
  width: 100%;
  min-height: 42px;
  margin-top: 16px;
}

.access-note {
  min-height: 20px;
  margin-top: 10px;
  text-align: center;
}

/* ── TOAST ── */
.toast {
  position: fixed;
  bottom: 18px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--surface-2);
  border: 1px solid var(--border);
  color: var(--text);
  padding: 7px 16px;
  border-radius: var(--radius);
  font-size: 13px;
  box-shadow: 0 4px 14px rgba(0,0,0,0.5);
  z-index: 300;
  transition: opacity 0.25s;
  pointer-events: none;
}
.toast.hidden  { opacity: 0; }
.toast.success { border-color: var(--success); color: var(--success); }
.toast.error   { border-color: var(--danger);  color: var(--danger);  }
.toast.warning { border-color: var(--warning); color: var(--warning); }

/* ── ANON REPORT ── */
.anon-report {
  position: fixed;
  top: 60px; right: 16px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 12px 16px;
  font-size: 12px;
  max-width: 280px;
  z-index: 150;
  box-shadow: 0 4px 14px rgba(0,0,0,0.4);
  transition: opacity 0.3s;
}
.anon-report.hidden { opacity: 0; pointer-events: none; }
.anon-report h4 { font-size: 11px; font-weight: 700; letter-spacing: 0.8px; color: var(--text-muted); margin-bottom: 8px; }
.anon-item { display: flex; justify-content: space-between; gap: 12px; padding: 3px 0; border-bottom: 1px solid var(--border); }
.anon-item:last-child { border-bottom: none; }
.anon-type  { color: var(--warning); font-family: var(--mono); font-size: 11px; }
.anon-orig  { color: var(--text-muted); font-family: var(--mono); font-size: 11px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 160px; }

/* ── MOBILE ── */
@media (max-width: 768px) {
  body { height: auto; min-height: 100vh; overflow-y: auto; }

  .panels {
    flex-direction: column;
    overflow: visible;
    background: none;
    gap: 0;
  }

  .panel { overflow: visible; }

  textarea {
    height: 220px;
    flex: none;
  }

	  .panel-toolbar {
	    flex-wrap: wrap;
	    gap: 5px;
	  }

	  .topbar {
	    flex-wrap: wrap;
	    height: auto;
	    min-height: 52px;
	    padding: 8px 14px;
	  }

	  .mode-switch {
	    order: 3;
	    width: 100%;
	    grid-template-columns: repeat(3, 1fr);
	  }

	  .convert-bar {
	    flex-wrap: wrap;
	  }

	  .support-strip {
	    align-items: flex-start;
	  }

	  .convert-bar select {
	    flex: 1;
	    min-width: 120px;
	  }

	  .panel-toolbar input { flex: 1; min-width: 80px; }
  #spaceCode    { width: auto; min-width: 90px; }
  #spacePassword { width: auto; flex: 1; }

  .toolbar-sep { display: none; }

  .ai-body { flex-direction: column; }
}

/* ── BRAND LINK ── */
a.brand { text-decoration: none; }

/* ── MODAL SIZE INFO ── */
.modal-size-info {
  font-size: 11px;
  margin: 4px 0 8px;
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
}

/* ── ANON CLOSE ROW ── */
.anon-close-row { margin-top: 8px; text-align: right; }
.btn-anon-close  { font-size: 11px; padding: 3px 8px; }

/* ── TEXT UTILITY CLASSES (used in JS-generated HTML) ── */
.text-success { color: var(--success); }
.text-warning { color: var(--warning); }
.text-muted   { color: var(--text-muted); }

/* ── HOME PAGE ── */
body.home-page { overflow: auto; display: block; min-height: 100vh; }
.home          { max-width: 760px; margin: 64px auto; padding: 0 24px 64px; }
.home-brand    { font-size: 26px; font-weight: 700; color: var(--accent); margin-bottom: 6px; }
.home-tagline  { color: var(--text-muted); margin-bottom: 40px; font-size: 14px; }
.tools-grid    { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 14px; }
.tool-card     { background: var(--surface); border: 1px solid var(--border); border-radius: 8px; padding: 20px; text-decoration: none; color: var(--text); transition: border-color 0.15s, box-shadow 0.15s; display: flex; flex-direction: column; gap: 6px; }
.tool-card:hover { border-color: var(--accent); box-shadow: 0 0 0 1px rgba(56,189,248,0.125); }
.tool-card.soon  { opacity: 0.45; cursor: default; pointer-events: none; }
.tool-icon  { font-size: 22px; }
.tool-name  { font-weight: 700; font-size: 14px; }
.tool-desc  { font-size: 12px; color: var(--text-muted); line-height: 1.5; }
.tool-badge { background: var(--surface-2); color: var(--text-muted); font-size: 10px; padding: 2px 7px; border-radius: 4px; border: 1px solid var(--border); align-self: flex-start; margin-top: 4px; }

/* ── FOCUS TIMER ── */
body.focus-page {
  min-height: 100vh;
  overflow-y: auto;
}

.focus-shell {
  flex: 1;
  display: grid;
  place-items: center;
  padding: 28px 18px;
}

.focus-with-tasks {
  grid-template-columns: minmax(360px, 620px) minmax(280px, 380px);
  align-items: stretch;
  justify-content: center;
  gap: 16px;
}

.focus-panel {
  width: min(620px, 100%);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 22px;
  box-shadow: 0 10px 28px rgba(0,0,0,.18);
}

.focus-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 18px;
}

.section-kicker {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 1px;
  color: var(--text-muted);
  margin-bottom: 6px;
}

.focus-header h1 {
  font-size: 22px;
  line-height: 1.15;
  color: var(--text);
}

.focus-count {
  min-width: 84px;
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 10px 12px;
  text-align: right;
}

.focus-count span {
  display: block;
  font-family: var(--mono);
  font-size: 24px;
  font-weight: 700;
  color: var(--accent);
  line-height: 1;
}

.focus-count small,
.focus-stats small {
  color: var(--text-muted);
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: .06em;
}

.focus-header-actions {
  display: flex;
  align-items: flex-start;
  gap: 8px;
}

.alert-toggle {
  color: var(--text-muted);
}

.alert-toggle.active {
  border-color: var(--accent);
  color: var(--accent);
  background: rgba(56,189,248,.08);
}

.mode-tabs {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  background: var(--border);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  margin-bottom: 22px;
}

.mode-tab {
  border: 0;
  border-radius: 0;
  background: var(--surface-2);
  color: var(--text-muted);
  height: 38px;
}

.mode-tab.active {
  background: rgba(56,189,248,.12);
  color: var(--accent);
  font-weight: 700;
}

.timer-face {
  position: relative;
  width: min(340px, 78vw);
  aspect-ratio: 1;
  margin: 6px auto 22px;
}

.timer-face svg {
  width: 100%;
  height: 100%;
}

.timer-track,
.timer-progress {
  fill: none;
  stroke-width: 10;
}

.timer-track {
  stroke: var(--surface-2);
}

.timer-progress {
  stroke: var(--accent);
  stroke-linecap: round;
  transform: rotate(-90deg);
  transform-origin: 50% 50%;
  transition: stroke-dashoffset .25s linear;
}

.timer-center {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 20px;
}

.timer-mode {
  color: var(--text-muted);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  margin-bottom: 8px;
}

.timer-time {
  font-family: var(--mono);
  font-size: clamp(42px, 10vw, 64px);
  line-height: 1;
  color: var(--text);
}

.timer-next {
  color: var(--text-muted);
  font-size: 12px;
  margin-top: 12px;
}

.timer-controls {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin-bottom: 20px;
}

.timer-primary {
  min-width: 132px;
  height: 40px;
}

.focus-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}

.focus-stats div {
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 10px 12px;
}

.focus-stats span {
  display: block;
  font-family: var(--mono);
  font-size: 18px;
  font-weight: 700;
  color: var(--text);
}

.timer-help {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  border-top: 1px solid var(--border);
  margin-top: 16px;
  padding-top: 12px;
  color: var(--text-muted);
  font-size: 11px;
  line-height: 1.5;
}

.task-panel {
  width: min(380px, 100%);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 18px;
  box-shadow: 0 10px 28px rgba(0,0,0,.18);
  display: flex;
  flex-direction: column;
  min-height: 0;
}

.task-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
}

.task-header h2 {
  font-size: 18px;
  line-height: 1.2;
}

.task-count {
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: 99px;
  color: var(--text-muted);
  font-size: 11px;
  padding: 4px 8px;
  white-space: nowrap;
}

.task-form {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 8px;
  margin-bottom: 10px;
}

.task-form input {
  min-width: 0;
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--text);
  font-family: var(--ui);
  font-size: 13px;
  outline: none;
  padding: 8px 10px;
}

.task-form input:focus {
  border-color: var(--accent);
}

.task-filters {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  background: var(--border);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  margin-bottom: 12px;
}

.task-filter {
  border: 0;
  border-radius: 0;
  background: var(--surface-2);
  color: var(--text-muted);
  height: 32px;
}

.task-filter.active {
  background: rgba(56,189,248,.12);
  color: var(--accent);
  font-weight: 700;
}

.task-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
  overflow-y: auto;
  min-height: 230px;
  max-height: 420px;
  padding-right: 2px;
}

.task-item {
  display: grid;
  grid-template-columns: 28px 1fr 28px;
  align-items: center;
  gap: 8px;
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 8px;
}

.task-item.done {
  opacity: .65;
}

.task-title {
  min-width: 0;
  color: var(--text);
  font-size: 13px;
  line-height: 1.35;
  overflow-wrap: anywhere;
}

.task-item.done .task-title {
  color: var(--text-muted);
  text-decoration: line-through;
}

.task-check,
.task-delete {
  width: 28px;
  height: 28px;
  padding: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.task-check {
  border-color: var(--border);
  color: var(--success);
  font-weight: 700;
}

.task-delete {
  color: var(--text-muted);
}

.task-delete:hover {
  color: var(--danger);
  border-color: var(--danger);
}

.task-empty {
  border: 1px dashed var(--border);
  border-radius: var(--radius);
  color: var(--text-muted);
  font-size: 13px;
  padding: 16px;
  text-align: center;
}

.task-footer {
  border-top: 1px solid var(--border);
  margin-top: 12px;
  padding-top: 12px;
  text-align: right;
}

@media (max-width: 620px) {
  .focus-shell {
    display: block;
    padding: 16px;
  }

  .focus-panel,
  .task-panel {
    width: 100%;
    padding: 16px;
  }

  .task-panel {
    margin-top: 16px;
  }

  .focus-header {
    align-items: stretch;
    flex-direction: column;
  }

  .focus-header-actions {
    align-items: center;
  }

  .focus-count {
    text-align: left;
  }

  .mode-tabs,
  .focus-stats {
    grid-template-columns: 1fr;
  }

  .timer-face {
    width: min(280px, 72vw);
  }

  .timer-help {
    align-items: flex-start;
    flex-direction: column;
  }
}
