/* SSSTikTok Downloader — self-contained, CLS-safe, mobile-first. */
.ssstk{max-width:640px;margin:0 auto}
.ssstk-sr{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0 0 0 0);white-space:nowrap;border:0}
.ssstk-hp{position:absolute!important;left:-9999px!important;width:1px;height:1px;overflow:hidden}
.ssstk-row{display:flex;gap:.5rem;flex-wrap:wrap}
.ssstk-input{flex:1 1 240px;min-height:52px;padding:0 1rem;font-size:16px;border:2px solid #d8dde3;border-radius:12px;outline:none}
.ssstk-input:focus{border-color:#fe2c55;box-shadow:0 0 0 3px rgba(254,44,85,.18)}
.ssstk-submit{min-height:52px;padding:0 1.5rem;font-size:16px;font-weight:700;color:#fff;background:#fe2c55;border:0;border-radius:12px;cursor:pointer}
.ssstk-submit:hover{background:#e01f46}
.ssstk-submit[aria-busy="true"]{opacity:.7;cursor:progress}
.ssstk-paste{min-height:52px;padding:0 1rem;font-size:15px;background:#eef1f4;border:0;border-radius:12px;cursor:pointer}
.ssstk-turnstile{margin-top:.75rem;min-height:65px}
.ssstk-msg{margin:.75rem 0 0;min-height:1.25rem;font-size:14px;color:#555}
.ssstk-msg.is-error{color:#c0143c}
/* reserve space so injecting the result never shifts layout */
.ssstk-result{margin-top:1rem;min-height:0}
.ssstk-card{display:flex;gap:1rem;padding:1rem;border:1px solid #e6e9ee;border-radius:16px;background:#fff}
.ssstk-thumb{flex:0 0 120px;width:120px;height:160px;border-radius:12px;overflow:hidden;background:#f0f2f5}
.ssstk-thumb img{width:100%;height:100%;object-fit:cover;display:block}
.ssstk-meta{flex:1;min-width:0}
.ssstk-author{margin:0 0 .25rem;font-weight:700}
.ssstk-caption{margin:0 0 .75rem;color:#555;font-size:14px;overflow-wrap:anywhere}
.ssstk-actions{display:flex;flex-wrap:wrap;gap:.5rem}
.ssstk-btn{display:inline-block;padding:.6rem 1rem;font-weight:600;color:#fff;background:#111;border-radius:10px;text-decoration:none}
.ssstk-btn.ssstk-audio{background:#3b5bdb}
.ssstk-again{margin-top:.75rem;background:none;border:0;color:#fe2c55;cursor:pointer;font-weight:600;padding:.25rem 0}
.ssstk-gallery{display:grid;grid-template-columns:repeat(auto-fill,minmax(90px,1fr));gap:.5rem;margin-top:.75rem}
.ssstk-img{position:relative;display:block;border-radius:8px;overflow:hidden;aspect-ratio:3/4;background:#f0f2f5}
.ssstk-img img{width:100%;height:100%;object-fit:cover;display:block}
.ssstk-img span{position:absolute;left:0;right:0;bottom:0;padding:.25rem;font-size:11px;color:#fff;background:rgba(0,0,0,.55);text-align:center}
/* loading skeleton */
.ssstk-card.is-loading .ssstk-line,.ssstk-card.is-loading .ssstk-thumb{background:linear-gradient(90deg,#eef1f4 25%,#e2e6ea 37%,#eef1f4 63%);background-size:400% 100%;animation:ssstk-sh 1.2s ease-in-out infinite}
.ssstk-card.is-loading .ssstk-line{display:block;height:14px;border-radius:6px;margin-bottom:.6rem}
.ssstk-card.is-loading .ssstk-line.short{width:60%}
.ssstk-card.is-loading .ssstk-line.btn{width:40%;height:38px;margin-top:1rem}
@keyframes ssstk-sh{0%{background-position:100% 50%}100%{background-position:0 50%}}
@media (prefers-reduced-motion:reduce){.ssstk-card.is-loading .ssstk-line,.ssstk-card.is-loading .ssstk-thumb{animation:none}}
@media (max-width:520px){.ssstk-submit,.ssstk-input{flex:1 1 100%}}
