:root {
  color-scheme: dark;
  --bg: #140b05;
  --panel: rgba(255, 255, 255, 0.06);
  --panel-strong: rgba(255, 255, 255, 0.1);
  --ink: #fff5ec;
  --muted: #c9a98c;
  --soft: #f1dac6;
  --line: rgba(255, 255, 255, 0.1);
  --line-strong: rgba(255, 255, 255, 0.2);
  --accent: #f07c1e;
  --accent-ink: #ffffff;
  --link: #c2f08c;
  --glow: linear-gradient(135deg, #ffb347 0%, #f07c1e 55%, #e0561b 100%);
  --lime: #b8f36b;
  --warn-bg: rgba(255, 200, 97, 0.1);
  --warn-line: rgba(255, 200, 97, 0.38);
  --warn-ink: #ffd68a;
  --error-bg: rgba(255, 90, 130, 0.12);
  --error-line: rgba(255, 90, 130, 0.42);
  --error-ink: #ff9ab4;
  --ok-bg: rgba(79, 227, 161, 0.1);
  --ok-line: rgba(79, 227, 161, 0.38);
  --ok-ink: #8ff0c2;
  --youtube: linear-gradient(135deg, #ff7a59, #ff1f5a);
  --instagram: linear-gradient(135deg, #fbbd5c, #f5673b 30%, #d62976 62%, #8f3cd9);
  --facebook: linear-gradient(135deg, #62a4ff, #2f5bea);
  --tiktok: linear-gradient(135deg, #25f4ee, #6b5bff 52%, #fe2c55);
  --radius: 22px;
  --shadow: 0 18px 50px rgba(10, 5, 2, 0.45);
  --glass: linear-gradient(160deg, rgba(255, 255, 255, 0.09), rgba(255, 255, 255, 0.03));
}

* { box-sizing: border-box; }
body {
  margin: 0;
  min-height: 100vh;
  font: 15px/1.5 -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  color: var(--ink);
  background:
    radial-gradient(1100px 650px at 8% -8%, rgba(240, 124, 30, 0.38), transparent 60%),
    radial-gradient(900px 600px at 102% 4%, rgba(255, 179, 71, 0.24), transparent 58%),
    radial-gradient(1000px 700px at 55% 115%, rgba(143, 227, 107, 0.2), transparent 60%),
    linear-gradient(160deg, #23130a 0%, #140b05 55%, #0a0603 100%);
  background-attachment: fixed;
}
a { color: var(--link); }
a:hover { color: #fff; }
code { background: rgba(255, 255, 255, 0.1); padding: 1px 6px; border-radius: 6px; font-size: 13px; }
svg { fill: currentColor; }

/* ---- header ---- */
.topbar {
  display: flex; align-items: center; gap: 22px; flex-wrap: wrap;
  padding: 14px 32px; position: sticky; top: 0; z-index: 5;
  background: rgba(20, 11, 5, 0.72);
  backdrop-filter: blur(18px) saturate(150%); -webkit-backdrop-filter: blur(18px) saturate(150%);
  border-bottom: 1px solid var(--line);
}
.brand { display: flex; align-items: center; }
.brand img { display: block; height: 96px; width: auto; }
.topbar nav { display: flex; gap: 6px; flex: 1; flex-wrap: wrap; font-size: 16px; }
.topbar nav a, .tabs a {
  padding: 9px 16px; border-radius: 999px; color: var(--muted); text-decoration: none; font-weight: 550;
  transition: background 0.15s, color 0.15s;
}
.topbar nav a:hover, .tabs a:hover { color: var(--ink); background: var(--panel); }
.topbar nav a.on, .tabs a.on {
  color: #fff;
  background: linear-gradient(135deg, rgba(255, 179, 71, 0.3), rgba(240, 124, 30, 0.34) 55%, rgba(143, 227, 107, 0.24));
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.16), 0 6px 18px rgba(240, 124, 30, 0.25);
}
.tabs { display: flex; gap: 4px; flex-wrap: wrap; }

.platform-chips { display: flex; gap: 8px; }
.chip {
  width: 44px; height: 44px; border-radius: 14px; display: grid; place-items: center; color: #fff;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.2); transition: transform 0.15s, box-shadow 0.15s;
}
.chip svg { width: 22px; height: 22px; }
.chip:hover { color: #fff; transform: translateY(-2px); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.3), 0 8px 20px rgba(240, 124, 30, 0.4); }
.chip.on { outline: 2px solid #fff; outline-offset: 2px; }
.youtube.chip, .platform-mark.youtube, .platform-switch a.youtube.on { background: var(--youtube); }
.instagram.chip, .platform-mark.instagram, .platform-switch a.instagram.on { background: var(--instagram); }
.facebook.chip, .platform-mark.facebook, .platform-switch a.facebook.on { background: var(--facebook); }
.tiktok.chip, .platform-mark.tiktok, .platform-switch a.tiktok.on { background: var(--tiktok); }

/* ---- layout ---- */
main { max-width: 1240px; margin: 0 auto; padding: 28px 28px 72px; }
h1 { font-size: 30px; font-weight: 750; margin: 0; letter-spacing: -0.02em; line-height: 1.15; }
h2 { font-size: 15px; font-weight: 650; margin: 0 0 12px; display: flex; align-items: center; gap: 8px; }
.page-head { display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; margin-bottom: 20px; }
.lead { margin: -6px 0 16px; }

.panel, .stat, .media-card, .task, .platform-tile {
  background: var(--glass);
  border: 1px solid var(--line);
  box-shadow: var(--shadow), inset 0 1px 0 rgba(255, 255, 255, 0.07);
  backdrop-filter: blur(18px) saturate(140%); -webkit-backdrop-filter: blur(18px) saturate(140%);
}
.panel { position: relative; border-radius: var(--radius); padding: 20px 22px; margin-bottom: 18px; }
.panel.urgent { border-color: rgba(255, 179, 71, 0.5); box-shadow: var(--shadow), 0 0 0 3px rgba(255, 179, 71, 0.14); }
.columns { display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 1fr); gap: 18px; }
.columns.even { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }

/* ---- stats ---- */
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); gap: 14px; margin-bottom: 18px; }
.stat { position: relative; overflow: hidden; border-radius: 20px; padding: 18px 20px 16px; display: flex; flex-direction: column; }
.stat::before { content: ""; position: absolute; inset: 0 0 auto 0; height: 3px; background: var(--glow); }
.stats .stat:nth-child(4n+2)::before { background: linear-gradient(90deg, var(--lime), #5fd38a); }
.stats .stat:nth-child(4n+3)::before { background: linear-gradient(90deg, #ffb86b, #f07c1e); }
.stats .stat:nth-child(4n+4)::before { background: linear-gradient(90deg, var(--lime), #ffb347); }
.stat .label { color: var(--muted); font-size: 13px; }
.stat strong { font-size: 32px; font-weight: 750; line-height: 1.2; margin: 4px 0; letter-spacing: -0.02em; font-variant-numeric: tabular-nums; }
.sub, .meta, .hint { color: var(--muted); font-size: 13px; }

/* ---- platform tiles and pages ---- */
.platform-tiles { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; margin-bottom: 18px; }
.platform-tile {
  display: grid; grid-template-columns: auto 1fr; grid-template-rows: auto auto auto; column-gap: 12px;
  align-items: center; padding: 16px 18px; border-radius: 20px; color: var(--ink); text-decoration: none;
  transition: transform 0.15s, box-shadow 0.15s, border-color 0.15s;
}
.platform-tile:hover { color: var(--ink); transform: translateY(-3px); border-color: var(--line-strong); box-shadow: var(--shadow), 0 10px 30px rgba(240, 124, 30, 0.3); }
.platform-tile .platform-mark { grid-row: 1 / span 3; }
.platform-tile .tile-name { font-weight: 650; }
.platform-tile strong { font-size: 24px; font-weight: 750; line-height: 1.2; font-variant-numeric: tabular-nums; }
.platform-mark {
  width: 48px; height: 48px; border-radius: 15px; display: grid; place-items: center; color: #fff; flex: none;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.22), 0 8px 22px rgba(0, 0, 0, 0.3);
}
.platform-mark svg { width: 24px; height: 24px; }
.platform-head .platform-title { display: flex; align-items: center; gap: 14px; }
.platform-head .platform-mark { width: 56px; height: 56px; border-radius: 18px; }
.platform-head .platform-mark svg { width: 28px; height: 28px; }
.platform-switch { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 20px; }
.platform-switch a {
  display: inline-flex; align-items: center; gap: 8px; padding: 7px 14px 7px 10px; border-radius: 999px;
  color: var(--soft); text-decoration: none; font-weight: 600; background: var(--panel); border: 1px solid var(--line);
}
.platform-switch a:hover { color: #fff; border-color: var(--line-strong); }
.platform-switch a.on { color: #fff; border-color: transparent; box-shadow: 0 8px 22px rgba(240, 124, 30, 0.3); }
.platform-switch svg { width: 18px; height: 18px; }
.table .video-title { color: var(--ink); text-decoration: none; font-weight: 550; overflow-wrap: anywhere; }
.table .video-title:hover { color: var(--link); text-decoration: underline; }

/* ---- posts ---- */
.post { display: flex; gap: 12px; align-items: flex-start; padding: 12px 0; border-top: 1px solid var(--line); }
.panel h2 + .post { border-top: 0; padding-top: 0; }
.post-main { flex: 1; min-width: 0; }
.post-title { display: block; font-weight: 600; color: var(--ink); text-decoration: none; overflow-wrap: anywhere; }
.post-title:hover { color: var(--link); text-decoration: underline; }
.actions, .task-actions, .row-actions, .form-actions { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.actions form, .task-actions form, .row-actions form { margin: 0; }
.row-actions { padding: 12px 20px; }

.pill {
  display: inline-block; font-size: 12px; font-weight: 650; padding: 2px 10px; border-radius: 999px; color: #fff;
  white-space: nowrap; text-decoration: none; text-shadow: 0 1px 2px rgba(0, 0, 0, 0.25);
}
a.pill:hover { color: #fff; filter: brightness(1.12); }
.pill.youtube { background: var(--youtube); }
.pill.instagram { background: var(--instagram); }
.pill.facebook { background: var(--facebook); }
.pill.tiktok { background: var(--tiktok); }
.pill.all { background: var(--glow); }
.count { background: rgba(255, 255, 255, 0.1); color: var(--soft); font-weight: 550; font-size: 12px; padding: 1px 9px; border-radius: 999px; }

/* ---- buttons ---- */
.button {
  display: inline-flex; align-items: center; justify-content: center; white-space: nowrap;
  border: 1px solid var(--line-strong); background: rgba(255, 255, 255, 0.06); color: var(--ink);
  padding: 8px 16px; border-radius: 999px; font: inherit; font-size: 14px; font-weight: 550; cursor: pointer; text-decoration: none;
  transition: background 0.15s, border-color 0.15s, filter 0.15s;
}
.button:hover { color: #fff; background: rgba(255, 255, 255, 0.12); border-color: rgba(255, 255, 255, 0.32); }
.button.primary { background: var(--glow); border-color: transparent; color: #fff; font-weight: 650; box-shadow: 0 8px 22px rgba(240, 124, 30, 0.4); }
.button.primary:hover { filter: brightness(1.1); }
.button.danger { color: var(--error-ink); border-color: var(--error-line); }
.button.small { padding: 3px 10px; font-size: 13px; }
fieldset[disabled] .button { opacity: 0.5; cursor: not-allowed; }

/* ---- messages ---- */
.banner {
  padding: 12px 16px; border-radius: 16px; margin-bottom: 18px; color: var(--soft);
  background: rgba(240, 124, 30, 0.12); border: 1px solid rgba(240, 124, 30, 0.35);
}
.banner.warn { background: var(--warn-bg); border-color: var(--warn-line); color: var(--warn-ink); }
.banner.error { background: var(--error-bg); border-color: var(--error-line); color: var(--error-ink); }
.banner.ok { background: var(--ok-bg); border-color: var(--ok-line); color: var(--ok-ink); }
.banner a { color: #fff; }
.banner ul { margin: 0; padding-left: 18px; }
.error { color: var(--error-ink); font-size: 13px; }
.empty { color: var(--muted); margin: 0; }
.checklist { padding-left: 20px; color: var(--soft); }

/* ---- account and sign in ---- */
.account { display: flex; align-items: center; gap: 12px; font-size: 13px; }
.account form { margin: 0; }
.account a, .link-button { color: var(--muted); text-decoration: none; }
.account a:hover, .account a.on, .link-button:hover { color: var(--ink); }
.link-button { background: none; border: 0; padding: 0; font: inherit; cursor: pointer; }
.auth-main { min-height: 100vh; display: grid; place-items: center; padding: 24px 16px; }
.auth-card { width: 100%; max-width: 400px; margin: 0; }
.auth-logo { display: block; width: 100%; max-width: 280px; height: auto; margin: 0 auto 18px; }
.auth-card h1 { font-size: 22px; margin-bottom: 14px; text-align: center; }
.auth-card .button { width: 100%; }

/* ---- forms ---- */
.form label { display: block; font-weight: 600; font-size: 14px; margin-bottom: 14px; }
.form .hint { font-weight: 400; margin-left: 6px; }
.form input:not([type=file]):not([type=hidden]):not([type=checkbox]):not([type=radio]), .form select, .form textarea {
  display: block; width: 100%; margin-top: 6px; padding: 10px 12px;
  border: 1px solid var(--line-strong); border-radius: 12px; font: inherit; background: rgba(12, 7, 3, 0.45); color: var(--ink);
}
.form input:focus, .form select:focus, .form textarea:focus { outline: 2px solid var(--accent); outline-offset: -1px; }
.form input[type=file] { display: block; margin-top: 6px; font-weight: 400; max-width: 100%; color: var(--soft); }
.form ::placeholder { color: #7d74a6; font-weight: 400; }
.form fieldset { border: 0; padding: 0; margin: 0; min-width: 0; }
.form p.hint { margin: -4px 0 12px; }
input[type=checkbox], input[type=radio] { accent-color: var(--accent); }

/* ---- charts and tables ---- */
.chart { display: block; width: 100%; height: 180px; }
.chart rect { fill: url(#bar-glow); }
.chart rect:hover { fill: var(--lime); }
.chart-axis { display: flex; justify-content: space-between; gap: 8px; color: var(--muted); font-size: 12px; margin-top: 6px; }

.table-wrap { overflow-x: auto; }
.table { width: 100%; border-collapse: collapse; font-size: 14px; }
.table th, .table td { text-align: left; padding: 9px 10px; border-top: 1px solid var(--line); vertical-align: top; }
.table th { color: var(--muted); font-weight: 550; font-size: 12px; text-transform: uppercase; letter-spacing: 0.05em; border-top: 0; }
.table .num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }

/* ---- plan ---- */
.board { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; margin-bottom: 18px; }
.column { margin: 0; }
.task { border-radius: 14px; padding: 10px 12px; margin-bottom: 10px; box-shadow: none; }
.task-title { font-weight: 600; overflow-wrap: anywhere; }
.notes { margin: 6px 0 0; font-size: 13px; white-space: pre-wrap; color: var(--soft); }
.task-actions { margin-top: 8px; }
.task-line { display: flex; justify-content: space-between; gap: 10px; padding: 7px 0; border-top: 1px solid var(--line); }
.panel h2 + .task-line { border-top: 0; }
.progress { height: 10px; background: rgba(255, 255, 255, 0.08); border-radius: 999px; overflow: hidden; margin-bottom: 18px; }
.progress span { display: block; height: 100%; background: var(--glow); border-radius: 999px; box-shadow: 0 0 14px rgba(255, 179, 71, 0.5); }

.platforms { list-style: none; margin: 0; padding: 0; }
.platforms li { display: flex; gap: 10px; align-items: center; padding: 7px 0; color: var(--muted); font-size: 14px; }

/* ---- uploads ---- */
.field { margin-bottom: 14px; }
.field-label { display: block; font-weight: 600; font-size: 14px; }
.form label.inline { margin: 10px 0 0; font-weight: 400; font-size: 13px; color: var(--muted); }
.dropzone {
  position: relative; margin-top: 6px; padding: 22px; text-align: center; color: var(--soft);
  border: 2px dashed rgba(255, 255, 255, 0.22); border-radius: 18px; background: rgba(255, 255, 255, 0.03);
  transition: border-color 0.15s, background 0.15s;
}
.dropzone.large { padding: 48px 22px; }
.dropzone.over { border-color: var(--accent); background: rgba(240, 124, 30, 0.14); }
.dropzone:hover { border-color: rgba(255, 255, 255, 0.36); }
.form .dropzone input[type=file], .dropzone input[type=file] {
  position: absolute; inset: 0; width: 100%; height: 100%; margin: 0; opacity: 0; cursor: pointer;
}
.dropzone-text { pointer-events: none; font-weight: 400; }
.link { color: var(--link); text-decoration: underline; }
.upload-list { position: relative; z-index: 1; text-align: left; }
.upload-list:not(:empty) { margin-top: 16px; }
.upload-row { display: grid; grid-template-columns: minmax(0, 1fr) minmax(80px, 180px) 56px; gap: 10px; align-items: center; padding: 6px 0; font-size: 14px; }
.upload-row .name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.upload-row .pct { text-align: right; }
.upload-row.failed .pct { color: var(--error-ink); }
.upload-progress { height: 6px; background: rgba(255, 255, 255, 0.1); border-radius: 999px; overflow: hidden; }
.upload-progress span { display: block; height: 100%; width: 0; background: var(--glow); transition: width 0.2s; }
.dropzone > .upload-progress { position: relative; z-index: 1; max-width: 360px; margin: 12px auto 0; }
.upload-status { position: relative; z-index: 1; margin-top: 6px; }
.upload-status:empty { display: none; }
.media-preview video, .media-preview img { display: block; max-width: 100%; max-height: 320px; margin-top: 12px; border-radius: 14px; background: #0b0703; }

.library { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 14px; }
.media-card { display: flex; flex-direction: column; min-width: 0; border-radius: 18px; overflow: hidden; }
.thumb { display: flex; align-items: center; justify-content: center; aspect-ratio: 16 / 9; max-width: 100%; background: #0b0703; }
.thumb video, .thumb img { display: block; width: 100%; height: 100%; }
.thumb video { object-fit: contain; }
.thumb img { object-fit: cover; }
.media-info { display: flex; flex-direction: column; gap: 4px; min-width: 0; padding: 10px 12px 12px; }
.media-info .post-title { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.media-info .actions { margin-top: 6px; }

.form-row { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 14px; }
h2 .more { margin-left: auto; font-size: 13px; font-weight: 500; }

/* ---- next moves ---- */
.badge { font-size: 12px; font-weight: 650; padding: 2px 10px; border-radius: 999px; white-space: nowrap; }
.badge.p1 { background: rgba(255, 79, 138, 0.18); color: #ff9ac0; box-shadow: inset 0 0 0 1px rgba(255, 79, 138, 0.35); }
.badge.p2 { background: rgba(255, 200, 97, 0.14); color: #ffd68a; box-shadow: inset 0 0 0 1px rgba(255, 200, 97, 0.3); }
.badge.p3 { background: rgba(79, 227, 161, 0.12); color: #8ff0c2; box-shadow: inset 0 0 0 1px rgba(79, 227, 161, 0.3); }
.source { margin-left: auto; color: var(--muted); font-size: 12px; white-space: nowrap; }
.move { padding: 14px 0; border-top: 1px solid var(--line); }
.panel h2 + .move { border-top: 0; padding-top: 2px; }
.move-head { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.move-title { font-weight: 650; font-size: 16px; margin: 6px 0 2px; overflow-wrap: anywhere; }
.move-why { margin: 0; color: var(--soft); font-size: 14px; }

.goal-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 18px; flex-wrap: wrap; margin-bottom: 12px; }
.goal .label { display: block; color: var(--muted); font-size: 13px; }
.goal-head strong { display: block; font-size: 32px; font-weight: 750; line-height: 1.2; letter-spacing: -0.02em; font-variant-numeric: tabular-nums; }
.goal .of { font-size: 16px; font-weight: 500; color: var(--muted); letter-spacing: 0; }
.goal-math { display: flex; gap: 28px; }
.goal-math strong { font-size: 22px; }
.goal .progress, aside .progress { margin-bottom: 10px; }
.goal-note { margin: 0; font-size: 14px; color: var(--soft); }
.goal-split { display: flex; gap: 8px 18px; flex-wrap: wrap; margin-top: 12px; font-size: 14px; }

.section-title { font-size: 18px; margin: 6px 0 12px; }
.scorecards { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 14px; margin-bottom: 18px; }
.scorecard { margin: 0; }
.metrics td { padding: 8px 6px; }
.metrics .target { color: var(--muted); font-size: 12px; text-align: right; white-space: nowrap; }
.dot { display: inline-block; width: 8px; height: 8px; margin-right: 8px; border-radius: 50%; background: rgba(255, 255, 255, 0.25); vertical-align: 1px; }
.dot.good { background: #4fe3a1; box-shadow: 0 0 8px rgba(79, 227, 161, 0.7); }
.dot.watch { background: #ffc861; box-shadow: 0 0 8px rgba(255, 200, 97, 0.6); }
.dot.bad { background: #ff5a82; box-shadow: 0 0 8px rgba(255, 90, 130, 0.7); }
.dot.info { visibility: hidden; }
.playbook dl { margin: 0; }
.playbook dt { display: flex; gap: 8px; align-items: baseline; margin-top: 14px; font-weight: 600; }
.playbook dt .source { margin-left: 0; }
.playbook dd { margin: 2px 0 0; color: var(--soft); font-size: 14px; }

.trend h2 .meta { margin-left: auto; font-weight: 500; }
.trend-video { margin: 0 0 8px; color: var(--muted); font-size: 14px; }
.trend-tips { list-style: none; margin: 12px 0 0; padding: 0; }
.trend-tips li { padding: 10px 0; border-top: 1px solid var(--line); }
.trend-tips li strong { margin-right: 4px; }
.trend-tips .meta { display: block; margin-top: 3px; color: var(--soft); font-size: 14px; }

@media (max-width: 1000px) {
  .platform-tiles { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 860px) {
  .columns, .columns.even, .board, .form-row { grid-template-columns: minmax(0, 1fr); }
  .topbar, main { padding-left: 16px; padding-right: 16px; }
  .brand img { height: 64px; }
  .post { flex-wrap: wrap; }
}
@media (max-width: 480px) {
  .platform-tiles { grid-template-columns: minmax(0, 1fr); }
}

/* ---- Facebook personal profile panel (platform page) ---- */
.personal-profile h2 .meta { font-weight: 500; }
.profile-numbers { display: grid; grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)); gap: 12px 18px; margin-bottom: 12px; }
.profile-numbers > div { display: flex; flex-direction: column; min-width: 0; padding-top: 10px; border-top: 1px solid var(--line); }
.profile-numbers .label { color: var(--muted); font-size: 13px; }
.profile-numbers strong { font-size: 24px; font-weight: 750; line-height: 1.2; letter-spacing: -0.02em; font-variant-numeric: tabular-nums; }
.profile-top { margin: 0 0 8px; color: var(--soft); font-size: 14px; overflow-wrap: anywhere; }
.personal-profile .hint { margin: 4px 0 0; }

/* ==== content calendar (/calendar) ==== */
.cal-controls { display: flex; gap: 10px 14px; align-items: center; flex-wrap: wrap; }
.cal-nav { display: flex; gap: 6px; }
.cal-hint { margin: -10px 0 14px; }
.cal { padding: 14px; }
.cal-weekdays, .cal-grid { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 6px; }
.cal-weekdays span {
  padding: 0 8px 6px; color: var(--muted); font-size: 12px; font-weight: 550; text-transform: uppercase; letter-spacing: 0.05em;
}
.cal-day {
  position: relative; min-width: 0; min-height: 118px; padding: 6px; border-radius: 14px; cursor: pointer;
  background: rgba(255, 255, 255, 0.03); border: 1px solid var(--line); transition: background 0.15s, border-color 0.15s;
}
.cal-week .cal-day { min-height: 340px; }
.cal-day:hover { background: rgba(255, 255, 255, 0.06); border-color: var(--line-strong); }
.cal-day.past { background: rgba(0, 0, 0, 0.14); }
.cal-day.other { background: transparent; border-color: rgba(255, 255, 255, 0.05); }
.cal-day.today {
  background: rgba(240, 124, 30, 0.14); border-color: transparent;
  box-shadow: inset 0 0 0 1.5px rgba(205, 180, 255, 0.75), 0 0 22px rgba(240, 124, 30, 0.3);
}
.cal-day.drop-target { background: rgba(240, 124, 30, 0.24); border-color: var(--accent); border-style: dashed; }
.cal-day-head { display: flex; align-items: center; gap: 6px; margin-bottom: 4px; }
.cal-num {
  display: inline-grid; place-items: center; min-width: 24px; height: 24px; padding: 0 6px; border-radius: 999px;
  color: var(--soft); font-size: 13px; font-weight: 650; font-variant-numeric: tabular-nums;
}
.cal-day.other .cal-num { color: var(--muted); font-weight: 500; }
.cal-day.today .cal-num { background: var(--glow); color: #fff; box-shadow: 0 4px 14px rgba(240, 124, 30, 0.45); }
.cal-long { display: none; color: var(--soft); font-weight: 650; font-size: 14px; }
.cal-day.today .cal-long { color: #fff; }
.cal-day.today .cal-long::after { content: " · Today"; color: var(--link); font-weight: 550; }
.cal-add {
  display: grid; place-items: center; width: 22px; height: 22px; margin-left: auto; border-radius: 8px;
  color: var(--muted); font-weight: 650; text-decoration: none; opacity: 0; transition: opacity 0.15s, background 0.15s;
}
.cal-day:hover .cal-add, .cal-add:focus-visible { opacity: 1; }
.cal-add:hover { color: #fff; background: var(--panel-strong); }
.cal-posts { display: flex; flex-direction: column; gap: 4px; }
.cal-chip.pill {
  display: flex; align-items: center; gap: 5px; width: 100%; min-width: 0; padding: 3px 7px; border-radius: 8px;
  font-size: 12px; line-height: 1.3; cursor: pointer; box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.14);
}
.cal-chip[draggable="true"] { cursor: grab; }
.cal-chip.dragging { opacity: 0.4; }
.cal-chip.saving { opacity: 0.6; pointer-events: none; }
.cal-time { flex: none; font-weight: 700; font-variant-numeric: tabular-nums; }
.cal-time:empty { display: none; }
.cal-snippet { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 550; }
.cal-week .cal-chip.pill { flex-wrap: wrap; row-gap: 1px; padding: 5px 8px; }
.cal-week .cal-snippet {
  flex-basis: 100%; white-space: normal; overflow-wrap: anywhere;
  display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical;
}
.cal-flag {
  flex: none; display: grid; place-items: center; width: 14px; height: 14px; border-radius: 50%;
  background: rgba(20, 11, 5, 0.85); color: var(--error-ink); font-size: 10px; font-weight: 800; text-shadow: none;
  box-shadow: 0 0 0 1px var(--error-line);
}
.cal-chip[data-status="due"] .cal-flag { color: var(--warn-ink); box-shadow: 0 0 0 1px var(--warn-line); }
.cal-chip.alert { box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.5); }
.cal-tray .meta { margin: -6px 0 10px; }
.cal-tray-list { display: flex; flex-wrap: wrap; gap: 6px; }
.cal-tray-list:empty { display: none; }
.cal-tray-list .cal-chip.pill { width: auto; max-width: 300px; }

@media (max-width: 700px) {
  .cal { padding: 10px; }
  .cal-weekdays { display: none; }
  .cal-grid {
    position: relative; grid-template-columns: minmax(0, 1fr); max-height: 72vh; overflow-y: auto;
    overscroll-behavior: contain; padding: 1px;
  }
  .cal-day, .cal-week .cal-day { min-height: 0; padding: 8px 10px; }
  .cal-month .cal-day.other { display: none; }
  .cal-num { display: none; }
  .cal-long { display: inline; }
  .cal-add { opacity: 1; }
  .cal-day.empty .cal-day-head { margin-bottom: 0; }
  .cal-day.empty .cal-posts { display: none; }
  .cal-chip.pill { padding: 5px 8px; font-size: 13px; }
}

/* ---- best times to post (platform pages and the post form) ---- */
.best-times h2 .count { margin-left: auto; }
.best-times-list { list-style: none; margin: 0 0 12px; padding: 0; counter-reset: best-time; }
.best-times-list li {
  display: flex; flex-wrap: wrap; align-items: center; gap: 2px 8px; padding: 9px 0;
  border-top: 1px solid var(--line); color: var(--soft); font-size: 14px;
}
.best-times-list li:first-child { border-top: 0; padding-top: 2px; }
.best-times-list li::before {
  counter-increment: best-time; content: counter(best-time);
  display: inline-grid; place-items: center; width: 22px; height: 22px; border-radius: 999px;
  background: var(--glow); color: #fff; font-size: 12px; font-weight: 700;
}
.best-times.default .best-times-list li::before { background: var(--panel-strong); color: var(--soft); box-shadow: inset 0 0 0 1px var(--line-strong); }
.best-times-list strong { color: var(--ink); font-weight: 650; }
.best-times p.meta { margin: 0; }
.best-times-suggest { margin: -6px 0 14px; }
.best-times-line { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 8px; }
.best-times-line[hidden] { display: none; }
.form .best-times-line .hint { margin-left: 0; }
.best-times-line .button.on { border-color: var(--accent); background: rgba(240, 124, 30, 0.24); color: #fff; }

/* ---- inbox (comments on recent posts) ---- */
.nav-count {
  display: inline-block; min-width: 20px; margin-left: 4px; padding: 0 6px; border-radius: 999px;
  background: var(--glow); color: #fff; font-size: 11px; font-weight: 700; line-height: 18px; text-align: center;
  box-shadow: 0 0 10px rgba(255, 179, 71, 0.45);
}
.platform-switch a.all.on { background: var(--glow); }
.platform-switch .count { margin-left: 2px; }
.inbox-tabs { margin-bottom: 14px; }
.comment { padding: 16px 0; border-top: 1px solid var(--line); }
.comment:first-child { border-top: 0; padding-top: 0; }
.comment-head { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; margin-bottom: 4px; }
.comment-head .post-title { min-width: 0; }
.comment-author { color: var(--soft); font-weight: 650; }
.comment-text { margin: 8px 0 12px; white-space: pre-wrap; overflow-wrap: anywhere; }
.comment-actions { display: flex; gap: 10px; align-items: flex-end; flex-wrap: wrap; }
.comment-actions form { margin: 0; }
.reply-form { flex: 1; min-width: min(100%, 260px); display: flex; gap: 8px; align-items: flex-end; }
.form.reply-form textarea { flex: 1; margin-top: 0; min-height: 44px; resize: vertical; }
.inbox-note { margin: 0; }
