/* ===== Look v3: Liquid Glass =====
   Loaded after portal.css (view.document) and layered over it, the way "Look v2" and "Detailo colours"
   were: the same pages, the same classes, a new surface. Translucent, frosted surfaces over a soft
   coloured light; pill buttons and tabs; depth from light and shadow instead of borders; calm motion.

   Rules kept on purpose:
   - Text sits on surfaces at least 72% white, so contrast stays as before (muted grey ≥ 4.5:1).
   - backdrop-filter only on the chrome that floats (side menu, phone bars, sticky bars, toasts): a
     blurred ancestor would trap position:fixed children (the phone's date picker, the + button), and
     blurring every card costs phones too much. Cards get their glass from translucency and light.
   - Every movement has a prefers-reduced-motion off switch at the end of this file.
   - Without backdrop-filter (old browsers) the floating surfaces turn nearly opaque. */

:root {
  --glass-bg: #eef1f6;
  --glass: rgba(255, 255, 255, 0.74);
  --glass-strong: rgba(255, 255, 255, 0.86);
  --glass-soft: rgba(255, 255, 255, 0.55);
  --glass-hi: inset 0 1px 0 rgba(255, 255, 255, 0.95), inset 0 0 0 1px rgba(255, 255, 255, 0.55);
  --glass-edge: 0 0 0 1px rgba(20, 33, 61, 0.06);
  --glass-shadow: 0 1px 2px rgba(20, 33, 61, 0.05), 0 8px 24px rgba(20, 33, 61, 0.07);
  --glass-lift: 0 2px 4px rgba(20, 33, 61, 0.06), 0 16px 40px rgba(20, 33, 61, 0.12);
  --glass-blur: saturate(185%) blur(22px);
  --muted: #58585e;
  --row: rgba(244, 246, 250, 0.92);
  --radius: 18px;
  --radius-s: 13px;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --shadow: var(--glass-edge), var(--glass-shadow);
  --shadow-card: var(--glass-edge), 0 1px 2px rgba(20, 33, 61, 0.05), 0 4px 12px rgba(20, 33, 61, 0.05);
  --shadow-lift: var(--glass-edge), var(--glass-lift);
}


/* ---------- Side menu: a floating pane of glass ---------- */
@media (min-width: 861px) {
  .shell { grid-template-columns: 248px minmax(0, 1fr); }
  .side {
    top: 0.75rem; height: calc(100vh - 1.5rem); margin: 0.75rem 0 0.75rem 0.75rem;
    border-radius: 24px; border: 0;
    background: rgba(255, 255, 255, 0.58);
    -webkit-backdrop-filter: var(--glass-blur); backdrop-filter: var(--glass-blur);
    box-shadow: var(--glass-hi), var(--glass-edge), 0 10px 40px rgba(20, 33, 61, 0.08);
    padding: 1rem 0.7rem 0.75rem;
  }
  .content { padding: 1.6rem 1.9rem 3.5rem; }
}
.nav { gap: 0.1rem; scrollbar-width: thin; scrollbar-color: rgba(20, 33, 61, 0.18) transparent; }
.nav-label { margin: 0.95rem 0.75rem 0.25rem; font-size: 0.7rem; letter-spacing: 0.07em; color: #6b6b71; }
.nav a, .nav-foot a, button.link {
  border-radius: 999px; padding: 0.44rem 0.8rem;
  transition: background 0.2s var(--ease), color 0.2s var(--ease), box-shadow 0.2s var(--ease);
}
.nav a:hover, .nav-foot a:hover, button.link:hover { background: rgba(255, 255, 255, 0.7); }
.nav a.on, .nav-foot a.on {
  background: rgba(255, 255, 255, 0.95); color: var(--accent); font-weight: 600;
  box-shadow: 0 1px 2px rgba(20, 33, 61, 0.08), 0 4px 14px rgba(20, 33, 61, 0.08), inset 0 0 0 1px rgba(20, 33, 61, 0.05);
}
.nav-count { box-shadow: 0 1px 3px rgba(215, 0, 21, 0.3); }
.nav-foot { border-top: 1px solid rgba(20, 33, 61, 0.07); }
.powered-by { border-top: 0 !important; }
.rail-search input {
  border-radius: 999px; background: rgba(20, 33, 61, 0.05); box-shadow: inset 0 0 0 1px rgba(20, 33, 61, 0.04);
  padding-left: 2.1rem;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%238a8a90' stroke-width='2' stroke-linecap='round'%3E%3Ccircle cx='11' cy='11' r='6.5'/%3E%3Cpath d='m20 20-4-4'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: 0.75rem center; background-size: 0.95rem;
}
.rail-search input:focus { background-color: rgba(255, 255, 255, 0.95); }
.nav a.set-link { display: flex; align-items: center; gap: 0.55rem; }
.nav a.set-link svg { width: 1.05rem; height: 1.05rem; flex: none; opacity: 0.75; }

/* ---------- Headings and the page's first breath ---------- */
h1 { letter-spacing: -0.035em; }
.content > :is(.head, .set-main > .head) h1, .head h1 { font-size: 2rem; }
@media (max-width: 860px) { .head h1 { font-size: 1.55rem; } }
.lead { color: var(--muted); }
/* Page to page: the browser's own cross-fade (View Transitions), never a page held half-drawn; the side
   menu and the phone's tab bar stay put while the page under them changes. Browsers without it just change page. */
@view-transition { navigation: auto; }
.side { view-transition-name: side; }
.tabbar { view-transition-name: tabbar; }
::view-transition-old(root), ::view-transition-new(root) { animation-duration: 0.22s; animation-timing-function: ease-out; }

/* ---------- Cards: frosted, borderless ---------- */
.box, .board, .tile, .table, .cal, .orders-find, .shelf-card, .unit, .set-card, .feature-card, .plan-card,
.sc-section, .photo-card, .look-preview, .vs-box {
  background: var(--glass);
  border: 0; border-radius: var(--radius);
  box-shadow: var(--glass-hi), var(--shadow);
}
.box { padding: 1.1rem 1.2rem; }
details.box > summary { list-style: none; display: flex; align-items: center; gap: 0.5rem; }
details.box > summary::-webkit-details-marker { display: none; }
details.box > summary::after {
  content: ""; margin-left: auto; width: 0.5rem; height: 0.5rem; flex: none;
  border-right: 2px solid currentColor; border-bottom: 2px solid currentColor; opacity: 0.45;
  transform: rotate(45deg) translateY(-2px); transition: transform 0.25s var(--ease);
}
details.box[open] > summary::after { transform: rotate(225deg) translateY(-2px); }
.board .cal, .board > .table { background: transparent; box-shadow: none; }
.stat { position: relative; overflow: hidden; }
a.box.stat::after { content: ""; position: absolute; inset: 0; border-radius: inherit; pointer-events: none;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.55), transparent 45%); }
.stat-icon { border-radius: 12px; box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.7); }
.drop, .trip, .desk-job, .job-row, .ledger li, .memo, .wo-note, .core-note { background: var(--row); }
.slip, .drop, .desk-job { border-radius: var(--radius-s); }
a.box.stat, .shelf-card, .unit, a.alert, .set-card, .feature-card, .slip, .drop, .desk-job {
  transition: box-shadow 0.3s var(--ease), transform 0.3s var(--ease), background 0.3s var(--ease);
}
a.box.stat:hover, .shelf-card:hover, .unit:hover, .set-card:hover, .feature-card:hover {
  transform: translateY(-2px); box-shadow: var(--glass-hi), var(--shadow-lift); background: var(--glass-strong);
}

/* ---------- Buttons: pills with light on top ---------- */
.btn, button.btn {
  border-radius: 999px; padding: 0 1.15rem; font-weight: 600; letter-spacing: -0.01em;
  background: linear-gradient(180deg, #2a3b62 0%, var(--accent) 55%, #101a31 100%);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.22), 0 1px 2px rgba(20, 33, 61, 0.25), 0 6px 16px rgba(20, 33, 61, 0.18);
  transition: transform 0.18s var(--ease), box-shadow 0.25s var(--ease), background 0.25s var(--ease), filter 0.2s;
}
.btn:hover { background: linear-gradient(180deg, #33476f 0%, var(--accent-hover) 55%, #14213d 100%); transform: translateY(-1px);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.25), 0 2px 4px rgba(20, 33, 61, 0.25), 0 10px 24px rgba(20, 33, 61, 0.22); }
.btn:active { transform: translateY(0) scale(0.98); filter: brightness(0.95); }
.btn.line, .btn.danger {
  background: rgba(255, 255, 255, 0.78); color: var(--ink);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.95), 0 0 0 1px rgba(20, 33, 61, 0.1), 0 2px 8px rgba(20, 33, 61, 0.06);
}
.btn.line:hover { background: rgba(255, 255, 255, 0.95); box-shadow: inset 0 1px 0 #fff, 0 0 0 1px rgba(20, 33, 61, 0.14), 0 8px 20px rgba(20, 33, 61, 0.1); }
.btn.danger { color: var(--danger); box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.95), 0 0 0 1px rgba(215, 0, 21, 0.25), 0 2px 8px rgba(215, 0, 21, 0.06); }
.btn.danger:hover { background: #fff5f5; }
.btn[disabled], button.btn:disabled { opacity: 0.55; transform: none; cursor: default; }
.navbtn { border: 0; background: var(--glass-strong); box-shadow: var(--glass-hi), 0 0 0 1px rgba(20, 33, 61, 0.08), 0 2px 8px rgba(20, 33, 61, 0.06); }

/* ---------- Chips and tabs: a segmented glass control ---------- */
.chip {
  border-radius: 999px; background: rgba(255, 255, 255, 0.62);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.9), 0 0 0 1px rgba(20, 33, 61, 0.08);
  transition: background 0.2s var(--ease), box-shadow 0.2s var(--ease), color 0.2s;
}
.chip:hover { background: rgba(255, 255, 255, 0.92); }
.chip.on { background: var(--accent); color: #fff; box-shadow: 0 2px 8px rgba(20, 33, 61, 0.22), inset 0 1px 0 rgba(255, 255, 255, 0.18); }
.page-tabs {
  display: inline-flex; flex-wrap: wrap; gap: 0.2rem; padding: 0.25rem; border-radius: 999px;
  background: rgba(20, 33, 61, 0.055); box-shadow: inset 0 1px 2px rgba(20, 33, 61, 0.06);
  max-width: 100%;
}
.page-tabs a {
  border: 0; background: transparent; padding: 0.42rem 0.95rem; border-radius: 999px; color: var(--ink);
  transition: background 0.25s var(--ease), box-shadow 0.25s var(--ease), color 0.2s;
}
.page-tabs a:hover { background: rgba(255, 255, 255, 0.6); }
.page-tabs a.on {
  background: #fff; color: var(--accent); font-weight: 600; border: 0;
  box-shadow: 0 1px 2px rgba(20, 33, 61, 0.1), 0 4px 12px rgba(20, 33, 61, 0.1);
}
@media (max-width: 860px) {
  .page-tabs { display: flex; flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; }
  .page-tabs::-webkit-scrollbar { display: none; }
  .page-tabs a { flex: none; white-space: nowrap; }
}

/* ---------- Fields ---------- */
input, select, textarea {
  border-radius: 12px; background-color: rgba(255, 255, 255, 0.9);
  box-shadow: inset 0 1px 2px rgba(20, 33, 61, 0.05), 0 0 0 1px rgba(20, 33, 61, 0.12);
  transition: box-shadow 0.2s var(--ease), background-color 0.2s;
}
input:hover, select:hover, textarea:hover { background-color: #fff; }
input:focus, select:focus, textarea:focus {
  background-color: #fff;
  box-shadow: 0 0 0 1px var(--accent), 0 0 0 4px rgba(20, 33, 61, 0.12), 0 6px 18px rgba(20, 33, 61, 0.08);
}
input[type="checkbox"]:not(.switch), input[type="radio"] { box-shadow: none; background: none; }
input.switch { box-shadow: none; }

/* ---------- Tables ---------- */
.table { overflow: auto; }
th { background: rgba(255, 255, 255, 0.5); color: #6e6e74; }
td, th { border-bottom-color: rgba(20, 33, 61, 0.06); }
tbody tr { transition: background 0.15s; }
tbody tr:hover td { background: rgba(255, 255, 255, 0.75); }

/* ---------- Notices, badges, toasts ---------- */
.notice, .warn { border-radius: 14px; box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.6); }
.notice { background: rgba(229, 246, 233, 0.9); }
.warn { background: rgba(255, 243, 223, 0.92); }
.badge { box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.5); }
.alert { border-radius: 999px; }
.toast, .save-bar {
  border-radius: 20px;
  background: rgba(20, 33, 61, 0.86);
  -webkit-backdrop-filter: var(--glass-blur); backdrop-filter: var(--glass-blur);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.15), 0 18px 50px rgba(20, 33, 61, 0.3);
}
.save-bar { border-radius: 999px; }
.toast-bad { background: rgba(255, 255, 255, 0.92); }

/* ---------- Settings: cards, groups, the plan ---------- */
.set-group-label { color: #6b6b71; }
.set-cards { gap: 0.85rem; }
.set-card { border-radius: var(--radius); padding: 1rem 1.05rem; }
.set-card-icon {
  border-radius: 14px; color: var(--accent);
  background: linear-gradient(160deg, rgba(255, 255, 255, 0.95), rgba(225, 231, 245, 0.9));
  box-shadow: inset 0 1px 0 #fff, 0 0 0 1px rgba(20, 33, 61, 0.06), 0 3px 8px rgba(20, 33, 61, 0.08);
}
.feature-card.on .set-card-icon { color: #fff; background: linear-gradient(160deg, #33476f, var(--accent)); box-shadow: inset 0 1px 0 rgba(255,255,255,0.2), 0 4px 12px rgba(20, 33, 61, 0.25); }
.feature-card.locked { background: var(--glass-soft); }
.plan-tag-small { box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.6); }

/* ---------- Phone: the top bar and the floating tab capsule ---------- */
@media (max-width: 860px) {
  .side {
    background: rgba(255, 255, 255, 0.66);
    -webkit-backdrop-filter: var(--glass-blur); backdrop-filter: var(--glass-blur);
    box-shadow: 0 1px 0 rgba(20, 33, 61, 0.06), 0 6px 24px rgba(20, 33, 61, 0.06);
    border-bottom: 0;
  }
  .side.open { background: rgba(255, 255, 255, 0.9); border-radius: 0 0 24px 24px; }
  .menu-btn { border-radius: 999px; background: rgba(20, 33, 61, 0.06); box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.8); }
  .tabbar {
    left: 0.6rem; right: 0.6rem; bottom: calc(0.55rem + env(safe-area-inset-bottom));
    padding: 0.32rem; border-radius: 28px;
    background: rgba(255, 255, 255, 0.7);
    -webkit-backdrop-filter: var(--glass-blur); backdrop-filter: var(--glass-blur);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.95), 0 0 0 1px rgba(20, 33, 61, 0.07), 0 12px 36px rgba(20, 33, 61, 0.18);
  }
  .tabbar a { color: #5f6370; border-radius: 22px; padding: 0.38rem 0; font-size: 0.64rem; transition: background 0.25s var(--ease), color 0.2s; }
  .tabbar a.on { color: var(--accent); background: rgba(20, 33, 61, 0.08); font-weight: 700; }
  .tabbar a.on svg { color: var(--brand-orange); }
  .shell:has(.tabbar) .content { padding-bottom: 6.5rem; }
  .btn.new-order { bottom: calc(5.4rem + env(safe-area-inset-bottom)); }
  .btn.new-order {
    background: linear-gradient(180deg, #33476f, var(--accent)); color: #fff;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.25), 0 10px 26px rgba(20, 33, 61, 0.35);
  }
  .toast { bottom: calc(6rem + env(safe-area-inset-bottom, 0px)); }
  .save-bar { bottom: calc(6rem + env(safe-area-inset-bottom, 0px)); }
  .box { padding: 1rem; }
  .content { padding-left: 0.85rem; padding-right: 0.85rem; }
}

/* ---------- Plan notes: what a feature costs, never a dead end ---------- */
.upsell {
  display: flex; align-items: center; gap: 0.85rem; flex-wrap: wrap;
  padding: 0.85rem 1rem; border-radius: var(--radius);
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.85), rgba(238, 236, 255, 0.85));
  box-shadow: var(--glass-hi), 0 0 0 1px rgba(75, 73, 201, 0.12), 0 6px 20px rgba(75, 73, 201, 0.08);
}
.upsell + .upsell, .box + .upsell, .upsell + .box { margin-top: 0.8rem; }
.upsell-icon {
  flex: none; display: grid; place-items: center; width: 2.4rem; height: 2.4rem; border-radius: 14px; color: #fff;
  background: linear-gradient(160deg, #6d6bf0, var(--indigo)); box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.3), 0 4px 12px rgba(75, 73, 201, 0.3);
}
.upsell-icon svg { width: 1.2rem; height: 1.2rem; }
.upsell-text { flex: 1 1 16rem; min-width: 0; display: grid; gap: 0.1rem; }
.upsell-text b { font-weight: 600; }
.upsell-text .muted { font-size: 0.88rem; }
.upsell-price { font-weight: 600; color: var(--indigo); white-space: nowrap; }
.upsell .btn { flex: none; }
.upsell.compact { padding: 0.55rem 0.7rem 0.55rem 0.85rem; gap: 0.6rem; }
.upsell.compact .upsell-icon { width: 1.9rem; height: 1.9rem; border-radius: 11px; }
.upsell.compact .upsell-icon svg { width: 1rem; height: 1rem; }
.upsell.compact .btn { min-height: 2.2rem; font-size: 0.88rem; }
.plan-tag-small.price { background: rgba(75, 73, 201, 0.1); color: var(--indigo); }
@media (max-width: 560px) { .upsell .btn { width: 100%; } }

.settings-more { margin-top: 1.6rem; }
.feature-group:first-of-type { margin-top: 0.4rem; }

/* A feature that is above the plan, on its own page */
.locked-page { max-width: 44rem; }
.locked-hero { display: grid; gap: 0.8rem; justify-items: start; padding: 1.6rem; margin-top: 1rem; }
.locked-hero .upsell-icon { width: 3.2rem; height: 3.2rem; border-radius: 18px; }
.locked-hero .upsell-icon svg { width: 1.6rem; height: 1.6rem; }
.locked-hero h2 { margin: 0; font-size: 1.35rem; }
.locked-hero ul { margin: 0; padding-left: 1.1rem; display: grid; gap: 0.2rem; color: var(--muted); }
.locked-price { font-size: 1.6rem; font-weight: 700; letter-spacing: -0.03em; }
.locked-price small { font-size: 0.9rem; font-weight: 500; color: var(--muted); }

/* ---------- Funkcijas, grouped ---------- */
.feature-group { margin-top: 1.4rem; }
.feature-group > .set-group-label { margin-bottom: 0.5rem; }
.feature-card .plan-tag-small { white-space: nowrap; }

/* ---------- Vietnes saturs: edit on the page, saved by itself, Publicēt always in sight ---------- */
.sc-publish {
  position: sticky; top: 0.75rem; z-index: 4;
  display: flex; flex-wrap: wrap; align-items: center; gap: 0.5rem 0.9rem;
  margin-top: 0.9rem; padding: 0.6rem 0.65rem 0.6rem 1rem; border-radius: 999px;
  background: rgba(255, 255, 255, 0.72);
  -webkit-backdrop-filter: var(--glass-blur); backdrop-filter: var(--glass-blur);
  box-shadow: var(--glass-hi), 0 0 0 1px rgba(20, 33, 61, 0.06), 0 10px 30px rgba(20, 33, 61, 0.1);
  transition: background 0.3s var(--ease), box-shadow 0.3s var(--ease);
}
.sc-publish.wait { background: rgba(255, 247, 232, 0.82); box-shadow: var(--glass-hi), 0 0 0 1px rgba(255, 159, 10, 0.25), 0 10px 30px rgba(255, 159, 10, 0.12); }
.sc-publish p { flex: 1 1 18rem; margin: 0; font-size: 0.92rem; min-width: 0; }
.sc-dot { flex: none; width: 0.6rem; height: 0.6rem; border-radius: 50%; background: var(--green-edge); box-shadow: 0 0 0 4px rgba(52, 199, 89, 0.18); }
.sc-publish.wait .sc-dot { background: var(--amber); box-shadow: 0 0 0 4px rgba(255, 159, 10, 0.2); animation: sc-breathe 2.4s ease-in-out infinite; }
@keyframes sc-breathe { 50% { box-shadow: 0 0 0 7px rgba(255, 159, 10, 0.08); } }
.sc-publish .sc-actions { margin-left: auto; align-items: center; gap: 0.4rem; }
.sc-publish .btn { min-height: 2.4rem; }
.sc-publish [data-publish] .btn { padding: 0 1.4rem; }
.sc-saved { font-size: 0.82rem; color: var(--muted); white-space: nowrap; }
.sc-saved:empty { display: none; }
.sc-saved.ok { color: var(--green); }
.sc-saved.ok::before { content: "✓ "; }
.sc-saved.busy, .sc-saved.wait { color: var(--muted); }
.sc-saved.bad { color: var(--danger); white-space: normal; }
@media (max-width: 760px) {
  .sc-publish { border-radius: 20px; top: 3.9rem; padding: 0.55rem 0.6rem 0.55rem 0.8rem; gap: 0.35rem 0.6rem; flex-wrap: nowrap; }
  .sc-publish p { flex: 1 1 auto; font-size: 0.8rem; line-height: 1.3; }
  .sc-publish p b { display: block; }
  .sc-publish .sc-long { display: none; }
  /* Saved / saving: quiet on a phone (still read out); a problem shows on a line of its own. */
  .sc-publish .sc-saved:not(.bad) { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
  .sc-publish:has(.sc-saved.bad) { flex-wrap: wrap; }
  .sc-publish .sc-saved.bad { order: 5; flex-basis: 100%; font-size: 0.82rem; }
  .sc-publish [data-public] { display: none; }
  .sc-publish .sc-actions { flex-wrap: nowrap; flex: none; }
  .sc-publish [data-discard] .btn { padding: 0 0.7rem; font-size: 0.8rem; }
  .sc-publish [data-publish] .btn { padding: 0 1rem; }
  .head .sc-actions .btn { min-height: 2.3rem; padding: 0 0.85rem; font-size: 0.88rem; }
}

.sc-grid { grid-template-columns: 12.5rem minmax(20rem, 0.9fr) minmax(0, 1.25fr); gap: 1.1rem; }
.sc-side { position: sticky; top: 5rem; display: grid; grid-template-columns: minmax(0, 1fr); gap: 0.9rem; align-content: start; min-width: 0; max-height: calc(100vh - 6rem); overflow: auto; scrollbar-width: thin; }
.sc-side .sc-parts { position: static; max-height: none; overflow: visible; }
.sc-parts { min-width: 0; padding: 0.5rem; border-radius: var(--radius); background: var(--glass); box-shadow: var(--glass-hi), var(--shadow); }
.sc-part { border-radius: 999px; padding: 0.42rem 0.75rem; transition: background 0.2s var(--ease), color 0.2s; }
.sc-part:hover { background: rgba(255, 255, 255, 0.85); }
.sc-part.on { background: var(--accent); color: #fff; box-shadow: 0 2px 8px rgba(20, 33, 61, 0.25); }
.sc-offers { display: flex; flex-wrap: wrap; gap: 0.5rem; margin-top: 0.7rem; }
.offer-chip {
  display: inline-flex; align-items: center; gap: 0.45rem; margin: 0; padding: 0.35rem 0.5rem 0.35rem 0.8rem; min-height: 2.4rem;
  border-radius: 999px; text-decoration: none; color: var(--ink); font-size: 0.86rem;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.85), rgba(238, 236, 255, 0.85));
  box-shadow: var(--glass-hi), 0 0 0 1px rgba(75, 73, 201, 0.14), 0 4px 14px rgba(75, 73, 201, 0.08);
  transition: transform 0.25s var(--ease), box-shadow 0.25s var(--ease);
}
a.offer-chip { padding-right: 0.95rem; }
a.offer-chip:hover { transform: translateY(-1px); box-shadow: var(--glass-hi), 0 0 0 1px rgba(75, 73, 201, 0.22), 0 8px 20px rgba(75, 73, 201, 0.14); }
.offer-chip b { font-weight: 600; }
.offer-chip span:not(.offer-spark) { color: var(--indigo); font-weight: 500; }
.offer-spark { color: var(--indigo); font-size: 0.8rem; }
.offer-chip .btn { min-height: 1.9rem; padding: 0 0.8rem; font-size: 0.82rem; }
.sc-form { padding: 1rem 1.1rem; border-radius: var(--radius); background: var(--glass); box-shadow: var(--glass-hi), var(--shadow); }
.sc-form.auto .sc-save .btn { display: none; }
.sc-save { background: linear-gradient(transparent, rgba(255, 255, 255, 0.9) 35%); margin: 0 -1.1rem -1rem; padding: 0.7rem 1.1rem; border-radius: 0 0 var(--radius) var(--radius); }
.sc-section { background: rgba(255, 255, 255, 0.8); }
.sc-group { border-color: rgba(20, 33, 61, 0.08); }
.sc-hit { animation: sc-hit 1.6s var(--ease); border-radius: 12px; }
@keyframes sc-hit { 0%, 30% { box-shadow: 0 0 0 3px rgba(20, 33, 61, 0.45); background: rgba(20, 33, 61, 0.05); } 100% { box-shadow: 0 0 0 3px transparent; background: transparent; } }
.sc-preview { top: 5rem; }
.sc-preview-bar { padding: 0 0.2rem; }
.sc-live { display: inline-flex; align-items: center; gap: 0.45rem; font-size: 0.86rem; font-weight: 600; }
.sc-live-dot { width: 0.5rem; height: 0.5rem; border-radius: 50%; background: var(--green-edge); box-shadow: 0 0 0 3px rgba(52, 199, 89, 0.2); }
.sc-sizes { background: rgba(20, 33, 61, 0.06); padding: 3px; }
.sc-sizes button.on { box-shadow: 0 1px 2px rgba(20, 33, 61, 0.12), 0 3px 10px rgba(20, 33, 61, 0.1); font-weight: 600; }
.sc-tip { margin: 0; padding: 0.45rem 0.8rem; border-radius: 12px; font-size: 0.84rem; color: var(--muted);
  background: rgba(255, 255, 255, 0.6); box-shadow: inset 0 0 0 1px rgba(20, 33, 61, 0.05); transition: background 0.3s, color 0.3s; }
.sc-tip::before { content: "✎ "; color: var(--brand-orange); font-weight: 700; }
.sc-tip.strong { background: rgba(255, 243, 223, 0.95); color: var(--amber-ink); }
.sc-tip a { color: inherit; font-weight: 600; }
.sc-frame { height: calc(100vh - 9.5rem); border-radius: 22px; background: #fff;
  box-shadow: 0 0 0 1px rgba(20, 33, 61, 0.08), 0 18px 50px rgba(20, 33, 61, 0.14); }
.sc-view { display: none; }
@media (max-width: 1180px) {
  .sc-grid { grid-template-columns: 12rem minmax(0, 1fr); }
  .sc-side { grid-row: 1 / span 2; }
  .sc-preview { grid-column: 2; position: static; }
}
@media (max-width: 760px) {
  .sc-grid { grid-template-columns: minmax(0, 1fr); }
  .sc-side { grid-row: auto; position: static; max-height: none; overflow: visible; }
  .sc-preview { grid-column: auto; }
  .sc-side .sc-parts { display: flex; flex-wrap: nowrap; overflow-x: auto; overflow-y: hidden; gap: 0.25rem; scrollbar-width: none; padding: 0.35rem; border-radius: 999px; }
  .sc-parts::-webkit-scrollbar { display: none; }
  .sc-parts .nav-label { display: none; }
  .sc-part { flex: none; white-space: nowrap; }
  .sc-part small { display: none; }
  .sc-offers { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; margin-left: -0.85rem; margin-right: -0.85rem; padding: 0.1rem 0.85rem 0.3rem; }
  .sc-offers::-webkit-scrollbar { display: none; }
  .offer-chip { flex: none; white-space: nowrap; }
  .sc-view {
    display: flex; position: fixed; z-index: 6; left: 50%; transform: translateX(-50%);
    bottom: calc(5.9rem + env(safe-area-inset-bottom, 0px)); width: max-content; margin: 0;
    padding: 0.25rem; border-radius: 999px; gap: 0.2rem;
    background: rgba(255, 255, 255, 0.72); -webkit-backdrop-filter: var(--glass-blur); backdrop-filter: var(--glass-blur);
    box-shadow: var(--glass-hi), 0 0 0 1px rgba(20, 33, 61, 0.07), 0 8px 24px rgba(20, 33, 61, 0.12);
  }
  .sc-view button { border: 0; background: none; font: inherit; font-weight: 600; font-size: 0.9rem; padding: 0.45rem 1.3rem; border-radius: 999px; color: var(--muted); cursor: pointer; }
  .sc-view button.on { background: var(--accent); color: #fff; box-shadow: 0 2px 8px rgba(20, 33, 61, 0.25); }
  .sc-grid[data-view-now="form"] .sc-preview { display: none; }
  .sc-grid[data-view-now="page"] .sc-form { display: none; }
  .sc-frame { height: calc(100vh - 15rem); min-height: 26rem; border-radius: 18px; }
  .sc-form { padding: 0.85rem; }
  .sc-save { margin: 0 -0.85rem -0.85rem; padding: 0.6rem 0.85rem; }
  .shell:has(.sc-view) .content { padding-bottom: 10rem; }
  body:has(.sc-view) .toast { bottom: calc(9.4rem + env(safe-area-inset-bottom, 0px)); }
}
@media (prefers-reduced-motion: reduce) {
  .sc-publish.wait .sc-dot, .sc-hit { animation: none; }
  .sc-publish, .sc-part, .sc-tip, .offer-chip { transition: none; }
  a.offer-chip:hover { transform: none; }
}

/* ---------- Vietnes saturs: a workspace of its own ---------- */
.ed-shell { min-height: 100vh; }
.ed-main.content { max-width: none; padding: 1rem 1.4rem 2.5rem; }
.ed-head { display: flex; flex-wrap: wrap; align-items: center; gap: 0.6rem 1rem; }
.ed-head .back { margin: 0; padding: 0.45rem 0.95rem; border-radius: 999px; text-decoration: none; font-weight: 600; color: var(--accent);
  background: rgba(255, 255, 255, 0.6); box-shadow: var(--glass-hi), 0 0 0 1px rgba(20, 33, 61, 0.08); }
.ed-head .back:hover { background: rgba(255, 255, 255, 0.92); }
.ed-head h1 { font-size: 1.55rem; margin: 0; }
.ed-head .sc-actions { margin-left: auto; }
.ed-lead { margin: 0.45rem 0 0; }
.ed-main .sc-publish { top: 0.6rem; }
.ed-main .sc-side, .ed-main .sc-preview { top: 4.8rem; }
.ed-main .sc-grid { grid-template-columns: 12.5rem minmax(20rem, 0.85fr) minmax(0, 1.45fr); }
.ed-main .sc-frame { height: calc(100vh - 8.5rem); }
@media (max-width: 1180px) { .ed-main .sc-grid { grid-template-columns: 12rem minmax(0, 1fr); } }
@media (max-width: 760px) {
  .ed-main.content { padding: 0.75rem 0.8rem 9rem; }
  .ed-main .sc-grid { grid-template-columns: minmax(0, 1fr); }
  .ed-head h1 { font-size: 1.3rem; }
  .ed-head .sc-actions { margin-left: 0; width: 100%; }
  .ed-main .sc-publish { top: 0.5rem; }
  .ed-main .sc-view { bottom: calc(1rem + env(safe-area-inset-bottom, 0px)); }
  body:has(.ed-main) .toast { bottom: calc(4.6rem + env(safe-area-inset-bottom, 0px)); }
}

/* The picture picker */
.pic-dialog {
  width: min(56rem, calc(100vw - 2rem)); max-height: min(44rem, calc(100vh - 2rem)); padding: 0; border: 0; border-radius: 26px;
  background: rgba(255, 255, 255, 0.82); color: var(--ink);
  -webkit-backdrop-filter: saturate(190%) blur(28px); backdrop-filter: saturate(190%) blur(28px);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.95), 0 0 0 1px rgba(255, 255, 255, 0.6), 0 30px 80px rgba(20, 33, 61, 0.35);
}
.pic-dialog[open] { display: flex; flex-direction: column; animation: pic-in 0.28s var(--ease); }
@keyframes pic-in { from { opacity: 0; transform: translateY(10px) scale(0.98); } }
.pic-dialog::backdrop { background: rgba(20, 33, 61, 0.28); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); }
.pic-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 1rem; padding: 1.1rem 1.2rem 0.6rem; }
.pic-head b { font-size: 1.1rem; }
.pic-head p { margin: 0.2rem 0 0; }
.pic-body { overflow: auto; padding: 0.2rem 1.2rem 1rem; min-height: 10rem; color: var(--muted); }
.pic-shelf + .pic-shelf { margin-top: 1rem; }
.pic-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(8.5rem, 1fr)); gap: 0.6rem; }
.pic-tile { position: relative; padding: 0; border: 0; border-radius: 16px; overflow: hidden; aspect-ratio: 4 / 3; cursor: pointer; background: #eef0f5;
  box-shadow: 0 0 0 1px rgba(20, 33, 61, 0.08), 0 4px 12px rgba(20, 33, 61, 0.08); transition: transform 0.2s var(--ease), box-shadow 0.2s var(--ease); }
.pic-tile img { width: 100%; height: 100%; object-fit: cover; }
.pic-tile:hover, .pic-tile:focus-visible { transform: translateY(-2px); box-shadow: 0 0 0 3px var(--brand-orange), 0 10px 24px rgba(20, 33, 61, 0.18); }
.pic-tile.on { box-shadow: 0 0 0 3px var(--accent), 0 6px 16px rgba(20, 33, 61, 0.2); }
.pic-tile.on::after { content: "Tagad"; position: absolute; left: 0.45rem; top: 0.45rem; padding: 0.1rem 0.5rem; border-radius: 999px;
  font-size: 0.72rem; font-weight: 600; color: #fff; background: rgba(20, 33, 61, 0.8); }
.pic-foot { display: flex; align-items: center; gap: 0.8rem; flex-wrap: wrap; padding: 0.8rem 1.2rem 1.1rem; border-top: 1px solid rgba(20, 33, 61, 0.06); }
.pic-upload { position: relative; overflow: hidden; }
.pic-upload input { position: absolute; inset: 0; opacity: 0; cursor: pointer; }
[data-pic-state].bad { color: var(--danger); }
@media (prefers-reduced-motion: reduce) { .pic-dialog[open] { animation: none; } .pic-tile { transition: none; } .pic-tile:hover, .pic-tile:focus-visible { transform: none; } }

/* ===== Liquid Glass, clearly: coloured light behind, real frosted glass in front =====
   The first version was too polite: near-white cards on a near-white page read as "a bit rounder".
   Here the light behind the page has colour, and the surfaces are glass you can see it through:
   blurred, a bright rim on the edge facing the light, a soft sheen across, depth underneath. */
:root {
  --lg-fill: rgba(255, 255, 255, 0.66);
  --lg-fill-strong: rgba(255, 255, 255, 0.68);
  --lg-blur: saturate(190%) blur(24px);
  --lg-rim: inset 0 1px 0 rgba(255, 255, 255, 0.95), inset 0 0 0 1px rgba(255, 255, 255, 0.55), inset 0 -1px 0 rgba(255, 255, 255, 0.25);
  --lg-depth: 0 1px 1px rgba(20, 33, 61, 0.04), 0 10px 30px rgba(20, 33, 61, 0.08);
  --lg-sheen: linear-gradient(135deg, rgba(255, 255, 255, 0.6) 0%, rgba(255, 255, 255, 0.18) 38%, rgba(255, 255, 255, 0.04) 70%, rgba(255, 255, 255, 0.2) 100%);
}
/* Light, not coloured: an almost white page with a soft daylight from the top left, so the glass reads
   by its rims, frost and shadow, never by colour behind it. */
body {
  background:
    radial-gradient(70rem 46rem at 12% -12%, rgba(255, 255, 255, 0.95), transparent 62%),
    radial-gradient(60rem 40rem at 100% 0%, rgba(228, 233, 242, 0.75), transparent 60%),
    linear-gradient(180deg, #f4f6f9 0%, #edf0f4 100%);
  background-attachment: fixed;
}
/* Cards are glass by light, rim and shadow, not by blur: a blurred card would hold fixed windows and lists
   (widgets, the client search list) inside it, and dozens of blurred cards slow phones down. */
a.box.stat:hover, .shelf-card:hover, .unit:hover, .set-card:hover, .feature-card:hover {
  background:
    linear-gradient(var(--lg-fill-strong), var(--lg-fill-strong)) padding-box,
    linear-gradient(135deg, rgba(255, 255, 255, 1) 0%, rgba(255, 255, 255, 0.4) 42%, rgba(255, 255, 255, 0.2) 62%, rgba(255, 255, 255, 0.8) 100%) border-box;
  box-shadow: var(--lg-rim), 0 2px 4px rgba(20, 33, 61, 0.05), 0 18px 44px rgba(40, 50, 110, 0.18);
}
.board .cal, .board > .table { background: transparent; box-shadow: none; -webkit-backdrop-filter: none; backdrop-filter: none; }
.drop, .trip, .desk-job, .job-row, .ledger li, .memo, .wo-note, .core-note, .day { background-color: rgba(255, 255, 255, 0.46); }
.slip, .drop, .desk-job { box-shadow: var(--lg-rim), 0 4px 14px rgba(40, 50, 110, 0.08); }

/* The side menu: a pane of glass floating over the light */
@media (min-width: 861px) {
  .side {
    background: rgba(255, 255, 255, 0.55);
    -webkit-backdrop-filter: saturate(200%) blur(30px); backdrop-filter: saturate(200%) blur(30px);
    box-shadow: var(--lg-rim), 0 18px 50px rgba(40, 50, 110, 0.16);
  }
}
.nav a:hover, .nav-foot a:hover, button.link:hover { background: rgba(255, 255, 255, 0.5); }
.nav a.on, .nav-foot a.on {
  background: rgba(255, 255, 255, 0.82) var(--lg-sheen);
  box-shadow: var(--lg-rim), 0 6px 18px rgba(40, 50, 110, 0.16);
}

/* Buttons: tinted glass with light on the top edge */
.btn, button.btn {
  background: linear-gradient(180deg, rgba(64, 86, 140, 0.96) 0%, rgba(28, 44, 82, 0.97) 52%, rgba(16, 26, 49, 0.98) 100%);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.35), inset 0 0 0 1px rgba(255, 255, 255, 0.08), 0 8px 22px rgba(20, 33, 61, 0.28);
}
.btn:hover { background: linear-gradient(180deg, rgba(76, 100, 158, 0.97) 0%, rgba(36, 54, 98, 0.98) 52%, rgba(20, 33, 61, 1) 100%); }
.btn.line, .btn.danger {
  background: rgba(255, 255, 255, 0.5) var(--lg-sheen);
  box-shadow: var(--lg-rim), 0 0 0 1px rgba(20, 33, 61, 0.08), 0 4px 12px rgba(40, 50, 110, 0.1);
}
.btn.line:hover { background-color: rgba(255, 255, 255, 0.85); }
.btn.danger { box-shadow: var(--lg-rim), 0 0 0 1px rgba(215, 0, 21, 0.25), 0 4px 12px rgba(215, 0, 21, 0.08); }
.chip { background: rgba(255, 255, 255, 0.5); box-shadow: var(--lg-rim), 0 0 0 1px rgba(20, 33, 61, 0.06); }
.page-tabs { background: rgba(255, 255, 255, 0.35); box-shadow: inset 0 1px 3px rgba(40, 50, 110, 0.12), inset 0 0 0 1px rgba(255, 255, 255, 0.5);
  -webkit-backdrop-filter: var(--lg-blur); backdrop-filter: var(--lg-blur); }
.page-tabs a.on { background: rgba(255, 255, 255, 0.92) var(--lg-sheen); box-shadow: var(--lg-rim), 0 4px 14px rgba(40, 50, 110, 0.16); }
input, select, textarea { background-color: rgba(255, 255, 255, 0.72); box-shadow: inset 0 1px 2px rgba(20, 33, 61, 0.06), 0 0 0 1px rgba(20, 33, 61, 0.1), 0 1px 0 rgba(255, 255, 255, 0.8); }
th { background: rgba(255, 255, 255, 0.35); }
tbody tr:hover td { background: rgba(255, 255, 255, 0.55); }
.set-card-icon { background: rgba(255, 255, 255, 0.7) var(--lg-sheen); box-shadow: var(--lg-rim), 0 4px 10px rgba(40, 50, 110, 0.12); }

/* Bars that float: the Publicēt bar, the phone's top bar and tab capsule */
.sc-publish { background: rgba(255, 255, 255, 0.84) var(--lg-sheen); box-shadow: var(--lg-rim), 0 14px 40px rgba(40, 50, 110, 0.16); }
.sc-publish.wait { background: rgba(255, 244, 224, 0.9) var(--lg-sheen); }
@media (max-width: 860px) {
  .side { background: rgba(255, 255, 255, 0.86); box-shadow: var(--lg-rim), 0 8px 30px rgba(40, 50, 110, 0.12); }
  .tabbar { background: rgba(255, 255, 255, 0.82) var(--lg-sheen); box-shadow: var(--lg-rim), 0 16px 44px rgba(40, 50, 110, 0.26); }
  .tabbar a.on { background: rgba(255, 255, 255, 0.85); box-shadow: var(--lg-rim), 0 4px 12px rgba(40, 50, 110, 0.14); }
}

/* ---------- Without backdrop-filter: solid enough to read ---------- */
@supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
  .side, .tabbar, .toast, .save-bar, .sc-publish, .sc-view { background: rgba(255, 255, 255, 0.97); }
  .box, .board, .tile, .table, .cal, .orders-find, .shelf-card, .unit, .set-card, .feature-card, .plan-card, .sc-parts, .sc-form, .stat { background-color: rgba(255, 255, 255, 0.9); }
  .toast, .save-bar { background: var(--accent); }
  .toast-bad { background: #fff; }
}

/* ---------- Calm motion only ---------- */
@media (prefers-reduced-motion: reduce) {
  @view-transition { navigation: none; }
  .btn, .chip, .page-tabs a, .nav a, a.box.stat, .shelf-card, .unit, .set-card, .feature-card, .slip, .drop, .desk-job,
  details.box > summary::after, input, select, textarea { transition: none; }
  .btn:hover, .btn:active, a.box.stat:hover, .shelf-card:hover, .unit:hover, .set-card:hover, .feature-card:hover { transform: none; }
}

/* ===== Look v4: Liquid Glass controls (light, neutral, no orange) =====
   The last word on every control: appended after everything above, so it wins by order where the
   specificity is equal. Three materials only, as in Apple's light Liquid Glass:
   - TINTED glass (navy you can faintly see through): primary buttons, the chosen filter chip, the
     chosen tile of the phone menu, the phone's round +. A bright rim on top, a cool glow along the
     bottom edge where the light bends through, a soft navy shadow. White text stays at 7:1 or more.
   - CLEAR glass (almost white): secondary and danger buttons, chips, round buttons, the editor's back
     link. A dark hairline outside and a white rim inside, so it shows on a near-white page with no
     colour behind it; a darker 1px bottom edge; a diffuse shadow.
   - THE LENS: every tab-like control is a recessed track holding one raised white lens; static/portal.js
     slides it to the tab you choose (springy, it swells a little while it travels). Without the script
     the chosen tab draws its own lens, so nothing depends on it.
   No orange anywhere in the portal: --brand-orange is navy from here on (the logo is an image file and
   keeps its colour); links to orders, clients and invoices are a calm navy token with no underline.
   backdrop-filter only on elements that hold nothing fixed: the round + (it is the fixed element) and
   the small photo buttons. Tracks, rows and table buttons are never blurred.
   Hover lifts and the pointer light only for a real mouse; on a touch screen a stuck :hover looks
   the same as rest. Reduced motion stops every movement (end of this block). */

:root {
  --brand-orange: var(--accent);
  --lg-spring: cubic-bezier(0.3, 1.3, 0.5, 1);
  /* tinted (navy) glass */
  --lg-navy: rgba(20, 33, 61, 0.9);
  --lg-navy-hi: rgba(30, 46, 84, 0.9);
  --lg-navy-image:
    linear-gradient(180deg, rgba(255, 255, 255, 0.17) 0%, rgba(255, 255, 255, 0.05) 42%, rgba(255, 255, 255, 0) 60%),
    radial-gradient(140% 120% at 50% 135%, rgba(130, 160, 235, 0.34), rgba(130, 160, 235, 0) 60%);
  --lg-navy-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.4), inset 0 0 0 1px rgba(255, 255, 255, 0.1), inset 0 -1px 0 rgba(170, 195, 255, 0.22),
    0 1px 1px rgba(20, 33, 61, 0.2), 0 8px 18px -6px rgba(20, 33, 61, 0.5);
  --lg-navy-shadow-hi:
    inset 0 1px 0 rgba(255, 255, 255, 0.55), inset 0 0 0 1px rgba(255, 255, 255, 0.16), inset 0 -1px 0 rgba(180, 205, 255, 0.3),
    0 2px 3px rgba(20, 33, 61, 0.18), 0 14px 28px -8px rgba(20, 33, 61, 0.55);
  --lg-navy-shadow-press:
    inset 0 1px 0 rgba(255, 255, 255, 0.55), inset 0 0 0 1px rgba(255, 255, 255, 0.18), inset 0 0 14px rgba(190, 210, 255, 0.2),
    0 1px 2px rgba(20, 33, 61, 0.25), 0 4px 10px -4px rgba(20, 33, 61, 0.4);
  /* clear glass */
  --lg-cap: rgba(255, 255, 255, 0.62);
  --lg-cap-image: linear-gradient(180deg, rgba(255, 255, 255, 0.88) 0%, rgba(255, 255, 255, 0.25) 55%, rgba(255, 255, 255, 0.42) 100%);
  --lg-cap-shadow:
    inset 0 1px 0 #fff, inset 0 0 0 1px rgba(255, 255, 255, 0.45), inset 0 -1px 0 rgba(20, 33, 61, 0.07),
    0 0 0 1px rgba(20, 33, 61, 0.14), 0 1px 2px rgba(20, 33, 61, 0.07), 0 6px 16px -6px rgba(20, 33, 61, 0.26);
  --lg-cap-shadow-hi:
    inset 0 1px 0 #fff, inset 0 0 0 1px rgba(255, 255, 255, 0.65), inset 0 -1px 0 rgba(20, 33, 61, 0.06),
    0 0 0 1px rgba(20, 33, 61, 0.17), 0 2px 4px rgba(20, 33, 61, 0.08), 0 12px 24px -8px rgba(20, 33, 61, 0.32);
  --lg-cap-shadow-press:
    inset 0 1px 0 #fff, inset 0 0 0 1px rgba(255, 255, 255, 0.75), inset 0 1px 3px rgba(20, 33, 61, 0.08),
    0 0 0 1px rgba(20, 33, 61, 0.17), 0 1px 2px rgba(20, 33, 61, 0.08);
  /* the lens and its recessed track */
  --lg-lens: linear-gradient(180deg, #fff 0%, rgba(255, 255, 255, 0.94) 100%);
  --lg-lens-shadow:
    inset 0 1px 0 #fff, inset 0 -1px 0 rgba(20, 33, 61, 0.07), 0 0 0 1px rgba(20, 33, 61, 0.08),
    0 1px 2px rgba(20, 33, 61, 0.12), 0 4px 12px -2px rgba(20, 33, 61, 0.2);
  --lg-track: rgba(20, 33, 61, 0.075);
  --lg-track-shadow: inset 0 1px 2px rgba(20, 33, 61, 0.13), inset 0 0 0 1px rgba(20, 33, 61, 0.04), 0 1px 0 rgba(255, 255, 255, 0.9);
  /* a soft platter: the chosen place in a floating bar (phone tab bar, Teksti / Lapa) */
  --lg-platter: rgba(20, 33, 61, 0.085);
  --lg-platter-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.75), inset 0 0 0 1px rgba(255, 255, 255, 0.4), inset 0 -1px 1px rgba(20, 33, 61, 0.06);
  /* cards: the same outer hairline, quieter */
  --lg-depth: 0 0 0 1px rgba(20, 33, 61, 0.05), 0 1px 2px rgba(20, 33, 61, 0.04), 0 10px 30px -6px rgba(20, 33, 61, 0.1);
}
@supports (transition-timing-function: linear(0, 1)) {
  /* a soft spring: about 5% past the target, then it settles */
  :root { --lg-spring: linear(0, 0.06 3%, 0.22 7%, 0.5 13%, 0.78 20%, 0.95 27%, 1.03 34%, 1.05 40%, 1.04 47%, 1.01 58%, 0.995 70%, 1); }
}
::selection { background: rgba(20, 33, 61, 0.16); }
.nav-count { box-shadow: 0 1px 3px rgba(217, 48, 37, 0.35); }
@keyframes sc-hit { 0%, 30% { box-shadow: 0 0 0 3px rgba(20, 33, 61, 0.3); background: rgba(20, 33, 61, 0.05); } 100% { box-shadow: 0 0 0 3px transparent; background: transparent; } }
.cal-month .day.picked.today { box-shadow: inset 0 0 0 2px rgba(255, 255, 255, 0.9); }  /* today on the chosen (navy) day */

/* ---------- Primary buttons: tinted navy glass ----------
   Each base rule also names :hover, so a stuck touch :hover (and every older hover rule) looks like
   rest; the lift and the light for a mouse come in the (hover: hover) block further down. */
.btn, button.btn, .btn:hover, button.btn:hover {
  --lg-glow: radial-gradient(6.5rem circle at var(--lg-mx, 50%) var(--lg-my, -7rem), rgba(255, 255, 255, 0.14), rgba(255, 255, 255, 0) 70%);
  border: 0; border-radius: 999px; color: #fff; filter: none; transform: none;
  background-color: var(--lg-navy);
  background-image: var(--lg-navy-image);
  box-shadow: var(--lg-navy-shadow);
  transition: transform 0.4s var(--lg-spring), box-shadow 0.3s var(--ease), background-color 0.3s var(--ease), opacity 0.2s;
}
.btn:active, button.btn:active { transform: scale(0.97); filter: none; transition-duration: 0.12s; box-shadow: var(--lg-navy-shadow-press); }

/* ---------- Secondary buttons and the other round controls: clear glass ---------- */
.btn.line, .btn.danger, .menu-btn, .navbtn, .cal-nav, .ed-head .back,
.btn.line:hover, .btn.danger:hover, .menu-btn:hover, .navbtn:hover, .cal-nav:hover, .ed-head .back:hover {
  --lg-glow: radial-gradient(6.5rem circle at var(--lg-mx, 50%) var(--lg-my, -7rem), rgba(255, 255, 255, 0.95), rgba(255, 255, 255, 0) 70%);
  border: 0; transform: none;
  background-color: var(--lg-cap);
  background-image: var(--lg-cap-image);
  box-shadow: var(--lg-cap-shadow);
  transition: transform 0.4s var(--lg-spring), box-shadow 0.3s var(--ease), background-color 0.3s var(--ease), opacity 0.2s;
}
.btn.line, .menu-btn, .navbtn, .cal-nav, .btn.line:hover, .menu-btn:hover, .navbtn:hover, .cal-nav:hover { color: var(--ink); }
.ed-head .back, .ed-head .back:hover { color: var(--accent); }
.navbtn, .cal-nav { display: inline-grid; place-items: center; }
.btn.danger, .btn.danger:hover { color: var(--danger);
  box-shadow: inset 0 1px 0 #fff, inset 0 0 0 1px rgba(255, 255, 255, 0.45), inset 0 -1px 0 rgba(215, 0, 21, 0.08),
    0 0 0 1px rgba(215, 0, 21, 0.28), 0 1px 2px rgba(215, 0, 21, 0.06), 0 6px 16px -6px rgba(215, 0, 21, 0.22); }
.btn.line:active, .btn.danger:active, .menu-btn:active, .navbtn:active, .cal-nav:active, .ed-head .back:active {
  transform: scale(0.97); transition-duration: 0.12s; background-color: rgba(255, 255, 255, 0.92); box-shadow: var(--lg-cap-shadow-press); }

/* WhatsApp: the same glass, tinted green (white text 5:1 or more; no pointer light on it on purpose) */
.btn.wa, .btn.wa:hover { color: #fff; background-color: rgba(19, 108, 44, 0.96);
  background-image: linear-gradient(180deg, rgba(255, 255, 255, 0.13), rgba(255, 255, 255, 0) 55%), radial-gradient(140% 120% at 50% 135%, rgba(120, 220, 150, 0.25), rgba(120, 220, 150, 0) 60%);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.36), inset 0 0 0 1px rgba(255, 255, 255, 0.1), inset 0 -1px 0 rgba(255, 255, 255, 0.12), 0 1px 1px rgba(10, 60, 25, 0.2), 0 8px 18px -6px rgba(10, 80, 30, 0.45); }

/* Copied: a green edge on the clear glass */
html :is(.snippet-row .btn, .btn, .g-copy-btn).copied { color: #137333; background-color: var(--lg-cap); background-image: var(--lg-cap-image);
  box-shadow: inset 0 1px 0 #fff, inset 0 0 0 1px rgba(255, 255, 255, 0.5), 0 0 0 1px rgba(26, 127, 55, 0.5), 0 6px 16px -6px rgba(26, 127, 55, 0.3); }

/* Disabled: flat, no light, no lift */
html .btn[disabled], html .btn:disabled { opacity: 0.45; transform: none; cursor: not-allowed; background-image: none;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.3), 0 0 0 1px rgba(20, 33, 61, 0.1); }

/* A form with changes not yet saved: its button keeps the soft ring (the glass owns box-shadow now) */
button.btn.attention:not(:focus-visible) { outline: 3px solid rgba(20, 33, 61, 0.2); outline-offset: 2px; }

/* Inside a dark bar ("Izmaiņas vēl nav saglabātas", a toast) the main button is white glass */
:is(.save-bar, .toast:not(.toast-bad)) .btn:not(.line):not(.danger),
:is(.save-bar, .toast:not(.toast-bad)) .btn:not(.line):not(.danger):hover {
  color: var(--accent); background-color: rgba(255, 255, 255, 0.94); background-image: var(--lg-cap-image);
  box-shadow: inset 0 1px 0 #fff, 0 1px 2px rgba(0, 0, 0, 0.2), 0 6px 16px -6px rgba(0, 0, 0, 0.4); }
html :is(.save-bar, .toast:not(.toast-bad)) :focus-visible { outline-color: #fff; }

/* The phone's round "+": a floating bead of navy glass. It is the fixed element itself and holds
   nothing fixed, so it may blur what passes under it. */
@media (max-width: 860px) {
  .btn.new-order, .btn.new-order:hover {
    color: #fff; transform: none;
    background-color: rgba(20, 33, 61, 0.82);
    background-image: radial-gradient(circle at 35% 22%, rgba(255, 255, 255, 0.3), rgba(255, 255, 255, 0) 55%), radial-gradient(circle at 50% 125%, rgba(130, 160, 240, 0.5), rgba(130, 160, 240, 0) 62%);
    -webkit-backdrop-filter: blur(14px) saturate(180%); backdrop-filter: blur(14px) saturate(180%);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.5), inset 0 0 0 1px rgba(255, 255, 255, 0.16), inset 0 -2px 6px rgba(255, 255, 255, 0.12),
      0 2px 4px rgba(20, 33, 61, 0.2), 0 14px 30px -6px rgba(20, 33, 61, 0.5);
  }
  .btn.new-order:active { transform: scale(0.94); }
}

/* Photo tile buttons (‹ › ★ ✕): small glass beads over the picture, blurred so they read on any photo */
.icon-btn, .icon-btn:hover { border: 0; color: var(--ink); transform: none; background-color: rgba(255, 255, 255, 0.74); background-image: var(--lg-cap-image);
  -webkit-backdrop-filter: blur(10px) saturate(180%); backdrop-filter: blur(10px) saturate(180%);
  box-shadow: inset 0 1px 0 #fff, inset 0 0 0 1px rgba(255, 255, 255, 0.5), 0 0 0 1px rgba(20, 33, 61, 0.12), 0 3px 10px -2px rgba(20, 33, 61, 0.3);
  transition: transform 0.4s var(--lg-spring), box-shadow 0.3s var(--ease); }
.icon-btn.danger { color: var(--danger); }
.icon-btn:active:not(:disabled) { transform: scale(0.92); transition-duration: 0.12s; }

/* ---------- Chips (filters, choices): clear glass capsules; the chosen one tinted navy glass ---------- */
:is(.chip, .sp-chips .chip), :is(.chip, .sp-chips .chip):hover {
  --lg-glow: radial-gradient(5rem circle at var(--lg-mx, 50%) var(--lg-my, -6rem), rgba(255, 255, 255, 0.95), rgba(255, 255, 255, 0) 70%);
  border: 0; border-radius: 999px; color: var(--ink); transform: none;
  background-color: var(--lg-cap);
  background-image: linear-gradient(180deg, rgba(255, 255, 255, 0.85), rgba(255, 255, 255, 0.15) 65%);
  box-shadow: inset 0 1px 0 #fff, inset 0 -1px 0 rgba(20, 33, 61, 0.06), 0 0 0 1px rgba(20, 33, 61, 0.13), 0 1px 2px rgba(20, 33, 61, 0.06), 0 4px 10px -5px rgba(20, 33, 61, 0.2);
  transition: transform 0.4s var(--lg-spring), box-shadow 0.3s var(--ease), background-color 0.3s var(--ease), color 0.2s;
}
:is(.chip, .sp-chips .chip).on, :is(.chip, .sp-chips .chip).on:hover {
  --lg-glow: radial-gradient(5rem circle at var(--lg-mx, 50%) var(--lg-my, -6rem), rgba(255, 255, 255, 0.12), rgba(255, 255, 255, 0) 70%);
  color: #fff; background-color: var(--lg-navy); background-image: var(--lg-navy-image);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.38), inset 0 0 0 1px rgba(255, 255, 255, 0.09), inset 0 -1px 0 rgba(170, 195, 255, 0.2), 0 1px 1px rgba(20, 33, 61, 0.2), 0 6px 14px -6px rgba(20, 33, 61, 0.5);
}
:is(a, button, label).chip:active { transform: scale(0.96); transition-duration: 0.12s; }
/* Free units of the day (Kalendārs): green-tinted glass, text 5.8:1 */
html .cal-free .chip, html .cal-free .chip:hover { color: #136c2c; background-color: rgba(229, 246, 233, 0.78);
  background-image: linear-gradient(180deg, rgba(255, 255, 255, 0.7), rgba(255, 255, 255, 0.1) 60%);
  box-shadow: inset 0 1px 0 #fff, inset 0 -1px 0 rgba(26, 127, 55, 0.08), 0 0 0 1px rgba(26, 127, 55, 0.24), 0 4px 10px -5px rgba(26, 127, 55, 0.25); }
/* A tick-box chip: glass too, a clear ring when ticked (a shape, not only a colour) */
.chip-check { border-radius: 999px; background-color: var(--lg-cap); background-image: var(--lg-cap-image);
  box-shadow: inset 0 1px 0 #fff, 0 0 0 1px rgba(20, 33, 61, 0.13), 0 4px 10px -5px rgba(20, 33, 61, 0.2); }
.chip-check:has(input:checked) { background-color: rgba(233, 236, 243, 0.92); box-shadow: inset 0 1px 0 #fff, 0 0 0 1.5px var(--accent), 0 4px 10px -5px rgba(20, 33, 61, 0.22); }
@media (max-width: 860px) {
  /* A row that scrolls sideways clips what sticks out: room for the edge, tighter shadows, the keyboard
     ring drawn inside the chip (white on the navy one) */
  .chips:not(.wrap):not(.tabs-row):not(.bt-tabs) { padding: 2px 3px 6px; }
  .chips:not(.wrap):not(.tabs-row):not(.bt-tabs) > :is(.chip, .sp-chips .chip) { box-shadow: inset 0 1px 0 #fff, inset 0 -1px 0 rgba(20, 33, 61, 0.06), 0 0 0 1px rgba(20, 33, 61, 0.14), 0 2px 5px -2px rgba(20, 33, 61, 0.18); }
  .chips:not(.wrap):not(.tabs-row):not(.bt-tabs) > :is(.chip, .sp-chips .chip).on { box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.38), inset 0 0 0 1px rgba(255, 255, 255, 0.09), 0 1px 1px rgba(20, 33, 61, 0.2), 0 3px 6px -3px rgba(20, 33, 61, 0.45); }
  .chips:not(.wrap):not(.tabs-row):not(.bt-tabs) > :focus-visible { outline-offset: -3px; }
  .chips:not(.wrap):not(.tabs-row):not(.bt-tabs) > .chip.on:focus-visible { outline-color: #fff; }
}

/* ---------- Tabs and segmented controls: a recessed track, one white lens ----------
   One look for .page-tabs (also .appt-tabs / .appt-seg), the Facebook and notification tab rows
   (.chips.tabs-row: "Ziņas", "Ieraksti" stay as they are), .bt-tabs, .tpl-tabs, .w-segs, .sc-sizes,
   .mc-device, .seo-device. "html" in front and ".chip.chip" inside :is(): these must beat the chip rules
   above and the older (0,3,0) rules such as .bt-tabs .chip.on without !important.
   Tracks never wrap; a long one scrolls sideways inside itself. */
html :is(.page-tabs, .tabs-row, .bt-tabs, .sc-sizes, .tpl-tabs, .w-segs, .mc-device, .seo-device) {
  position: relative; isolation: isolate;
  display: flex; flex-wrap: nowrap; align-items: stretch; gap: 2px; width: fit-content; max-width: 100%;
  padding: 3px; border: 0; border-radius: 999px; vertical-align: middle;
  overflow-x: auto; overflow-y: hidden; scrollbar-width: none; -webkit-overflow-scrolling: touch; overscroll-behavior-x: contain;
  background-color: var(--lg-track);
  background-image: linear-gradient(180deg, rgba(20, 33, 61, 0.03), rgba(255, 255, 255, 0.25));
  box-shadow: var(--lg-track-shadow);
  -webkit-backdrop-filter: none; backdrop-filter: none;
}
:is(.page-tabs, .tabs-row, .bt-tabs, .sc-sizes, .tpl-tabs, .w-segs, .mc-device, .seo-device)::-webkit-scrollbar { display: none; }
html :is(.page-tabs, .tabs-row, .bt-tabs, .sc-sizes, .sc-view, .tpl-tabs, .mc-device, .seo-device) > :is(a, button, .chip.chip, .tpl-tab),
html :is(.page-tabs, .tabs-row, .bt-tabs, .sc-sizes, .sc-view, .tpl-tabs, .mc-device, .seo-device) > :is(a, button, .chip.chip, .tpl-tab):hover,
html .w-segs > .w-seg > span {
  position: relative; z-index: 1; flex: none; white-space: nowrap; margin: 0;
  border: 0; border-radius: 999px; color: #3c3d44; text-decoration: none;
  background: transparent; box-shadow: none; transform: none;
  -webkit-backdrop-filter: none; backdrop-filter: none;
  transition: color 0.25s var(--ease), background-color 0.25s var(--ease), transform 0.3s var(--lg-spring);
}
.w-segs > .w-seg { position: relative; z-index: 1; flex: none; margin: 0; }
/* The chosen segment: navy text; it draws its own lens until the script's lens takes over */
html :is(.page-tabs, .tabs-row, .bt-tabs, .sc-sizes, .sc-view, .tpl-tabs, .mc-device, .seo-device) > :is(a, button, .chip.chip, .tpl-tab).on,
html .w-segs > .w-seg > input:checked + span { color: var(--accent); font-weight: 600; }
html :is(.page-tabs, .tabs-row, .bt-tabs, .sc-sizes, .tpl-tabs, .mc-device, .seo-device):not(.lg-live) > :is(a, button, .chip.chip, .tpl-tab).on,
html .w-segs:not(.lg-live) > .w-seg > input:checked + span { background: var(--lg-lens); box-shadow: var(--lg-lens-shadow); }
html :is(.page-tabs, .tabs-row, .bt-tabs, .sc-sizes, .sc-view, .tpl-tabs, .mc-device, .seo-device).lg-live > :is(a, button, .chip.chip, .tpl-tab).on,
html .w-segs.lg-live > .w-seg > input:checked + span { background: transparent; box-shadow: none; }
/* Keyboard: a ring inside the segment (the track would clip one outside) */
html :is(.page-tabs, .tabs-row, .bt-tabs, .sc-sizes, .sc-view, .tpl-tabs, .mc-device, .seo-device) > :is(a, button, .chip.chip, .tpl-tab):focus-visible,
html .w-segs > .w-seg > input:focus-visible + span { outline: 2px solid var(--accent); outline-offset: -2px; }

/* The lens: one per control, placed by static/portal.js */
.lg-thumb {
  position: absolute; left: 0; top: 0; z-index: 0; margin: 0; pointer-events: none;
  width: var(--lg-w, 0px); height: var(--lg-h, 0px);
  transform: translate3d(var(--lg-x, 0px), var(--lg-y, 0px), 0);
  border-radius: 999px; opacity: 0;
  background: var(--lg-lens); box-shadow: var(--lg-lens-shadow);
  transition: transform 0.45s var(--lg-spring), width 0.45s var(--lg-spring), height 0.45s var(--lg-spring), scale 0.3s var(--lg-spring),
    opacity 0.2s var(--ease), box-shadow 0.3s var(--ease), background-color 0.3s var(--ease);
}
.lg-thumb.show { opacity: 1; }
.lg-thumb.lg-still { transition: none; }
/* While it travels it swells a little and brightens, like a drop of glass, then settles */
.lg-thumb.moving {
  transform: translate3d(var(--lg-x, 0px), var(--lg-y, 0px), 0) scale(1.05, 1.1);
  box-shadow: inset 0 1px 0 #fff, inset 0 0 0 1px rgba(255, 255, 255, 0.9), 0 0 0 1px rgba(20, 33, 61, 0.06), 0 6px 18px -2px rgba(20, 33, 61, 0.24);
}
.lg-thumb.show.moving { opacity: 0.92; }
/* Pressing the chosen segment: the lens swells under the finger (Apple's press) */
.lg-live:has(> .on:active, > .w-seg:active > input:checked) > .lg-thumb { scale: 1.04 1.08; }

/* The phone editor's floating Teksti / Lapa switch: a soft platter under navy text (never white text
   on a lens that may be mid-way) */
@media (max-width: 760px) {
  html .sc-view { gap: 2px; padding: 4px;
    background-color: rgba(255, 255, 255, 0.7); background-image: var(--lg-cap-image);
    box-shadow: var(--lg-cap-shadow), 0 14px 34px -8px rgba(20, 33, 61, 0.32); }
  html .sc-view > button { color: #45464d; }
  html .sc-view > button.on { color: var(--accent); }
  html .sc-view:not(.lg-live) > button.on { background: var(--lg-platter); box-shadow: var(--lg-platter-shadow); }
  .sc-view > .lg-thumb, .sc-view > .lg-thumb.moving { background: var(--lg-platter); box-shadow: var(--lg-platter-shadow); }
}

/* Vietnes saturs: the list of page parts holds a lens too */
.sc-parts > .sc-part { position: relative; z-index: 1; }
html .sc-parts > .sc-part.on { color: var(--accent); font-weight: 600; }
html .sc-parts:not(.lg-live) > .sc-part.on { background: var(--lg-lens); box-shadow: var(--lg-lens-shadow); }
html .sc-parts.lg-live > .sc-part.on { background: transparent; box-shadow: none; }

/* ---------- The phone's tab bar: one platter behind the page you are on, no pill around the icon ---------- */
@media (max-width: 860px) {
  .tabbar > a { position: relative; z-index: 1; transition: color 0.25s var(--ease), transform 0.4s var(--lg-spring); }
  .tabbar > a:active { transform: scale(0.94); transition-duration: 0.12s; }
  html .tabbar a svg, html .tabbar a.on svg, html .tabbar a:active svg { background: none; box-shadow: none; color: inherit; }
  html .tabbar a.on { color: var(--accent); }
  html .tabbar:not(.lg-live) > a.on { background: var(--lg-platter); box-shadow: var(--lg-platter-shadow); }
  html .tabbar.lg-live > a.on { background: transparent; box-shadow: none; }
  html .tabbar > a:focus-visible { outline: 2px solid var(--accent); outline-offset: -2px; }
  .tabbar > .lg-thumb, .tabbar > .lg-thumb.moving { border-radius: 22px; background: var(--lg-platter); box-shadow: var(--lg-platter-shadow); }
  /* held: the platter turns into a clear lens that swells, as on iOS 26 */
  .tabbar.lg-live:has(> a.on:active) > .lg-thumb { scale: 1.08 1.12; background: rgba(255, 255, 255, 0.6);
    box-shadow: inset 0 1px 0 #fff, inset 0 0 0 1px rgba(255, 255, 255, 0.85), inset 0 -2px 6px rgba(150, 178, 255, 0.18), 0 0 0 0.5px rgba(20, 33, 61, 0.12), 0 8px 22px rgba(20, 33, 61, 0.18); }
}

/* ---------- The side menu ---------- */
/* No orange diamond in front of the chosen item; the chosen item is a raised white lens. */
html .nav > a:not(.set-link):not(.back-desk):not(.set-home)::before, html .nav-foot > a::before { content: none; display: none; }
html .nav a.set-link.on svg { color: var(--accent); opacity: 1; }
@media (min-width: 861px) {
  .side .nav > a { position: relative; z-index: 1; }
  .side .nav > a:focus-visible, .side .nav-foot > a:focus-visible { outline-offset: -2px; }
  html .side .nav:not(.lg-live) > a.on, html .nav-foot > a.on { background: var(--lg-lens); box-shadow: var(--lg-lens-shadow); }
  html .side .nav.lg-live > a.on { background: transparent; box-shadow: none; }
  /* a tighter shadow: the menu scrolls, and its edges would cut a wide one */
  .side .nav > .lg-thumb { box-shadow: inset 0 1px 0 #fff, inset 0 -1px 0 rgba(20, 33, 61, 0.06), 0 0 0 1px rgba(20, 33, 61, 0.07), 0 1px 2px rgba(20, 33, 61, 0.1), 0 3px 8px -2px rgba(20, 33, 61, 0.14); }
}
@media (max-width: 860px) {
  .side .nav > .lg-thumb { display: none; }
  /* The open menu: tiles of clear glass; the page you are on is navy glass */
  html .side .nav a, html .side .nav-foot > a, html .side .nav-foot button.link {
    border-radius: 18px; color: var(--ink); background-color: var(--lg-cap); background-image: var(--lg-cap-image); box-shadow: var(--lg-cap-shadow);
    transition: transform 0.3s var(--lg-spring);
  }
  html .side .nav a:active, html .side .nav-foot > a:active, html .side .nav-foot button.link:active { transform: scale(0.97); }
  html .side .nav a.on, html .side .nav-foot > a.on {
    color: #fff; background-color: var(--lg-navy); background-image: var(--lg-navy-image); box-shadow: var(--lg-navy-shadow);
  }
  html .side .nav a.on .nav-ico, html .side .nav a.on > svg { color: #fff; }
  html .side .nav a.on:focus-visible { outline-color: var(--accent); outline-offset: 2px; }
  html .side .nav-foot > a.powered-by { background: none; box-shadow: none; }
}

/* ---------- The editor's hint mark: navy, not orange ---------- */
.sc-tip::before { color: var(--accent); }

/* ---------- Links to an order, a client, an invoice: a calm navy token, never an underline ----------
   The token's shape (tint + hairline) tells a link from text without relying on colour. */
a.ref {
  color: var(--accent); font-weight: 600; text-decoration: none;
  padding: 0.05em 0.34em; margin: 0 -0.1em; border-radius: 0.55em;
  background-color: rgba(20, 33, 61, 0.06);
  box-shadow: inset 0 0 0 1px rgba(20, 33, 61, 0.08), inset 0 1px 0 rgba(255, 255, 255, 0.7);
  -webkit-box-decoration-break: clone; box-decoration-break: clone;
  transition: background-color 0.2s var(--ease), box-shadow 0.2s var(--ease);
}
a.ref:hover { text-decoration: none; }
a.ref:active { background-color: rgba(20, 33, 61, 0.11); }
a.ref:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

/* ---------- Fields: recessed glass ---------- */
input, select, textarea {
  background-color: rgba(255, 255, 255, 0.72);
  box-shadow: inset 0 1px 2px rgba(20, 33, 61, 0.08), inset 0 0 0 1px rgba(20, 33, 61, 0.12), 0 1px 0 rgba(255, 255, 255, 0.9);
}
input:focus, select:focus, textarea:focus {
  background-color: #fff;
  box-shadow: inset 0 0 0 1px var(--accent), 0 0 0 4px rgba(20, 33, 61, 0.14), 0 6px 18px -6px rgba(20, 33, 61, 0.18);
}
/* Switches (doubled class: beats glass.css's input[type=checkbox]{background:none}, which had erased the
   off track, and input:hover): a recessed track, a glass knob that stretches into a lens while held */
input.switch.switch {
  background-color: rgba(20, 33, 61, 0.17);
  background-image: linear-gradient(180deg, rgba(20, 33, 61, 0.06), rgba(255, 255, 255, 0.12));
  box-shadow: inset 0 1px 2px rgba(20, 33, 61, 0.22), inset 0 -1px 0 rgba(255, 255, 255, 0.55), 0 0 0 1px rgba(20, 33, 61, 0.05);
  transition: background-color 0.25s var(--ease), box-shadow 0.25s var(--ease);
}
input.switch.switch:hover { background-color: rgba(20, 33, 61, 0.21); }
input.switch.switch:checked { background-color: #34c759; box-shadow: inset 0 1px 2px rgba(0, 60, 20, 0.28), inset 0 -1px 0 rgba(255, 255, 255, 0.3); }
input.switch.switch::after {
  background: radial-gradient(120% 100% at 50% 0%, #fff 55%, #eef1f6 100%);
  box-shadow: inset 0 1px 0 #fff, inset 0 -1px 1px rgba(20, 33, 61, 0.08), 0 0 0 0.5px rgba(20, 33, 61, 0.1), 0 1px 1px rgba(20, 33, 61, 0.12), 0 2px 6px rgba(20, 33, 61, 0.22);
  transition: transform 0.45s var(--lg-spring), width 0.25s var(--ease), background 0.25s var(--ease), box-shadow 0.25s var(--ease);
}
input.switch.switch:active::after {
  width: calc(1.55rem + 0.3rem - 4px);
  background: rgba(255, 255, 255, 0.82);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.95), 0 0 0 0.5px rgba(20, 33, 61, 0.12), 0 3px 10px rgba(20, 33, 61, 0.25);
}
input.switch.switch:checked:active::after { transform: translateX(calc(1.05rem - 0.3rem)); }
input.switch.switch:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; }

/* ---------- Keyboard focus on glass: a clear navy ring with air around it ---------- */
:is(.btn, .chip, .navbtn, .cal-nav, .icon-btn, .menu-btn, .ed-head .back):focus-visible { outline: 2.5px solid var(--accent); outline-offset: 3px; }

/* ---------- Mouse only: hover lifts, brighter rims, a light that follows the pointer ---------- */
@media (hover: hover) and (pointer: fine) {
  .btn:hover, button.btn:hover {
    transform: translateY(-1px);
    background-color: var(--lg-navy-hi);
    background-image: var(--lg-glow), var(--lg-navy-image);
    box-shadow: var(--lg-navy-shadow-hi);
  }
  .btn.line:hover, .btn.danger:hover, .menu-btn:hover, .navbtn:hover, .cal-nav:hover, .ed-head .back:hover {
    transform: translateY(-1px);
    background-color: rgba(255, 255, 255, 0.86);
    background-image: var(--lg-glow), var(--lg-cap-image);
    box-shadow: var(--lg-cap-shadow-hi);
  }
  .btn.danger:hover { background-color: rgba(255, 246, 246, 0.94);
    box-shadow: inset 0 1px 0 #fff, inset 0 0 0 1px rgba(255, 255, 255, 0.6), 0 0 0 1px rgba(215, 0, 21, 0.38), 0 2px 4px rgba(215, 0, 21, 0.06), 0 12px 24px -8px rgba(215, 0, 21, 0.28); }
  .btn.wa:hover { transform: translateY(-1px); background-color: rgba(16, 98, 40, 0.97); }
  html :is(.snippet-row .btn, .btn, .g-copy-btn).copied:hover { background-image: var(--lg-cap-image); }
  html .btn[disabled]:hover, html .btn:disabled:hover { transform: none; background-image: none; }
  :is(.save-bar, .toast:not(.toast-bad)) .btn:not(.line):not(.danger):hover { transform: translateY(-1px); background-color: #fff; background-image: var(--lg-cap-image); }
  .btn:active, button.btn:active, .btn.line:active, .btn.danger:active, .menu-btn:active, .navbtn:active, .cal-nav:active, .ed-head .back:active { transform: scale(0.97); }  /* the press wins over the hover lift */
  .icon-btn:hover:not(:disabled) { transform: translateY(-1px); box-shadow: inset 0 1px 0 #fff, inset 0 0 0 1px rgba(255, 255, 255, 0.6), 0 0 0 1px rgba(20, 33, 61, 0.16), 0 8px 18px -4px rgba(20, 33, 61, 0.35); }
  .icon-btn:active:not(:disabled) { transform: scale(0.92); }

  :is(a, button, label).chip:not(.on):hover {
    transform: translateY(-1px);
    background-color: rgba(255, 255, 255, 0.9);
    background-image: var(--lg-glow), linear-gradient(180deg, rgba(255, 255, 255, 0.85), rgba(255, 255, 255, 0.2) 65%);
    box-shadow: inset 0 1px 0 #fff, 0 0 0 1px rgba(20, 33, 61, 0.16), 0 2px 3px rgba(20, 33, 61, 0.07), 0 8px 16px -6px rgba(20, 33, 61, 0.26);
  }
  :is(a, button, label).chip.on:hover { background-color: var(--lg-navy-hi); background-image: var(--lg-glow), var(--lg-navy-image); }
  :is(a, button, label).chip:hover:active { transform: scale(0.96); }
  html .cal-free .chip:hover { background-color: rgba(229, 246, 233, 0.95); background-image: var(--lg-glow), linear-gradient(180deg, rgba(255, 255, 255, 0.7), rgba(255, 255, 255, 0.1) 60%);
    box-shadow: inset 0 1px 0 #fff, 0 0 0 1px rgba(26, 127, 55, 0.42), 0 8px 16px -6px rgba(26, 127, 55, 0.3); }

  /* inside a track: a faint glass where the pointer is, never a second lens */
  html :is(.page-tabs, .tabs-row, .bt-tabs, .sc-sizes, .sc-view, .tpl-tabs, .mc-device, .seo-device) > :is(a, button, .chip.chip, .tpl-tab):not(.on):hover,
  html .w-segs > .w-seg > input:not(:checked) + span:hover { background: rgba(255, 255, 255, 0.5); color: var(--ink); transform: none; box-shadow: none; }
  html .sc-parts > .sc-part:not(.on):hover { background: rgba(255, 255, 255, 0.55); }

  a.ref:hover { background-color: rgba(255, 255, 255, 0.96);
    box-shadow: inset 0 1px 0 #fff, 0 0 0 1px rgba(20, 33, 61, 0.15), 0 3px 10px -2px rgba(20, 33, 61, 0.2); }

  /* Cards you can open: the light follows the pointer across the glass */
  a.box.stat, .shelf-card, .unit, .set-card, .feature-card {
    --lg-glow: radial-gradient(16rem circle at var(--lg-mx, 50%) var(--lg-my, -16rem), rgba(255, 255, 255, 0.6), rgba(255, 255, 255, 0) 70%);
  }
  a.box.stat:hover, .shelf-card:hover, .unit:hover, .set-card:hover, .feature-card:hover {
    background:
      var(--lg-glow) padding-box,
      linear-gradient(var(--lg-fill-strong), var(--lg-fill-strong)) padding-box,
      linear-gradient(135deg, #fff 0%, rgba(255, 255, 255, 0.4) 42%, rgba(255, 255, 255, 0.2) 62%, rgba(255, 255, 255, 0.8) 100%) border-box;
  }
}

/* ---------- Without backdrop-filter ---------- */
@supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
  @media (max-width: 860px) { .btn.new-order { background-color: rgba(20, 33, 61, 0.96); } }
  .icon-btn { background-color: rgba(255, 255, 255, 0.95); }
}

/* ---------- High contrast (forced colours): real borders; the lens is decoration, the chosen tab gets an outline ---------- */
@media (forced-colors: active) {
  .btn, .chip, .navbtn, .cal-nav, .icon-btn, .menu-btn { border: 1px solid ButtonText; }
  .lg-thumb { display: none; }
  html :is(.page-tabs, .tabs-row, .bt-tabs, .sc-sizes, .sc-view, .tpl-tabs, .mc-device, .seo-device, .sc-parts, .tabbar, .nav, .chips) > .on,
  html .w-segs > .w-seg > input:checked + span { outline: 2px solid Highlight; outline-offset: -2px; }
  a.ref { text-decoration: underline; }
}

/* ---------- Reduced motion: no slide, no lift, no squeeze, no swell ---------- */
@media (prefers-reduced-motion: reduce) {
  .lg-thumb, .btn, button.btn, .chip, .chip-check, a.ref, .menu-btn, .navbtn, .cal-nav, .icon-btn, .ed-head .back,
  input.switch, input.switch::after, .tabbar > a, .sc-part, .side .nav a, .side .nav-foot > a, .side .nav-foot button.link,
  html :is(.page-tabs, .tabs-row, .bt-tabs, .sc-sizes, .sc-view, .tpl-tabs, .mc-device, .seo-device) > :is(a, button, .chip.chip, .tpl-tab),
  html .w-segs > .w-seg > span { transition: none !important; }
  .btn:hover, .btn:active, button.btn:active, .chip:hover, .chip:active, .menu-btn:hover, .menu-btn:active, .navbtn:hover, .navbtn:active,
  .cal-nav:hover, .cal-nav:active, .icon-btn:hover, .icon-btn:active, .tabbar > a:active, .ed-head .back:hover, .ed-head .back:active,
  .side .nav a:active, .side .nav-foot > a:active, .side .nav-foot button.link:active { transform: none !important; }
  .lg-thumb.moving { transform: translate3d(var(--lg-x, 0px), var(--lg-y, 0px), 0); opacity: 1; }
  .lg-thumb { scale: none !important; }
  input.switch.switch:active::after { width: calc(1.55rem - 4px); }
  input.switch.switch:checked:active::after { transform: translateX(1.05rem); }
}

/* ===== Vietnes saturs, round 3: the page first =====
   One glass bar on top (the way back, history, design, colours, Publicēt); the parts of the site on the left;
   the page itself takes the rest. Every text of a part as a list ("Visi teksti") opens beside the page only when
   wanted — editing happens on the page. A phone shows the page or the texts, one at a time. */
.ed-main.content { padding-top: 0.6rem; }
.ed-top {
  position: sticky; top: 0.5rem; z-index: 6; display: grid; gap: 0.45rem;
  margin: 0 -0.3rem; padding: 0.55rem 0.6rem; border-radius: 26px;
  background: rgba(255, 255, 255, 0.8);
  -webkit-backdrop-filter: saturate(180%) blur(24px); backdrop-filter: saturate(180%) blur(24px);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.95), 0 0 0 1px rgba(20, 33, 61, 0.07), 0 12px 34px rgba(20, 33, 61, 0.1);
}
.ed-top .ed-head h1 { font-size: 1.35rem; }
html .ed-top .sc-publish { position: static; margin: 0; padding: 0.45rem 0.5rem 0.45rem 0.9rem; box-shadow: inset 0 0 0 1px rgba(20, 33, 61, 0.06);
  background: rgba(246, 248, 251, 0.9); -webkit-backdrop-filter: none; backdrop-filter: none; }
html .ed-top .sc-publish.wait { background: rgba(255, 245, 226, 0.95); box-shadow: inset 0 0 0 1px rgba(255, 159, 10, 0.28); }
.ed-main .sc-offers { margin-top: 0.6rem; }
html .ed-main .sc-grid { grid-template-columns: 11.5rem minmax(0, 1fr); grid-template-areas: "side page"; margin-top: 0.8rem; }
html .ed-main .sc-grid.texts-open { grid-template-columns: 11.5rem minmax(0, 1fr) minmax(20rem, 25rem); grid-template-areas: "side page form"; }
.ed-main .sc-side { grid-area: side; top: 8.6rem; max-height: calc(100vh - 9.5rem); }
.ed-main .sc-preview { grid-area: page; top: 8.6rem; }
.ed-main .sc-form { grid-area: form; display: none; }
.ed-main .sc-grid.texts-open .sc-form { display: grid; position: sticky; top: 8.6rem; max-height: calc(100vh - 9.5rem); overflow: auto; overscroll-behavior: contain; }
.ed-main .sc-frame { height: calc(100vh - 13.4rem); min-height: 26rem; }
.sc-preview-bar { flex-wrap: wrap; gap: 0.4rem 0.8rem; }
.sc-bar-tools { display: inline-flex; flex-wrap: wrap; align-items: center; gap: 0.4rem; }
.sc-bar-tools .btn.small { min-height: 2.1rem; }
html .sc-bar-tools [data-marks].on { color: var(--accent); box-shadow: inset 0 0 0 1.5px var(--accent), 0 2px 8px rgba(20, 33, 61, 0.1); }
.sc-tip [data-done] { margin-right: 0.5rem; min-height: 1.9rem; padding: 0 0.85rem; }
.ed-more { margin-top: 1.4rem; }
.ed-more > summary { cursor: pointer; color: var(--muted); font-weight: 600; padding: 0.4rem 0.2rem; }
.ed-more[open] > summary { margin-bottom: 0.6rem; }
.ed-more > .box + .box, .ed-more > details + .box, .ed-more > .box + details { margin-top: 0.8rem; }
@media (max-width: 1180px) {
  html .ed-main .sc-grid, html .ed-main .sc-grid.texts-open { grid-template-columns: minmax(0, 1fr); grid-template-areas: "side" "page" "form"; }
  .ed-main .sc-side { position: static; max-height: none; overflow: visible; }
  html .ed-main .sc-side .sc-parts { display: flex; flex-wrap: nowrap; overflow-x: auto; overflow-y: hidden; gap: 0.25rem; scrollbar-width: none; padding: 0.35rem; border-radius: 999px; }
  .ed-main .sc-side .sc-parts::-webkit-scrollbar { display: none; }
  .ed-main .sc-parts .nav-label { display: none; }
  .ed-main .sc-part { flex: none; white-space: nowrap; }
  .ed-main .sc-preview { position: static; }
  .ed-main .sc-grid.texts-open .sc-form { position: static; max-height: none; }
}
@media (max-width: 760px) {
  .ed-top { top: 0.3rem; margin: 0; padding: 0.45rem; border-radius: 20px; }
  .ed-top .ed-head { gap: 0.4rem; }
  .ed-top .ed-head h1 { font-size: 1.1rem; }
  .ed-top .ed-head .sc-actions { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; }
  .ed-top .ed-head .sc-actions::-webkit-scrollbar { display: none; }
  .ed-top .ed-head .sc-actions .btn { flex: none; }
  html .ed-top .sc-publish .sc-saved:not(.bad) { position: static; width: auto; height: auto; overflow: visible; clip: auto; font-size: 0.74rem; }
  html .ed-top .sc-publish [data-public] { display: inline-flex; }
  .sc-bar-tools [data-texts], .sc-bar-tools .sc-sizes { display: none; }
  /* The phone shows one at a time: the page (Lapa) or the texts (Teksti). */
  html .ed-main .sc-grid[data-view-now="form"] .sc-form { display: grid; position: static; max-height: none; }
  html .ed-main .sc-grid[data-view-now="form"] .sc-preview { display: none; }
  html .ed-main .sc-grid[data-view-now="page"] .sc-form { display: none; }
  .ed-main .sc-frame { height: calc(100vh - 17rem); min-height: 24rem; }
}

/* ===== Glass you can see: the light on the controls, stronger =====
   On a light page Apple's glass shows by its light, not by colour: a bright band over the top half (where
   the light falls), a cool glow where it bends through the bottom edge, a crisp white rim, a thin dark
   edge outside. Same three materials, the same neutral colours; only the light is turned up. */
:root {
  --lg-navy-image:
    linear-gradient(180deg, rgba(255, 255, 255, 0.3) 0%, rgba(255, 255, 255, 0.12) 46%, rgba(255, 255, 255, 0) 54%),
    radial-gradient(130% 110% at 50% 140%, rgba(150, 180, 255, 0.5), rgba(150, 180, 255, 0) 62%);
  --lg-navy-shadow:
    inset 0 1.5px 0 rgba(255, 255, 255, 0.55), inset 0 0 0 1px rgba(255, 255, 255, 0.14), inset 0 -2px 3px rgba(170, 195, 255, 0.25),
    0 1px 1px rgba(20, 33, 61, 0.22), 0 10px 22px -8px rgba(20, 33, 61, 0.6);
  --lg-cap-image:
    linear-gradient(180deg, #fff 0%, rgba(255, 255, 255, 0.86) 44%, rgba(255, 255, 255, 0.4) 56%, rgba(255, 255, 255, 0.62) 100%),
    radial-gradient(120% 100% at 50% 135%, rgba(170, 190, 235, 0.35), rgba(170, 190, 235, 0) 60%);
  --lg-cap-shadow:
    inset 0 1.5px 0 #fff, inset 0 0 0 1px rgba(255, 255, 255, 0.6), inset 0 -2px 3px rgba(150, 170, 220, 0.16),
    0 0 0 1px rgba(20, 33, 61, 0.16), 0 1px 2px rgba(20, 33, 61, 0.08), 0 8px 20px -8px rgba(20, 33, 61, 0.32);
  --lg-lens:
    linear-gradient(180deg, #fff 0%, rgba(255, 255, 255, 0.95) 46%, rgba(246, 248, 252, 0.92) 54%, rgba(255, 255, 255, 0.96) 100%);
  --lg-lens-shadow:
    inset 0 1.5px 0 #fff, inset 0 -2px 3px rgba(150, 170, 220, 0.18), 0 0 0 1px rgba(20, 33, 61, 0.1),
    0 1px 2px rgba(20, 33, 61, 0.14), 0 6px 14px -4px rgba(20, 33, 61, 0.26);
  --lg-track: rgba(20, 33, 61, 0.085);
  --lg-track-shadow: inset 0 1.5px 3px rgba(20, 33, 61, 0.16), inset 0 0 0 1px rgba(20, 33, 61, 0.05), 0 1px 0 #fff;
}
/* Tabs a size up: easier to see and to hit */
html :is(.page-tabs, .tabs-row, .bt-tabs, .tpl-tabs, .w-segs, .mc-device, .seo-device) > :is(a, button, .chip.chip, .tpl-tab) {
  padding: 0.5rem 1.05rem; font-size: 0.93rem;
}
@media (max-width: 760px) {
  /* The phone: the bar scrolls away with the page (a sticky bar would take a third of the screen); the
     state on a line of its own, the buttons on a row under it, Publicēt last and in reach. */
  .ed-top { position: static; }
  html .ed-top .sc-publish { flex-wrap: wrap; border-radius: 18px; gap: 0.45rem 0.6rem; }
  html .ed-top .sc-publish p { flex: 1 1 calc(100% - 1.6rem); min-width: 0; }
  html .ed-top .sc-publish .sc-saved { order: 3; }
  html .ed-top .sc-publish .sc-actions { order: 4; width: 100%; flex-wrap: nowrap; justify-content: flex-end; }
  html .ed-top .sc-publish [data-public] { margin-right: auto; }
  html .ed-top .sc-publish .sc-actions .btn { white-space: nowrap; }
}
.ed-top { grid-template-columns: minmax(0, 1fr); }
.ed-top > *, .ed-top .ed-head .sc-actions { min-width: 0; }

/* Kalendārs: what the colours mean, as a row of small glass labels (the mark beside its word), and the
   blocked items as a real button, not an underlined word under them. */
html .legend { display: flex; flex-wrap: wrap; align-items: center; gap: 0.45rem; margin: 0.8rem 0 0; color: var(--ink); font-size: 0.85rem; }
html .legend > span { display: inline-flex; align-items: center; gap: 0.45rem; padding: 0.32rem 0.75rem 0.32rem 0.55rem; border-radius: 999px; white-space: nowrap;
  background-color: var(--lg-cap); background-image: var(--lg-cap-image); box-shadow: var(--lg-cap-shadow); }
html .legend .sw { flex: none; margin: 0; width: 0.8rem; height: 0.8rem; border-radius: 0.28rem; vertical-align: 0; }
html .legend > .btn { margin-left: auto; }
@media (max-width: 560px) { html .legend > .btn { margin-left: 0; } }

/* ===== Hints: a subtitle and captions, not paragraphs of grey text =====
   The page's hint (.lead) is one quiet line under the title, Apple's secondary label; a small note under
   a field is a caption; an info box (.core-note) is a glass card with an "i". */
html .lead { margin: 0.3rem 0 1.15rem; max-width: 44rem; font-size: 1rem; line-height: 1.45; letter-spacing: -0.006em; color: #55565c; }
html .head + .lead { margin-top: 0.25rem; }
html .small-note, html p.muted.small-note { font-size: 0.82rem; line-height: 1.45; color: #5d5e64; margin-top: 0.35rem; }
html .core-note {
  position: relative; padding: 0.75rem 1rem 0.75rem 2.7rem; border-radius: 16px; color: #4a4b51; font-size: 0.9rem;
  background-color: var(--lg-cap); background-image: var(--lg-cap-image); box-shadow: var(--lg-cap-shadow);
}
html .core-note::before {
  content: "i"; position: absolute; left: 0.85rem; top: 0.78rem; width: 1.25rem; height: 1.25rem; border-radius: 50%;
  display: grid; place-items: center; font: 600 0.78rem/1 Georgia, serif; font-style: italic; color: #fff;
  background-color: var(--lg-navy); background-image: var(--lg-navy-image); box-shadow: var(--lg-navy-shadow);
}
@media (max-width: 760px) { html .lead { font-size: 0.95rem; margin-bottom: 0.9rem; } }

/* ===== Review fixes (adversarial review of Look v4 and the editor) ===== */
/* The lens's containing block, in CSS (portal.js no longer writes an inline position). */
html :is(.page-tabs, .tabs-row, .bt-tabs, .sc-sizes, .tpl-tabs, .w-segs, .mc-device, .seo-device, .sc-parts) { position: relative; }
/* With a mouse, long tab rows wrap again (a hidden sideways scroll cannot be reached with a mouse wheel);
   on a touch screen they stay one row that the finger scrolls. */
@media (hover: hover) and (pointer: fine) {
  html :is(.page-tabs, .tabs-row, .bt-tabs, .tpl-tabs, .w-segs) { flex-wrap: wrap; overflow: visible; border-radius: 20px; max-width: 100%; }
}
@media (hover: hover) and (pointer: fine) and (min-width: 761px) and (max-width: 1180px) {
  html .ed-main .sc-side .sc-parts { flex-wrap: wrap; overflow: visible; border-radius: 20px; }
}
/* Warnings keep their amber colour inside a small note. */
html .warn.small-note, html .small-note.kind-off { color: var(--amber-ink); }
html .warn.small-note { margin-top: 0; }
/* Switches: both states read at 3:1 or more (the knob's place says on or off as well). */
html input.switch.switch { background-color: rgba(20, 33, 61, 0.42); }
html input.switch.switch:checked { background-color: #198038; }
/* The chosen tab: a clearer edge on the lens, so it does not rest on the white alone. */
html .lg-thumb, html :is(.page-tabs, .tabs-row, .bt-tabs, .sc-sizes, .tpl-tabs, .mc-device, .seo-device):not(.lg-live) > :is(a, button, .chip.chip, .tpl-tab).on {
  outline: 1.5px solid rgba(20, 33, 61, 0.4); outline-offset: -1.5px;
}
/* The upload button in the picture picker shows keyboard focus. */
.pic-upload:has(input:focus-visible), .pic-upload:focus-within { outline: 2.5px solid var(--accent); outline-offset: 3px; }
/* The side menu's lens does not swell (it would spill past the menu's scroll box); labels stay above the lens. */
@media (min-width: 861px) {
  html .side .nav > .lg-thumb.moving { transform: translate3d(var(--lg-x, 0px), var(--lg-y, 0px), 0); }
  html .side .nav.lg-live:has(> .on:active) > .lg-thumb { scale: none; }
}
.side .nav > .nav-label, .sc-parts > .nav-label { position: relative; z-index: 1; }
/* Today on the chosen start day of a membership: a white ring inside the navy day. */
.sp-d.new.first.today, .sp-d.new.last.today { box-shadow: inset 0 0 0 2px rgba(255, 255, 255, 0.9); }
/* Pieraksti: the Diena / Nedēļa switch as low as the controls beside it. */
html .appt-bar .page-tabs.appt-seg > :is(a, .chip.chip) { padding: 0.28rem 0.85rem; font-size: 0.88rem; line-height: 1.25; }
/* The phone's floating pill: what was saved, and Publicēt when something waits. */
.sc-view-state { display: none; }
.sc-view [data-publish-now] { margin-left: 0.2rem; }
@media (max-width: 760px) {
  html .ed-main .sc-offers { margin-left: -0.8rem; margin-right: -0.8rem; padding-left: 0.8rem; padding-right: 0.8rem; }
  .ed-top .ed-head .sc-actions { padding: 6px 6px 10px; margin: -6px -6px -10px; width: calc(100% + 12px); scroll-padding-inline: 6px; }
  .ed-top .ed-head .sc-actions .btn:focus-visible { outline-offset: -3px; }
  .sc-view .sc-view-state:not(:empty) { display: inline-flex; align-items: center; padding: 0 0.6rem; font-size: 0.74rem; max-width: 9rem;
    overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--muted); }
  .sc-view .sc-view-state.bad { color: var(--danger); white-space: normal; max-width: 12rem; }
  .sc-view .sc-view-state.ok::before { content: "✓ "; }
  .ed-main .sc-tip.strong { position: sticky; top: 0.4rem; z-index: 4; }
}

/* ===== Look v5: no old-fashioned corners left =====
   One recipe per kind of control, the same on every page: no orange (the amber tokens are a calm slate;
   red stays for late and danger), no coloured edge stripes (a dot before the status word), links as navy
   tokens, actions as clear glass capsules, one-of-a-few choices as the segmented track, radios and ticks as
   glass beads, notices as glass cards with a bead, pickers as capsules with a chevron, tables as cards on a
   phone, empty lists as a quiet panel. */

/* ---------- 1. No orange anywhere: the "waiting" colour is slate (text 9:1 on its tint) ---------- */
:root {
  --amber: #5b6b8f;
  --amber-ink: #34446b;
  --amber-soft: rgba(20, 33, 61, 0.065);
  --warn: rgba(20, 33, 61, 0.065);
}
html .alert.wait { color: var(--ink); background-color: var(--lg-cap); background-image: var(--lg-cap-image); box-shadow: var(--lg-cap-shadow); }
html .alert.wait b { color: var(--accent); }
html .badge.new { color: #fff; background-color: var(--lg-navy); background-image: var(--lg-navy-image); box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.3); }
html .badge:is(.partial, .planned) { color: var(--amber-ink); background: var(--amber-soft); box-shadow: inset 0 0 0 1px rgba(20, 33, 61, 0.2); }
html .shelf-strip span.busy { color: var(--amber-ink); background: rgba(20, 33, 61, 0.13); }
html .shelf-strip span.part { background: linear-gradient(180deg, var(--green-soft) 50%, rgba(20, 33, 61, 0.13) 50%); }
html .sc-publish.wait { background: rgba(255, 255, 255, 0.84) var(--lg-sheen); box-shadow: var(--lg-rim), 0 0 0 1px rgba(20, 33, 61, 0.08), 0 14px 40px rgba(40, 50, 110, 0.16); }
html .ed-top .sc-publish.wait { background: rgba(246, 248, 251, 0.92); box-shadow: inset 0 0 0 1px rgba(20, 33, 61, 0.1); }
html .sc-publish.wait .sc-dot { box-shadow: 0 0 0 4px rgba(20, 33, 61, 0.14); animation-name: lg-breathe; }
@keyframes lg-breathe { 50% { box-shadow: 0 0 0 7px rgba(20, 33, 61, 0.06); } }
html .sc-tip.strong { color: var(--ink); background-color: var(--lg-cap); background-image: var(--lg-cap-image); box-shadow: var(--lg-cap-shadow); }

/* ---------- 2. Status: no coloured stripe down the edge; a dot before the word (a shape, not only a colour) ---------- */
html :is(.slip, .drop, .desk-job):is(.open, .done, .off),
html :is(.slip, .drop, .desk-job):is(.open, .done, .off):hover { box-shadow: var(--lg-rim), 0 0 0 1px rgba(20, 33, 61, 0.05), 0 4px 14px rgba(40, 50, 110, 0.08); }
html .trip:is(.open, .done) { box-shadow: inset 0 0 0 1px rgba(20, 33, 61, 0.06), inset 0 1px 0 rgba(255, 255, 255, 0.8); }
html .tile:is(.wait, .good, .bad) { box-shadow: var(--glass-hi), var(--shadow); }
html :is(.money, .gone) > b, html b.verb { display: inline-flex; align-items: center; gap: 0.4rem; }
html :is(.money, .gone) > b::before, html b.verb::before {
  content: ""; flex: none; width: 0.5rem; height: 0.5rem; border-radius: 50%; background: currentColor;
  box-shadow: 0 0 0 3px color-mix(in srgb, currentColor 16%, transparent);
}
html .money { border-left-color: rgba(20, 33, 61, 0.07); }
/* An order card opens as a whole (Apple list row); the client and the phone stay their own links */
html .slip { position: relative; }
html .slip .order-no::after { content: ""; position: absolute; inset: 0; z-index: 0; border-radius: var(--radius); }
html .slip :is(a.ref, a.call, a.drop-pic) { position: relative; z-index: 1; }

/* ---------- 3. Links inside text: the navy token a.ref already uses, never an underline ---------- */
html .order-no { text-decoration: none; letter-spacing: -0.01em; }
html :is(a.call, .desk-job-main .muted a:not(.ref), .block-order a[href^="tel:"], .terms-note p a,
  :is(.small-note, .pl-hint, .warn, p.line) a:not(.btn):not(.ref)) {
  color: var(--accent); font-weight: 600; text-decoration: none; border-bottom: 0;
  padding: 0.05em 0.4em; margin: 0 -0.1em; border-radius: 0.55em;
  background-color: rgba(20, 33, 61, 0.06);
  box-shadow: inset 0 0 0 1px rgba(20, 33, 61, 0.08), inset 0 1px 0 rgba(255, 255, 255, 0.7);
  -webkit-box-decoration-break: clone; box-decoration-break: clone;
  transition: background-color 0.2s var(--ease), box-shadow 0.2s var(--ease);
}
html :is(a.call, .block-order a[href^="tel:"]) { display: inline-flex; align-items: center; gap: 0.3rem; padding-left: 0.38em; white-space: nowrap; }
html :is(a.call, .block-order a[href^="tel:"])::before {
  content: ""; flex: none; width: 0.8em; height: 0.8em; background: currentColor;
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M6.6 10.8a15.1 15.1 0 0 0 6.6 6.6l2.2-2.2a1 1 0 0 1 1-.25 11.4 11.4 0 0 0 3.6.57 1 1 0 0 1 1 1V20a1 1 0 0 1-1 1A17 17 0 0 1 3 4a1 1 0 0 1 1-1h3.5a1 1 0 0 1 1 1c0 1.25.2 2.45.57 3.57a1 1 0 0 1-.25 1z'/%3E%3C/svg%3E") center / contain no-repeat;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M6.6 10.8a15.1 15.1 0 0 0 6.6 6.6l2.2-2.2a1 1 0 0 1 1-.25 11.4 11.4 0 0 0 3.6.57 1 1 0 0 1 1 1V20a1 1 0 0 1-1 1A17 17 0 0 1 3 4a1 1 0 0 1 1-1h3.5a1 1 0 0 1 1 1c0 1.25.2 2.45.57 3.57a1 1 0 0 1-.25 1z'/%3E%3C/svg%3E") center / contain no-repeat;
}
html :is(a.call, .desk-job-main .muted a:not(.ref), .block-order a[href^="tel:"], .terms-note p a,
  :is(.small-note, .pl-hint, .warn, p.line) a:not(.btn):not(.ref)):active { background-color: rgba(20, 33, 61, 0.11); }
html :is(a.call, .desk-job-main .muted a:not(.ref), .block-order a[href^="tel:"], .terms-note p a,
  :is(.small-note, .pl-hint, .warn, p.line) a:not(.btn):not(.ref)):focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

/* ---------- 4. Actions are clear glass capsules, not underlined words ---------- */
html :is(.cal-free-title, .board > p.see-all) > a:not(.btn), html .box-head > a.more {
  display: inline-flex; align-items: center; gap: 0.3rem; min-height: 2.3rem; padding: 0 1rem; border-radius: 999px;
  color: var(--ink); font-size: 0.88rem; font-weight: 600; text-decoration: none; white-space: nowrap;
  background-color: var(--lg-cap); background-image: var(--lg-cap-image); box-shadow: var(--lg-cap-shadow);
  transition: transform 0.4s var(--lg-spring), box-shadow 0.3s var(--ease), background-color 0.3s var(--ease);
}
html :is(.cal-free-title, .board > p.see-all) > a:not(.btn):active, html .box-head > a.more:active {
  transform: scale(0.97); transition-duration: 0.12s; background-color: rgba(255, 255, 255, 0.92); box-shadow: var(--lg-cap-shadow-press); }
html :is(.cal-free-title, .board > p.see-all) > a:not(.btn):focus-visible, html .box-head > a.more:focus-visible { outline: 2.5px solid var(--accent); outline-offset: 3px; }
html .cal-free-title:has(> a) { margin-top: 1.2rem; }
html .board > p.see-all { margin: 0.8rem 0 0; }
html .box-head { align-items: center; }
html .box-head > a.more { flex: none; }
/* A board's "see all" link: navy words with a chevron (Apple's "See All") */
html .board-head > a:not(.btn) {
  display: inline-flex; align-items: center; gap: 0.15rem; flex: none;
  padding: 0.35rem 0.35rem 0.35rem 0.6rem; margin: -0.35rem -0.35rem -0.35rem 0; border-radius: 999px;
  color: var(--accent); text-decoration: none; transition: background-color 0.2s var(--ease);
}
html .board-head > a:not(.btn)::after { content: "›"; font-size: 1.2em; line-height: 1; }
html .board-head > a:not(.btn):active { background-color: rgba(20, 33, 61, 0.08); }
html .board-head > a:not(.btn):focus-visible { outline: 2px solid var(--accent); outline-offset: 0; }
/* "← Back": one capsule everywhere (the editor's own stays as it is) */
html a.back:not(.ed-head *) {
  display: inline-flex; align-items: center; min-height: 2.2rem; padding: 0.3rem 0.95rem 0.3rem 0.8rem; margin-bottom: 0.7rem; border-radius: 999px;
  color: var(--accent); font-size: 0.92rem; font-weight: 600; text-decoration: none;
  background-color: var(--lg-cap); background-image: var(--lg-cap-image); box-shadow: var(--lg-cap-shadow);
  transition: transform 0.4s var(--lg-spring), box-shadow 0.3s var(--ease), background-color 0.3s var(--ease);
}
html a.back:not(.ed-head *):active { transform: scale(0.97); transition-duration: 0.12s; box-shadow: var(--lg-cap-shadow-press); }
html a.back:not(.ed-head *):focus-visible { outline: 2.5px solid var(--accent); outline-offset: 3px; }

/* ---------- 5. Notices: glass cards with a bead ("i" information, "!" needs a look, red "!" blocked) ---------- */
html .notice.terms-note {
  position: relative; padding: 0.85rem 1rem 0.85rem 2.8rem; border: 0; border-radius: 18px; color: var(--ink);
  background-color: var(--lg-cap); background-image: var(--lg-cap-image); box-shadow: var(--lg-cap-shadow);
}
html p.pl-hint {
  position: relative; padding: 0.75rem 1rem 0.75rem 2.7rem; border-radius: 16px; color: #4a4b51; font-size: 0.9rem;
  background-color: var(--lg-cap); background-image: var(--lg-cap-image); box-shadow: var(--lg-cap-shadow);
}
html :is(p, div).warn, html p.w-note.warn {
  position: relative; padding: 0.75rem 1rem 0.75rem 2.75rem; border: 0; border-radius: 16px; color: #3a3b41;
  background-color: rgba(255, 255, 255, 0.72); background-image: var(--lg-cap-image);
  box-shadow: inset 0 1px 0 #fff, 0 0 0 1px rgba(20, 33, 61, 0.12), 0 6px 16px -8px rgba(20, 33, 61, 0.25);
}
html .box.block-check { position: relative; padding: 1.1rem 1.2rem 1.1rem 3rem; border: 0; color: var(--ink); }
html .box.block-check h2 { color: var(--ink); }
html .block-check .block-orders { list-style: none; padding: 0; }
html :is(.notice.terms-note, p.pl-hint, p.warn, div.warn, .box.block-check)::before {
  content: "!"; position: absolute; left: 0.85rem; top: 0.78rem; width: 1.25rem; height: 1.25rem; border-radius: 50%;
  display: grid; place-items: center; font: 700 0.78rem/1 -apple-system, system-ui, sans-serif; color: #fff;
  background-color: var(--lg-navy); background-image: var(--lg-navy-image); box-shadow: var(--lg-navy-shadow);
}
html :is(.notice.terms-note, p.pl-hint)::before { content: "i"; font: italic 600 0.78rem/1 Georgia, serif; }
html .notice.terms-note::before { left: 0.9rem; top: 0.9rem; }
html .box.block-check::before { left: 1.1rem; top: 1.25rem; }
html :is(p.warn.block-warn, .box.block-check)::before {
  background-color: #c4000f; background-image: linear-gradient(180deg, #e5303f, #c4000f);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.4), 0 2px 6px -2px rgba(215, 0, 21, 0.5);
}

/* ---------- 6. Pickers (a drop-down that chooses what is shown): a capsule with a chevron ---------- */
html :is(.filters select, select#add-item, form.orders-find > select) {
  width: auto; max-width: 100%; min-width: 0; min-height: 2.5rem; padding: 0 2.3rem 0 1rem; border: 0; border-radius: 999px;
  font-weight: 600; color: var(--ink); cursor: pointer;
  background: var(--lg-cap) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 8' fill='none' stroke='%2314213d' stroke-width='1.7' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M1 1.5l5 5 5-5'/%3E%3C/svg%3E") no-repeat right 0.9rem center / 0.7rem auto;
  box-shadow: var(--lg-cap-shadow);
}
html :is(.filters select, select#add-item, form.orders-find > select):focus { background-color: #fff; box-shadow: var(--lg-cap-shadow); }
html :is(.filters select, select#add-item, form.orders-find > select):focus-visible { outline: 2.5px solid var(--accent); outline-offset: 3px; }

/* ---------- 7. Search: one recessed capsule, a magnifier, the navy "Meklēt" bead inside it ---------- */
html .find-q {
  align-items: center; gap: 2px; padding: 3px; border-radius: 999px; background-color: rgba(255, 255, 255, 0.72);
  box-shadow: inset 0 1px 2px rgba(20, 33, 61, 0.08), inset 0 0 0 1px rgba(20, 33, 61, 0.12), 0 1px 0 rgba(255, 255, 255, 0.9);
  transition: background-color 0.2s var(--ease), box-shadow 0.2s var(--ease);
}
html .find-q:focus-within { background-color: #fff; box-shadow: inset 0 0 0 1px var(--accent), 0 0 0 4px rgba(20, 33, 61, 0.14); }
html .find-q input, html .find-q input:hover, html .find-q input:focus {
  min-height: 2.15rem; border: 0; border-radius: 999px; padding-left: 2.1rem; box-shadow: none; background-color: transparent;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%236e6e73' stroke-width='2' stroke-linecap='round'%3E%3Ccircle cx='11' cy='11' r='6.5'/%3E%3Cpath d='M16 16l4.5 4.5'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: 0.75rem center; background-size: 0.95rem;
}
html .find-q button, html .find-q button:hover {
  min-height: 2.15rem; padding: 0 1.05rem; border: 0; border-radius: 999px; color: #fff; font-weight: 600; cursor: pointer;
  background-color: var(--lg-navy); background-image: var(--lg-navy-image); box-shadow: var(--lg-navy-shadow);
  transition: transform 0.3s var(--lg-spring), background-color 0.2s var(--ease);
}
html .find-q button:active { transform: scale(0.96); transition-duration: 0.12s; }
html .find-q button:focus-visible { outline: 2.5px solid var(--accent); outline-offset: 2px; }
html .find-q .clear-dates { width: 1.6rem; height: 1.6rem; border: 0; color: var(--ink); background: rgba(20, 33, 61, 0.08); box-shadow: none; }
/* Date filters: quiet capsules; a filled range keeps its navy ring; an empty one says so in grey (4.6:1) */
html .find-range > input[type="date"] { border: 0; border-radius: 999px; padding: 0.15rem 0.7rem; background-color: rgba(255, 255, 255, 0.78); box-shadow: inset 0 0 0 1px rgba(20, 33, 61, 0.12); }
html .find-range.live > input[type="date"] { background-color: #fff; box-shadow: inset 0 0 0 1.5px var(--accent); }
html .find-range > input[type="date"]:focus { background-color: #fff; box-shadow: inset 0 0 0 1px var(--accent), 0 0 0 4px rgba(20, 33, 61, 0.14); }
html .find-range:not(.live) > input[type="date"]::-webkit-datetime-edit { color: #6e6e73; }
/* The browser's black calendar icon: a navy glyph (Safari draws none, so nothing changes there) */
html input[type="date"]::-webkit-calendar-picker-indicator {
  cursor: pointer; width: 1rem; height: 1rem; padding: 0.25rem; margin-right: -0.2rem; border-radius: 8px; opacity: 0.7;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2314213d' stroke-width='1.9' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='3' y='5' width='18' height='16' rx='3'/%3E%3Cpath d='M3 10h18M8 3v4M16 3v4'/%3E%3C/svg%3E") center / 1rem no-repeat;
}
html input[type="date"]::-webkit-calendar-picker-indicator:hover { opacity: 1; background-color: rgba(20, 33, 61, 0.07); }

/* ---------- 8. One of a few: the segmented track with one white lens ---------- */
/* Šodien's range: Šodien / 7 dienas / 30 dienas in the track, Periods beside it (the track would clip its pop-up) */
html .range-row { display: flex; align-items: center; gap: 0.5rem; flex-wrap: wrap; }
html .range-pick form {
  align-items: end; gap: 0.5rem; padding: 0.75rem; border: 0; border-radius: 20px; background: rgba(255, 255, 255, 0.9);
  -webkit-backdrop-filter: saturate(180%) blur(24px); backdrop-filter: saturate(180%) blur(24px);
  box-shadow: inset 0 1px 0 #fff, 0 0 0 1px rgba(20, 33, 61, 0.08), 0 18px 44px -10px rgba(20, 33, 61, 0.32);
}
html .range-field { display: grid; gap: 0.2rem; font-size: 0.78rem; font-weight: 600; color: #5d5e64; }
html .range-pick form :is(input[type="date"], .btn) { min-height: 2.5rem; }
/* Ilgums, Privātpersona / Uzņēmums: the radio stays in the form, invisible, over the whole segment */
html .row-checks { gap: 0.55rem 1.4rem; }
html :is(.days, .buyer-kind) {
  display: flex; flex-wrap: nowrap; gap: 2px; width: fit-content; max-width: 100%; padding: 3px; border-radius: 999px;
  overflow-x: auto; scrollbar-width: none; background-color: var(--lg-track);
  background-image: linear-gradient(180deg, rgba(20, 33, 61, 0.03), rgba(255, 255, 255, 0.25)); box-shadow: var(--lg-track-shadow);
}
html :is(.days, .buyer-kind)::-webkit-scrollbar { display: none; }
html .days > .daypick, html .buyer-kind > .check {
  position: relative; flex: none; display: flex; align-items: center; min-height: 2.3rem; margin: 0; padding: 0 1rem;
  border: 0; border-radius: 999px; background: transparent; box-shadow: none; color: #3c3d44; font-weight: 500; white-space: nowrap; cursor: pointer;
  transition: color 0.25s var(--ease), background-color 0.25s var(--ease), box-shadow 0.25s var(--ease);
}
html .days > .daypick:has(input:checked), html .buyer-kind > .check:has(input:checked) { background: var(--lg-lens); box-shadow: var(--lg-lens-shadow); color: var(--accent); font-weight: 600; }
html .days > .daypick:has(input:focus-visible), html .buyer-kind > .check:has(input:focus-visible) { outline: 2px solid var(--accent); outline-offset: -2px; }
/* Bloķēt — Kad: Dienas / No–līdz / Bez beigām */
html .block-modes { gap: 3px; padding: 3px; border-radius: 18px; background-color: var(--lg-track); box-shadow: var(--lg-track-shadow); }
html .block-mode { border-radius: 15px; box-shadow: none; padding: 0.55rem 0.8rem; transition: background-color 0.25s var(--ease), box-shadow 0.25s var(--ease); }
html .block-mode:has(input:checked) { background: var(--lg-lens); box-shadow: var(--lg-lens-shadow); }
html .block-mode:has(input:checked) b { color: var(--accent); }
html .block-mode:has(input:focus-visible) { outline-offset: -2px; }

/* ---------- 9. Radios and tick boxes: glass beads (navy with a white dot or tick when chosen) ---------- */
html .check > input:is([type="radio"], [type="checkbox"]):not(.switch) {
  -webkit-appearance: none; appearance: none; width: 1.15rem; height: 1.15rem; margin: 0; padding: 0; border: 0; border-radius: 50%;
  display: inline-grid; place-content: center; cursor: pointer;
  background: linear-gradient(180deg, #fff, rgba(255, 255, 255, 0.75));
  box-shadow: inset 0 1px 2px rgba(20, 33, 61, 0.12), 0 0 0 1px rgba(20, 33, 61, 0.3);
  transition: background-color 0.2s var(--ease), box-shadow 0.2s var(--ease);
}
html .check > input[type="checkbox"]:not(.switch) { border-radius: 0.36rem; }
html .check > input:is([type="radio"], [type="checkbox"]):not(.switch):checked {
  background-color: var(--accent); background-image: var(--lg-navy-image);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.35), 0 0 0 1px var(--accent), 0 2px 5px -2px rgba(20, 33, 61, 0.45);
}
html .check > input[type="radio"]:checked::after { content: ""; width: 0.42rem; height: 0.42rem; border-radius: 50%; background: #fff; }
html .check > input[type="checkbox"]:not(.switch):checked::after {
  content: ""; width: 0.72rem; height: 0.72rem; background: #fff;
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12'%3E%3Cpath d='M2.4 6.3l2.3 2.3 4.9-5.1' fill='none' stroke='%23000' stroke-width='1.9' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / contain no-repeat;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12'%3E%3Cpath d='M2.4 6.3l2.3 2.3 4.9-5.1' fill='none' stroke='%23000' stroke-width='1.9' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / contain no-repeat;
}
html .check > input:is([type="radio"], [type="checkbox"]):not(.switch):disabled { opacity: 0.45; cursor: not-allowed; }
html .check > input:is([type="radio"], [type="checkbox"]):not(.switch):focus-visible { outline: 2.5px solid var(--accent); outline-offset: 2px; }
/* Inside a segmented track the radio is the whole segment (after the beads: it must win) */
html .buyer-kind > .check > input[type="radio"]:not(.switch), html .days > .daypick > input {
  position: absolute; inset: 0; width: 100%; height: 100%; margin: 0; opacity: 0; cursor: pointer; transform: none;
}
/* Kādu rēķinu / Kā sūtīt: the chosen card is a raised white lens, not a thick ring */
html .check.send-pick { border-radius: 14px; padding-left: 2.6rem; background: rgba(255, 255, 255, 0.5); box-shadow: inset 0 0 0 1px rgba(20, 33, 61, 0.07); }
html .check.send-pick:has(input:checked) { background: var(--lg-lens); box-shadow: var(--lg-lens-shadow), 0 0 0 1.5px rgba(20, 33, 61, 0.55); }
html .check.send-pick > input { left: 0.8rem; top: 0.82rem; }

/* ---------- 10. Calendars ---------- */
/* Kalendārs' key: marks you can see (3:1 or more); today is the navy number circle */
html .legend .sw.busy { background: var(--accent-soft); box-shadow: inset 0 0 0 1px rgba(20, 33, 61, 0.3); }
html .legend .sw.shut { box-shadow: inset 0 0 0 1px rgba(20, 33, 61, 0.3); }
html .legend .sw.today { border-radius: 50%; background: var(--accent); box-shadow: none; }
/* Out of use: a light hatch and a drawn "no entry" circle in grey, no red emoji */
html .cal-month .day.shut:not(.picked), html .legend .sw.shut { background: repeating-linear-gradient(135deg, rgba(20, 33, 61, 0.03) 0 6px, rgba(20, 33, 61, 0.075) 6px 12px); }
html .job.blocked { color: #55565c; }
html .job.blocked::before {
  content: ""; display: inline-block; width: 0.62rem; height: 0.62rem; margin-right: 0.3rem; vertical-align: -0.06rem; font-size: inherit; border-radius: 50%;
  box-shadow: inset 0 0 0 1.5px currentColor;
  background: linear-gradient(135deg, transparent calc(50% - 0.8px), currentColor calc(50% - 0.8px) calc(50% + 0.8px), transparent calc(50% + 0.8px));
}
/* The month (Apple Calendar): items as small white pills, today's number in a navy circle, the chosen day navy glass */
html .cal-month .day.picked { background-color: var(--lg-navy); background-image: var(--lg-navy-image); box-shadow: var(--lg-navy-shadow); }
html .cal-month .day.today, html .strip .day.today { box-shadow: none; }
html .cal-month .day.picked.today { box-shadow: var(--lg-navy-shadow); }
html :is(.cal-month, .strip) .day.today .num {
  display: inline-grid; place-items: center; min-width: 1.55rem; height: 1.55rem; padding: 0 0.3rem; border-radius: 999px; color: #fff;
  background-color: var(--lg-navy); background-image: var(--lg-navy-image); box-shadow: var(--lg-navy-shadow);
}
html .cal-month .day.picked.today .num { color: var(--accent); background: #fff; box-shadow: none; }
@media (min-width: 861px) {
  html .cal-month .day { border-radius: 12px; padding: 0.4rem 0.45rem; }
  html .cal-month .day.today .num { margin: -0.15rem 0 0 -0.15rem; }
  html .cal-month .day .job:not(.more) {
    margin-top: 0.22rem; padding: 0.12rem 0.42rem; border-radius: 7px; font-size: 0.74rem;
    background: rgba(255, 255, 255, 0.82); box-shadow: 0 0 0 1px rgba(20, 33, 61, 0.07), 0 1px 2px rgba(20, 33, 61, 0.06);
  }
  html .cal-month .day.picked .job:not(.more) { background: rgba(255, 255, 255, 0.16); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.18); }
}
/* Šodien — Tuvākās 7 dienas: tiles you can see, the weekday as a label over the number */
html .strip .grid7 { gap: 0.4rem; }
html .strip a.day {
  display: flex; flex-direction: column; align-items: flex-start; gap: 0.15rem; min-height: 5rem; padding: 0.5rem 0.55rem; border-radius: 14px;
  background-color: rgba(255, 255, 255, 0.6); box-shadow: inset 0 0 0 1px rgba(20, 33, 61, 0.07);
}
html .strip a.day.has { background-color: var(--accent-soft); }
html .strip a.day.today { box-shadow: inset 0 0 0 1px rgba(20, 33, 61, 0.07); }
html .strip .day .dow { order: -1; text-transform: uppercase; letter-spacing: 0.04em; font-size: 0.68rem; }
html .strip .day .num { font-size: 1.05rem; font-weight: 600; }
html .strip .day .job { max-width: 100%; padding: 0.1rem 0.4rem; border-radius: 7px; font-size: 0.72rem; background: rgba(255, 255, 255, 0.85); box-shadow: 0 0 0 1px rgba(20, 33, 61, 0.07); }
/* Jauns pasūtījums: the same glass key, today a ring (not an underline), the calendar a recessed panel */
html .staff-cal { border: 0; border-radius: 18px; background: rgba(255, 255, 255, 0.6); box-shadow: inset 0 0 0 1px rgba(20, 33, 61, 0.07), inset 0 1px 0 #fff; }
html .cal-legend { gap: 0.4rem; margin-top: 0.75rem; font-size: 0.8rem; color: var(--ink); }
html .cal-legend > .key {
  gap: 0.4rem; padding: 0.28rem 0.7rem 0.28rem 0.5rem; border-radius: 999px; white-space: nowrap;
  background-color: var(--lg-cap); background-image: var(--lg-cap-image); box-shadow: var(--lg-cap-shadow);
}
html .cal-legend > span:not(.key) { flex-basis: 100%; color: #5d5e64; }
html .cal-day.today .n { text-decoration: none; }
html .cal-day.today:not(.picked) { box-shadow: inset 0 0 0 1.5px rgba(20, 33, 61, 0.45); }

/* ---------- 11. Round buttons (✎, ×): clear glass beads, a finger's size on a phone ---------- */
html :is(.pen, .clear-dates), html :is(.pen, .clear-dates):hover {
  border: 0; width: 2.25rem; height: 2.25rem; color: var(--ink);
  background-color: var(--lg-cap); background-image: var(--lg-cap-image); box-shadow: var(--lg-cap-shadow);
  transition: transform 0.4s var(--lg-spring), box-shadow 0.3s var(--ease);
}
html :is(.pen, .clear-dates):active { transform: scale(0.94); transition-duration: 0.12s; box-shadow: var(--lg-cap-shadow-press); }
html :is(.pen, .clear-dates):focus-visible { outline: 2.5px solid var(--accent); outline-offset: 2px; }
html .find-q .clear-dates, html .find-q .clear-dates:hover { width: 1.6rem; height: 1.6rem; background: rgba(20, 33, 61, 0.08); box-shadow: none; }

/* ---------- 12. Lists, headings, cards ---------- */
html .drop-day { margin: 1.4rem 0 0.4rem 0.2rem; font-size: 0.95rem; font-weight: 600; color: #3c3d44; }
html .run { border-radius: 14px; font-weight: 600; box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.6), inset 0 0 0 1px rgba(20, 33, 61, 0.05); }
html .ledger li { align-items: baseline; border-radius: 12px; background: rgba(255, 255, 255, 0.6); box-shadow: inset 0 0 0 1px rgba(20, 33, 61, 0.06); }
html .box > h2 + p.muted:has(+ form) { margin-bottom: 0.9rem; }
html a.drop-pic:has(> span) { background: linear-gradient(145deg, rgba(20, 33, 61, 0.1), rgba(20, 33, 61, 0.035)); box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.85), inset 0 0 0 1px rgba(20, 33, 61, 0.07); }
html a.drop-pic > span { font-size: 1.5rem; font-weight: 700; color: rgba(20, 33, 61, 0.72); }
html aside.order-sum > .muted:first-child { margin-bottom: 0.6rem; color: var(--ink); font-size: 1.05rem; font-weight: 600; }
html .block-head + h2 { margin-top: 1.5rem; }
html .block-head .actions .btn { min-height: 2.5rem; padding: 0 1.1rem; font-size: 0.92rem; }
html .block-move .btn.small { min-height: 2.75rem; padding: 0 1.2rem; }
html .content > .head { align-items: center; }
html .content > :is(.chips, .page-tabs) { margin-bottom: 1rem; }

/* ---------- 13. Empty: a quiet panel, not a line of grey text ---------- */
html p.empty-note {
  margin: 1rem 0 0; padding: 2rem 1.2rem; text-align: center; border-radius: var(--radius); color: #55565c; font-size: 0.95rem;
  background-color: rgba(255, 255, 255, 0.55); box-shadow: inset 0 0 0 1px rgba(20, 33, 61, 0.07);
}
html .empty-state { display: grid; justify-items: center; gap: 0.5rem; padding: 2rem 1.2rem; text-align: center; }
html .empty-state h2 { margin: 0.2rem 0 0; font-size: 1.15rem; }
html .empty-state p { margin: 0; max-width: 30rem; }
html .empty-state .btn { margin-top: 0.4rem; }
html .empty-icon { display: grid; place-items: center; width: 3rem; height: 3rem; border-radius: 50%; color: var(--accent); background-color: var(--lg-track); box-shadow: var(--lg-track-shadow); }
html .empty-icon svg { width: 1.4rem; height: 1.4rem; }

/* ---------- 14. A phone ---------- */
@media (max-width: 860px) {
  /* Lists become glass cards, the way Maksājumi already does (nothing scrolls sideways) */
  html :is(.inv-table, .clients-table, .log-table, .block-list-title + .table) { overflow: visible; background: none; box-shadow: none; }
  html :is(.inv-table, .clients-table, .log-table, .block-list-title + .table) thead { display: none; }
  html :is(.inv-table, .clients-table, .log-table, .block-list-title + .table) :is(table, tbody) { display: block; }
  html :is(.inv-table, .clients-table, .log-table) tr {
    display: flex; flex-wrap: wrap; align-items: baseline; gap: 0.25rem 0.5rem; margin-bottom: 0.55rem; padding: 0.85rem 0.95rem;
    border-radius: var(--radius-s); background: var(--glass); box-shadow: var(--glass-hi), var(--lg-depth);
  }
  html :is(.inv-table, .clients-table, .log-table, .block-list-title + .table) td { padding: 0; border: 0; background: transparent !important; min-width: 0; }
  html :is(.inv-table, .clients-table, .log-table) .muted { font-size: 0.86rem; }
  /* Rēķini: number and total, buyer, kind · date and the order */
  html .inv-table td:nth-child(1) { order: 1; }
  html .inv-table td:nth-child(8) { order: 2; margin-left: auto; font-size: 1.05rem; }
  html .inv-table td:nth-child(4) { order: 3; flex-basis: 100%; }
  html .inv-table td:is(:nth-child(2), :nth-child(3)) { color: var(--muted); font-size: 0.86rem; }
  html .inv-table td:nth-child(3) { order: 4; }
  html .inv-table td:nth-child(2) { order: 5; }
  html .inv-table td:nth-child(2)::before { content: "· "; }
  html .inv-table td:nth-child(5) { order: 6; margin-left: auto; }
  html .inv-table td:is(:nth-child(6), :nth-child(7)) { display: none; }
  /* Klienti: name and paid, contacts, orders and the last one */
  html .clients-table td:nth-child(1) { order: 1; flex: 1 1 auto; }
  html .clients-table td:nth-child(5) { order: 2; font-weight: 600; }
  html .clients-table td:nth-child(2) { order: 3; flex-basis: 100%; }
  html .clients-table td:nth-child(3) { order: 4; color: var(--muted); font-size: 0.86rem; }
  html .clients-table td:nth-child(3)::after { content: " pas."; }
  html .clients-table td:nth-child(4) { order: 5; margin-left: auto; font-size: 0.86rem; }
  /* Ziņas: what and its state, to whom, the text (3 lines), when · channel and the order */
  html .log-table td:nth-child(3) { order: 1; flex: 1 1 auto; font-weight: 600; }
  html .log-table td:nth-child(7) { order: 2; }
  html .log-table td:nth-child(4) { order: 3; flex-basis: 100%; }
  html .log-table td:nth-child(6) { order: 4; flex-basis: 100%; font-size: 0.88rem; color: #4a4b51; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
  html .log-table td:is(:nth-child(1), :nth-child(2)) { order: 5; color: var(--muted); font-size: 0.82rem; }
  html .log-table td:nth-child(2)::before { content: "· "; }
  html .log-table td:nth-child(5) { order: 6; margin-left: auto; }
  /* Bloķētās vienības: what and the button on top, when, why and the orders */
  html .block-list-title + .table tr {
    display: grid; grid-template-columns: minmax(0, 1fr) auto; grid-template-areas: "what act" "when when" "why orders";
    gap: 0.35rem 0.8rem; margin-bottom: 0.6rem; padding: 0.85rem 1rem; border-radius: 16px; background: rgba(255, 255, 255, 0.8); box-shadow: var(--lg-depth);
  }
  html .block-list-title + .table td:nth-child(1) { grid-area: what; }
  html .block-list-title + .table td:nth-child(2) { grid-area: when; }
  html .block-list-title + .table td:nth-child(3) { grid-area: why; }
  html .block-list-title + .table td:nth-child(4) { grid-area: orders; justify-self: end; }
  html .block-list-title + .table td:nth-child(5) { grid-area: act; }

  /* Overdue money is never off screen: the alerts wrap */
  html .alerts { flex-wrap: wrap; overflow: visible; margin: 0 0 0.9rem; padding: 0; }
  html .alert { white-space: normal; }
  /* Buttons inside a form are all in sight */
  html .chips.block-reasons { flex-wrap: wrap; overflow: visible; }
  /* A chip row that scrolls sideways fades at its edge, so a cut word looks meant */
  html .chips:not(.wrap):not(.tabs-row):not(.bt-tabs):not(.block-reasons) {
    -webkit-mask-image: linear-gradient(90deg, #000 calc(100% - 1.6rem), transparent); mask-image: linear-gradient(90deg, #000 calc(100% - 1.6rem), transparent); }
  /* Šodien's 7 days: centred, the item a dot */
  html .strip a.day { min-height: 4.2rem; padding: 0.35rem 0.3rem; align-items: center; }
  html .strip .day .job { width: 0.45rem; height: 0.45rem; padding: 0; font-size: 0; border-radius: 999px; background: var(--accent); box-shadow: none; }
  /* Periods: the two fields side by side, labelled */
  html .range-field { flex: 1 1 8rem; min-width: 0; }
  html .range-field > input { width: 100%; min-width: 0; }
}
@media (max-width: 760px) {
  html .orders-find .page-tabs { width: 100%; }
  html .orders-find .page-tabs > a.chip.chip { flex: 1 1 auto; padding: 0.5rem 0.55rem; font-size: 0.86rem; text-align: center; }
  html :is(.days, .buyer-kind) > :is(.daypick, .check) { min-height: 2.75rem; }
  html .row-checks:not(.buyer-kind) > .check { display: flex; align-items: center; min-height: 2.75rem; }
  html .row-checks:not(.buyer-kind) > .check > input { top: 50%; transform: translateY(-50%); }
  html .row-checks { row-gap: 0; }
  html .pen { width: 2.75rem; height: 2.75rem; }
  html .find-range .clear-dates { flex: none; width: 2.75rem; height: 2.75rem; }
  html .drop .actions .btn.small { min-height: 2.75rem; padding: 0 1rem; }
  html :is(.cal-free-title, .board > p.see-all) > a:not(.btn), html .box-head > a.more { min-height: 2.75rem; }
}
@media (max-width: 560px) {
  html .block-modes { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  html .block-mode { text-align: center; padding: 0.55rem 0.3rem; }
  html .block-mode small { font-size: 0.7rem; line-height: 1.25; }
}

/* ---------- Mouse only: the same lift and light as the other glass ---------- */
@media (hover: hover) and (pointer: fine) {
  html :is(.slip, .drop, .desk-job):is(.open, .done, .off):hover { box-shadow: var(--lg-rim), 0 0 0 1px rgba(20, 33, 61, 0.06), var(--glass-lift); }
  html :is(.cal-free-title, .board > p.see-all) > a:not(.btn):hover, html .box-head > a.more:hover, html a.back:not(.ed-head *):hover,
  html :is(.pen, .clear-dates):not(.find-q .clear-dates):hover {
    transform: translateY(-1px); background-color: rgba(255, 255, 255, 0.86); box-shadow: var(--lg-cap-shadow-hi); }
  html .find-q button:hover { background-color: var(--lg-navy-hi); box-shadow: var(--lg-navy-shadow-hi); }
  html .board-head > a:not(.btn):hover { background-color: rgba(20, 33, 61, 0.06); }
  html :is(a.call, .desk-job-main .muted a:not(.ref), .block-order a[href^="tel:"], .terms-note p a,
    :is(.small-note, .pl-hint, .warn, p.line) a:not(.btn):not(.ref)):hover {
    background-color: rgba(255, 255, 255, 0.96); box-shadow: inset 0 1px 0 #fff, 0 0 0 1px rgba(20, 33, 61, 0.15), 0 3px 10px -2px rgba(20, 33, 61, 0.2); }
  html :is(.filters select, select#add-item, form.orders-find > select):hover { background-color: rgba(255, 255, 255, 0.9); box-shadow: var(--lg-cap-shadow-hi); }
  html .strip a.day:hover { background-color: #fff; box-shadow: inset 0 0 0 1px rgba(20, 33, 61, 0.1), var(--glass-lift); }
  html :is(.days > .daypick, .buyer-kind > .check, .block-mode):not(:has(input:checked)):hover { background: rgba(255, 255, 255, 0.5); color: var(--ink); }
}

/* ---------- High contrast: real controls and outlines ---------- */
@media (forced-colors: active) {
  html .check > input:is([type="radio"], [type="checkbox"]):not(.switch) { -webkit-appearance: auto; appearance: auto; }
  html :is(.days > .daypick, .buyer-kind > .check, .block-mode):has(input:checked) { outline: 2px solid Highlight; outline-offset: -2px; }
  html :is(.cal-free-title, .board > p.see-all) > a:not(.btn), html .box-head > a.more, html a.back:not(.ed-head *), html :is(.filters select, select#add-item, form.orders-find > select) { border: 1px solid LinkText; }
  html :is(a.call, .desk-job-main .muted a:not(.ref), .block-order a[href^="tel:"], .terms-note p a, :is(.small-note, .pl-hint, .warn, p.line) a:not(.btn):not(.ref)) { text-decoration: underline; }
}

/* ---------- Reduced motion: no lift, no squeeze, no pulse ---------- */
@media (prefers-reduced-motion: reduce) {
  html :is(.cal-free-title, .board > p.see-all) > a:not(.btn), html .box-head > a.more, html a.back:not(.ed-head *), html .find-q, html .find-q button,
  html :is(.pen, .clear-dates), html .days > .daypick, html .buyer-kind > .check, html .block-mode, html .check > input,
  html :is(a.call, .desk-job-main .muted a:not(.ref), .block-order a[href^="tel:"], .terms-note p a, :is(.small-note, .pl-hint, .warn, p.line) a:not(.btn):not(.ref)) { transition: none !important; }
  html :is(.cal-free-title, .board > p.see-all) > a:not(.btn):is(:hover, :active), html .box-head > a.more:is(:hover, :active), html a.back:not(.ed-head *):is(:hover, :active),
  html .find-q button:active, html :is(.pen, .clear-dates):is(:hover, :active), html .strip a.day:hover { transform: none !important; }
  html .sc-publish.wait .sc-dot { animation: none; }
}

/* ===== Look v6: the rest of the portal (money and clients, Katalogs, settings, social pages, Platforma,
   Apmeklējumi, the site editor) =====
   Only Look v5's recipes, used once per kind of control: navy tokens for links, clear glass capsules for
   actions and small folds, glass beads for ticks and radios, chosen cards as a raised lens, tick-box chips,
   the segmented track, notices as glass cards with a bead, tables as cards on a phone, quiet empty panels.
   No orange. Nothing here changes a word or a control on the Facebook / Instagram / TikTok pages, only their look. */

/* ---------- R1. Links inside text: the navy token (same as Look v5 section 3) ---------- */
html :is(.rv-contact a, .rv-empty a, .site-place a, .site-gap-list a, .shelf-next a, .shelf-now a, .lead a, .set-main > p.muted a,
  .set-main :is(p, li, dd, legend, label, span) > a):not(.btn, .ref, .chip, .back, .pv-card) {
  color: var(--accent); font-weight: 600; text-decoration: none; border-bottom: 0;
  padding: 0.05em 0.4em; margin: 0 -0.1em; border-radius: 0.55em; overflow-wrap: anywhere;
  background-color: rgba(20, 33, 61, 0.06);
  box-shadow: inset 0 0 0 1px rgba(20, 33, 61, 0.08), inset 0 1px 0 rgba(255, 255, 255, 0.7);
  -webkit-box-decoration-break: clone; box-decoration-break: clone;
  transition: background-color 0.2s var(--ease), box-shadow 0.2s var(--ease);
}
html :is(.rv-contact a, .rv-empty a, .site-place a, .site-gap-list a, .shelf-next a, .shelf-now a, .lead a, .set-main > p.muted a,
  .set-main :is(p, li, dd, legend, label, span) > a):not(.btn, .ref, .chip, .back, .pv-card):active { background-color: rgba(20, 33, 61, 0.11); }
html :is(.rv-contact a, .rv-empty a, .site-place a, .site-gap-list a, .shelf-next a, .shelf-now a, .lead a, .set-main > p.muted a,
  .set-main :is(p, li, dd, legend, label, span) > a):not(.btn, .ref, .chip, .back, .pv-card):focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
/* One token stays one shape: a long name wraps inside it, an order or invoice number never wraps */
html a.ref { display: inline-block; max-width: 100%; vertical-align: baseline; }
html a.ref:is([href^="/orders/"], [href^="/invoices/"]) { white-space: nowrap; }
html .pl-top > a.ref:first-child { flex: 0 1 auto; }
html .clients-table td:nth-child(4) a.ref { font-weight: 500; color: #3c3d44; }
/* Phone and e-mail: the token with a glyph (as a.call) */
html :is(.table a.contact-link, .pf-dl dd > a:is([href^="tel:"], [href^="mailto:"])) {
  display: inline-flex; align-items: center; gap: 0.3rem; max-width: 100%;
  color: var(--accent); font-weight: 600; text-decoration: none; border-bottom: 0;
  padding: 0.05em 0.4em 0.05em 0.38em; margin: 0 -0.1em; border-radius: 0.55em;
  background-color: rgba(20, 33, 61, 0.06);
  box-shadow: inset 0 0 0 1px rgba(20, 33, 61, 0.08), inset 0 1px 0 rgba(255, 255, 255, 0.7);
  transition: background-color 0.2s var(--ease), box-shadow 0.2s var(--ease);
}
html :is(.table a.contact-link, .pf-dl dd > a)[href^="tel:"] {
  white-space: nowrap;
  --ic: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M6.6 10.8a15.1 15.1 0 0 0 6.6 6.6l2.2-2.2a1 1 0 0 1 1-.25 11.4 11.4 0 0 0 3.6.57 1 1 0 0 1 1 1V20a1 1 0 0 1-1 1A17 17 0 0 1 3 4a1 1 0 0 1 1-1h3.5a1 1 0 0 1 1 1c0 1.25.2 2.45.57 3.57a1 1 0 0 1-.25 1z'/%3E%3C/svg%3E");
}
html :is(.table a.contact-link, .pf-dl dd > a)[href^="mailto:"] {
  overflow-wrap: anywhere;
  --ic: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='3' y='5' width='18' height='14' rx='2.5'/%3E%3Cpath d='M4 7.5l8 5.8 8-5.8'/%3E%3C/svg%3E");
}
html :is(.table a.contact-link, .pf-dl dd > a):is([href^="tel:"], [href^="mailto:"])::before {
  content: ""; flex: none; width: 0.8em; height: 0.8em; background: currentColor;
  -webkit-mask: var(--ic) center / contain no-repeat; mask: var(--ic) center / contain no-repeat;
}
html :is(.table a.contact-link, .pf-dl dd > a):is([href^="tel:"], [href^="mailto:"]):active { background-color: rgba(20, 33, 61, 0.11); }
html :is(.table a.contact-link, .pf-dl dd > a):is([href^="tel:"], [href^="mailto:"]):focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
/* Ieraksti: the post title a navy link, not a grey box on every line */
html td > a.ref[href^="/facebook/posts/"], html td > a.ref[href^="/facebook/posts/"]:hover {
  padding: 0; margin: 0; border-radius: 0.3em; background: none; box-shadow: none; color: var(--accent); font-weight: 600;
  -webkit-box-decoration-break: slice; box-decoration-break: slice;
}
/* "E-pasts · nav iestatīts" in a message's heading: a slate status pill with its dot */
html .set-main h2 > span.muted.small-note:has(> a) { font-size: 0; margin-left: 0.5rem; vertical-align: 0.2em; }
html .set-main h2 > span.muted.small-note > a:not(.btn) {
  display: inline-flex; align-items: center; gap: 0.4rem; margin: 0; padding: 0.25rem 0.7rem; border-radius: 999px;
  font-size: 0.8rem; font-weight: 600; color: var(--amber-ink); background: var(--amber-soft); box-shadow: inset 0 0 0 1px rgba(20, 33, 61, 0.2);
}
html .set-main h2 > span.muted.small-note > a:not(.btn)::before { content: ""; width: 0.45rem; height: 0.45rem; border-radius: 50%; background: currentColor; }

/* ---------- R2. Small folds (Kas ir failā, Papildu, Cita 1 dienas cena, Skaitļi pa dienām, Vairāk, Lauki tekstā):
   one glass capsule with a chevron that turns ---------- */
html :is(details.inner, details.fold-inline, .fields > details.g-fold:not(.w-more), details.vs-table, details.ed-more, details.sc-tokens) > summary {
  list-style: none; display: inline-flex; align-items: center; justify-content: flex-start; gap: 0.5rem; width: fit-content; max-width: 100%;
  min-height: 2.3rem; margin: 0.4rem 0 0; padding: 0 0.95rem 0 1rem; border-radius: 999px; cursor: pointer;
  font-size: 0.9rem; font-weight: 600; color: var(--ink);
  background-color: var(--lg-cap); background-image: var(--lg-cap-image); box-shadow: var(--lg-cap-shadow);
  transition: transform 0.4s var(--lg-spring), box-shadow 0.3s var(--ease), background-color 0.3s var(--ease);
}
html :is(details.inner, details.fold-inline, .fields > details.g-fold:not(.w-more), details.vs-table, details.ed-more, details.sc-tokens) > summary::-webkit-details-marker { display: none; }
html :is(details.inner, details.fold-inline, .fields > details.g-fold:not(.w-more), details.vs-table, details.ed-more, details.sc-tokens) > summary::after {
  content: ""; flex: none; width: 0.42rem; height: 0.42rem; font-size: 0; border-right: 2px solid currentColor; border-bottom: 2px solid currentColor;
  opacity: 0.65; transform: translateY(-2px) rotate(45deg); transition: transform 0.25s var(--ease);
}
html :is(details.inner, details.fold-inline, .fields > details.g-fold:not(.w-more), details.vs-table, details.ed-more, details.sc-tokens)[open] > summary::after { transform: translateY(1px) rotate(225deg); }
html :is(details.inner, details.fold-inline, .fields > details.g-fold:not(.w-more), details.vs-table, details.ed-more, details.sc-tokens)[open] > summary { margin-bottom: 0.7rem; }
html :is(details.inner, details.fold-inline, .fields > details.g-fold:not(.w-more), details.vs-table, details.ed-more, details.sc-tokens) > summary:active { transform: scale(0.97); transition-duration: 0.12s; box-shadow: var(--lg-cap-shadow-press); }
html :is(details.inner, details.fold-inline, .fields > details.g-fold:not(.w-more), details.vs-table, details.ed-more, details.sc-tokens) > summary:focus-visible { outline: 2.5px solid var(--accent); outline-offset: 3px; }
/* The file list inside "Kas ir failā": hairlines, the file names in mono that wrap */
html details.fold-inline .plain-list { list-style: none; padding: 0; margin-top: 0.7rem; gap: 0; }
html details.fold-inline .plain-list li { padding: 0.5rem 0; font-size: 0.9rem; color: var(--muted); }
html details.fold-inline .plain-list li + li { border-top: 1px solid var(--line); }
html details.fold-inline .plain-list b { color: var(--ink); font-family: ui-monospace, Menlo, monospace; font-size: 0.85rem; font-weight: 600; overflow-wrap: anywhere; }

/* ---------- R3. A whole card that folds (Sezonas cenas, Atlaides, Vietnes detaļas, Google (SEO), Parametri vietnē, Kods):
   one round glass button with a drawn chevron ---------- */
html details.box:is(.fold, .tool) {
  --lg-fold-chev: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2314213d' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
}
html details.box:is(.fold, .tool)[open] {
  --lg-fold-chev: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2314213d' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 15 6-6 6 6'/%3E%3C/svg%3E");
}
html details.box:is(.fold, .tool) > summary::after,
html details.box:is(.fold, .tool)[open] > summary::after,
html details.box:is(.fold, .tool):hover > summary::after {
  content: ""; flex: none; width: 2.1rem; height: 2.1rem; margin-left: auto; border: 0; border-radius: 50%;
  opacity: 1; transform: none; font-size: 0; color: var(--ink);
  background-color: var(--lg-cap); background-image: var(--lg-fold-chev), var(--lg-cap-image);
  background-repeat: no-repeat; background-position: center; background-size: 0.95rem 0.95rem, 100% 100%;
  box-shadow: var(--lg-cap-shadow);
  transition: background-color 0.25s var(--ease), box-shadow 0.25s var(--ease);
}
html details.box:is(.fold, .tool) > summary:focus-visible { outline: 2.5px solid var(--accent); outline-offset: 4px; border-radius: 12px; }
/* Its title keeps its line; the note beside it stays quiet (under it on a phone) */
html details.box > summary > b { flex: none; }
html details.box > summary > .muted { flex: 1 1 auto; min-width: 0; font-size: 0.88rem; font-weight: 400; }
/* A row that folds (Google, logrīks): the action a capsule, the chevron drawn */
html .g-chev {
  display: inline-flex; align-items: center; gap: 0.45rem; min-height: 2.3rem; padding: 0 0.95rem; border-radius: 999px; flex: none;
  color: var(--ink); font-size: 0.86rem; font-weight: 600; white-space: nowrap;
  background-color: var(--lg-cap); background-image: var(--lg-cap-image); box-shadow: var(--lg-cap-shadow);
  transition: transform 0.4s var(--lg-spring), box-shadow 0.3s var(--ease), background-color 0.3s var(--ease);
}
html .g-chev::after, html .g-fold[open] .g-chev::after {
  content: ""; width: 0.42rem; height: 0.42rem; border-right: 2px solid currentColor; border-bottom: 2px solid currentColor; opacity: 0.55;
  transform: rotate(45deg) translateY(-2px); transition: transform 0.25s var(--ease);
}
html .g-fold[open] .g-chev::after { transform: rotate(225deg) translateY(-1px); }
/* In a link (Atsauksmes, "Pārvaldīt") the chevron points onward */
html a .g-chev::after { transform: rotate(-45deg); }
html a.rv-gsum:active .g-chev { transform: scale(0.97); transition-duration: 0.12s; box-shadow: var(--lg-cap-shadow-press); }
html a.rv-gsum:focus-visible { outline: 2.5px solid var(--accent); outline-offset: 3px; }
html details.w-more > summary { display: flex; align-items: center; gap: 0.8rem; min-height: 2.75rem; list-style: none; }
html details.w-more > summary::-webkit-details-marker { display: none; }
html details.w-more > summary::after {
  content: ""; flex: none; margin-left: auto; width: 0.5rem; height: 0.5rem; border-right: 2px solid currentColor; border-bottom: 2px solid currentColor; opacity: 0.45;
  transform: rotate(45deg) translateY(-2px); transition: transform 0.25s var(--ease);
}
html details.w-more[open] > summary::after { transform: rotate(225deg) translateY(-2px); }
html details.w-folder > summary { display: flex; flex-wrap: wrap; align-items: center; gap: 0.3rem 0.5rem; min-height: 2.75rem; }
html details.w-folder > summary > b { overflow-wrap: anywhere; min-width: 0; }
html .w-folder .w-link {
  display: inline-flex; align-items: center; min-height: 2.2rem; margin-left: auto; padding: 0 0.95rem; border-radius: 999px;
  color: var(--ink); font-weight: 600; background-color: var(--lg-cap); background-image: var(--lg-cap-image); box-shadow: var(--lg-cap-shadow);
}
html :is(.g-fold, .w-folder) > summary:focus-visible { outline: 2.5px solid var(--accent); outline-offset: 3px; border-radius: 14px; }

/* ---------- R4. Radios and tick boxes: Look v5's glass bead where a .check label does not reach
   (choice cards, Līdzīgās vienības, Dzēst). Every bead's off edge is 3:1 on white. ---------- */
html .check > input:is([type="radio"], [type="checkbox"]):not(.switch):not(:checked) { box-shadow: inset 0 1px 2px rgba(20, 33, 61, 0.12), 0 0 0 1px rgba(20, 33, 61, 0.5); }
html :is(.pay-card, .chip-check, .choice-card:not(.look), .sc-del) > input:is([type="radio"], [type="checkbox"]):not(.switch) {
  -webkit-appearance: none; appearance: none; flex: none; width: 1.15rem; height: 1.15rem; min-height: 0; margin: 0; padding: 0; border: 0; border-radius: 50%;
  display: inline-grid; place-content: center; cursor: pointer;
  background: linear-gradient(180deg, #fff, rgba(255, 255, 255, 0.75));
  box-shadow: inset 0 1px 2px rgba(20, 33, 61, 0.12), 0 0 0 1px rgba(20, 33, 61, 0.5);
  transition: background-color 0.2s var(--ease), box-shadow 0.2s var(--ease);
}
html :is(.pay-card, .chip-check, .choice-card:not(.look), .sc-del) > input[type="checkbox"]:not(.switch) { border-radius: 0.36rem; }
html :is(.pay-card, .chip-check, .choice-card:not(.look), .sc-del) > input:is([type="radio"], [type="checkbox"]):not(.switch):checked {
  background-color: var(--accent); background-image: var(--lg-navy-image);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.35), 0 0 0 1px var(--accent), 0 2px 5px -2px rgba(20, 33, 61, 0.45);
}
html :is(.pay-card, .chip-check, .choice-card:not(.look), .sc-del) > input[type="radio"]:checked::after { content: ""; width: 0.42rem; height: 0.42rem; border-radius: 50%; background: #fff; }
html :is(.pay-card, .chip-check, .choice-card:not(.look), .sc-del) > input[type="checkbox"]:not(.switch):checked::after {
  content: ""; width: 0.72rem; height: 0.72rem; background: #fff;
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12'%3E%3Cpath d='M2.4 6.3l2.3 2.3 4.9-5.1' fill='none' stroke='%23000' stroke-width='1.9' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / contain no-repeat;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12'%3E%3Cpath d='M2.4 6.3l2.3 2.3 4.9-5.1' fill='none' stroke='%23000' stroke-width='1.9' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / contain no-repeat;
}
html :is(.pay-card, .chip-check, .choice-card:not(.look), .sc-del) > input:is([type="radio"], [type="checkbox"]):not(.switch):focus-visible { outline: 2.5px solid var(--accent); outline-offset: 2px; }
html :is(.pay-card, .chip-check, .choice-card:not(.look), .sc-del) > input:is([type="radio"], [type="checkbox"]):not(.switch):disabled { opacity: 0.45; cursor: not-allowed; }
html .pay-card.pay-card > input:is([type="radio"], [type="checkbox"]):not(.switch) { margin-top: 0.15rem; }
html .choice-card:not(.look) > input[type="radio"] { top: 0.95rem; right: 0.95rem; }
/* A switch inside a settings table keeps its own size */
html .set-main .table input.switch { min-height: 0; padding: 0; vertical-align: middle; }

/* ---------- R5. Choice cards (Kā piedāvā, Kā rēķinām piegādi, SMS pakalpojums, Plāns, Izskats vietnē):
   Look v5's .send-pick card, the chosen one a raised lens with a navy ring ---------- */
html :is(.choice-card, .pay-card) {
  border: 0; border-radius: 16px; background: rgba(255, 255, 255, 0.5); box-shadow: inset 0 0 0 1px rgba(20, 33, 61, 0.1);
  transition: background-color 0.25s var(--ease), box-shadow 0.25s var(--ease);
}
html :is(.choice-card, .pay-card):has(input:checked) { background: var(--lg-lens); box-shadow: var(--lg-lens-shadow), 0 0 0 1.5px rgba(20, 33, 61, 0.55); }
html .pay-card a { overflow-wrap: anywhere; }
html #veids > h2 { margin-bottom: 0; }
html .item-editor .pay-card { margin: 0; padding: 0.85rem 1rem; gap: 0.75rem; align-items: flex-start; }
/* Izskats vietnē (Stūri, Bilžu rādīšana): picker tiles, the radio hidden, the chosen tile with a tick */
html .looks .choice-card { border-radius: 14px; }
html .looks .choice-card > input[type="radio"] { opacity: 0; pointer-events: none; }
html .looks .choice-card:has(input:checked)::after {
  content: ""; position: absolute; right: 0.45rem; bottom: 0.5rem; width: 1.05rem; height: 1.05rem; border-radius: 50%;
  background-color: var(--accent); background-repeat: no-repeat; background-position: center; background-size: 0.7rem 0.7rem, 100% 100%;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='none' stroke='%23fff' stroke-width='2.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m3.6 8.4 2.9 2.9 5.9-6.6'/%3E%3C/svg%3E"), var(--lg-navy-image);
}
html .looks .choice-card:has(input:focus-visible) { outline: 2.5px solid var(--accent); outline-offset: 2px; }
html .looks .swatch { border: 1.5px solid rgba(20, 33, 61, 0.14); background: linear-gradient(160deg, #f3f5f9, #e3e8f1); }
html .looks .choice-card.look:has(input:checked) .swatch { border-color: rgba(20, 33, 61, 0.45); }
/* Plāns: glass cards with a bead, the list ticks navy */
html form.box:has(> .plans) { padding: 0; background: transparent; box-shadow: none; }
html .box .plan-card { padding-right: 2.8rem; background: var(--glass); box-shadow: var(--glass-hi), var(--shadow); transition: background-color 0.25s var(--ease), box-shadow 0.25s var(--ease); }
html .box .plan-card::after {
  content: ""; position: absolute; top: 1.05rem; right: 1rem; width: 1.3rem; height: 1.3rem; border-radius: 50%;
  background: linear-gradient(180deg, #fff, rgba(255, 255, 255, 0.75));
  box-shadow: inset 0 1px 2px rgba(20, 33, 61, 0.12), 0 0 0 1px rgba(20, 33, 61, 0.5);
}
html .box .plan-card:has(input:checked) { background: var(--lg-lens); box-shadow: var(--lg-lens-shadow), 0 0 0 1.5px rgba(20, 33, 61, 0.55); }
html .box .plan-card:has(input:checked)::after {
  background-color: var(--accent); background-image: radial-gradient(circle, #fff 0 0.22rem, transparent 0.25rem), var(--lg-navy-image);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.35), 0 0 0 1px var(--accent), 0 2px 5px -2px rgba(20, 33, 61, 0.45);
}
html .box .plan-card:has(input:focus-visible) { outline: 2.5px solid var(--accent); outline-offset: 3px; }
html .box .plan-card li::before {
  content: "✓"; width: auto; height: auto; top: 0; left: 0; background: none; transform: none;
  color: var(--accent); font-weight: 700; font-size: 0.8rem; line-height: inherit;
}
/* Logrīka izkārtojums: the chosen layout a raised lens */
html .w-logo { color: var(--accent); }
html .w-layout > span { border-radius: 16px; background: rgba(255, 255, 255, 0.5); box-shadow: inset 0 0 0 1px rgba(20, 33, 61, 0.1); transition: background-color 0.25s var(--ease), box-shadow 0.25s var(--ease); }
html .w-layout input:checked + span { background: var(--lg-lens); box-shadow: var(--lg-lens-shadow), 0 0 0 1.5px rgba(20, 33, 61, 0.55); }
html .w-layout input:checked + span svg { color: var(--accent); }
html .w-layout input:focus-visible + span { outline: 2.5px solid var(--accent); outline-offset: 3px; }

/* ---------- R6. Tick-box chips (Kur publicēt, Kārto, Neviens parametrs, Izvēlētām vienībām): the .chip-check recipe ---------- */
html :is(.spec-row, #parametri form, .code-targets) > label.check, html .ch-targets .check {
  display: inline-flex; align-items: center; gap: 0.45rem; justify-self: start; min-height: 2.5rem; margin: 0; padding: 0.4rem 0.95rem 0.4rem 0.7rem;
  border-radius: 999px; font-size: 0.9rem; font-weight: 500; cursor: pointer;
  background-color: var(--lg-cap); background-image: var(--lg-cap-image);
  box-shadow: inset 0 1px 0 #fff, 0 0 0 1px rgba(20, 33, 61, 0.13), 0 4px 10px -5px rgba(20, 33, 61, 0.2);
  transition: box-shadow 0.2s var(--ease), background-color 0.2s var(--ease);
}
html :is(.spec-row, #parametri form, .code-targets) > label.check > input, html .ch-targets .check > input { position: static; flex: none; transform: none; }
html :is(.spec-row, #parametri form, .code-targets) > label.check:has(input:checked), html .ch-targets .check:has(input:checked) {
  background-color: rgba(233, 236, 243, 0.92); box-shadow: inset 0 1px 0 #fff, 0 0 0 1.5px var(--accent), 0 4px 10px -5px rgba(20, 33, 61, 0.22);
}
html .ch-targets { gap: 0.5rem; }
html .code-targets:not([hidden]) { display: flex; flex-wrap: wrap; gap: 0.4rem; margin-top: 0.6rem; }
/* Maksājumi (Noapaļot, Virziens, Kā rakstīt): choice chips, the chosen one navy like .chip.on */
html .money-page fieldset.pay-choices:has(input[type="radio"]) { display: flex; flex-wrap: wrap; align-items: center; gap: 0.45rem; }
html .money-page fieldset.pay-choices > label.check:has(> input[type="radio"]) {
  position: relative; display: inline-flex; align-items: center; min-height: 2.6rem; padding: 0.4rem 1rem; border-radius: 999px; cursor: pointer;
  font-weight: 500; color: var(--ink);
  background-color: var(--lg-cap); background-image: var(--lg-cap-image);
  box-shadow: inset 0 1px 0 #fff, 0 0 0 1px rgba(20, 33, 61, 0.13), 0 4px 10px -5px rgba(20, 33, 61, 0.2);
  transition: box-shadow 0.3s var(--ease), background-color 0.3s var(--ease), color 0.2s;
}
html .money-page fieldset.pay-choices > label.check > input[type="radio"] { position: absolute; inset: 0; width: 100%; height: 100%; margin: 0; opacity: 0; cursor: pointer; transform: none; }
html .money-page fieldset.pay-choices > label.check:has(> input:checked) {
  color: #fff; background-color: var(--lg-navy); background-image: var(--lg-navy-image); box-shadow: var(--lg-navy-shadow);
}
html .money-page fieldset.pay-choices > label.check:has(> input:focus-visible) { outline: 2.5px solid var(--accent); outline-offset: 3px; }
html .money-page fieldset.pay-choices > :is(.err, p) { flex-basis: 100%; }
/* Kam der (now the .w-segs track): it may wrap on a phone, so no choice hides */
@media (max-width: 560px) { html .pay-choices > .w-segs { flex-wrap: wrap; overflow: visible; border-radius: 20px; } }

/* ---------- R7. Pickers people type into: file, colour, search ---------- */
/* File: a recessed capsule with a glass "Choose" capsule inside (drop zones keep their hidden input) */
html input[type="file"]:not([hidden], .photo-drop input, .pic-upload input, .sc-photo input) {
  max-width: 100%; min-height: 2.9rem; padding: 0.35rem 0.6rem 0.35rem 0.35rem; border-radius: 999px; font-size: 0.88rem; color: #55565c; cursor: pointer;
  background-color: rgba(255, 255, 255, 0.72);
  box-shadow: inset 0 1px 2px rgba(20, 33, 61, 0.08), inset 0 0 0 1px rgba(20, 33, 61, 0.12), 0 1px 0 rgba(255, 255, 255, 0.9);
}
html input[type="file"]:not([hidden], .photo-drop input, .pic-upload input, .sc-photo input)::file-selector-button {
  margin-right: 0.75rem; min-height: 2.15rem; padding: 0 1rem; border: 0; border-radius: 999px; cursor: pointer;
  font: inherit; font-weight: 600; color: var(--ink);
  background-color: var(--lg-cap); background-image: var(--lg-cap-image); box-shadow: var(--lg-cap-shadow);
  transition: background-color 0.2s var(--ease), box-shadow 0.2s var(--ease);
}
html input[type="file"]:not([hidden], .photo-drop input, .pic-upload input, .sc-photo input)::-webkit-file-upload-button {
  margin-right: 0.75rem; min-height: 2.15rem; padding: 0 1rem; border: 0; border-radius: 999px; cursor: pointer;
  font: inherit; font-weight: 600; color: var(--ink);
  background-color: var(--lg-cap); background-image: var(--lg-cap-image); box-shadow: var(--lg-cap-shadow);
}
html input[type="file"]:not([hidden], .photo-drop input, .pic-upload input, .sc-photo input):focus { background-color: #fff; }
html input[type="file"]:not([hidden], .photo-drop input, .pic-upload input, .sc-photo input):focus-visible { outline: 2.5px solid var(--accent); outline-offset: 3px; }
html .box > :is(p.muted, .icon-now, img.logo-preview, img.share-preview) + .logo-form { margin-top: 0.85rem; }
/* Colour: a round glass bead holding the colour */
html :is(.set-main, .fields) input[type="color"] {
  -webkit-appearance: none; appearance: none; flex: none; display: block; width: 2.75rem; height: 2.75rem; min-height: 0; padding: 0.25rem; border: 0;
  border-radius: 999px; overflow: hidden; cursor: pointer;
  background-color: var(--lg-cap); background-image: var(--lg-cap-image); box-shadow: var(--lg-cap-shadow);
}
html :is(.set-main, .fields) input[type="color"]::-webkit-color-swatch-wrapper { padding: 0; }
html :is(.set-main, .fields) input[type="color"]::-webkit-color-swatch { border: 0; border-radius: 999px; box-shadow: inset 0 0 0 1px rgba(20, 33, 61, 0.18), inset 0 1px 2px rgba(0, 0, 0, 0.15); }
html :is(.set-main, .fields) input[type="color"]::-moz-color-swatch { border: 0; border-radius: 999px; box-shadow: inset 0 0 0 1px rgba(20, 33, 61, 0.18); }
html :is(.set-main, .fields) input[type="color"]:focus { background-color: #fff; box-shadow: var(--lg-cap-shadow); }
html :is(.set-main, .fields) input[type="color"]:focus-visible { outline: 2.5px solid var(--accent); outline-offset: 3px; }
html .w-color input[type="color"] { display: inline-block; }
/* Search (Katalogs, Platforma): the recessed capsule with a magnifier, as Look v5's .find-q */
html :is(.shelf-search, .pf-tools .pf-search) input:not([type="hidden"]) {
  width: 100%; min-width: 0; min-height: 2.5rem; border: 0; border-radius: 999px; padding: 0 1rem 0 2.2rem;
  background: rgba(255, 255, 255, 0.72) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%236e6e73' stroke-width='2' stroke-linecap='round'%3E%3Ccircle cx='11' cy='11' r='6.5'/%3E%3Cpath d='M16 16l4.5 4.5'/%3E%3C/svg%3E") no-repeat 0.85rem center / 0.95rem;
  box-shadow: inset 0 1px 2px rgba(20, 33, 61, 0.08), inset 0 0 0 1px rgba(20, 33, 61, 0.12), 0 1px 0 rgba(255, 255, 255, 0.9);
  transition: background-color 0.2s var(--ease), box-shadow 0.2s var(--ease);
}
html :is(.shelf-search, .pf-tools .pf-search) input:not([type="hidden"]):focus { background-color: #fff; box-shadow: inset 0 0 0 1px var(--accent), 0 0 0 4px rgba(20, 33, 61, 0.14); }
html .pf-tools .pf-search { flex: 1 1 18rem; max-width: 24rem; }
/* Kods citai vietnei: the item picker a capsule (Look v5 section 6) */
html .code-item select {
  width: auto; max-width: 100%; min-width: 0; min-height: 2.5rem; padding: 0 2.3rem 0 1rem; border: 0; border-radius: 999px; font-weight: 600; color: var(--ink); cursor: pointer;
  background: var(--lg-cap) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 8' fill='none' stroke='%2314213d' stroke-width='1.7' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M1 1.5l5 5 5-5'/%3E%3C/svg%3E") no-repeat right 0.9rem center / 0.7rem auto;
  box-shadow: var(--lg-cap-shadow);
}
html .code-item select:focus { background-color: #fff; box-shadow: var(--lg-cap-shadow); }
html .code-item select:focus-visible { outline: 2.5px solid var(--accent); outline-offset: 3px; }
html .code-item > .muted { font-weight: 600; color: var(--ink); }

/* ---------- R8. Inner groups of a form (Uzņēmuma dati, Parametri, Pārdevēja rekvizīti): a soft panel, its title inside ---------- */
html :is(#labot > .sc-group, .sc-group[data-company], .item-editor .sc-group, #rekini fieldset.sc-group) {
  border: 0; padding: 0.85rem 0.95rem 0.95rem; border-radius: 16px;
  background: rgba(20, 33, 61, 0.035); box-shadow: inset 0 0 0 1px rgba(20, 33, 61, 0.06);
}
html :is(#labot > .sc-group, .sc-group[data-company], .item-editor .sc-group, #rekini fieldset.sc-group) > legend {
  float: left; width: 100%; margin: 0 0 0.2rem; padding: 0; font-size: 0.95rem; font-weight: 600; letter-spacing: -0.005em; text-transform: none; color: var(--ink);
}
html :is(#labot > .sc-group, .sc-group[data-company], .item-editor .sc-group, #rekini fieldset.sc-group) > legend + * { clear: both; }
html .item-editor .sc-group { margin-top: 1rem; }
/* Section headings inside a long settings form: a real heading with a hairline above */
html .fields > p.side-label {
  margin: 0.6rem 0 0; padding-top: 1.1rem; border-top: 1px solid var(--line);
  font-size: 1.02rem; font-weight: 600; letter-spacing: -0.01em; text-transform: none; color: var(--ink);
}
html .fields > p.side-label + p.small-note { margin-top: -0.5rem; }
/* Veikals: each fieldset a section with a real title, a hairline between them */
html .set-main form[action="/settings/shop"] > fieldset.pay-choices { gap: 0.7rem; }
html .set-main form[action="/settings/shop"] > fieldset.pay-choices + fieldset.pay-choices { margin-top: 0.4rem; padding-top: 1.1rem; border-top: 1px solid rgba(20, 33, 61, 0.09); }
html .set-main form[action="/settings/shop"] > fieldset.pay-choices > legend.lbl { float: left; width: 100%; margin: 0 0 0.2rem; padding: 0; font-size: 1.05rem; font-weight: 600; letter-spacing: -0.01em; color: var(--ink); }
html .set-main .locker-way { display: grid; gap: 0.6rem; padding: 0.85rem 0.95rem; border-radius: 16px; background: rgba(255, 255, 255, 0.5); box-shadow: inset 0 0 0 1px rgba(20, 33, 61, 0.08), inset 0 1px 0 #fff; }
/* A field's hint is a caption under its label */
html .lbl .lbl-hint { display: block; margin-top: 0.12rem; font-size: 0.8rem; font-weight: 400; line-height: 1.4; letter-spacing: 0; color: #5d5e64; }
/* A button in a settings form: a normal pill, not a bar across the card (full width on a phone) */
html :is(.set-main form.fields, form.box.narrow.fields) > button.btn:not(.small):not(.wide) { justify-self: start; min-width: 10rem; padding-inline: 1.6rem; }
@media (min-width: 761px) { html form.box.fields[action^="/codes"] > button.btn { justify-self: start; padding: 0 1.8rem; } }
html #parametri form.fields > .btn, html #versijas form.fields > .btn { justify-self: start; }
html .box.fields > * { min-width: 0; }

/* ---------- R9. Notes: glass cards with a bead ("i" information, "!" needs a look), as Look v5 section 5 ---------- */
/* (plain selector lists, not :is(), so each element keeps its own weight and its overrides below still win) */
html .site-place.site-place, html .set-main p.note:not(.see-all) {
  position: relative; border-radius: 16px; font-size: 0.9rem; line-height: 1.45; color: #45464c;
  background-color: var(--lg-cap); background-image: var(--lg-cap-image); box-shadow: var(--lg-cap-shadow);
}
html .site-place.site-place { margin: 0.7rem 0 0; padding: 0.65rem 0.85rem 0.65rem 2.55rem; font-size: 0.88rem; }
html .set-main p.note:not(.see-all) { padding: 0.75rem 1rem 0.75rem 2.7rem; }
html .site-place.site-place::before, html .set-main p.note:not(.see-all)::before, html .box.site-gap::before {
  content: "i"; position: absolute; left: 0.8rem; top: 0.72rem; width: 1.2rem; height: 1.2rem; border-radius: 50%;
  display: grid; place-items: center; font: italic 600 0.75rem/1 Georgia, serif; color: #fff;
  background-color: var(--lg-navy); background-image: var(--lg-navy-image); box-shadow: var(--lg-navy-shadow);
}
html .site-place.site-place.warn-line::before { content: "!"; font: 700 0.75rem/1 -apple-system, system-ui, sans-serif; }
html :is(.site-place, .set-main p.note) b { color: var(--ink); }
/* On the site: a short green line (its own ✓ is in the text, 5.9:1) */
html .site-place.site-place.ok { padding: 0.5rem 0.8rem; color: #136c2c; font-weight: 500; background: rgba(229, 246, 233, 0.9); box-shadow: inset 0 0 0 1px rgba(26, 127, 55, 0.2); }
html .site-place.site-place.ok::before { content: none; }
/* Katalogs, "not on the site yet": the glass note with its bead, the groups as soft rows */
html .box.site-gap { position: relative; padding-left: 3rem; border: 0; }
html .box.site-gap::before { left: 1.1rem; top: 1.2rem; width: 1.25rem; height: 1.25rem; font-size: 0.78rem; }
html .site-gap-list { list-style: none; margin: 0; padding: 0; gap: 0.45rem; }
html .site-gap-list li { padding: 0.6rem 0.8rem; border-radius: 12px; line-height: 1.5; background: rgba(20, 33, 61, 0.035); box-shadow: inset 0 0 0 1px rgba(20, 33, 61, 0.05); }
/* A note that carries actions (Messente atlikums, plāns): the actions as capsules at its end */
html .note-acts { display: inline-flex; flex-wrap: wrap; gap: 0.4rem; margin: 0.25rem 0 0 0.5rem; vertical-align: middle; }
html .plan-note > .btn { margin-left: auto; }
html .set-main :is(.lead, .hint-row, .w-note) > .btn { vertical-align: middle; margin: 0.2rem 0 0.2rem 0.35rem; }
html .g-place > .btn { flex: none; }
/* Site editor hint line: words with a pencil bead; the plan offer clear glass */
html .sc-tip:not(.strong) { background: transparent; box-shadow: none; padding: 0.2rem 0.2rem 0.2rem 0; color: #5d5e64; }
html .sc-tip::before {
  content: ""; display: inline-block; width: 1.2rem; height: 1.2rem; margin-right: 0.45rem; vertical-align: -0.28em; border-radius: 50%;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2314213d' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4 20h4L19 9l-4-4L4 16v4z'/%3E%3C/svg%3E") center / 0.68rem no-repeat, var(--lg-cap-image);
  background-color: var(--lg-cap); box-shadow: var(--lg-cap-shadow);
}
html .offer-chip { background-color: var(--lg-cap); background-image: var(--lg-cap-image); box-shadow: var(--lg-cap-shadow); }
html .offer-chip span:not(.offer-spark), html .offer-spark { color: #55565c; }
html a.offer-chip { transition: transform 0.4s var(--lg-spring), box-shadow 0.3s var(--ease), background-color 0.3s var(--ease); }
html a.offer-chip:active { transform: scale(0.97); transition-duration: 0.12s; box-shadow: var(--lg-cap-shadow-press); }
html a.offer-chip:focus-visible { outline: 2.5px solid var(--accent); outline-offset: 3px; }

/* ---------- R10. No orange, no Google blue: waiting is slate, steps and picks are navy glass ---------- */
html .rv-state.new { color: #fff; background-color: var(--lg-navy); background-image: var(--lg-navy-image); box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.3); }
html :is(.g-status.wait, .g-ready:not(.ok), .plan-tag-small:not(.price)) { color: var(--amber-ink); background: var(--amber-soft); box-shadow: inset 0 0 0 1px rgba(20, 33, 61, 0.2); }
html .g-ready.ok { box-shadow: inset 0 0 0 1px rgba(26, 127, 55, 0.25); }
html .g-mini { color: #55565c; }
html .w-state.none { color: var(--amber-ink); font-weight: 600; }
html .g-copy.missing { background: rgba(20, 33, 61, 0.03); }
html .g-copy.missing dd { gap: 0.4rem 0.6rem; }
html .stars, html .rv-who .stars { color: #3c3d44; }
html .g-avatar { box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.4), inset 0 -1px 2px rgba(0, 0, 0, 0.12), 0 2px 6px -2px rgba(20, 33, 61, 0.35); }
html .g-avatar[style*="#e37400"] { background: #5b5fc7 !important; }
html .g-avatar[style*="#b06000"] { background: #3c4a6b !important; }
html .g-steps li span { color: #4a4b51; background-color: var(--lg-cap); background-image: var(--lg-cap-image); box-shadow: inset 0 1px 0 #fff, 0 0 0 1px rgba(20, 33, 61, 0.16); }
html .g-steps li.now span { color: #fff; background-color: var(--lg-navy); background-image: var(--lg-navy-image); box-shadow: var(--lg-navy-shadow); }
html .g-steps li.done span { color: #137333; background: rgba(229, 246, 233, 0.9); box-shadow: inset 0 0 0 1px rgba(26, 127, 55, 0.25); }
html .g-steps li + li::before { background: rgba(20, 33, 61, 0.18); }
html .g-create-icon { color: var(--accent); border-radius: 14px; background-color: var(--lg-cap); background-image: var(--lg-cap-image); box-shadow: var(--lg-cap-shadow); }
html .g-place-pick { border: 0; border-radius: 16px; background: rgba(255, 255, 255, 0.55); box-shadow: inset 0 0 0 1px rgba(20, 33, 61, 0.08); }
/* A changed postal code: a dot before the code, not an edge stripe */
html .code-row.changed { box-shadow: none; background: rgba(20, 33, 61, 0.045); }
html .code-no { display: inline-flex; align-items: center; gap: 0.35rem; }
html .code-row.changed .code-no::before { content: ""; flex: none; width: 0.45rem; height: 0.45rem; border-radius: 50%; background: var(--accent); box-shadow: 0 0 0 3px rgba(20, 33, 61, 0.14); }
/* Iestatīšana: "Vēl jāizdara" slate with an open ring (done keeps its green tick) */
html .step-state { padding: 0.16rem 0.6rem; }
html .step-state:not(.ok) {
  display: inline-flex; align-items: center; gap: 0.35rem; color: var(--accent); background: rgba(20, 33, 61, 0.07);
  box-shadow: inset 0 0 0 1px rgba(20, 33, 61, 0.12), inset 0 1px 0 rgba(255, 255, 255, 0.7);
}
html .step-state:not(.ok)::before { content: ""; flex: none; width: 0.45rem; height: 0.45rem; border-radius: 50%; box-shadow: inset 0 0 0 1.5px currentColor; }
/* Apmeklējumi: no orange in the tablet share */
html .vs-ideas { background: var(--glass); }
html .vs-ideas li::before { color: var(--accent); }
html .d-tablet { background: #6f7fa8; }

/* ---------- R11. Actions that were underlined words: clear capsules ---------- */
/* Izlaist, Atgriezt, Paslēpt */
html :is(.setup-step .actions, .first-steps, .step-guide) :is(a, button).linkish {
  display: inline-flex; align-items: center; min-height: 2.2rem; padding: 0 0.95rem; border: 0; border-radius: 999px;
  font: inherit; font-size: 0.88rem; font-weight: 600; text-decoration: none; color: #4a4b51; cursor: pointer;
  background: transparent; box-shadow: inset 0 0 0 1px rgba(20, 33, 61, 0.16);
  transition: background-color 0.2s var(--ease), color 0.2s var(--ease), transform 0.3s var(--lg-spring);
}
html :is(.setup-step .actions, .first-steps, .step-guide) :is(a, button).linkish:active { transform: scale(0.97); transition-duration: 0.12s; background-color: var(--lg-platter); }
html :is(.setup-step .actions, .first-steps, .step-guide) :is(a, button).linkish:focus-visible { outline: 2.5px solid var(--accent); outline-offset: 2px; }
/* Atlaides: Noņemt a small red capsule */
html .rule-card .link-btn {
  align-self: end; min-height: 2.2rem; padding: 0 0.85rem; border-radius: 999px; font-weight: 600; font-size: 0.85rem; color: var(--danger);
  background-color: var(--lg-cap); background-image: var(--lg-cap-image);
  box-shadow: inset 0 1px 0 #fff, 0 0 0 1px rgba(215, 0, 21, 0.4), 0 4px 10px -6px rgba(215, 0, 21, 0.25);
  transition: transform 0.4s var(--lg-spring), background-color 0.2s var(--ease);
}
html .rule-card .link-btn:active { transform: scale(0.96); transition-duration: 0.12s; background-color: rgba(255, 235, 237, 0.9); }
html .rule-card .link-btn:focus-visible { outline: 2.5px solid var(--accent); outline-offset: 3px; }
/* Platforma: pending messages a capsule */
html .pf-inbox a { color: var(--ink); background-color: var(--lg-cap); background-image: var(--lg-cap-image); box-shadow: var(--lg-cap-shadow); }
html .pf-inbox a b { color: var(--accent); }
html .pf-inbox a:focus-visible { outline: 2.5px solid var(--accent); outline-offset: 3px; }
/* Google: "Atvērt Google atsauksmes" with its words beside it */
html .rv-google { display: flex; flex-wrap: wrap; align-items: center; gap: 0.5rem 0.75rem; }

/* ---------- R12. Empty: Look v5's quiet panel ---------- */
html p.rv-empty {
  margin: 1rem 0 0; padding: 2rem 1.2rem; text-align: center; border-radius: var(--radius); color: #55565c; font-size: 0.95rem;
  background-color: rgba(255, 255, 255, 0.55); box-shadow: inset 0 0 0 1px rgba(20, 33, 61, 0.07);
}
html .shelf > .shelf-empty {
  grid-column: 1 / -1; border-radius: var(--radius); color: #55565c;
  background-color: rgba(255, 255, 255, 0.55); box-shadow: inset 0 0 0 1px rgba(20, 33, 61, 0.07);
}
html .client-orders > p.empty-note { margin: 0; padding: 1.4rem 1rem; }
html .narrow-stack > .box > p.empty-note { margin-top: 0.7rem; padding: 1.2rem 1rem; }
html .g-overview-main > p.empty-note { flex: 1 1 14rem; margin: 0; padding: 1.2rem 1rem; }
html .w-stage .w-empty { display: grid; place-items: center; min-height: 10rem; margin: 0; text-align: center; color: #55565c; }
html .w-stage.dark .w-empty { color: #b4b8be; }
html .fb-chat-empty p { display: grid; justify-items: center; gap: 0.75rem; margin: 0; color: #5d5e64; font-weight: 500; }
html .fb-chat-empty p::before {
  content: ""; width: 3rem; height: 3rem; border-radius: 50%;
  background: var(--lg-track) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2314213d' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M21 12a8 8 0 0 1-11.6 7.1L4 20l1-4.6A8 8 0 1 1 21 12z'/%3E%3C/svg%3E") center / 1.4rem no-repeat;
  box-shadow: var(--lg-track-shadow);
}

/* ---------- R13. Code and links to copy: light recessed panels, Kopēt centred beside ---------- */
html :is(.code-block, .w-code) { color: #1d1d1f; background: rgba(20, 33, 61, 0.055); border-radius: 14px; box-shadow: inset 0 1px 2px rgba(20, 33, 61, 0.08), inset 0 0 0 1px rgba(20, 33, 61, 0.06); }
html .w-code code { color: inherit; background: none; padding: 0; }
html .snippet-row { align-items: center; gap: 0.45rem; }
html .snippet-row > .btn { flex: none; margin-top: 0; }
html .snippet-row > input { flex: 1 1 auto; min-width: 0; }
html .set-main :is(p, li) > code { overflow-wrap: anywhere; word-break: break-word; padding: 0.05rem 0.4rem; border-radius: 6px; background: rgba(20, 33, 61, 0.06); font-size: 0.86em; }
html .set-main p.lbl + .snippet-row .code-block { margin-top: 0; }
html .trk-text { border-left: 0; border-radius: 16px; padding: 0.95rem 1.05rem; background: rgba(255, 255, 255, 0.6); box-shadow: inset 0 1px 0 #fff, 0 0 0 1px rgba(20, 33, 61, 0.09); }
/* Numbered steps as navy beads (Kods citai vietnei) */
html #kods p.small-note > b:first-child {
  display: inline-grid; place-items: center; min-width: 1.45rem; height: 1.45rem; margin-right: 0.4rem; padding: 0 0.2rem; border-radius: 999px;
  vertical-align: 0.05em; font-size: 0.75rem; color: #fff;
  background-color: var(--lg-navy); background-image: var(--lg-navy-image); box-shadow: var(--lg-navy-shadow);
}
html #kods p.small-note:has(> b:first-child) { margin-top: 1rem; color: var(--ink); }

/* ---------- R14. Lists: bead or tick markers, hairline groups ---------- */
html ul.tick-list { list-style: none; margin: 0.4rem 0 0; padding: 0; display: grid; gap: 0.5rem; }
html ul.tick-list > li { position: relative; padding-left: 1.35rem; }
html ul.tick-list > li::before { content: ""; position: absolute; left: 0.15rem; top: 0.48em; width: 0.45rem; height: 0.45rem; border-radius: 50%; background: var(--accent); box-shadow: 0 0 0 3px rgba(20, 33, 61, 0.12); }
html .box > h2 + ul.plain-list { list-style: none; padding-left: 0; gap: 0.6rem; font-size: 0.95rem; line-height: 1.5; }
html .box > h2 + ul.plain-list > li { position: relative; padding-left: 1.95rem; }
html .box > h2 + ul.plain-list > li::before {
  content: ""; position: absolute; left: 0; top: 0.1em; width: 1.3rem; height: 1.3rem; border-radius: 50%;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2314213d' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m5 12.5 4.5 4.5L19 7.5'/%3E%3C/svg%3E") center / 0.72rem no-repeat, var(--lg-cap-image);
  background-color: var(--lg-cap); box-shadow: var(--lg-cap-shadow);
}
/* Lomas: a title with a caption under it, hairlines between */
html .role-list { list-style: none; margin: 0.3rem 0 0; padding: 0; display: grid; }
html .role-list li { display: grid; gap: 0.15rem; padding: 0.7rem 0; }
html .role-list li:first-child { padding-top: 0.2rem; }
html .role-list li + li { border-top: 1px solid var(--line); }
html .role-list b { font-weight: 600; color: var(--ink); }
html .role-list span { color: var(--muted); font-size: 0.92rem; line-height: 1.45; }
/* Iestatīšana: the steps as hairline rows in one card; the step to do now has the navy number */
html .setup-group .setup-list { gap: 0; }
html .setup-group .setup-step { padding: 0.75rem 0; border-radius: 0; background: transparent; box-shadow: none; }
html .setup-group .setup-step:first-child { padding-top: 0.2rem; }
html .setup-group .setup-step:last-child { padding-bottom: 0; }
html .setup-group .setup-step + .setup-step { border-top: 1px solid var(--line); }
html .setup-step:not(.done) .tick { border: 0; color: var(--accent); background: var(--lg-lens); box-shadow: var(--lg-lens-shadow), 0 0 0 1px rgba(20, 33, 61, 0.14); }
html .setup-step.now:not(.done) .tick { color: #fff; background-color: var(--lg-navy); background-image: var(--lg-navy-image); box-shadow: var(--lg-navy-shadow); }
html .step-phases li i {
  height: 0.5rem; margin-bottom: 0.4rem;
  background: linear-gradient(90deg, var(--accent) var(--fill), transparent var(--fill)), var(--lg-track); box-shadow: var(--lg-track-shadow);
}
html .step-phases li.done i { background: #34c759 linear-gradient(180deg, rgba(255, 255, 255, 0.4), rgba(255, 255, 255, 0) 60%); box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.5), 0 1px 2px rgba(0, 60, 20, 0.2); }
html .step-phases li.done b { color: #1a7f37; }
html .set-main > .step-phases { gap: 0.6rem; margin: 1rem 0 1.1rem; }
html .set-main > .setup-group + p.muted { margin-top: 1.1rem; }
/* Funkcijas: each group one glass panel with hairlines (Apple's Settings) */
html .set-main > .core-note { max-width: 46rem; }
html .feature-list { gap: 0; border-radius: var(--radius); background: var(--glass); box-shadow: var(--glass-hi), var(--shadow); }
html .feature-list > .feature-card, html .feature-list > .feature-card:hover { border-radius: 0; background: transparent; box-shadow: none; transform: none; }
html .feature-list > .feature-card:first-child { border-radius: var(--radius) var(--radius) 0 0; }
html .feature-list > .feature-card:last-child { border-radius: 0 0 var(--radius) var(--radius); }
html .feature-list > .feature-card:only-child { border-radius: var(--radius); }
html .feature-list > .feature-card + .feature-card { border-top: 1px solid var(--line); }
html .feature-list > a.feature-card:focus-visible { outline: 2.5px solid var(--accent); outline-offset: -3px; }
/* Komanda: labels like every form label, the pickers in an even grid */
html .box > h2 + .team-row { border-top: 0; padding-top: 0.2rem; }
html .team-row form.inline { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0.7rem; align-items: end; }
html .team-row form.inline > label { display: grid; gap: 0.3rem; min-width: 0; font-size: 0.88rem; font-weight: 500; color: var(--ink); }
html .team-row form.inline > label select { width: 100%; min-width: 0; }
html .team-row form.inline > label:nth-of-type(3) { grid-column: 1 / -1; }
html .team-row form.inline > .btn { justify-self: start; min-height: 2.5rem; padding: 0 1.2rem; }

/* ---------- R15. Tables: quiet sentence-case headers, money in tabular figures ---------- */
html .table th { text-transform: none; letter-spacing: -0.005em; font-size: 0.8rem; font-weight: 600; color: #5d5e64; }
html :is(.pay-table, .inv-table, .clients-table) td { font-variant-numeric: tabular-nums; }
@media (min-width: 861px) {
  html .pay-table :is(th, td):is(:nth-child(3), :nth-child(4), :nth-child(5)),
  html .inv-table :is(th, td):nth-child(n+6),
  html .clients-table :is(th, td):is(:nth-child(3), :nth-child(5)) { text-align: right; white-space: nowrap; }
}
html .codes-table td, html .rule-table td { vertical-align: middle; }
html .rule-table td[data-label] { white-space: nowrap; }
html .rule-table td:last-child { text-align: right; }
html .pf-table .actions { flex-wrap: wrap; justify-content: flex-end; gap: 0.35rem; }
html .pf-table td:last-child { width: 1%; min-width: 6.5rem; }
html .vs-grid .box .table { background: transparent; box-shadow: none; border-radius: 0; -webkit-backdrop-filter: none; backdrop-filter: none; }
html .vs-grid .box th { background: transparent; }

/* ---------- R16. Money and clients ---------- */
html .rv-chips .chip span {
  display: inline-grid; place-items: center; min-width: 1.35rem; height: 1.25rem; margin-left: 0.35rem; padding: 0 0.35rem; border-radius: 999px;
  font-size: 0.75rem; font-weight: 600; color: #46474d; background: rgba(20, 33, 61, 0.08); font-variant-numeric: tabular-nums;
}
html .rv-chips .chip.on span { color: #fff; background: rgba(255, 255, 255, 0.2); }
html .orders-find:has(> .page-tabs:only-child) { padding: 0; background: none; box-shadow: none; border-radius: 0; }
html form.orders-find:has(> select:only-child) { display: flex; padding: 0; background: none; box-shadow: none; border-radius: 0; }
html form.orders-find > select:only-child { min-width: 13rem; }
html .head + .tabs-row { margin-top: 0.75rem; }
html .log-retry { margin: 0.8rem 0 0 0.2rem; }
html .invoice-frame { overflow: hidden; border-radius: var(--radius); background: var(--glass); box-shadow: var(--glass-hi), var(--shadow); }
html .invoice-frame iframe { display: block; width: 100%; }
html .head + .split { margin-top: 1rem; }
html .set-main .example { padding: 0.7rem 0.95rem; border-radius: 14px; background: rgba(255, 255, 255, 0.55); box-shadow: inset 0 0 0 1px rgba(20, 33, 61, 0.08), inset 0 1px 0 #fff; }
html .set-main .example b { font-size: 1.05rem; color: var(--accent); font-variant-numeric: tabular-nums; white-space: nowrap; }

/* ---------- R17. Katalogs and the item page ---------- */
html .shelf-extras .badge.new { color: var(--accent); background: rgba(20, 33, 61, 0.08); box-shadow: inset 0 0 0 1px rgba(20, 33, 61, 0.14); }
html .shelf-extras:has(.badge.new) .small-note { display: none; }
html .shelf-now { color: var(--ink); }
/* The 14 days: free green, taken navy (as in Kalendārs), out of use hatched, today a navy ring; its key matches */
html .shelf-strip span { height: 1.7rem; font-size: 0.66rem; border-radius: 0.45rem; background: rgba(229, 246, 233, 0.9); color: #136c2c; }
html .shelf-strip span.busy { background: rgba(20, 33, 61, 0.13); color: var(--accent); }
html .shelf-strip span.part { background: linear-gradient(180deg, rgba(229, 246, 233, 0.9) 50%, rgba(20, 33, 61, 0.13) 50%); color: var(--accent); }
html .shelf-strip span.blocked { background: repeating-linear-gradient(135deg, rgba(20, 33, 61, 0.03) 0 6px, rgba(20, 33, 61, 0.075) 6px 12px); color: #55565c; }
html .shelf-strip span.today { box-shadow: inset 0 0 0 2px var(--accent); font-weight: 700; }
html .legend.shelf-key { margin: -0.2rem 0 0.9rem; }
html .shelf-key .sw.free { background: rgba(229, 246, 233, 0.9); box-shadow: inset 0 0 0 1px rgba(26, 127, 55, 0.4); }
html .shelf-key .sw.busy { background: rgba(20, 33, 61, 0.13); box-shadow: inset 0 0 0 1px rgba(20, 33, 61, 0.3); }
html .shelf-key .sw.today { border-radius: 0.28rem; background: #fff; box-shadow: inset 0 0 0 2px var(--accent); }
/* No picture yet: a soft tile, the letter in a glass disc, "+ Pievienot bildi" a small capsule */
html .shelf-pic .ph { gap: 0.6rem; background: radial-gradient(120% 90% at 50% 0%, #fbfcfe 0%, #eef1f7 62%, #e7ebf3 100%); }
html .shelf-pic .ph b {
  display: grid; place-items: center; width: 3.5rem; height: 3.5rem; border-radius: 50%; font-size: 1.5rem; line-height: 1; color: var(--accent);
  background-color: var(--lg-cap); background-image: var(--lg-cap-image); box-shadow: var(--lg-cap-shadow);
}
html .shelf-pic .ph span { padding: 0.28rem 0.75rem; border-radius: 999px; font-size: 0.78rem; font-weight: 600; color: var(--accent); background: rgba(255, 255, 255, 0.78); box-shadow: inset 0 0 0 1px rgba(20, 33, 61, 0.12); }
html .shelf-pic .ph span::before { content: "+ "; }
@media (min-width: 761px) {
  html .shelf-card .actions:has(> :nth-child(4)) { display: grid; grid-template-columns: 1fr 1fr; gap: 0.4rem; }
  html .shelf-card .actions:has(> :nth-child(4)) > .btn { justify-content: center; margin: 0; }
}
html .shelf + details.box, html .shelf + .box { margin-top: 1.2rem; }
/* Parametri vietnē: even columns */
html .spec-row { grid-template-columns: minmax(0, 1fr) 9rem 6.3rem; }
html .spec-row.new input { border-style: solid; }
html .item-editor .box :is(.pair, .sc-group, .chip-checks) + :is(.field, .sc-group, details) { margin-top: 0.95rem; }
html .item-editor details.fold > p.muted + .field { margin-top: 0.7rem; }
html .len-row > span.len-name { padding-left: 3.3rem; }
/* Bildes, Video: a soft recessed tile with a navy glass "+" (a new item: the same tile, waiting) */
html .photo-drop {
  border: 0; border-radius: 16px; color: var(--accent); background: rgba(20, 33, 61, 0.035);
  box-shadow: inset 0 0 0 1.5px rgba(20, 33, 61, 0.12); transition: background-color 0.25s var(--ease), box-shadow 0.25s var(--ease);
}
html .photo-drop:focus-within { outline: 2.5px solid var(--accent); outline-offset: 3px; }
html .photo-drop-plus {
  display: grid; place-items: center; width: 2.5rem; height: 2.5rem; margin-bottom: 0.4rem; border-radius: 50%;
  font-size: 1.4rem; font-weight: 400; line-height: 1; color: #fff;
  background-color: var(--lg-navy); background-image: var(--lg-navy-image); box-shadow: var(--lg-navy-shadow);
}
html .photo-drop .muted { color: #5d5e64; }
html .photo-drop.is-off, html .photo-drop.is-off:hover { cursor: default; background: rgba(20, 33, 61, 0.035); box-shadow: inset 0 0 0 1.5px rgba(20, 33, 61, 0.12); }
html .photo-drop.is-off .photo-drop-plus { color: #55565c; background: rgba(20, 33, 61, 0.1); box-shadow: inset 0 0 0 1px rgba(20, 33, 61, 0.12); }
html .photo-drop.is-off b { color: #3c3d44; }
/* Sezonas cenas, Atlaides: white rule cards, fields on one line, glass day pills */
html .rule-card { border-radius: 16px; background: #fff; box-shadow: 0 0 0 1px rgba(20, 33, 61, 0.08), 0 6px 16px -10px rgba(20, 33, 61, 0.25); }
html .rule-line { align-items: end; }
html .rule-line .mini-field :is(input, select) { height: 2.5rem; min-height: 2.5rem; }
html .rule-line .mini-field > select { min-width: 8.6rem; }
html .day-pill span {
  min-width: 2.3rem; height: 2.3rem; background-color: var(--lg-cap); background-image: var(--lg-cap-image);
  box-shadow: inset 0 1px 0 #fff, 0 0 0 1px rgba(20, 33, 61, 0.3); transition: background-color 0.2s var(--ease), box-shadow 0.2s var(--ease);
}
html .day-pill input:checked + span { color: #fff; background-color: var(--lg-navy); background-image: var(--lg-navy-image); box-shadow: var(--lg-navy-shadow); }
html .day-pill input:focus-visible + span { outline: 2.5px solid var(--accent); outline-offset: 2px; }
/* The save bar: a floating glass capsule, a navy ring while something is unsaved, above the phone tab bar */
html .savebar {
  border-radius: 999px; padding: 0.45rem 0.45rem 0.45rem 1.2rem;
  background: rgba(255, 255, 255, 0.8); -webkit-backdrop-filter: var(--glass-blur); backdrop-filter: var(--glass-blur);
  box-shadow: var(--lg-rim), 0 0 0 1px rgba(20, 33, 61, 0.07), 0 12px 32px -8px rgba(20, 33, 61, 0.22);
}
html .savebar .when-dirty { color: var(--accent); font-weight: 600; }
html :is(.item-editor, .web-form, #price-list).dirty .savebar { box-shadow: var(--lg-rim), 0 0 0 1.5px var(--accent), 0 12px 32px -8px rgba(20, 33, 61, 0.3); }

/* ---------- R18. Settings pages ---------- */
/* Uzņēmuma dati: Darba laiks one recessed panel, hairlines between days */
html .hours-grid { gap: 0; padding: 0.2rem 0.9rem; border-radius: 16px; background: rgba(255, 255, 255, 0.5); box-shadow: inset 0 0 0 1px rgba(20, 33, 61, 0.08); }
html .hours-row { grid-template-columns: 7rem 6.2rem auto 6.2rem; padding: 0.45rem 0; }
html .hours-row + .hours-row { border-top: 1px solid var(--line); }
html .hours-row input { min-height: 2.4rem; text-align: center; font-weight: 600; font-variant-numeric: tabular-nums; }
html .hours-row input::placeholder { color: #6e6e73; font-weight: 400; }
@supports (field-sizing: content) {
  html .fields textarea#social { resize: none; field-sizing: content; min-height: 5.5rem; max-height: 16rem; }
}
html .set-main .box > p.small-note + p:has(> .btn) { margin-top: 0.95rem; }
/* Ziņas klientiem: the message page's switches and its reset card */
html .check.switch-row { display: inline-flex; align-items: center; gap: 0.65rem; min-height: 2.5rem; padding-left: 0; }
html .row-checks > .check.switch-row > input.switch, html .check.switch-row > input.switch { position: relative; left: auto; top: auto; transform: none; }
html .reset-box { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 0.6rem 1rem; }
html .reset-box > p, html .reset-box > form { margin: 0; }
html .sms-keys { margin-top: 0.55rem; }
/* E-pasts: the test row under its heading */
html .set-main form.test-row { display: flex; flex-wrap: wrap; align-items: center; gap: 0.4rem 0.75rem; margin: 0 0 0.8rem; }
html .set-main form.test-row > .small-note { overflow-wrap: anywhere; min-width: 0; }
/* Piegādes cenas: one glass sheet of codes, recessed number fields, a glass special card */
html .code-list { border-radius: 16px; background: rgba(255, 255, 255, 0.55); box-shadow: inset 0 0 0 1px rgba(20, 33, 61, 0.08), inset 0 1px 0 #fff; }
html .code-row { background: transparent; border-top-color: rgba(20, 33, 61, 0.06); }
html .code-row.has-price { background: rgba(255, 255, 255, 0.5); }
html .special-card { border-radius: 18px; background-color: var(--lg-cap); background-image: var(--lg-cap-image); box-shadow: var(--lg-cap-shadow); }
html .fill-row { border-radius: 16px; background: rgba(255, 255, 255, 0.5); box-shadow: inset 0 0 0 1px rgba(20, 33, 61, 0.08); }
html :is(.unit-input, .unit-field) {
  border-radius: 12px; background-color: rgba(255, 255, 255, 0.72);
  box-shadow: inset 0 1px 2px rgba(20, 33, 61, 0.08), inset 0 0 0 1px rgba(20, 33, 61, 0.12), 0 1px 0 rgba(255, 255, 255, 0.9);
}
html :is(.unit-input, .unit-field):focus-within { background-color: #fff; box-shadow: inset 0 0 0 1px var(--accent), 0 0 0 4px rgba(20, 33, 61, 0.14); }
html :is(.unit-input, .unit-field) input:focus { background-color: transparent; }
html .code-row.bad .unit-field { box-shadow: inset 0 0 0 1.5px var(--danger); }
/* Savs domēns: glass cards, DNS values select at a tap, a free name a green chip */
html .domain-card { border-radius: 18px; background: rgba(255, 255, 255, 0.55); box-shadow: inset 0 1px 0 #fff, 0 0 0 1px rgba(20, 33, 61, 0.09), 0 8px 22px -12px rgba(20, 33, 61, 0.25); }
html .dns td { border-top-color: rgba(20, 33, 61, 0.07); word-break: normal; overflow-wrap: anywhere; }
html .dns code { padding: 0.1rem 0.45rem; border-radius: 8px; background: rgba(20, 33, 61, 0.06); }
html .dns code.copy { -webkit-user-select: all; user-select: all; cursor: text; }
html p.ok-line { display: inline-flex; align-items: center; gap: 0.4rem; padding: 0.35rem 0.85rem; border-radius: 999px; color: #137333; background: rgba(229, 246, 233, 0.9); box-shadow: inset 0 0 0 1px rgba(26, 127, 55, 0.25); }
html p.ok-line::before { content: ""; width: 0.45rem; height: 0.45rem; border-radius: 50%; background: currentColor; }
/* Maksājumi tiešsaistē: providers as glass cards; "Drīzumā" quiet but readable */
html .pv-card { background: var(--glass); box-shadow: var(--glass-hi), var(--shadow); transition: box-shadow 0.3s var(--ease), transform 0.3s var(--ease), background 0.3s var(--ease); }
html a.pv-card:focus-visible { outline: 2.5px solid var(--accent); outline-offset: 3px; }
html .pv-card.later { opacity: 1; color: #55565c; background: rgba(255, 255, 255, 0.35); box-shadow: inset 0 0 0 1px rgba(20, 33, 61, 0.1); }
html .pv-card.later b { color: #3c3d44; }
html .pv-card.later .g-logo { filter: grayscale(1); opacity: 0.75; }

/* ---------- R19. Social pages (look only) ---------- */
html #fb-post-form .box.fields > div > .chips { flex-wrap: wrap !important; overflow: visible !important; -webkit-mask-image: none; mask-image: none; }
html .fb-schedule { align-items: end; }
html .fb-schedule > * { margin-bottom: 0; }
html .fb-schedule .btn { min-height: 2.7rem; }
html .ch-mark {
  display: inline-grid; place-items: center; height: 1.15rem; min-width: 1.5rem; padding: 0 0.3rem; margin-right: 0.4rem;
  font-size: 0.64rem; line-height: 1; vertical-align: middle; border-radius: 0.4rem;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.35), 0 1px 2px rgba(20, 33, 61, 0.2);
}
html :is(.fb-head-page, .ch-targets) .ch-mark { margin-right: 0; }
html .ch-mark.ig { background: linear-gradient(45deg, #d62976, #962fbf 60%, #4f5bd5); }
html .ch-mark.tt { box-shadow: inset 2px 0 0 #25f4ee, inset -2px 0 0 #fe2c55, 0 1px 2px rgba(20, 33, 61, 0.2); }
html .fb-heads { gap: 0.45rem; }
html .fb-head-page {
  gap: 0.45rem; padding: 0.22rem 0.8rem 0.22rem 0.22rem; border-radius: 999px; color: var(--ink); font-size: 0.86rem; white-space: nowrap;
  background-color: var(--lg-cap); background-image: var(--lg-cap-image); box-shadow: var(--lg-cap-shadow);
}
html .fb-head-page :is(.g-avatar, .fb-page-pic) { width: 1.7rem; height: 1.7rem; font-size: 0.78rem; }
html .fb-list .chips {
  flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; padding: 2px 3px 6px; margin: 0 -3px;
  -webkit-mask-image: linear-gradient(90deg, #000 calc(100% - 1.6rem), transparent); mask-image: linear-gradient(90deg, #000 calc(100% - 1.6rem), transparent);
}
html .fb-list .chips::-webkit-scrollbar { display: none; }
html .fb-list .chips > .chip { flex: none; }
html .fb-list .chips > :focus-visible { outline-offset: -3px; }
html .fb-chat.box { padding: 0; }
html .fb-messages { background: rgba(20, 33, 61, 0.025); }
html .fb-reply { background: transparent; }
html :is(.fb-chat-head, .fb-reply) { border-color: rgba(20, 33, 61, 0.07); }
html .fb-chat-head .btn { gap: 0.25em; flex: none; }

/* ---------- R20. Platforma, Apmeklējumi ---------- */
html .stats.pf-stats { margin-bottom: 1rem; }
html .pf-tools > .chips.tabs-row { margin: 0; }
html .vs-devices div { display: grid; grid-template-columns: auto minmax(0, 1fr); column-gap: 0.45rem; align-items: center; }
html .vs-devices div > b { grid-column: 1 / -1; grid-row: 1; }
html .vs-devices div > .vs-dot { grid-column: 1; grid-row: 2; margin: 0; }
html .vs-devices div > .muted { grid-column: 2; grid-row: 2; }
html td > .vs-dot { vertical-align: 0.05em; margin: 0 0.3rem 0 0; }
html .vs-extras { gap: 0.45rem; margin: 0.8rem 0 1rem; font-size: 0.84rem; }
html .vs-extras > span {
  padding: 0.3rem 0.8rem; border-radius: 999px; white-space: nowrap;
  background-color: var(--lg-cap); background-image: var(--lg-cap-image); box-shadow: var(--lg-cap-shadow);
}

/* ---------- R21. Wider than a phone, narrower than a desktop ---------- */
@media (max-width: 1180px) {
  html .ed-main .sc-side .sc-parts {
    padding-right: 1.6rem;
    -webkit-mask-image: linear-gradient(90deg, #000 calc(100% - 1.6rem), transparent); mask-image: linear-gradient(90deg, #000 calc(100% - 1.6rem), transparent);
  }
}
@media (max-width: 1100px) {
  /* The item page: Redzama first */
  html .item-editor > .item-side { display: contents; }
  html .item-editor > .item-side > section.box:first-child { order: -1; }
}

/* ---------- R22. A phone ---------- */
@media (max-width: 860px) {
  html .shell:has(.tabbar) .savebar { bottom: calc(5.5rem + env(safe-area-inset-bottom, 0px)); }
  /* Maksājumi: each order a glass card (no box in a box) */
  html .board:has(> .pay-table) { padding: 0; background: none; box-shadow: none; }
  html .board:has(> .pay-table) > p.muted { margin: 0 0 0.5rem 0.2rem; font-size: 0.85rem; }
  html .pay-table tr { background: var(--glass); box-shadow: var(--glass-hi), var(--lg-depth); border-radius: var(--radius-s); padding: 0.85rem 0.95rem; }
  html .pay-table td:is(:nth-child(3), :nth-child(4), :nth-child(5))::before { text-transform: none; letter-spacing: 0; font-size: 0.75rem; color: #5d5e64; }
  /* Lists as glass cards: Atlaižu kodi, Ziņas klientiem, Ieraksti, Uzņēmumi */
  html :is(.codes-table, .rule-table, .table:has(a.ref[href^="/facebook/posts/"]), .table:has(> .pf-table)) { overflow: visible; background: none; box-shadow: none; }
  html :is(.codes-table, .rule-table, .table:has(a.ref[href^="/facebook/posts/"])) thead, html .pf-table thead { display: none; }
  html :is(.codes-table, .rule-table, .table:has(a.ref[href^="/facebook/posts/"])) :is(table, tbody), html :is(.pf-table, .pf-table tbody) { display: block; }
  html :is(.codes-table, .rule-table, .table:has(a.ref[href^="/facebook/posts/"])) tr, html .pf-table tr {
    margin-bottom: 0.55rem; padding: 0.85rem 0.95rem; border-radius: var(--radius-s); background: var(--glass); box-shadow: var(--glass-hi), var(--lg-depth);
  }
  html :is(.codes-table, .rule-table, .table:has(a.ref[href^="/facebook/posts/"])) td, html .pf-table td { min-width: 0; padding: 0; border: 0; background: transparent !important; }
  /* Atlaižu kodi: code and state, the discount, when and used, Izslēgt */
  html .codes-table tr { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); grid-template-areas: "code state" "off off" "when used" "act act"; gap: 0.45rem 0.8rem; }
  html .codes-table td { font-size: 0.9rem; }
  html .codes-table td:nth-child(1) { grid-area: code; }
  html .codes-table td:nth-child(2) { grid-area: off; }
  html .codes-table td:nth-child(3) { grid-area: when; }
  html .codes-table td:nth-child(4) { grid-area: used; }
  html .codes-table td:nth-child(5) { grid-area: state; justify-self: end; align-self: start; }
  html .codes-table td.row-actions { grid-area: act; text-align: left; }
  html :is(.codes-table td.row-actions, .rule-table td:last-child) .btn { min-height: 2.75rem; padding: 0 1.1rem; }
  /* Ziņas klientiem: name and Teksts on top, the E-pasts and SMS switches below */
  html .rule-table tr { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) auto; grid-template-areas: "what what text" "mail sms sms"; align-items: center; gap: 0.7rem 0.9rem; }
  html .rule-table td { display: flex; flex-wrap: wrap; align-items: center; gap: 0.3rem 0.5rem; white-space: normal; text-align: left; }
  html .rule-table td:nth-child(1) { display: block; grid-area: what; }
  html .rule-table td:nth-child(2) { grid-area: mail; }
  html .rule-table td:nth-child(3) { grid-area: sms; }
  html .rule-table td:nth-child(4) { grid-area: text; align-self: start; }
  html .rule-table td[data-label]::before { content: attr(data-label); font-size: 0.86rem; font-weight: 600; color: #4a4b51; }
  /* Ieraksti: title, then status and time, then where */
  html .table:has(a.ref[href^="/facebook/posts/"]) tr { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 0.35rem 0.6rem; align-items: center; }
  html .table:has(a.ref[href^="/facebook/posts/"]) td:is(:first-child, :nth-child(4)) { grid-column: 1 / -1; }
  html .table:has(a.ref[href^="/facebook/posts/"]) td:is(:nth-child(3), :nth-child(4)) { font-size: 0.86rem; color: #58585e; }
  /* Uzņēmumi: the numbers say what they are */
  html .pf-table td { display: block; width: auto; text-align: left; }
  html .pf-table tr { display: grid; gap: 0.2rem; }
  html .pf-table td:last-child { width: auto; min-width: 0; }
  html .pf-table td:nth-child(2)::before { content: "Reģistrējās: "; color: #58585e; }
  html .pf-table td:nth-child(5)::before { content: "Noteikumi: "; color: #58585e; }
  html .pf-table td:nth-child(7)::before { content: "Apmeklētāji 30 d.: "; color: #58585e; }
  html .pf-table td:nth-child(8):not(:last-child)::before { content: "Maksa mēnesī: "; color: #58585e; }
  html .pf-table td:last-child .actions { justify-content: flex-start; margin-top: 0.45rem; }
  /* Sarunas: ← a round glass bead (its words stay for screen readers) */
  html .fb-chat-head { gap: 0.5rem; padding: 0.6rem 0.75rem; }
  html .fb-chat-head .g-avatar { width: 2rem; height: 2rem; font-size: 0.9rem; }
  html .fb-back {
    display: inline-grid; place-items: center; flex: none; width: 2.75rem; height: 2.75rem; border-radius: 50%; font-size: 0; text-decoration: none;
    background-color: var(--lg-cap); background-image: var(--lg-cap-image); box-shadow: var(--lg-cap-shadow);
    transition: transform 0.4s var(--lg-spring), box-shadow 0.3s var(--ease);
  }
  html .fb-back::before { content: "←"; font-size: 1.1rem; line-height: 1; color: var(--ink); }
  html .fb-back:active { transform: scale(0.94); transition-duration: 0.12s; box-shadow: var(--lg-cap-shadow-press); }
  html .fb-back:focus-visible { outline: 2.5px solid var(--accent); outline-offset: 3px; }
}
@media (max-width: 760px) {
  /* Every small button and capsule a finger's height */
  html .set-main .btn.small { min-height: 2.75rem; padding: 0 1rem; font-size: 0.9rem; }
  html a.back:not(.ed-head *), html .g-chev, html :is(.setup-step .actions, .first-steps, .step-guide) :is(a, button).linkish, html .team-row form.inline > .btn { min-height: 2.75rem; }
  html input[type="file"]:not([hidden], .photo-drop input, .pic-upload input, .sc-photo input) { width: 100%; }
  html .g-reviews .g-section-head > .actions { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0.45rem; width: 100%; }
  html .g-reviews .g-section-head > .actions > .btn { justify-content: center; white-space: normal; text-align: center; line-height: 1.2; }
  /* The accounts beside the title: one row that scrolls, fading at its edge */
  html .fb-heads {
    display: flex; flex-wrap: nowrap; max-width: 100%; overflow-x: auto; scrollbar-width: none; padding: 2px 3px 6px; margin: 0 -3px;
    -webkit-mask-image: linear-gradient(90deg, #000 calc(100% - 1.6rem), transparent); mask-image: linear-gradient(90deg, #000 calc(100% - 1.6rem), transparent);
  }
  html .fb-heads::-webkit-scrollbar { display: none; }
  html .fb-head-page { flex: none; }
  /* Site editor: the publish bar's buttons wrap, Publicēt on its own row; the auto-save note above the switch */
  html .ed-top .sc-publish .sc-actions { flex-wrap: wrap; gap: 0.45rem; }
  html .ed-top .sc-publish .sc-actions > * { flex: 1 1 auto; margin: 0; }
  html .ed-top .sc-publish .sc-actions > [data-publish] { flex-basis: 100%; }
  html .ed-top .sc-publish .sc-actions > form .btn, html .ed-top .sc-publish .sc-actions > a.btn { width: 100%; justify-content: center; }
  html .ed-top .sc-publish [data-public] { margin-right: 0; }
  html .ed-main .sc-form .sc-save { bottom: calc(4.2rem + env(safe-area-inset-bottom, 0px)); justify-content: center; background: none; padding: 0.3rem 0; }
  html .ed-main .sc-form .sc-save .sc-auto-note {
    margin: 0; padding: 0.3rem 0.8rem; border-radius: 999px; color: #55565c;
    background-color: var(--lg-cap); background-image: var(--lg-cap-image); box-shadow: var(--lg-cap-shadow);
  }
  html .ed-top .ed-head .sc-actions {
    padding-right: 1.6rem;
    -webkit-mask-image: linear-gradient(90deg, #000 calc(100% - 1.6rem), transparent); mask-image: linear-gradient(90deg, #000 calc(100% - 1.6rem), transparent);
  }
  html .shelf-pic:has(> .ph) { aspect-ratio: 16 / 7; }
}
@media (max-width: 640px) {
  /* Three sums as one short list (label left, amount right) */
  html .client-tiles { grid-template-columns: minmax(0, 1fr); gap: 0; padding: 0.15rem 0; border-radius: var(--radius); background: var(--glass); box-shadow: var(--glass-hi), var(--shadow); }
  html .client-tiles > .stat {
    display: flex; align-items: baseline; justify-content: space-between; gap: 0.75rem; min-width: 0;
    margin: 0 1rem; padding: 0.7rem 0; border: 0; border-radius: 0; background: transparent; box-shadow: none;
    -webkit-backdrop-filter: none; backdrop-filter: none;
  }
  html .client-tiles > .stat + .stat { border-top: 1px solid rgba(20, 33, 61, 0.08); }
  html .client-tiles > .stat > .muted { font-size: 0.92rem; color: #55565c; }
  html .client-tiles > .stat > b.amount { margin: 0; font-size: 1.05rem; white-space: nowrap; }
  /* The client card's buttons: an even grid (an odd first one takes the whole row) */
  html .head:has(+ .client-tiles) > .actions { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0.45rem; width: 100%; }
  html .head:has(+ .client-tiles) > .actions > .btn { justify-content: center; text-align: center; min-width: 0; padding-inline: 0.8rem; }
  html .head:has(+ .client-tiles) > .actions > .btn:first-child:nth-last-child(odd) { grid-column: 1 / -1; }
  /* Each Iezīme: icon + title, its text under them */
  html .item-editor .feature-row { grid-template-columns: 8.5rem minmax(0, 1fr); padding-top: 0.6rem; border-top: 1px solid rgba(20, 33, 61, 0.07); }
  html .item-editor .feature-row > :nth-child(3) { grid-column: 1 / -1; }
  /* Attālums no bāzes: each ring a small card */
  html .ring-table { overflow: visible; }
  html .ring-table thead { display: none; }
  html .ring-table :is(table, tbody) { display: block; }
  html .ring-table tr { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 0.45rem; margin-bottom: 0.5rem; padding: 0.6rem; border-radius: 16px; background: rgba(255, 255, 255, 0.55); box-shadow: inset 0 0 0 1px rgba(20, 33, 61, 0.08); }
  html .ring-table td { display: block; padding: 0; border: 0; min-width: 0; }
  html .ring-table td:last-child { grid-column: 1 / -1; }
  html .ring-table td > input { width: 100%; }
  html .ring-table .unit-field { display: flex; width: 100%; }
  html .ring-table .unit-field input { flex: 1 1 auto; width: 100%; }
  /* Iestatīšana: the phase names stay readable */
  html .step-phases b { font-size: 0.78rem; letter-spacing: -0.01em; }
}
@media (max-width: 560px) {
  html :is(.set-main form.fields, form.box.narrow.fields) > button.btn:not(.small):not(.wide), html .logo-form > .btn { justify-self: stretch; width: 100%; justify-content: center; }
  html .set-main > .head:has(> form.inline) { flex-direction: column; align-items: flex-start; gap: 0.55rem; }
  html .set-main > .head > form.inline .btn { min-height: 2.75rem; font-size: 0.9rem; }
  html .team-row form.inline { grid-template-columns: minmax(0, 1fr); }
  html .team-row form.inline > label:nth-of-type(3) { grid-column: auto; }
  html .team-row form.inline > .btn { justify-self: stretch; }
  html .set-main .box > p.actions { display: grid; grid-template-columns: minmax(0, 1fr); gap: 0.5rem; }
  html .set-main .box > p.actions .btn { justify-content: center; }
  html .plan-box > .btn { flex: 1 1 100%; justify-content: center; }
  html .hours-grid { padding: 0.15rem 0.7rem; }
  html .hours-row { grid-template-columns: 5.4rem minmax(0, 1fr) auto minmax(0, 1fr); justify-content: stretch; gap: 0.35rem; }
  html .box.site-gap { padding-left: 1rem; }
  html .box.site-gap::before { left: 1rem; top: 1.05rem; }
  html .site-gap h2 { padding-left: 1.75rem; }
  html .spec-row { grid-template-columns: minmax(0, 1fr) auto; padding-top: 0.55rem; border-top: 1px solid rgba(20, 33, 61, 0.07); }
  html .spec-row > input:not([type="hidden"]) { grid-column: 1 / -1; }
  html .rule-line { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
  html .rule-line .mini-field { min-width: 0; }
  html .rule-line .mini-field.grow { grid-column: 1 / -1; }
  html .rule-line .mini-field > :is(input, select) { width: 100%; min-width: 0; }
  html .rule-line .mini-field .amount-pair { min-width: 0; }
  html .rule-line .mini-field .amount-pair input { flex: 1 1 0; width: 0; min-width: 0; }
  html .rule-line .mini-field .amount-pair select { flex: none; width: 4.4rem; }
  html .rule-card .link-btn { grid-column: -2; justify-self: end; margin-left: 0; }
  html .rule-days > .muted { flex-basis: 100%; }
  html .sms-keys { margin-left: 0; }
  html .note-acts { display: flex; margin-left: 0; }
  html .plan-note > .btn { margin-left: 0; }
  html details.box > summary { flex-wrap: wrap; }
  html details.box > summary > .muted { order: 3; flex-basis: 100%; }
  /* Savs domēns: DNS records as labelled rows */
  html .dns thead { display: none; }
  html :is(.dns, .dns tbody, .dns tr, .dns td) { display: block; width: auto; }
  html .dns tr { margin-top: 0.5rem; padding: 0.65rem 0.75rem; border-radius: 14px; background: rgba(255, 255, 255, 0.6); box-shadow: inset 0 0 0 1px rgba(20, 33, 61, 0.08); }
  html .dns td { padding: 0.15rem 0; border: 0; }
  html .dns td[data-label]::before { content: attr(data-label); display: block; margin-top: 0.25rem; font-size: 0.75rem; font-weight: 600; color: #5d5e64; }
  html .dns td:first-child b { display: inline-block; padding: 0.1rem 0.6rem; border-radius: 999px; font-size: 0.75rem; color: #fff; background-color: var(--lg-navy); background-image: var(--lg-navy-image); }
}

/* ---------- Mouse only: the same lift and light as the other glass ---------- */
@media (hover: hover) and (pointer: fine) {
  html :is(.rv-contact a, .rv-empty a, .site-place a, .site-gap-list a, .shelf-next a, .shelf-now a, .lead a, .set-main > p.muted a,
    .set-main :is(p, li, dd, legend, label, span) > a):not(.btn, .ref, .chip, .back, .pv-card):hover,
  html :is(.table a.contact-link, .pf-dl dd > a):is([href^="tel:"], [href^="mailto:"]):hover {
    background-color: rgba(255, 255, 255, 0.96); box-shadow: inset 0 1px 0 #fff, 0 0 0 1px rgba(20, 33, 61, 0.15), 0 3px 10px -2px rgba(20, 33, 61, 0.2); }
  html td > a.ref[href^="/facebook/posts/"]:hover { text-decoration: underline; text-underline-offset: 0.18em; }
  html :is(details.inner, details.fold-inline, .fields > details.g-fold:not(.w-more), details.vs-table, details.ed-more, details.sc-tokens) > summary:hover,
  html a.rv-gsum:hover .g-chev, html a.offer-chip:hover {
    transform: translateY(-1px); background-color: rgba(255, 255, 255, 0.86); box-shadow: var(--lg-cap-shadow-hi); }
  html details.box:is(.fold, .tool):hover > summary::after { background-color: rgba(255, 255, 255, 0.92); box-shadow: var(--lg-cap-shadow-hi); }
  html :is(.g-fold > summary:hover .g-chev, .w-folder > summary:hover .w-link),
  html input[type="file"]:not([hidden], .photo-drop input, .pic-upload input, .sc-photo input)::file-selector-button:hover,
  html .pf-inbox a:hover { background-color: rgba(255, 255, 255, 0.86); box-shadow: var(--lg-cap-shadow-hi); }
  html input[type="file"]:not([hidden], .photo-drop input, .pic-upload input, .sc-photo input):hover,
  html :is(.shelf-search, .pf-tools .pf-search) input:not([type="hidden"]):hover { background-color: #fff; }
  html :is(.choice-card, .pay-card):not(:has(input:checked)):hover,
  html .w-layout:hover input:not(:checked) + span { background: rgba(255, 255, 255, 0.8); }
  html .box .plan-card:not(:has(input:checked)):hover { background-color: rgba(255, 255, 255, 0.9); box-shadow: var(--glass-hi), var(--shadow-lift); }
  html :is(.spec-row, #parametri form, .code-targets) > label.check:not(:has(input:checked)):hover,
  html .ch-targets .check:not(:has(input:checked)):hover,
  html .money-page fieldset.pay-choices > label.check:not(:has(> input:checked)):hover { background-color: rgba(255, 255, 255, 0.92); }
  html .photo-drop:not(.is-off):hover { background-color: rgba(255, 255, 255, 0.9); box-shadow: inset 0 0 0 1.5px rgba(20, 33, 61, 0.2), 0 10px 24px -10px rgba(20, 33, 61, 0.3); }
  html .rule-card .link-btn:hover { background-color: rgba(255, 255, 255, 0.95); }
  html .day-pill input:not(:checked) + span:hover { background-color: #fff; }
  html :is(.setup-step .actions, .first-steps, .step-guide) :is(a, button).linkish:hover { color: var(--ink); background-color: var(--lg-platter); }
  html .feature-list > .feature-card:hover { background: rgba(255, 255, 255, 0.55); }
  html .g-place-pick:hover { background: rgba(255, 255, 255, 0.9); box-shadow: inset 0 0 0 1px rgba(20, 33, 61, 0.14), 0 8px 20px -10px rgba(20, 33, 61, 0.3); }
  html .code-row:hover { background: rgba(255, 255, 255, 0.75); }
  html a.pv-card:hover { transform: translateY(-2px); background: var(--glass-strong); box-shadow: var(--glass-hi), var(--shadow-lift); }
}

/* ---------- High contrast: real controls and outlines ---------- */
@media (forced-colors: active) {
  html :is(.pay-card, .chip-check, .choice-card:not(.look), .sc-del) > input:is([type="radio"], [type="checkbox"]):not(.switch) { -webkit-appearance: auto; appearance: auto; }
  html .looks .choice-card > input[type="radio"] { opacity: 1; }
  html :is(.rv-contact a, .rv-empty a, .site-place a, .site-gap-list a, .shelf-next a, .shelf-now a, .lead a, .set-main > p.muted a,
    .set-main :is(p, li, dd, legend, label, span) > a):not(.btn, .ref, .chip, .back, .pv-card),
  html :is(.table a.contact-link, .pf-dl dd > a):is([href^="tel:"], [href^="mailto:"]) { text-decoration: underline; }
  html details.box:is(.fold, .tool) > summary::after,
  html details.box:is(.fold, .tool)[open] > summary::after,
  html details.box:is(.fold, .tool):hover > summary::after { content: "▾"; font-size: 1.1rem; display: grid; place-items: center; background-image: none; border: 1px solid CanvasText; color: CanvasText; }
  html details.box:is(.fold, .tool)[open] > summary::after { content: "▴"; }
  html :is(details.inner, details.fold-inline, .fields > details.g-fold:not(.w-more), details.vs-table, details.ed-more, details.sc-tokens) > summary,
  html :is(.g-chev, .w-folder .w-link, .savebar, .rule-card .link-btn, .photo-drop, .pf-inbox a, .fb-head-page, .vs-extras > span),
  html :is(.setup-step .actions, .first-steps, .step-guide) :is(a, button).linkish,
  html :is(.spec-row, #parametri form, .code-targets) > label.check, html .ch-targets .check,
  html .money-page fieldset.pay-choices > label.check,
  html :is(.shelf-search, .pf-tools .pf-search) input:not([type="hidden"]), html :is(.set-main, .fields) input[type="color"],
  html input[type="file"]:not([hidden], .photo-drop input, .pic-upload input, .sc-photo input) { border: 1px solid ButtonText; }
  html .fb-back { border: 1px solid LinkText; }
  html :is(.choice-card, .pay-card):has(input:checked), html .box .plan-card:has(input:checked), html .w-layout input:checked + span,
  html :is(.spec-row, #parametri form, .code-targets) > label.check:has(input:checked), html .ch-targets .check:has(input:checked),
  html .money-page fieldset.pay-choices > label.check:has(> input:checked) { outline: 2px solid Highlight; outline-offset: -2px; }
  html .box .plan-card::after { border: 1px solid CanvasText; }
  html .box .plan-card:has(input:checked)::after { background: Highlight; }
  html .shelf-strip span.today { outline: 2px solid CanvasText; outline-offset: -2px; }
}

/* ---------- Reduced motion: no turn, no lift, no squeeze ---------- */
@media (prefers-reduced-motion: reduce) {
  html :is(.rv-contact a, .rv-empty a, .site-place a, .site-gap-list a, .shelf-next a, .shelf-now a, .lead a, .set-main > p.muted a, .set-main :is(p, li, dd, legend, label, span) > a),
  html :is(.table a.contact-link, .pf-dl dd > a),
  html :is(details.inner, details.fold-inline, .fields > details.g-fold:not(.w-more), details.vs-table, details.ed-more, details.sc-tokens) > summary,
  html :is(details.inner, details.fold-inline, .fields > details.g-fold:not(.w-more), details.vs-table, details.ed-more, details.sc-tokens) > summary::after,
  html details.box:is(.fold, .tool) > summary::after, html details.w-more > summary::after, html .g-chev, html .g-chev::after,
  html :is(.pay-card, .chip-check, .choice-card, .sc-del) > input, html :is(.choice-card, .pay-card, .w-layout > span, .box .plan-card, .pv-card, .photo-drop, .day-pill span),
  html :is(.spec-row, #parametri form, .code-targets) > label.check, html .ch-targets .check, html .money-page fieldset.pay-choices > label.check,
  html :is(.setup-step .actions, .first-steps, .step-guide) :is(a, button).linkish, html .rule-card .link-btn, html a.offer-chip, html .fb-back,
  html input[type="file"]::file-selector-button, html :is(.shelf-search, .pf-tools .pf-search) input:not([type="hidden"]) { transition: none !important; }
  html :is(details.inner, details.fold-inline, .fields > details.g-fold:not(.w-more), details.vs-table, details.ed-more, details.sc-tokens) > summary:is(:hover, :active),
  html a.rv-gsum:is(:hover, :active) .g-chev, html a.offer-chip:is(:hover, :active), html a.pv-card:hover, html .fb-back:active,
  html :is(.setup-step .actions, .first-steps, .step-guide) :is(a, button).linkish:active, html .rule-card .link-btn:active { transform: none !important; }
}

/* ===== Regression check fixes (read-only QA of every page after Look v5/v6) =====
   Breakage only: washed-out stat cards, tap sizes, folds, overflows, alignment. */
/* ===== Breakage fixes (screen check of Look v5/v6 at 1280 and 390): only what broke, in the v5/v6 recipes ===== */

/* ---------- Colour: navy tokens stay navy, no orange left ---------- */
/* Šodien: the client's name in a job card is the navy token, not a grey one ("color: inherit" in portal.css won) */
html .desk-job-main .muted a.ref { color: var(--accent); font-weight: 600; }
/* The waiting alert carries no orange edge; Katalogs' "Cenas ir paraugs" badge is slate like every waiting badge */
html a.alert.wait { border-color: transparent; }
html .badge.kind_quote { color: var(--amber-ink); background: var(--amber-soft); box-shadow: inset 0 0 0 1px rgba(20, 33, 61, 0.2); }
/* Platforma → Apmeklējumi: links in its text are the R1 navy token (as on Iestatījumi → Apmeklējumi) */
html :is(.vs-grid, .vs-box) :is(p, li) > a:not(.btn, .ref, .chip) {
  color: var(--accent); font-weight: 600; text-decoration: none; border-bottom: 0;
  padding: 0.05em 0.4em; margin: 0 -0.1em; border-radius: 0.55em; overflow-wrap: anywhere;
  background-color: rgba(20, 33, 61, 0.06);
  box-shadow: inset 0 0 0 1px rgba(20, 33, 61, 0.08), inset 0 1px 0 rgba(255, 255, 255, 0.7);
  -webkit-box-decoration-break: clone; box-decoration-break: clone;
  transition: background-color 0.2s var(--ease), box-shadow 0.2s var(--ease);
}
html :is(.vs-grid, .vs-box) :is(p, li) > a:not(.btn, .ref, .chip):active { background-color: rgba(20, 33, 61, 0.11); }
html :is(.vs-grid, .vs-box) :is(p, li) > a:not(.btn, .ref, .chip):focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
/* A short page name in a sentence stays one capsule (a long one still wraps inside it, like a.ref) */
html :is(.set-main > p.muted, .lead) > a:not(.btn, .ref, .chip, .back, .pv-card) { display: inline-block; max-width: 100%; vertical-align: baseline; }

/* ---------- Stat cards ---------- */
/* A stat card that is a link: the sheen sits under its words, not over them */
html a.box.stat { isolation: isolate; }
html a.box.stat::after { z-index: -1; }
/* Apmeklējumi: the arrows between the steps sit outside the cards, so the cards must not clip them */
html .stats.vs-path > .stat { overflow: visible; }
/* A row of numbers never sits on the heading */
html .head + .stats { margin-top: 0.9rem; }

/* ---------- Buttons keep their shape ---------- */
/* "btn line" also matched portal.css's .line text row (display:flex): a link button in a sentence was a bar across the card */
html .btn.line { display: inline-flex; justify-content: center; }
/* The main Saglabāt in a section.box.fields is a pill too (R8 already does this for form.fields) */
html .set-main section.box.fields > button.btn[type="submit"]:not(.small):not(.wide) { justify-self: start; min-width: 10rem; padding-inline: 1.6rem; }
/* Rēķini in an order: both buttons in "Izrakstīt bez sūtīšanas" one full width */
html details.invoice-manual > form:not(.fields) { margin-top: 0.6rem; }
html details.invoice-manual > form:not(.fields) > .btn { display: flex; width: 100%; justify-content: center; }
/* Maksājumi tiešsaistē (Montonio, MakeCommerce, Klix, Stripe): the back link is the compact capsule, not a bar */
html .g-page > a.back { justify-self: start; }
/* The floating save capsule: the button keeps its label on one line, the status text takes the rest */
html .savebar > .btn { flex: none; white-space: nowrap; padding-inline: 1.1rem; }
html .savebar-text { flex: 1 1 auto; min-width: 0; line-height: 1.25; }
/* Platforma, desktop: Apturēt and Dati one even column of capsules */
@media (min-width: 861px) {
  html .pf-table td:last-child .actions { display: grid; justify-items: stretch; gap: 0.35rem; }
  html .pf-table td:last-child .actions .btn { width: 100%; justify-content: center; }
}
/* Phone: a card's main action is as tall as the actions beside it (44px tap target) */
@media (max-width: 760px) {
  html .drop .gone .btn.small,
  html :is(.desk-job, .desk-row) form .btn.small { min-height: 2.75rem; padding: 0 1rem; }
}

/* ---------- Radios, notes, spacing ---------- */
/* Atslēgas (Sandbox / Īsta nauda): the two radio beads do not touch */
html .field > label.check:has(> input[type="radio"]) + label.check { margin-top: 0.5rem; }
/* An info notice above a card does not run into it */
html .set-main > p.note { margin-bottom: 0.9rem; }
/* The lead under a segmented track (E-pasts / Noformējums / SMS) is spaced like the rest of the page */
html nav.page-tabs + p.lead { margin-top: 0.85rem; }
/* Bloķētās vienības: the empty panel as wide as the form card above it */
html .block-form ~ .empty-note { max-width: 42rem; }
/* Maksājumi with no rows: one quiet panel, not a box inside a box */
html .board:has(> p.empty-note:only-child) { padding: 0; background: none; box-shadow: none; -webkit-backdrop-filter: none; backdrop-filter: none; }
/* Piegādes cenas: the map's legend stays inside the map, never over the sticky top bar */
html .map-wrap { isolation: isolate; }
/* Maksājumi, desktop: a client's name stays a one-line token */
@media (min-width: 861px) {
  html .pay-table td:nth-child(2) { min-width: 10rem; }
  html .pay-table td:nth-child(2) a.ref { white-space: nowrap; }
}
/* Phone cards of Ziņas and Rēķini: the "·" has the same space on both sides */
@media (max-width: 860px) {
  html .log-table td:nth-child(2), html .inv-table td:nth-child(2) { margin-left: -0.3rem; }
  /* Platforma: the trial column labelled like the others, not a stray dash */
  html .pf-table td:nth-child(4)::before { content: "Izmēģinājums: "; color: #58585e; }
}

/* ---------- Folds ---------- */
/* Jauns pasūtījums: "Vēl brīvs šajās dienās" and "Aizņemtas" are R2 small folds (glass capsule, turning chevron) */
html details.avail-more > summary {
  list-style: none; display: inline-flex; align-items: center; justify-content: flex-start; gap: 0.5rem; width: fit-content; max-width: 100%;
  min-height: 2.3rem; margin: 0.4rem 0 0; padding: 0 0.95rem 0 1rem; border-radius: 999px; cursor: pointer;
  font-size: 0.9rem; font-weight: 600; color: var(--ink);
  background-color: var(--lg-cap); background-image: var(--lg-cap-image); box-shadow: var(--lg-cap-shadow);
  transition: transform 0.4s var(--lg-spring), box-shadow 0.3s var(--ease), background-color 0.3s var(--ease);
}
html details.avail-more > summary::-webkit-details-marker { display: none; }
html details.avail-more > summary::after {
  content: ""; flex: none; width: 0.42rem; height: 0.42rem; font-size: 0; border-right: 2px solid currentColor; border-bottom: 2px solid currentColor;
  opacity: 0.65; transform: translateY(-2px) rotate(45deg); transition: transform 0.25s var(--ease);
}
html details.avail-more[open] > summary::after { transform: translateY(1px) rotate(225deg); }
html details.avail-more[open] > summary { margin-bottom: 0.7rem; }
html details.avail-more > summary:active { transform: scale(0.97); transition-duration: 0.12s; box-shadow: var(--lg-cap-shadow-press); }
html details.avail-more > summary:focus-visible { outline: 2.5px solid var(--accent); outline-offset: 3px; }
@media (hover: hover) and (pointer: fine) {
  html details.avail-more > summary:hover { transform: translateY(-1px); background-color: rgba(255, 255, 255, 0.86); box-shadow: var(--lg-cap-shadow-hi); }
}
@media (forced-colors: active) { html details.avail-more > summary { border: 1px solid ButtonText; } }
@media (prefers-reduced-motion: reduce) {
  html details.avail-more > summary, html details.avail-more > summary::after { transition: none !important; }
  html details.avail-more > summary:is(:hover, :active) { transform: none !important; }
}

/* ---------- Site editor ---------- */
/* The lens of the page-parts list stays inside its list at every width */
html .ed-main .sc-side .sc-parts { position: relative; }

/* ---------- Tab tracks on a touch phone ---------- */
/* Pieprasījumi, Nepabeigtie: the long filter track fades at its edge, so a cut word looks meant (as chip rows do) */
@media (max-width: 760px) and (not ((hover: hover) and (pointer: fine))) {
  html .content > nav.page-tabs[aria-label="Filtrs"] {
    padding-right: 1.6rem; scroll-padding-right: 1.6rem;
    -webkit-mask-image: linear-gradient(90deg, #000 calc(100% - 1.6rem), transparent);
    mask-image: linear-gradient(90deg, #000 calc(100% - 1.6rem), transparent);
  }
}

/* ---------- A phone ---------- */
@media (max-width: 560px) {
  /* Social tabs (Ziņas, Ieraksti, Instagram komentāri, TikTok): wrap, as with a mouse, so TikTok is never hidden */
  html .chips.tabs-row { flex-wrap: wrap; overflow: visible; border-radius: 20px; }
  /* A folding card whose title and note share one span: the round chevron stays on the title's line */
  html details.box:is(.fold, .tool) > summary > span:first-child:not(.muted) { flex: 1 1 0; min-width: 0; }
  /* Parametri vietnē: no second divider on the first row; the new row's type picker as wide as its name field */
  html .spec-row:not(.spec-row ~ .spec-row) { border-top: 0; padding-top: 0; }
  html .spec-row.new > select { grid-column: 1 / -1; }
  html .spec-row.new > span:empty { display: none; }
}