:root{color-scheme:light;font-family:Inter,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;background:#f5f8f6;color:#1f3431}
*{box-sizing:border-box}
body{margin:0}
a{color:#176b62;text-underline-offset:3px}
.page{max-width:1060px;margin:auto;padding:0 clamp(18px,4vw,46px)}
.top{display:flex;align-items:center;justify-content:space-between;gap:16px;padding:26px 0;border-bottom:1px solid #d9e7e0}
.brand{font-size:16px;font-weight:800;letter-spacing:-.025em}.brand span{font-weight:500;color:#62766f}
.back{text-decoration:none;font-size:14px;font-weight:650}
.hero{padding:56px 0 28px;max-width:760px}
.eyebrow{font-size:11px;letter-spacing:.16em;font-weight:800;color:#32877a}
h1{font-size:clamp(30px,5.3vw,54px);line-height:1.08;letter-spacing:-.046em;margin:13px 0 20px}
.hero>p:last-child{font-size:clamp(16px,2vw,19px);line-height:1.65;color:#536c63}
.lookup,.editor,.panel{padding:26px;background:#fff;border:1px solid #dce8e3;border-radius:18px;box-shadow:0 7px 26px #16352909}
.lookup label,.editor label{display:block;font-size:13px;font-weight:750;margin-bottom:8px}
.inline{display:flex;gap:10px}
input:not([type=checkbox]),select,textarea{font:inherit;border:1px solid #bdd0c8;border-radius:10px;min-width:0;padding:13px 14px;background:white;color:#23342f}
input:focus,textarea:focus,select:focus,button:focus-visible{outline:3px solid #77b5a6;outline-offset:2px}
.inline input{flex:1}
button{font:inherit;border:0;border-radius:10px;background:#257f71;color:white;padding:13px 20px;font-weight:750;cursor:pointer}
button:hover{background:#176557}button:disabled{opacity:.52;cursor:not-allowed}
.feedback{min-height:22px;color:#9a403c;margin:12px 2px 22px;font-size:14px}
.results{padding:20px 0 38px}
.results h2{font-size:27px;letter-spacing:-.035em}
.secondary{color:#677870;font-size:14px;line-height:1.6}
.metrics{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:13px;margin:20px 0}
.metric{background:#eaf2ed;border-radius:14px;padding:17px}
.metric strong{display:block;font-size:28px;letter-spacing:-.035em}
.metric span{display:block;font-size:12px;color:#556c63;margin-top:5px}
.panel-grid{display:grid;grid-template-columns:1fr 1fr;gap:14px;margin-bottom:14px}
.panel h3{margin:0 0 15px;font-size:18px}
.entry{display:flex;align-items:center;justify-content:space-between;border-bottom:1px solid #eef2f0;padding:9px 0;gap:12px;font-size:14px}
.entry:last-child{border-bottom:0}.entry strong{color:#176b62}
.disclaimer{font-size:13px;color:#647a72;background:#e6efe9;padding:16px;border-radius:12px;line-height:1.6}
.editor{margin:32px 0 46px}
.editor h2{margin-top:0}.editor>p{color:#647a72;line-height:1.6}
.editor form{display:grid;gap:6px;margin:18px 0}
.editor form button{justify-self:start;margin:10px 0}
.editor>label{margin:16px 0 8px}
.editor textarea,.editor select,.editor form input:not([type=checkbox]){width:100%}
.editor .confirm{display:flex;align-items:center;gap:8px;font-weight:500}
#registered,#import-feedback{min-height:20px}
footer{padding:28px 0 50px;border-top:1px solid #d9e7e0;font-size:12px;line-height:1.7;color:#677970}

.quick-actions{display:flex;align-items:center;flex-wrap:wrap;gap:10px;margin-top:14px;font-size:13px}
.quick-label{color:#647a72;font-weight:600}
.quick-btn{background:#e7f1ec;color:#1c594f;padding:7px 14px;font-size:13px;border-radius:8px;font-weight:600}
.quick-btn:hover{background:#d5e6df;color:#0e3e36}
.file-load-btn{background:#2a6f62;color:white;padding:7px 14px;font-size:13px;border-radius:8px;font-weight:600;cursor:pointer;display:inline-flex;align-items:center}
.file-load-btn:hover{background:#1e5349}
.file-status{font-size:12px;color:#28695e;font-weight:600}

.publications-section{margin:24px 0 28px}
.publications-header{display:flex;align-items:flex-end;justify-content:space-between;flex-wrap:wrap;gap:12px;margin-bottom:16px}
.publications-header h2{font-size:26px;letter-spacing:-.03em;margin:4px 0 0}
.publications-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(min(100%,340px),1fr));gap:16px}
.pub-embed-shell{width:min(100%,244px);aspect-ratio:9/16;align-self:center;flex:none;position:relative;
  overflow:hidden;border-radius:11px;background:#eaf1ec;border:1px solid #dce8e3}
/* O player oficial inclui cabeçalho, controles e faixas pretas laterais.
   O iframe permanece funcional, mas sua janela mostra a área de vídeo 9:16.
   O cartão contém link para a postagem completa e seus controles. */
.pub-embed-frame{display:block;position:absolute;left:-66px;top:-64px;width:326px;height:640px;
  max-width:none;border:0;background:#eaf1ec;transform:scale(1.15);transform-origin:top left}
#sync-status{white-space:pre-wrap;overflow-wrap:anywhere;margin:12px 0}
.pub-card{background:#fff;border:1px solid #dce8e3;border-radius:14px;padding:18px;display:flex;flex-direction:column;gap:10px;box-shadow:0 4px 16px rgba(22,53,41,0.04);transition:transform .15s ease,box-shadow .15s ease}
.pub-card:hover{transform:translateY(-2px);box-shadow:0 6px 20px rgba(22,53,41,0.08)}
.pub-card-top{display:flex;align-items:center;justify-content:space-between;gap:8px}
.pub-author{font-weight:750;color:#28695e;font-size:14px}
.pub-status-badge{font-size:11px;font-weight:700;padding:3px 9px;border-radius:12px;text-transform:uppercase;letter-spacing:.03em}
.pub-status-badge.synced{background:#dcfce7;color:#166534}
.pub-status-badge.pending{background:#fef3c7;color:#92400e}
.pub-status-badge.needs_update{background:#e0f2fe;color:#075985}
.pub-title{font-size:17px;font-weight:700;margin:0;color:#1e293b;line-height:1.3}
.pub-summary{font-size:13px;line-height:1.5;color:#475569;margin:0;display:-webkit-box;-webkit-line-clamp:3;-webkit-box-orient:vertical;overflow:hidden}
.pub-meta{display:flex;align-items:center;flex-wrap:wrap;gap:10px;font-size:12px;color:#64748b;margin-top:auto;padding-top:8px;border-top:1px solid #f1f5f9}
.pub-link{color:#28695e;text-decoration:none;font-weight:600}
.pub-link:hover{text-decoration:underline}
.pub-video-tag{background:#fee2e2;color:#991b1b;padding:2px 7px;border-radius:6px;font-weight:600}
.pub-actions{display:flex;gap:8px;margin-top:8px;flex-wrap:wrap}
.pub-btn-view{background:#28695e;color:#fff;border-radius:8px;padding:9px 16px;font-size:13px;font-weight:700;flex:1;cursor:pointer}
.pub-btn-view:hover{background:#1f534a}
.pub-btn-sync{background:#d97706;color:#fff;border-radius:8px;padding:9px 16px;font-size:13px;font-weight:700;flex:1;cursor:pointer}
.pub-btn-sync:hover{background:#b45309}
.manual-lookup-details{margin:18px 0;background:#f8faf9;border:1px solid #e2ece7;border-radius:10px;padding:10px 14px;font-size:13px}
.manual-lookup-details summary{font-weight:600;color:#28695e;cursor:pointer}

.comments-explorer{margin-top:36px;padding-top:28px;border-top:2px solid #dce8e3}
.explorer-header{display:flex;flex-direction:column;gap:16px;margin-bottom:24px}
.explorer-header h2{font-size:24px;letter-spacing:-.03em;margin:4px 0 0}
.explorer-controls{display:flex;flex-direction:column;gap:10px;background:#fff;border:1px solid #dce8e3;padding:18px;border-radius:14px;box-shadow:0 4px 16px #16352906}
.explorer-controls input[type=search]{width:100%;padding:10px 14px;font-size:14px}
.filter-row{display:flex;align-items:center;gap:10px;flex-wrap:wrap}
.filter-title{font-size:12px;font-weight:750;color:#546e65;min-width:90px}
.pills-row{display:flex;flex-wrap:wrap;gap:6px}
.pill-btn{background:#edf4f0;border:1px solid #d5e4dd;color:#28564c;padding:5px 11px;border-radius:20px;font-size:12px;font-weight:600;cursor:pointer;transition:all .15s ease}
.pill-btn:hover{background:#dbe9e2;border-color:#b9d5c9}
.pill-btn.active{background:#217364;border-color:#217364;color:white}

.comments-grid{display:grid;grid-template-columns:1fr;gap:12px;margin:20px 0}
.comment-card{background:#fff;border:1px solid #dbe7e1;border-radius:12px;padding:16px 18px;box-shadow:0 2px 10px #16352905;display:flex;flex-direction:column;gap:10px}
.comment-card:hover{border-color:#adcbc1;box-shadow:0 4px 14px #1635290a}
.comment-card-top{display:flex;align-items:center;justify-content:space-between;gap:12px}
.comment-user-box{display:flex;align-items:center;gap:8px}
.comment-avatar{width:32px;height:32px;border-radius:50%;background:#e0eee7;color:#1d574d;display:flex;align-items:center;justify-content:center;font-size:12px;font-weight:800;border:1px solid #c9ded4}
.comment-handle{font-weight:750;font-size:14px;color:#1b4a41}
.comment-time{font-size:12px;color:#788d85}
.comment-body{font-size:14.5px;line-height:1.55;color:#21332e;white-space:pre-wrap;word-break:break-word}
.comment-badges{display:flex;align-items:center;flex-wrap:wrap;gap:6px;margin-top:2px}
.c-badge{font-size:11px;padding:3px 8px;border-radius:6px;font-weight:650}
.badge-topic{background:#e3f0ea;color:#185b4f}
.badge-subtopic{background:#fdf2dc;color:#875604;border:1px solid #f2dbaf}
.badge-intent{background:#e7effc;color:#1f4b8f}
.badge-relation{background:#f5eafc;color:#672391;cursor:pointer}

.pagination-controls{display:flex;align-items:center;justify-content:center;gap:12px;margin:24px 0}
.page-nav-btn{background:#e8f2ed;color:#225c50;padding:8px 16px;border-radius:8px;font-size:13px;font-weight:700}
.page-nav-btn:hover:not(:disabled){background:#d5e7de}
.page-info{font-size:13px;color:#5b736b;font-weight:600}

.video-context-box{background:linear-gradient(135deg,rgba(40,105,94,0.08) 0%,rgba(192,38,45,0.05) 100%);border:1px solid rgba(40,105,94,0.22);border-radius:12px;padding:16px 20px;margin:16px 0 20px 0}
.video-context-header{display:flex;align-items:center;justify-content:space-between;margin-bottom:8px;flex-wrap:wrap;gap:8px}
.video-context-tag{font-size:12px;font-weight:700;text-transform:uppercase;letter-spacing:0.04em;color:#28695e;display:flex;align-items:center;gap:6px}
.video-author-badge{font-size:12px;font-weight:700;color:#c0262d;background:#fee2e2;padding:2px 8px;border-radius:6px}
.video-summary-content{font-size:14px;line-height:1.55;color:#1e293b;margin:0;font-weight:500}
.video-transcription-details{margin-top:14px;border-top:1px solid #cfdfd9;padding-top:12px}
.video-transcription-details summary{cursor:pointer;font-size:13px;font-weight:750;color:#176b62;list-style:revert}
.video-transcription-details summary:focus-visible{outline:3px solid #77b5a6;outline-offset:3px}
.video-transcription-content{font-size:13px;line-height:1.7;color:#334155;white-space:pre-wrap;overflow-wrap:anywhere;max-height:360px;overflow:auto;margin:12px 0 0;padding:14px;border-radius:9px;background:#fff;border:1px solid #d8e6df}


@media(max-width:680px){.top{flex-wrap:wrap;padding:20px 0}.hero{padding-top:40px}.inline{flex-direction:column}.inline button{width:100%}.metrics{grid-template-columns:1fr 1fr}.panel-grid{grid-template-columns:1fr}.lookup,.panel,.editor{padding:20px}.filter-row{flex-direction:column;align-items:flex-start;gap:4px}.pub-actions button{flex:1 1 100%}}
@media(prefers-reduced-motion:reduce){*{scroll-behavior:auto}}
