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

:root {
  --bg:            #EEEEEE;
  --ink:           #213C51;
  --steel:         #6594B1;
  --mauve:         #DDAED3;
  --navy:          #213C51;
  /* legacy aliases — repointed to the new palette so existing var() usages migrate */
  --orange:        #6594B1;   /* → steel */
  --orange-soft:   #e9f0f5;   /* → light steel */
  --orange-border: #213C51;   /* → ink */
  --orange-grad:   linear-gradient(to bottom, #2E5077, #213C51); /* → navy CTA */
  --teal:          #6594B1;   /* → steel */
  --teal-dark:     #213C51;   /* → ink/navy */
  --teal-light:    #e9f0f5;   /* → light steel */
  --card-border:   #d7d2cc;   /* soft neutral hairline */
  --text:          #233240;
  --text-2:        #51677a;
  --text-muted:    #8a98a4;
  --font:          'Hanken Grotesk', sans-serif;
  --display:       'Space Grotesk', sans-serif;
}

html, body {
  height: 100%;
  overflow: hidden;
  overscroll-behavior: none;
}

body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  line-height: 1.5;
}

/* ── VIEWPORT + WORLD ── */
.viewport {
  position: fixed;
  inset: 0;
  overflow: hidden;
  touch-action: none;
  cursor: default;
  /* obsidian-canvas dot grid */
  background-image: radial-gradient(rgba(33,60,81,0.17) 1.3px, transparent 1.3px);
  background-size: 30px 30px;
}
.viewport.dragging { cursor: grabbing; }

.world {
  position: absolute;
  top: 0;
  left: 0;
  width: 3550px;
  height: 2950px;
  transform-origin: 0 0;
  will-change: transform;
}
.world.glide { transition: transform 0.95s cubic-bezier(0.22, 0.8, 0.25, 1); }

/* grain */
body::after {
  content: '';
  position: fixed;
  inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  opacity: 0.025;
  pointer-events: none;
  z-index: 50;
}

/* ── PIPELINE EDGES ── */
.edges {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

.edge {
  stroke: rgba(101,148,177,0.78);
  stroke-width: 2.5;
  fill: none;
  stroke-dasharray: 8 9;
  stroke-linecap: round;
  animation: edge-flow 40s linear infinite;
}

.edge.quiet { stroke: rgba(221,174,211,0.8); }

@keyframes edge-flow {
  to { stroke-dashoffset: -640; }
}

.edge-label {
  font-family: var(--display);
  font-style: normal;
  font-size: 18px;
  fill: var(--text-2);
}

/* ── HUB (headline) ── */
.hub {
  position: absolute;
  left: 1600px;
  top: 400px;
  transform: translate(-50%, -50%);
  width: 760px;
  text-align: center;
}

@keyframes pulse-dot {
  0%, 100% { opacity: 1; transform: scale(1); }
  50%       { opacity: 0.55; transform: scale(1.35); }
}

.hub h1 {
  font-family: var(--display);
  font-size: 40px;
  font-weight: 560;
  letter-spacing: -0.02em;
  line-height: 1.06;
  color: var(--navy);
  margin-bottom: 35px;
}

/* brand mark: centered above the hero on home/overview, top-left on clusters */
.hub-brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  margin-bottom: 35px;
}
.hub-brand .brand-name { font-size: 40px; }
.topbar .brand { transition: opacity 0.35s ease; }
.topbar .brand { opacity: 0; pointer-events: none; }
body.at-cluster .topbar .brand { opacity: 1; pointer-events: auto; }

.hub h1 em { font-style: normal; color: var(--orange); }
.hub-sub em { font-style: normal; color: var(--navy); }
.hub-sub i { font-style: italic; }


.hub-actions {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  flex-wrap: wrap;
}

.btn-map {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font);
  font-size: 14px;
  font-weight: 600;
  color: var(--teal-dark);
  background: rgba(255,255,255,0.6);
  border: 1px solid var(--teal);
  border-radius: 10px;
  padding: 12px 22px;
  cursor: pointer;
  transition: background 0.15s, box-shadow 0.15s;
}
.btn-map:hover { background: var(--teal-light); box-shadow: 0 4px 14px rgba(101,148,177,0.3); }

.hub-hint {
  font-size: 13px;
  color: var(--text-muted);
  margin-top: 22px;
}
.hub-hint b { color: var(--teal-dark); font-weight: 600; }

/* ── CLUSTERS ── */
.cluster {
  position: absolute;
  transform: translate(-50%, -50%);
  cursor: default;
}

.ghost-num {
  position: absolute;
  top: -180px;
  left: 50%;
  transform: translateX(-50%);
  font-family: var(--display);
  font-style: normal;
  font-size: 230px;
  font-weight: 500;
  line-height: 1;
  color: transparent;
  -webkit-text-stroke: 1.5px rgba(221,174,211,0.6);
  pointer-events: none;
  user-select: none;
  white-space: nowrap;
}

.cluster-row {
  display: flex;
  align-items: center;
  gap: 36px;
  position: relative;
}

.info-card {
  width: 330px;
  background: white;
  border: 2px solid var(--ink);
  border-radius: 14px;
  padding: 26px 26px 28px;
  box-shadow: 6px 6px 0 var(--ink);
}

.info-tag {
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: var(--steel);
  margin-bottom: 10px;
}

.info-card h2 {
  font-family: var(--display);
  font-size: 25px;
  font-weight: 580;
  letter-spacing: -0.015em;
  line-height: 1.15;
  color: var(--navy);
  margin-bottom: 12px;
}

.info-card h2 em { font-style: normal; color: var(--steel); }

.info-card .sub {
  font-size: 13.5px;
  color: var(--text-2);
  line-height: 1.6;
  margin-bottom: 16px;
}

.feat {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 7px;
  margin-bottom: 20px;
}

.feat li {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12.5px;
  color: var(--text-2);
  font-weight: 500;
}

.feat li::before {
  content: '';
  width: 14px; height: 14px;
  flex-shrink: 0;
  background: var(--teal-light);
  border: 1.5px solid var(--teal);
  border-radius: 50%;
  background-image: url("data:image/svg+xml,%3Csvg width='8' height='8' viewBox='0 0 10 10' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M2 5l2.5 2.5L8 3' stroke='%23213C51' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: center;
}

.btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  background: var(--ink);
  color: white;
  border: none;
  border-radius: 9px;
  padding: 11px 20px;
  font-family: var(--font);
  font-size: 13px;
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
  transition: background 0.15s ease;
  white-space: nowrap;
}
.btn-primary:hover { background: #2E5077; }
.btn-primary:active { background: #16293a; }

.btn-primary.large { font-size: 15px; padding: 13px 26px; border-radius: 11px; }

/* sticky notes */
.sticky {
  position: absolute;
  background: var(--mauve);
  border: 2px solid var(--ink);
  border-radius: 8px;
  padding: 10px 14px;
  font-size: 12.5px;
  color: var(--ink);
  box-shadow: 4px 4px 0 var(--ink);
  white-space: nowrap;
  z-index: 5;
}

.sticky.t { background: var(--mauve); }


/* sticky tooltip */
.info-icon {
  position: absolute;
  top: -7px;
  right: -7px;
  width: 15px;
  height: 15px;
  border-radius: 50%;
  background: var(--teal-dark);
  color: white;
  font-size: 9px;
  font-weight: 700;
  font-family: var(--font);
  font-style: italic;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 20;
}
.info-icon:hover .tooltip { opacity: 1; }

.okf-wrap { position: relative; display: inline; }
.okf-wrap::after { content: '.'; }
.okf-link { color: var(--steel); text-decoration: underline dotted; text-underline-offset: 2px; cursor: pointer; }
.okf-wrap:hover .tooltip { opacity: 1; pointer-events: auto; }
.okf-wrap .tooltip { bottom: calc(100% + 6px); width: 190px; left: 50%; text-align: center; }

.tooltip {
  position: absolute;
  bottom: calc(100% + 10px);
  left: 50%;
  transform: translateX(-50%);
  background: var(--navy);
  color: rgba(255,255,255,0.88);
  font-size: 11.5px;
  font-weight: 400;
  font-style: normal;
  font-family: var(--font);
  line-height: 1.55;
  padding: 9px 13px;
  border-radius: 9px;
  width: 230px;
  white-space: normal;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.2s ease;
  box-shadow: 0 4px 16px rgba(0,0,0,0.22);
  z-index: 20;
}

/* expandable stickies */
.sticky.x { padding: 0; }

.sticky-head {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  font-family: var(--font);
  font-size: 12.5px;
  color: var(--ink);
  background: none;
  border: none;
  padding: 10px 14px 0;
  cursor: pointer;
  white-space: nowrap;
  min-width: 100%;
}


/* + button sits on the bottom border, centered */
.plus {
  position: absolute;
  bottom: -11px;
  left: 50%;
  transform: translateX(-50%);
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--ink);
  color: transparent;
  font-size: 0;
  flex-shrink: 0;
  transition: transform 0.25s ease;
  cursor: pointer;
  border: 2px solid var(--mauve);
  box-shadow: 0 2px 6px rgba(0,0,0,0.12);
  z-index: 10;
}
/* draw the + with two centered bars (rotates to a clean × when open) */
.plus::before, .plus::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 10px;
  height: 2px;
  background: white;
  border-radius: 1px;
}
.plus::before { transform: translate(-50%, -50%); }
.plus::after  { transform: translate(-50%, -50%) rotate(90deg); }
.sticky.t .plus { background: var(--ink); }
.sticky.open .plus { transform: translateX(-50%) rotate(45deg); }

.sticky-body {
  padding: 0 12px 14px;
  box-sizing: border-box;
  max-height: 0;
  opacity: 0;
  overflow: hidden;
  white-space: normal;
  display: grid;
  grid-template-columns: repeat(3, auto);
  gap: 4px;
  transition: max-height 0.35s ease, opacity 0.25s ease;
}

.sticky-body .legend { grid-column: 1 / -1; }

.sticky.open .sticky-body {
  max-height: 220px;
  opacity: 1;
}

.mini-chip {
  display: inline-block;
  background: white;
  border: 1px solid var(--card-border);
  border-radius: 6px;
  padding: 3px 9px;
  font-size: 11px;
  font-weight: 500;
  color: var(--text-2);
  margin: 2px 3px 2px 0;
  white-space: nowrap;
  cursor: default;
}
.legend, .qc-tag, .pm-chip, .otm-badge { cursor: default; }

/* interactive clip-type chips (drive the Capture popup) */
.mini-chip[data-clip] {
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}
.mini-chip[data-clip]:hover { border-color: var(--ink); }
.mini-chip[data-clip].active {
  background: var(--ink);
  color: #fff;
  border-color: var(--ink);
}


.sticky-body .legend {
  display: block;
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--ink);
  margin: 6px 0 3px;
}

/* ── clip type selector (s-filter sticky) ── */
.clip-type-selector {
  grid-template-columns: repeat(3, auto);
}

#s-filter {
  padding: 0;
}
#s-filter .sticky-body {
  max-height: 220px;
  opacity: 1;
  padding: 10px 12px 12px;
}

.clip-type-btn {
  background: white;
  border: 1px solid var(--card-border);
  border-radius: 6px;
  padding: 3px 9px;
  font-size: 11px;
  font-weight: 500;
  color: var(--text-2);
  font-family: var(--font);
  white-space: nowrap;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s, color 0.15s;
}
.clip-type-btn.active {
  background: var(--ink);
  border-color: var(--ink);
  color: #fff;
}

/* ── ob-window clip views ── */
.ob-clip-view { display: none; }
.ob-clip-view.active { display: block; }

.qc-close {
  margin-left: auto;
  width: 17px;
  height: 17px;
  border-radius: 50%;
  background: rgba(255,255,255,0.07);
  border: 1px solid rgba(255,255,255,0.13);
  color: rgba(255,255,255,0.4);
  font-size: 10px;
  font-family: var(--font);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: default;
  line-height: 1;
  flex-shrink: 0;
}

/* full page */
.qc-fp-bar {
  height: 2px;
  background: rgba(255,255,255,0.1);
  border-radius: 1px;
  margin-bottom: 9px;
}
.qc-fp-fill {
  height: 100%;
  background: var(--orange);
  border-radius: 1px;
}
.qc-fp-meta {
  display: flex;
  gap: 5px;
  font-size: 10.5px;
  color: rgba(255,255,255,0.55);
  margin-bottom: 3px;
}
.qc-fp-meta .sep { opacity: 0.35; }
.qc-fp-sub {
  font-size: 10px;
  color: rgba(255,255,255,0.3);
  margin-bottom: 9px;
}
.qc-fp-body {
  font-size: 11px;
  color: rgba(255,255,255,0.65);
  line-height: 1.6;
}

/* tweet */
.qc-tweet-card {
  background: rgba(255,255,255,0.05);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 8px;
  padding: 11px 13px;
}
.qc-tweet-top {
  display: flex;
  align-items: flex-start;
  gap: 9px;
  margin-bottom: 9px;
}
.qc-avatar {
  width: 28px; height: 28px;
  border-radius: 50%;
  background: var(--teal-dark);
  color: white;
  font-size: 10px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.qc-tname { font-size: 11.5px; font-weight: 700; color: rgba(255,255,255,0.9); line-height: 1.3; }
.qc-thandle { font-size: 10px; color: rgba(255,255,255,0.38); }
.qc-tweet-text {
  font-size: 11.5px;
  color: rgba(255,255,255,0.8);
  line-height: 1.55;
  margin-bottom: 9px;
}
.qc-tweet-foot {
  font-size: 10px;
  color: rgba(255,255,255,0.32);
}

/* video clip */
.qc-vthumb {
  position: relative;
  background: rgba(0,0,0,0.35);
  border-radius: 6px;
  height: 52px;
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 10px;
  padding: 0 13px;
  margin-bottom: 8px;
  overflow: hidden;
}
.qc-vscrub {
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 3px;
  background: rgba(255,255,255,0.12);
}
.qc-vscrub-fill {
  height: 100%;
  width: 15%;
  background: var(--steel);
  transition: width 0.55s cubic-bezier(0.22, 0.8, 0.25, 1);
}
.qc-vtable tr.vts-active { background: rgba(101,148,177,0.10); }
.qc-vtable tr.vts-active .qc-ts { background: rgba(101,148,177,0.5); color: #fff; }
.qc-vplay {
  width: 22px; height: 22px;
  border-radius: 50%;
  background: var(--orange);
  color: white;
  font-size: 9px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.qc-vtitle { font-size: 11px; font-weight: 600; color: rgba(255,255,255,0.85); line-height: 1.3; }
.qc-vchan  { font-size: 10px; color: rgba(255,255,255,0.4); margin-top: 2px; }
.qc-vtable {
  width: 100%;
  border-collapse: collapse;
  font-size: 10.5px;
}
.qc-vtable thead tr { border-bottom: 1px solid rgba(255,255,255,0.1); }
.qc-vtable td:last-child { text-align: right; width: 24px; }
.qc-vtable th {
  padding: 5px 4px 5px 0;
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.28);
  text-align: left;
}
.qc-vtable tr { border-bottom: 1px solid rgba(255,255,255,0.05); }
.qc-vtable td { padding: 5px 4px 5px 0; color: rgba(255,255,255,0.6); vertical-align: middle; font-size: 10.5px; }
.qc-ts {
  display: inline-flex;
  align-items: center;
  background: rgba(101,148,177,0.18);
  border: 1px solid rgba(101,148,177,0.3);
  border-radius: 4px;
  padding: 1px 6px;
  font-size: 10px;
  color: #a9cce0;
  font-weight: 600;
  white-space: nowrap;
  cursor: pointer;
}

/* note field — rounded box with ○ icon, matches actual Obsidian render */
.qc-note {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  font-size: 11px;
  color: rgba(255,255,255,0.55);
  line-height: 1.55;
  background: rgba(255,255,255,0.06);
  border-radius: 8px;
  padding: 8px 11px;
  margin-bottom: 10px;
}
.qc-note-icon {
  color: rgba(255,255,255,0.3);
  flex-shrink: 0;
  margin-top: 1px;
}

/* image */
.qc-img-mock {
  background: rgba(255,255,255,0.05);
  border: 1px solid rgba(255,255,255,0.07);
  border-radius: 6px;
  height: 72px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 7px;
}
.qc-img-caption {
  font-size: 10px;
  color: rgba(255,255,255,0.32);
  text-align: center;
}

/* ── mockups (compact reuse) ── */
.popup-mockup {
  width: 310px;
  background: var(--bg);
  border-radius: 14px;
  border: 1px solid var(--card-border);
  box-shadow: 0 4px 12px rgba(0,0,0,0.07), 0 18px 48px rgba(33,60,81,0.14);
  overflow: hidden;
  font-size: 12px;
  transform: rotate(1.6deg);
  font-family: var(--font);
  color: var(--text);
}

/* Capture popup is taken out of flow so its height changes (clip-type
   rotation) never resize the cluster and shift the info card. Row width is
   pinned to its natural size (330 card + 36 gap + 310 popup) so the cluster's
   horizontal center stays put with the popup removed from flow. */
[data-go="capture"] .cluster-row { width: 676px; }
#cap-popup {
  position: absolute;
  top: 50%;
  right: 0;
  transform: translateY(-50%) rotate(1.6deg);
}

/* topbar */
.pm-topbar {
  padding: 13px 14px 10px;
  border-bottom: 1px solid var(--card-border);
  display: flex; align-items: flex-start; justify-content: space-between;
}
.pm-topbar-left { display: flex; flex-direction: column; gap: 4px; }
.pm-logo {
  font-size: 16px; font-weight: 800; letter-spacing: -0.05em; color: #213C51; line-height: 1.2;
}
.pm-vault-switcher {
  display: flex; align-items: center; gap: 4px;
  font-size: 11px; font-weight: 500; color: #999;
}
.pm-online-dot {
  width: 6px; height: 6px; background: #4caf7d; border-radius: 50%;
  box-shadow: 0 0 0 0 rgba(76,175,125,0.5);
  animation: pulse-dot 2.5s ease-in-out infinite;
  flex-shrink: 0;
}
.pm-vault-arrow { font-size: 10px; opacity: 0.6; }
.pm-settings-icon { color: #aaa; flex-shrink: 0; margin-top: 2px; }

/* field sections */
.pm-body { padding: 11px 14px 13px; display: flex; flex-direction: column; gap: 0; }

.pm-field-label {
  display: block;
  font-size: 9px; font-weight: 700; color: #3a4f60;
  text-transform: uppercase; letter-spacing: 0.07em;
  margin-bottom: 4px;
}
.pm-field-label-row {
  display: flex; justify-content: space-between; align-items: center; margin-bottom: 4px;
}
.pm-field-label-row .pm-field-label { margin-bottom: 0; }
.pm-toggle-row { display: flex; align-items: center; gap: 5px; font-size: 10px; font-weight: 500; color: #888; }
.pm-toggle-track {
  position: relative; width: 26px; height: 15px;
  background: #cfd3d8; border-radius: 8px; flex-shrink: 0;
}
.pm-toggle-thumb {
  position: absolute; width: 11px; height: 11px;
  background: white; border-radius: 50%; top: 2px; left: 2px;
  box-shadow: 0 1px 2px rgba(0,0,0,0.2);
}

.pm-input {
  width: 100%; padding: 7px 10px; margin-bottom: 9px;
  border: 1px solid #d7d2cc; border-radius: 8px;
  font-size: 11.5px; font-family: var(--font);
  background: #ffffff; color: var(--text);
}
/* smooth collapse/expand for the daily-note destination swap */
#pm-folder-section, #pm-dest-normal, #pm-dest-daily {
  max-height: 80px;
  overflow: hidden;
  transition: max-height 0.32s cubic-bezier(0.22, 0.8, 0.25, 1),
              opacity 0.24s ease,
              margin 0.28s ease,
              padding 0.28s ease,
              background 0.25s ease;
}
.pm-collapsed {
  max-height: 0 !important;
  opacity: 0 !important;
  margin-top: 0 !important;
  margin-bottom: 0 !important;
  padding-top: 0 !important;
  padding-bottom: 0 !important;
}
.pm-input.frozen {
  display: flex; justify-content: space-between; align-items: center;
  background: #f0eeec; color: #7a7a7a;
}
.pm-input.frozen::after { content: '🔒'; font-size: 9px; opacity: 0.55; }
.pm-folder-picker {
  display: flex; justify-content: space-between; align-items: center;
  padding: 7px 10px; margin-bottom: 9px;
  border: 1px solid #d7d2cc; border-radius: 8px;
  font-size: 11.5px; background: white; color: var(--text);
}
.pm-folder-picker::after { content: "▾"; font-size: 10px; color: #999; }

.pm-tags-box {
  border: 1px solid var(--teal);
  box-shadow: 0 0 0 3px rgba(101,148,177,0.18);
  border-radius: 8px; padding: 5px 8px; margin-bottom: 9px;
  display: flex; flex-wrap: wrap; gap: 4px; align-items: center;
  background: white;
}
.pm-chip {
  background: #cfe0ec; color: #213C51;
  border-radius: 5px; padding: 2px 7px;
  font-size: 10.5px; font-weight: 600;
}
.pm-chip-ghost {
  font-size: 10.5px; color: #bbb;
}

.pm-textarea {
  width: 100%; padding: 7px 10px; margin-bottom: 9px;
  border: 1px solid #d7d2cc; border-radius: 8px;
  font-size: 11px; font-family: var(--font);
  background: #ffffff; color: #9aa6b0;
  height: 44px; resize: none; line-height: 1.45;
}

.pm-save-btn {
  background: linear-gradient(160deg, #2E5077, #213C51);
  border: 1px solid #16293a; border-radius: 8px;
  color: white; padding: 9px 12px; margin-bottom: 7px;
  font-size: 12px; font-weight: 700; font-family: var(--font);
  text-align: center; width: 100%;
  box-shadow: 0 1px 3px rgba(33,60,81,0.2);
  user-select: none;
}
.pm-full-page-btn {
  display: block; text-align: center; width: fit-content; margin: 0 auto;
  background: none; border: 1px solid #6594B1; border-radius: 20px;
  padding: 4px 12px; font-size: 10.5px; font-weight: 600;
  color: #213C51; font-family: var(--font);
}

/* status banner in popup (shows after save) */
.pm-status {
  margin: 4px 0 0;
  padding: 8px 11px;
  border-radius: 8px;
  font-size: 10.5px; line-height: 1.45;
  display: flex; align-items: flex-start; gap: 7px;
  background: #e9f0f5; color: #213C51;
  border: 1px solid #6594B1; border-left: 3px solid #4a7d9c;
  max-height: 80px; overflow: hidden;
  transition: max-height 0.3s ease, opacity 0.3s ease, margin 0.3s ease;
}
.pm-status.pm-hidden {
  max-height: 0;
  opacity: 0;
  margin: 0;
}
.pm-status-icon { flex-shrink: 0; font-size: 13px; line-height: 1.3; }
.pm-status-body strong { display: block; font-weight: 700; font-size: 10.5px; margin-bottom: 2px; }
.pm-status-body em { font-style: normal; }

/* save button invite animation */
@keyframes pm-btn-invite {
  0%, 100% { box-shadow: 0 1px 3px rgba(33,60,81,0.2), 0 0 0 0 rgba(101,148,177,0); }
  50% { box-shadow: 0 2px 8px rgba(33,60,81,0.3), 0 0 0 6px rgba(101,148,177,0); }
}
@keyframes pm-btn-glow {
  0%, 100% { box-shadow: 0 1px 3px rgba(33,60,81,0.2); }
  50% { box-shadow: 0 3px 14px rgba(101,148,177,0.55), 0 1px 3px rgba(33,60,81,0.25); }
}
.pm-save-btn {
  cursor: pointer;
  animation: pm-btn-glow 2s ease-in-out infinite;
  transition: background 0.2s, transform 0.1s, box-shadow 0.2s;
}
.pm-save-btn:hover { filter: brightness(1.07); transform: translateY(-1px); }
.pm-save-btn:active { transform: scale(0.97); }

/* success state */
.pm-save-btn.pm-saved {
  background: linear-gradient(160deg, #4a8880, #3a7068);
  border-color: #213C51;
  box-shadow: 0 1px 3px rgba(33,60,81,0.2) !important;
  animation: none;
  cursor: default;
}
.pm-field-saved {
  background: #f0eeec !important;
  color: #aaa !important;
  border-color: #e0dbd6 !important;
}
.pm-field-saved.pm-tags-box {
  border-color: transparent !important;
  box-shadow: none !important;
}
.pm-open-obsidian {
  display: none;
  text-align: center; width: fit-content; margin: 7px auto 0;
  background: none; border: 1px solid #6594B1; border-radius: 20px;
  padding: 4px 14px; font-size: 10.5px; font-weight: 600;
  color: #213C51; font-family: var(--font); cursor: default;
}
.pm-open-obsidian.pm-visible {
  display: block;
  animation: fade-in-up 0.3s ease forwards;
}
@keyframes fade-in-up {
  from { opacity: 0; transform: translateY(4px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* daily note target banner (replaces file input when toggle is on) */
.pm-daily-note-target {
  display: flex; align-items: center; gap: 6px;
  background: #e9f0f5; border: 1px solid #6594B1;
  border-radius: 8px; padding: 7px 10px; margin-bottom: 9px;
  font-size: 11px; font-weight: 500; color: #213C51;
}

/* toggle active state */
.pm-toggle-track.on { background: #6594B1; }
.pm-toggle-track.on .pm-toggle-thumb { transform: translateX(11px); }
.pm-toggle-thumb { transition: transform 0.2s ease; }
.pm-toggle-track { transition: background 0.2s ease; }

.ob-window {
  width: 360px;
  background: var(--navy);
  border-radius: 12px;
  border: 1px solid rgba(255,255,255,0.08);
  box-shadow: 0 20px 50px rgba(33,60,81,0.35);
  overflow: hidden;
  font-size: 13px;
  transform: rotate(-1.4deg);
  transition: height 0.35s cubic-bezier(0.22, 0.8, 0.25, 1);
}
.ob-titlebar {
  display: flex; align-items: center; gap: 8px;
  padding: 9px 13px;
  background: rgba(255,255,255,0.04);
  border-bottom: 1px solid rgba(255,255,255,0.07);
}
.ob-dot { width: 9px; height: 9px; border-radius: 50%; background: rgba(255,255,255,0.16); }
.ob-title { flex: 1; text-align: center; font-size: 10.5px; color: rgba(255,255,255,0.4); margin-right: 40px; }
.ob-body { padding: 18px 20px 20px; }
.ob-heading { font-size: 14px; font-weight: 700; color: #b8d4ce; margin-bottom: 13px; }
.ob-heading .ext { font-size: 10.5px; color: rgba(255,255,255,0.3); font-weight: 400; }

.qc-callout {
  background: rgba(101,148,177,0.09);
  border: 1px solid rgba(101,148,177,0.25);
  border-left: 3px solid var(--orange);
  border-radius: 8px;
  overflow: hidden;
}
.qc-head {
  display: flex; align-items: center; gap: 7px;
  padding: 9px 13px;
  font-size: 12px; font-weight: 600;
  color: #a9cce0;
}
.qc-head .chev { margin-left: auto; color: rgba(255,255,255,0.3); font-size: 10px; }
.qc-body { padding: 1px 13px 11px; font-size: 12px; color: rgba(255,255,255,0.78); line-height: 1.6; }
.qc-meta {
  display: flex; align-items: center; gap: 6px; flex-wrap: wrap;
  padding: 9px 13px;
  border-top: 1px solid rgba(255,255,255,0.07);
  font-size: 10px; color: rgba(255,255,255,0.35);
}
.qc-tag {
  background: rgba(101,148,177,0.14);
  border: 1px solid rgba(101,148,177,0.3);
  border-radius: 4px;
  padding: 1px 7px;
  font-size: 10px;
  color: var(--teal);
  font-weight: 500;
}


/* ── Cluster 03 — Organize table mockup ── */
.org-table-mock {
  width: 532px;
  background: var(--navy);
  border-radius: 12px;
  border: 1px solid rgba(255,255,255,0.08);
  box-shadow: 0 20px 50px rgba(33,60,81,0.35);
  overflow: hidden;
  transform: rotate(1.4deg);
  font-family: var(--font);
  font-size: 12px;
  color: rgba(255,255,255,0.75);
}
.otm-tabs {
  display: flex;
  align-items: center;
  gap: 2px;
  padding: 11px 14px 10px;
  border-bottom: 1px solid rgba(255,255,255,0.07);
  background: rgba(255,255,255,0.03);
}
.otm-tab {
  padding: 4px 12px;
  border-radius: 20px;
  color: rgba(255,255,255,0.38);
  font-size: 11px;
  font-weight: 500;
  white-space: nowrap;
}
.otm-tab.active { background: rgba(255,255,255,0.1); color: rgba(255,255,255,0.88); }
.otm-show-org {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 5px;
  color: rgba(255,255,255,0.3);
  font-size: 11px;
  white-space: nowrap;
}
.otm-filters {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  border-bottom: 1px solid rgba(255,255,255,0.06);
}
.otm-fl { color: rgba(255,255,255,0.3); font-size: 11px; white-space: nowrap; }
.otm-fv {
  padding: 3px 10px;
  border: 1px solid rgba(255,255,255,0.11);
  border-radius: 12px;
  color: rgba(255,255,255,0.55);
  font-size: 11px;
  margin-right: 4px;
  white-space: nowrap;
}
.otm-table {
  width: 100%;
  border-collapse: collapse;
  table-layout: fixed;
}
.otm-table thead th {
  padding: 8px 10px;
  text-align: left;
  font-size: 9.5px;
  font-weight: 600;
  letter-spacing: 0.04em;
  color: rgba(255,255,255,0.28);
  border-bottom: 1px solid rgba(255,255,255,0.07);
  white-space: nowrap;
}
.col-title   { width: 152px; }
.col-type    { width: 72px;  }
.col-saved   { width: 52px;  }
.col-belongs { width: 120px; }
.col-org     { width: 68px;  }
.col-prog    { width: 68px;  }
.otm-table tbody tr { border-bottom: 1px solid rgba(255,255,255,0.05); }
.otm-table tbody tr:last-child { border-bottom: none; }
.otm-table tbody td { padding: 10px 10px; vertical-align: middle; white-space: nowrap; }
.otm-title {
  overflow: hidden;
  text-overflow: ellipsis;
  font-size: 11.5px;
}
.otm-badge {
  display: inline-block;
  padding: 3px 10px;
  border-radius: 9px;
  font-size: 11px;
  background: rgba(255,255,255,0.07);
  border: 1px solid rgba(255,255,255,0.13);
  color: rgba(255,255,255,0.6);
}
.otm-badge.topic {
  background: rgba(101,148,177,0.12);
  border-color: rgba(101,148,177,0.3);
  color: var(--teal);
}
.otm-badge.person {
  background: rgba(101,148,177,0.12);
  border-color: rgba(101,148,177,0.3);
  color: #a9cce0;
}
.otm-muted { color: rgba(255,255,255,0.35); font-size: 11px; }
.otm-belongs { font-size: 11px; overflow: hidden; text-overflow: ellipsis; transition: color 0.35s ease; }
.otm-belongs.dim { color: rgba(255,255,255,0.18); }
.otm-org-cell { text-align: center; }
.otm-chk {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 14px;
  height: 14px;
  border: 1px solid rgba(255,255,255,0.18);
  border-radius: 3px;
  font-size: 10px;
  color: transparent;
  transition: background 0.35s ease, border-color 0.35s ease, color 0.35s ease;
}
.otm-chk.on {
  background: rgba(76,175,125,0.35);
  border-color: rgba(76,175,125,0.55);
  color: #7fd4a8;
}
.otm-prog { font-size: 10px; letter-spacing: 2px; }
.pd { font-size: 10px; transition: opacity 0.45s ease; }
.pd1 { color: #888; }
.pd2 { color: #6594B1; }
.pd3 { color: #c97fb5; }
.pd.off { opacity: 0.18; }

/* ── INSTALL CLUSTER ── */
.install-wrap { text-align: center; }

.install-wrap h2 {
  font-family: var(--display);
  font-size: 42px;
  font-weight: 560;
  letter-spacing: -0.02em;
  color: var(--navy);
  margin-bottom: 8px;
}
.install-wrap h2 em { font-style: normal; color: var(--orange); }
.install-wrap > p { font-size: 18px; color: var(--text-2); margin-bottom: 32px; }

.cta-cards { display: flex; gap: 18px; }

.cta-card {
  width: 270px;
  background: white;
  border: 2px solid var(--ink);
  border-radius: 14px;
  padding: 28px 24px;
  text-align: left;
  display: flex;
  flex-direction: column;
  box-shadow: 5px 5px 0 var(--ink);
  transition: box-shadow 0.2s, transform 0.2s;
}
.cta-card:hover { box-shadow: 8px 8px 0 var(--ink); transform: translate(-2px,-2px); }
.cta-card .btn-primary { align-self: flex-start; }

.cta-num { font-family: var(--display); font-style: normal; font-weight: 700; font-size: 14px; color: var(--steel); margin-bottom: 8px; }
.cta-title { font-size: 18px; font-weight: 700; letter-spacing: -0.02em; color: var(--navy); margin-bottom: 6px; }
.cta-desc { font-size: 14px; color: var(--text-2); line-height: 1.55; margin-bottom: 20px; flex: 1; }

/* ── CHROME: top bar ── */
.topbar {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 20px;
  pointer-events: none;
}

.topbar > * { pointer-events: auto; }

.brand {
  display: flex;
  align-items: center;
  gap: 9px;
  text-decoration: none;
  background: rgba(255,255,255,0.85);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid var(--card-border);
  border-radius: 12px;
  padding: 8px 14px;
}

.brand-name { font-size: 15px; font-weight: 700; letter-spacing: -0.025em; color: var(--navy); }

.chips {
  display: flex;
  gap: 2px;
  background: rgba(255,255,255,0.85);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid var(--card-border);
  border-radius: 26px;
  padding: 4px;
}

.chip {
  font-family: var(--font);
  font-size: 12.5px;
  font-weight: 600;
  color: var(--text-2);
  background: none;
  border: none;
  border-radius: 20px;
  padding: 7px 15px;
  cursor: pointer;
  transition: background 0.15s, color 0.15s;
  white-space: nowrap;
}
.chip:hover { color: var(--teal-dark); }
.chip.active { background: var(--teal-dark); color: white; }

/* ── CHROME: bottom corners ── */

.hint {
  position: fixed;
  left: 20px;
  bottom: 20px;
  z-index: 100;
  font-size: 12px;
  color: var(--text-muted);
  background: rgba(255,255,255,0.9);
  backdrop-filter: blur(12px);
  border: 1px solid var(--card-border);
  border-radius: 12px;
  padding: 9px 14px;
  display: flex;
  align-items: center;
  gap: 0;
}

.hint a { color: var(--teal-dark); text-decoration: none; }
.hint a:hover { text-decoration: underline; }
.tooltip a { color: var(--teal); text-decoration: underline; cursor: pointer; }
#s-portent .tooltip { pointer-events: auto; }
#s-portent .tooltip::after { content: ''; position: absolute; top: 100%; left: 0; right: 0; height: 12px; }

noscript .nojs {
  position: fixed;
  inset: 0;
  z-index: 999;
  background: var(--bg);
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 24px;
  font-size: 16px;
  color: var(--text-2);
}

@media (max-width: 760px) {
  .chips { display: none; }
  .hint span.kbd-only { display: none; }
  .hub h1 { font-size: 52px; }
}

@media (prefers-reduced-motion: reduce) {
  .world.glide { transition: none; }
  .edge, .g-pulse, .pm-online-dot, .hub-dot { animation: none; }
}
