/* likes.php: likes viewer. White cards on the site's blue background, the same card
   language as the label checker report. Likes accent is Bluesky-ish pink-red. */

.lk-report {
    --lk-accent: #ec4899;
    --lk-blue: #0a7afc;
    --lk-muted: #7a8496;
    --lk-ink: #26303f;
    --lk-line: #e8ecf2;
    --lk-soft: #f6f8fc;

    display: flex;
    flex-direction: column;
    gap: 16px;
    margin-bottom: 24px;
    color: var(--lk-ink);
}

.lk-report:empty { display: none; }

/* --- Intro card: mode tabs, hint, teaser --- */

.lk-modes {
    display: flex;
    gap: 8px;
    margin: 4px 0 14px;
    flex-wrap: wrap;
}

.lk-mode {
    padding: 8px 14px;
    border-radius: 999px;
    border: 1px solid #d5dce8;
    background: #fff;
    color: #4a5568;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
}

.lk-mode.active {
    background: #0a7afc;
    border-color: #0a7afc;
    color: #fff;
}

.lk-soon {
    margin-left: 4px;
    padding: 1px 7px;
    border-radius: 999px;
    background: #fde68a;
    color: #7a5b00;
    font-size: 10px;
    font-weight: 700;
    vertical-align: 1px;
}

.lk-hint {
    margin: 10px 0 0;
    font-size: 13px;
    color: #7a8496;
}

.lk-teaser {
    padding: 16px;
    border-radius: 12px;
    background: #f2f6ff;
    color: #26303f;
}

.lk-teaser p { margin: 6px 0 0; font-size: 14px; line-height: 1.6; color: #4a5568; }

/* --- Cards --- */

.lk-card {
    background: #fff;
    border-radius: 14px;
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.08);
    padding: 20px 22px;
    min-width: 0;
}

.lk-title {
    margin: 0 0 4px;
    font-size: 17px;
    font-weight: 700;
}

.lk-subtitle {
    margin: 0 0 10px;
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--lk-muted);
}

.lk-sub {
    margin: 0 0 14px;
    font-size: 13px;
    color: var(--lk-muted);
}

.lk-empty, .lk-note {
    margin: 8px 0 0;
    font-size: 13px;
    color: var(--lk-muted);
}

.lk-avatar {
    flex: 0 0 auto;
    border-radius: 50%;
    object-fit: cover;
    background: #e8ecf2;
    display: block;
}

.lk-avatar-empty {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: var(--lk-blue);
    color: #fff;
    font-weight: 700;
}

.lk-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 8px 14px;
    border-radius: 999px;
    font-size: 13px;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
    white-space: nowrap;
    border: 1px solid transparent;
}

.lk-btn-ghost { background: #fff; border-color: #d5dce8; color: #2f5fd0; }
.lk-btn-ghost:hover { background: #f2f6ff; }
.lk-btn-primary { background: var(--lk-blue); color: #fff; }
.lk-btn-primary:hover { background: #0862ca; }
.lk-btn-primary:disabled { background: #a9c3e8; cursor: default; }

.lk-loading {
    display: flex;
    align-items: center;
    gap: 16px;
}

.lk-loading .lk-sub { margin: 4px 0 0; }

.lk-spinner {
    flex: 0 0 28px;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    border: 3px solid #fde2ef;
    border-top-color: var(--lk-accent);
    animation: lk-spin 0.8s linear infinite;
}

@keyframes lk-spin { to { transform: rotate(360deg); } }

.lk-error { border-left: 5px solid #d23b3b; }
.lk-error .lk-sub { margin: 6px 0 0; }

/* --- Header --- */

.lk-head {
    display: flex;
    align-items: center;
    gap: 14px;
    flex-wrap: wrap;
    border-top: 5px solid var(--lk-accent);
}

.lk-head-id { flex: 1 1 200px; min-width: 0; }
.lk-head-name { font-size: 19px; font-weight: 800; overflow-wrap: anywhere; }
.lk-head-handle { font-size: 14px; color: #2f5fd0; text-decoration: none; }
.lk-head-handle:hover { text-decoration: underline; }
.lk-head-meta { margin-top: 3px; font-size: 12px; color: var(--lk-muted); }
.lk-head-actions { display: flex; gap: 8px; flex-wrap: wrap; }

/* --- Summary --- */

.lk-stats {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 10px;
    margin-bottom: 18px;
}

.lk-stat {
    display: flex;
    flex-direction: column;
    padding: 12px;
    border-radius: 10px;
    background: var(--lk-soft);
    text-align: center;
}

.lk-stat-value { font-size: 22px; font-weight: 800; color: var(--lk-ink); }
.lk-stat-label { font-size: 12px; color: var(--lk-muted); }

.lk-split {
    display: grid;
    grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr);
    gap: 24px;
}

.lk-top {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.lk-top-row {
    width: 100%;
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 6px 8px;
    border: 1px solid transparent;
    border-radius: 10px;
    background: none;
    font: inherit;
    color: inherit;
    text-align: left;
    cursor: pointer;
}

.lk-top-row:hover { background: var(--lk-soft); }
a.lk-top-row { text-decoration: none; }
.lk-top-row.active { background: #fdf0f6; border-color: #f9c4dd; }

.lk-top-text { flex: 1 1 auto; min-width: 0; display: flex; flex-direction: column; gap: 4px; }

.lk-top-name {
    font-size: 13px;
    font-weight: 600;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.lk-top-bar { height: 5px; border-radius: 999px; background: #f1f3f7; overflow: hidden; }
.lk-top-bar span { display: block; height: 100%; border-radius: 999px; background: var(--lk-accent); }
.lk-top-count { font-size: 13px; font-weight: 700; color: var(--lk-muted); }

.lk-hours {
    display: flex;
    align-items: flex-end;
    gap: 2px;
    height: 120px;
    padding: 8px;
    border-radius: 10px;
    background: var(--lk-soft);
}

.lk-hour {
    flex: 1 1 0;
    border-radius: 3px 3px 0 0;
    background: #f9a8d4;
}

.lk-hour-peak { background: var(--lk-accent); }

.lk-hours-axis {
    display: flex;
    justify-content: space-between;
    padding: 4px 8px 0;
    font-size: 11px;
    color: var(--lk-muted);
}

/* --- Feed --- */

.lk-feed-head {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 10px;
    flex-wrap: wrap;
    margin-bottom: 12px;
}

.lk-filter {
    font-size: 13px;
    color: #4a5568;
}

.lk-clear {
    margin-left: 6px;
    padding: 3px 10px;
    border-radius: 999px;
    border: 1px solid #f9c4dd;
    background: #fdf0f6;
    color: #be185d;
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
}

/* One column, like a timeline: posts differ a lot in height, and two columns left
   ragged gaps and made the newest-first order hard to follow. */
.lk-posts {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 12px;
    max-width: 680px;
    margin: 0 auto;
}

.lk-feed-status,
.lk-more {
    max-width: 680px;
    margin-left: auto;
    margin-right: auto;
}

.lk-more { display: flex; }

.lk-post {
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding: 14px;
    border: 1px solid var(--lk-line);
    border-radius: 12px;
    background: #fff;
    min-width: 0;
}

.lk-post-head { display: flex; gap: 10px; align-items: center; min-width: 0; }
.lk-post-who { display: flex; flex-direction: column; min-width: 0; }

.lk-post-name {
    font-size: 14px;
    font-weight: 700;
    color: var(--lk-ink);
    text-decoration: none;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.lk-post-name:hover { text-decoration: underline; }

.lk-post-handle {
    font-size: 12px;
    color: var(--lk-muted);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.lk-tag {
    padding: 0 6px;
    border-radius: 999px;
    background: #eef0f3;
    color: #4a5568;
    font-size: 11px;
}

.lk-post-text {
    margin: 0;
    font-size: 14px;
    line-height: 1.5;
    white-space: pre-wrap;
    overflow-wrap: anywhere;
}

.lk-media { position: relative; border-radius: 10px; overflow: hidden; }

.lk-images { display: grid; gap: 3px; }
.lk-images-1 { grid-template-columns: 1fr; }
.lk-images-2, .lk-images-4 { grid-template-columns: 1fr 1fr; }
.lk-images-3 { grid-template-columns: 2fr 1fr; }
.lk-images-3 img:first-child { grid-row: span 2; }

.lk-images img, .lk-video img {
    display: block;
    width: 100%;
    height: 100%;
    max-height: 260px;
    object-fit: cover;
    background: #e8ecf2;
}

.lk-images-2 img, .lk-images-3 img, .lk-images-4 img { aspect-ratio: 1; }

.lk-video { position: relative; }

.lk-play {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 44px;
    height: 44px;
    margin: -22px 0 0 -22px;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.6);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
}

.lk-blur img { filter: blur(22px); transform: scale(1.1); }

.lk-reveal {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    padding: 8px 14px;
    border-radius: 999px;
    border: none;
    background: rgba(0, 0, 0, 0.7);
    color: #fff;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
}

.lk-link {
    display: flex;
    gap: 10px;
    align-items: center;
    padding: 8px;
    border: 1px solid var(--lk-line);
    border-radius: 10px;
    color: inherit;
    text-decoration: none;
    min-width: 0;
}

.lk-link img { width: 64px; height: 64px; border-radius: 8px; object-fit: cover; flex: 0 0 auto; }
.lk-link span { display: flex; flex-direction: column; min-width: 0; }
.lk-link strong { font-size: 13px; overflow: hidden; text-overflow: ellipsis; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.lk-link em { font-size: 12px; font-style: normal; color: var(--lk-muted); }

.lk-quote {
    margin: 0;
    padding: 8px 10px;
    border-left: 3px solid #d5dce8;
    border-radius: 0 8px 8px 0;
    background: var(--lk-soft);
    font-size: 13px;
    color: #4a5568;
    overflow-wrap: anywhere;
}

.lk-post-foot {
    display: flex;
    align-items: center;
    gap: 6px 12px;
    flex-wrap: wrap;
    padding-top: 8px;
    border-top: 1px solid var(--lk-line);
    font-size: 12px;
    color: var(--lk-muted);
}

.lk-liked { color: #be185d; font-weight: 600; }
.lk-open { margin-left: auto; color: #2f5fd0; text-decoration: none; font-weight: 600; }
.lk-open:hover { text-decoration: underline; }

.lk-feed-status:empty { display: none; }
.lk-more { margin-top: 14px; }
.lk-more[hidden] { display: none; }
.lk-sentinel { height: 1px; }

/* --- Who liked a post --- */

.lk-likers {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 10px;
}

.lk-liker {
    display: flex;
    gap: 10px;
    padding: 12px;
    border: 1px solid var(--lk-line);
    border-radius: 12px;
    min-width: 0;
}

.lk-liker-text { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.lk-liker-name { font-size: 14px; font-weight: 700; color: var(--lk-ink); text-decoration: none; overflow-wrap: anywhere; }
.lk-liker-name:hover { text-decoration: underline; }
.lk-liker-handle { font-size: 12px; color: var(--lk-muted); overflow-wrap: anywhere; }
.lk-liker-bio { font-size: 12px; color: #4a5568; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.lk-liker-more { margin-top: 4px; font-size: 12px; font-weight: 600; color: #be185d; text-decoration: none; }

/* --- Phones --- */

@media (max-width: 768px) {
    .lk-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .lk-split { grid-template-columns: 1fr; gap: 18px; }
}

@media (max-width: 576px) {
    .lk-report { gap: 12px; }
    .lk-card { padding: 16px; }
    .lk-head-actions { width: 100%; }
    .lk-head-actions .lk-btn { flex: 1 1 0; }
    .lk-stat-value { font-size: 19px; }
    .lk-likers { grid-template-columns: 1fr; }
}

/* --- Likes received: engagement report (engagement_report.js) --- */

.lk-head-eng { border-top-color: #0a7afc; }

.lk-stats-cards { margin: 0; }

.lk-stats-cards .lk-stat {
    background: #fff;
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.08);
    border-radius: 12px;
    padding: 14px 12px;
}

.lk-chip {
    display: inline-block;
    padding: 2px 9px;
    border-radius: 999px;
    background: #eef0f3;
    color: #4a5568;
    font-size: 11px;
    font-weight: 600;
    white-space: nowrap;
}

.lk-chip-strong   { background: #e8f7ef; color: #1f7a4d; }
.lk-chip-moderate { background: #fff3df; color: #8a5600; }

/* Recommendations */

.lk-recs-card { border-top: 5px solid #1f9d61; }

.lk-recs {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.lk-rec {
    display: flex;
    gap: 14px;
    padding: 14px;
    border: 1px solid var(--lk-line);
    border-radius: 12px;
    background: #fbfcfe;
}

.lk-rec-num {
    flex: 0 0 30px;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: #0a7afc;
    color: #fff;
    font-weight: 800;
}

.lk-rec-body { min-width: 0; }

.lk-rec-top {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.lk-rec-icon { font-size: 18px; }
.lk-rec-title { font-size: 16px; }

.lk-rec-detail {
    margin: 6px 0 0;
    font-size: 14px;
    line-height: 1.55;
    color: #34404f;
}

.lk-rec-evidence {
    margin: 4px 0 0;
    font-size: 12px;
    color: var(--lk-muted);
}

/* Trend */

.lk-trend-change { margin: 0 0 12px; font-weight: 700; font-size: 15px; }
.lk-trend-change span { font-weight: 400; font-size: 12px; color: var(--lk-muted); margin-left: 4px; }
.lk-trend-up   { color: #1f7a4d; }
.lk-trend-down { color: #b42318; }
.lk-trend-flat { color: #4a5568; }

.lk-trend {
    display: flex;
    align-items: flex-end;
    gap: 6px;
    height: 170px;
    padding: 10px 8px 0;
    border-radius: 10px;
    background: var(--lk-soft);
    overflow-x: auto;
}

.lk-trend-col {
    flex: 1 0 34px;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    align-items: center;
    gap: 3px;
}

.lk-trend-val { font-size: 10px; color: var(--lk-muted); }

.lk-trend-bar {
    width: 70%;
    min-height: 3px;
    border-radius: 4px 4px 0 0;
    background: #0a7afc;
}

.lk-trend-col:last-child .lk-trend-bar { background: var(--lk-accent); }

.lk-trend-lbl {
    padding-bottom: 6px;
    font-size: 10px;
    color: var(--lk-muted);
    white-space: nowrap;
}

/* What works */

.lk-cmp-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 22px;
}

.lk-cmp-row {
    display: grid;
    grid-template-columns: 112px minmax(0, 1fr) 40px;
    grid-template-areas: "label bar value" "label n n";
    align-items: center;
    column-gap: 8px;
    padding: 5px 0;
}

.lk-cmp-few { opacity: 0.45; }
.lk-cmp-label { grid-area: label; font-size: 13px; }
.lk-cmp-bar { grid-area: bar; height: 9px; border-radius: 999px; background: #eef1f6; overflow: hidden; }
.lk-cmp-bar span { display: block; height: 100%; border-radius: 999px; background: #0a7afc; }
.lk-cmp-value { grid-area: value; font-size: 13px; font-weight: 700; text-align: right; }
.lk-cmp-n { grid-area: n; font-size: 11px; color: var(--lk-muted); }

/* Heatmap */

.lk-heat-wrap { overflow-x: auto; }

.lk-heat {
    display: grid;
    grid-template-columns: 38px repeat(8, minmax(34px, 1fr));
    gap: 4px;
    min-width: 330px;
}

.lk-heat-h, .lk-heat-d {
    font-size: 11px;
    color: var(--lk-muted);
    display: flex;
    align-items: center;
    justify-content: center;
}

.lk-heat-d { justify-content: flex-start; font-weight: 600; }

.lk-heat-c {
    height: 34px;
    border-radius: 6px;
    background: rgba(10, 122, 252, var(--lk-a, 0.1));
    color: #fff;
    font-size: 11px;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.25);
}

.lk-heat-empty { background: #f4f6fa; }
.lk-heat-best { outline: 3px solid var(--lk-accent); outline-offset: -1px; }

/* Like speed */

.lk-speed {
    display: flex;
    height: 16px;
    border-radius: 999px;
    overflow: hidden;
    background: #eef1f6;
}

.lk-speed span { display: block; height: 100%; }
.lk-speed-1     { background: #be185d; }
.lk-speed-3     { background: #ec4899; }
.lk-speed-24    { background: #f9a8d4; }
.lk-speed-later { background: #fde2ef; }

.lk-speed-legend {
    display: flex;
    flex-wrap: wrap;
    gap: 6px 16px;
    margin-top: 10px;
    font-size: 12px;
    color: #4a5568;
}

.lk-speed-legend i {
    display: inline-block;
    width: 10px;
    height: 10px;
    margin-right: 5px;
    border-radius: 3px;
    vertical-align: -1px;
}

/* Best posts */

.lk-best {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.lk-best-item {
    display: flex;
    gap: 12px;
    padding: 12px;
    border: 1px solid var(--lk-line);
    border-radius: 12px;
    min-width: 0;
}

.lk-best-thumb {
    flex: 0 0 72px;
    width: 72px;
    height: 72px;
    border-radius: 8px;
    object-fit: cover;
    background: #e8ecf2;
}

.lk-best-body { min-width: 0; flex: 1 1 auto; display: flex; flex-direction: column; gap: 6px; }
.lk-best-text { margin: 0; font-size: 14px; line-height: 1.45; overflow-wrap: anywhere; }
.lk-best-tags { display: flex; flex-wrap: wrap; gap: 4px; }
.lk-best-foot { display: flex; justify-content: space-between; gap: 8px; font-size: 12px; color: var(--lk-muted); }
.lk-best-foot a { color: #2f5fd0; font-weight: 600; text-decoration: none; }

.lk-method p {
    margin: 0;
    font-size: 13px;
    line-height: 1.6;
    color: #4a5568;
}

@media (max-width: 768px) {
    .lk-cmp-grid { grid-template-columns: 1fr; gap: 16px; }
}

@media (max-width: 576px) {
    .lk-rec { padding: 12px; gap: 10px; }
    .lk-rec-num { flex-basis: 26px; width: 26px; height: 26px; font-size: 13px; }
    .lk-rec-title { font-size: 15px; }
    .lk-best-thumb { flex-basis: 56px; width: 56px; height: 56px; }
    .lk-cmp-row { grid-template-columns: 100px minmax(0, 1fr) 36px; }
}
