.section{
  display:none;
  text-align:center;
}

.section.show{
  display:block;
}

.drop{
  max-width:1160px;
  margin:0 auto;
}

#list,
#mergeList,
#rotateList,
#splitList,
#videoList,
#compressList,
#protectList,
#removeBgList{
  max-width:1160px;
  margin:12px auto 0;
}

#batchActions,
#rotateBatch,
#splitBatch,
#videoBatch,
#compressBatch,
#protectBatch{
  justify-content:center;
}

.inputs{
  display:flex;
  justify-content:center;
  align-items:center;
  gap:10px;
  flex-wrap:wrap;
  text-align:center;
  margin-top:10px;
}

.note{
  text-align:center;
}

#mergeResult,
#rotateOut{
  text-align:center;
}

.removebg-preview-wrap{
  max-width:1160px;
  margin:18px auto 0;
  display:grid;
  grid-template-columns:minmax(280px, 420px) minmax(320px, 1fr);
  gap:18px;
  align-items:stretch;
}

.removebg-strength,
.removebg-preview-card{
  background:linear-gradient(180deg, rgba(255,255,255,.96), rgba(248,250,252,.96));
  border:1px solid var(--stroke);
  border-radius:22px;
  box-shadow:var(--shadow-soft);
}

.removebg-strength{
  padding:18px 20px;
  text-align:left;
}

.removebg-strength-top{
  display:flex;
  justify-content:space-between;
  align-items:center;
  gap:12px;
  margin-bottom:14px;
}

.removebg-strength-top label{
  font-weight:700;
}

.removebg-strength-top strong{
  color:var(--brand-strong);
}

#removeBgStrength{
  width:100%;
  accent-color:var(--brand);
}

.removebg-preview-card{
  padding:16px;
}

.removebg-preview-head{
  display:flex;
  justify-content:space-between;
  align-items:center;
  gap:12px;
  margin-bottom:12px;
  text-align:left;
}

.removebg-preview-head span{
  font-weight:700;
}

.removebg-preview-head small{
  color:var(--muted);
}

.removebg-preview-stage{
  min-height:260px;
  border:1px solid var(--stroke);
  border-radius:18px;
  display:flex;
  align-items:center;
  justify-content:center;
  padding:14px;
}

.checkerboard{
  background:
    linear-gradient(45deg, #eef2f7 25%, transparent 25%),
    linear-gradient(-45deg, #eef2f7 25%, transparent 25%),
    linear-gradient(45deg, transparent 75%, #eef2f7 75%),
    linear-gradient(-45deg, transparent 75%, #eef2f7 75%);
  background-size:24px 24px;
  background-position:0 0, 0 12px, 12px -12px, -12px 0;
  background-color:#fff;
}

#removeBgPreviewCanvas{
  max-width:100%;
  max-height:360px;
  width:auto;
  height:auto;
  border-radius:14px;
  box-shadow:0 10px 28px rgba(15,23,42,.08);
}

.removebg-note{
  margin:10px 0 0;
  text-align:left;
}

@media (max-width: 900px){
  .removebg-preview-wrap{
    grid-template-columns:1fr;
  }
}

.footer{
  text-align:center;
}
.footer-link{
  color:#2563eb;
  text-decoration:none;
  font-weight:500;
}

.footer-link:hover{
  text-decoration:underline;
}
:root{
  --brand-strong:#0f172a;
  --brand:#2563eb;
  --bg:#f8fafc;
  --fg:#0f172a;
  --muted:#64748b;
  --card:#ffffff;
  --stroke:#e2e8f0;
  --stroke-strong:#cbd5e1;
  --soft:#f1f5f9;
  --soft-2:#f8fafc;
  --shadow:0 10px 40px -10px rgba(0,0,0,.08);
  --shadow-soft:0 4px 20px -4px rgba(0,0,0,.05);
  --glow:0 0 20px rgba(37,99,235,.15);
  --danger:#ef4444;
}

:root[data-theme="dark"]{
  --brand-strong:#bfdbfe;
  --brand:#3b82f6;
  --bg:#0f172a;
  --fg:#f8fafc;
  --muted:#94a3b8;
  --card:#1e293b;
  --stroke:#334155;
  --stroke-strong:#475569;
  --soft:#0f172a;
  --soft-2:#1e293b;
  --shadow:0 10px 40px -10px rgba(0,0,0,.5);
  --shadow-soft:0 4px 20px -4px rgba(0,0,0,.3);
  --glow:0 0 20px rgba(59,130,246,.25);
  --danger:#f87171;
}

*{ box-sizing:border-box }
html,body{ height:100%; margin:0 }
html{ background:var(--bg); }

body{
  color:var(--fg);
  font-family:Inter, ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
  background:var(--bg);
  position:relative;
  overflow-x:hidden;
}

.sr-only{
  position:absolute !important;
  width:1px !important;
  height:1px !important;
  padding:0 !important;
  margin:-1px !important;
  overflow:hidden !important;
  clip:rect(0,0,0,0) !important;
  white-space:nowrap !important;
  border:0 !important;
}

body::before{
  content:"";
  position:absolute;
  top:0;
  left:0;
  width:100%;
  height:400px;
  background:linear-gradient(180deg, rgba(37,99,235,0.04) 0%, rgba(248,250,252,0) 100%);
  pointer-events:none;
  z-index:-1;
}

.hidden { display: none !important; }

.header{
  position:relative;
  z-index:1;
  display:flex;
  flex-direction:column;
  justify-content:center;
  align-items:center;
  text-align:center;
  gap:8px;
  padding:20px 20px 8px;
}

.header-top{
  width:min(1460px, 100%);
  display:flex;
  justify-content:flex-end;
  align-items:center;
  gap:12px;
  margin-bottom:8px;
}

.lang-picker{
  position:relative;
  z-index:8;
}

.lang-current{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  width:58px;
  height:58px;
  padding:0;
  border:none;
  border-radius:18px;
  background:rgba(255,255,255,.9);
  color:var(--fg);
  box-shadow:0 12px 30px rgba(15,23,42,.08);
  backdrop-filter:blur(16px);
  cursor:pointer;
  transition:transform .2s ease, box-shadow .2s ease, background .2s ease;
}

.lang-current:hover{
  transform:translateY(-1px);
  box-shadow:0 18px 34px rgba(15,23,42,.12);
  background:#fff;
}

.lang-flag-img{
  width:28px;
  height:20px;
  display:block;
  object-fit:cover;
  border-radius:5px;
  box-shadow:0 2px 6px rgba(15,23,42,.14);
}

.lang-menu{
  position:absolute;
  top:calc(100% + 10px);
  right:0;
  display:grid;
  grid-template-columns:repeat(4, minmax(0, 1fr));
  gap:8px;
  width:max-content;
  padding:10px;
  border-radius:22px;
  background:rgba(255,255,255,.96);
  border:1px solid rgba(219,228,240,.95);
  box-shadow:0 22px 44px rgba(15,23,42,.12);
  backdrop-filter:blur(18px);
}

.lang-option{
  width:52px;
  height:52px;
  display:flex;
  align-items:center;
  justify-content:center;
  padding:0;
  border:none;
  border-radius:16px;
  background:transparent;
  color:var(--fg);
  font:inherit;
  cursor:pointer;
  transition:background .2s ease, transform .2s ease;
}

.lang-option:hover,
.lang-option.active{
  background:linear-gradient(135deg, rgba(37,99,235,.12), rgba(96,165,250,.08));
  transform:translateY(-1px);
}

.logo-wrap{
  display:flex;
  justify-content:center;
  align-items:center;
  position:relative;
}

.logo{
  width:420px;
  max-width:85%;
  height:auto;
  margin-bottom:0;
  filter:drop-shadow(0 6px 18px rgba(37,99,235,.10));
  transition:transform .25s ease, filter .25s ease;
  user-select:none;
}

.logo:hover{
  transform:translateY(-2px) scale(1.01);
  filter:drop-shadow(0 12px 30px rgba(37,99,235,.16));
}

.brand{
  font-weight:800;
  font-size:26px;
  letter-spacing:-.02em;
  color:var(--fg);
}

.brand .beta{
  font-size:.55em;
  text-transform:uppercase;
  letter-spacing:.08em;
  color:#fff;
  background:linear-gradient(135deg, var(--brand), var(--brand-strong));
  padding:4px 8px;
  border-radius:999px;
  margin-left:8px;
  position:relative;
  top:-.2em;
  box-shadow:0 8px 20px rgba(37,99,235,.18);
}

.wrap{
  position:relative;
  z-index:1;
  max-width:1460px;
  margin:6px auto 28px;
  padding:0 16px;
}

.card{
  background:var(--card);
  border:1px solid var(--stroke);
  border-radius:24px;
  padding:32px;
  box-shadow:var(--shadow);
}

.hero{
  max-width:1160px;
  margin:0 auto 20px;
  text-align:center;
}

.pill{
  display:inline-flex;
  align-items:center;
  gap:8px;
  padding:8px 14px;
  border-radius:999px;
  background:rgba(255,255,255,.78);
  border:1px solid var(--stroke);
  color:#1e3a8a;
  font-weight:700;
  font-size:12px;
  letter-spacing:.04em;
  text-transform:uppercase;
  box-shadow:var(--shadow-soft);
}

.hero-title{
  margin:14px 0 10px;
  font-size:clamp(30px, 4vw, 48px);
  line-height:1.02;
  letter-spacing:-.04em;
}

.hero-title .accent{
  background:linear-gradient(135deg, var(--brand), #60a5fa);
  -webkit-background-clip:text;
  background-clip:text;
  color:transparent;
}

.hero-sub{
  max-width:760px;
  margin:0 auto;
  color:var(--muted);
  font-size:15px;
  line-height:1.7;
}

.hero-grid{
  display:grid;
  grid-template-columns:repeat(3, minmax(0,1fr));
  gap:12px;
  max-width:860px;
  margin:18px auto 6px;
}

.hero-stat{
  background:linear-gradient(180deg, rgba(255,255,255,.95), rgba(248,250,252,.95));
  border:1px solid var(--stroke);
  border-radius:18px;
  padding:14px 16px;
  box-shadow:var(--shadow-soft);
}

.hero-stat strong{
  display:block;
  font-size:20px;
  letter-spacing:-.03em;
}

.hero-stat span{
  color:var(--muted);
  font-size:13px;
}

.title{
  margin:0 0 8px;
  font-size:26px;
  letter-spacing:-.03em;
  text-align:center;
}

.sub{
  margin:0 0 16px;
  color:var(--muted);
  text-align:center;
}

.nav-shell{
  max-width:1120px;
  margin:0 auto 30px;
}

.main-tabs,
.tool-tabs{
  align-items:center;
  width:100%;
  overflow-x:auto;
  overflow-y:hidden;
  scrollbar-width:none;
  -ms-overflow-style:none;
  -webkit-overflow-scrolling:touch;
}

.main-tabs::-webkit-scrollbar,
.tool-tabs::-webkit-scrollbar{
  display:none;
}

.main-tabs{
  display:grid;
  grid-template-columns:repeat(4, minmax(0, 1fr));
  gap:8px;
  margin:0 auto;
  padding:6px;
  border-radius:20px;
  background:var(--soft);
}

.tool-tabs{
  display:flex;
  justify-content:center;
  flex-wrap:wrap;
  gap:8px;
  margin-top:20px;
  padding-top:20px;
  border-top:1px solid var(--stroke);
}

.main-tab,
.tool-tab{
  appearance:none;
  -webkit-appearance:none;
  font:inherit;
  cursor:pointer;
  background:transparent;
  border:none;
  color:var(--muted);
  border-radius:14px;
  font-weight:600;
  min-width:0;
  white-space:nowrap;
  touch-action:manipulation;
  -webkit-tap-highlight-color:transparent;
  transition:background-color .2s ease, border-color .2s ease, color .2s ease, box-shadow .2s ease, transform .2s ease;
}

.main-tab{
  justify-content:center;
  width:100%;
  padding:14px;
  min-height:48px;
  text-align:center;
}

.main-tab-label{
  display:block;
}

.tool-tab{
  flex:0 1 auto;
  padding:10px 18px;
  min-height:40px;
  background:var(--card);
  border:1px solid var(--stroke);
  box-shadow:var(--shadow-soft);
}

.main-tab:hover{
  color:var(--fg);
}

.tool-tab:hover{
  border-color:var(--stroke-strong);
  transform:translateY(-1px);
}

.main-tab:focus-visible,
.tool-tab:focus-visible{
  outline:3px solid rgba(37,99,235,.28);
  outline-offset:2px;
}

.main-tab.active{
  background:var(--card);
  color:var(--fg);
  font-weight:700;
  box-shadow:var(--shadow-soft);
}

.tool-tab.active{
  background:var(--brand);
  color:#fff;
  border-color:var(--brand);
  box-shadow:0 8px 16px -4px rgba(37,99,235,.3);
}

.tool-tab.is-hidden{
  display:none;
}

.section{
  display:none;
  opacity:0;
  transform:translateY(4px);
}

.section.show{
  display:block;
  opacity:1;
  transform:translateY(0);
  animation:sectionFade .22s ease;
}

@keyframes sectionFade{
  from{
    opacity:0;
    transform:translateY(8px);
  }
  to{
    opacity:1;
    transform:translateY(0);
  }
}

.media-grid{
  max-width:1160px;
  margin:0 auto;
  display:grid;
  grid-template-columns:minmax(0, 1.08fr) minmax(320px, .92fr);
  gap:18px;
  align-items:start;
}

.media-tool-block{
  max-width:1160px;
  margin:0 auto;
}

.media-tool-title{
  margin:0 0 8px;
  text-align:left;
  font-size:22px;
  letter-spacing:-.02em;
}

.media-tool-sub{
  margin-bottom:16px;
  text-align:left;
}

@media (max-width: 900px){
  .main-tabs{
    display:flex;
    justify-content:flex-start;
    scroll-snap-type:x proximity;
  }

  .tool-tabs{
    justify-content:flex-start;
    flex-wrap:nowrap;
    scroll-snap-type:x proximity;
  }

  .main-tab{
    flex:0 0 auto;
    width:auto;
    min-width:max-content;
    scroll-snap-align:start;
  }

  .tool-tab{
    scroll-snap-align:start;
  }

  .media-grid{
    grid-template-columns:1fr;
  }
}

@media (max-width: 720px){
  .nav-shell{
    border-radius:18px;
    padding:8px;
    margin-bottom:18px;
  }

  .main-tab{
    padding:10px 13px;
    font-size:13px;
  }

  .tool-tab{
    padding:8px 11px;
    font-size:12px;
  }

  .media-tool-title,
  .media-tool-sub{
    text-align:center;
  }
}

@media (prefers-reduced-motion: reduce){
  .main-tab,
  .tool-tab,
  .section.show{
    transition:none;
    animation:none;
  }
}

.drop{
  position:relative;
  border:2px dashed var(--stroke-strong);
  border-radius:24px;
  padding:40px 24px;
  text-align:center;
  background:var(--soft);
  transition:background-color .2s ease, border-color .2s ease, transform .2s ease;
}

.drop .icon{
  width:56px;
  height:56px;
  margin:0 auto 16px;
  color:var(--brand);
  opacity:0.8;
}

.drop.dragover{
  border-color:var(--brand);
  background:#eff6ff;
  transform:scale(1.01);
}

.btn{
  background:var(--brand);
  border:none;
  color:#fff;
  padding:12px 24px;
  border-radius:14px;
  font-weight:600;
  font-size:15px;
  transition:background-color .2s ease, color .2s ease, box-shadow .2s ease, transform .2s ease;
  cursor:pointer;
  display:inline-flex;
  align-items:center;
  justify-content:center;
}

.btn:hover{
  background:#1d4ed8;
  transform:translateY(-1px);
  box-shadow:0 10px 20px -5px rgba(37,99,235,.3);
}

.btn:focus-visible{
  outline:3px solid rgba(37,99,235,.28);
  outline-offset:2px;
}

.btn:active{
  transform:translateY(0) scale(.98);
}

.btn.alt{
  background:#fff;
  border:1px solid var(--stroke);
  color:#334155;
  box-shadow:var(--shadow-soft);
}

.note{
  font-size:13px;
  color:var(--muted);
  margin-top:8px;
}

.footer{
  text-align:center;
  color:var(--muted);
  font-size:12px;
  line-height:1.8;
  margin:24px 0 8px;
  padding:16px;
  border:1px solid rgba(219,228,240,.8);
  background:rgba(255,255,255,.68);
  backdrop-filter:blur(10px);
  border-radius:18px;
  box-shadow:var(--shadow-soft);
}

.footer-link{
  color:var(--brand);
  text-decoration:none;
  font-weight:700;
}

.footer-link:hover{
  text-decoration:underline;
}

#confettiCanvas{
  position:fixed;
  inset:0;
  width:100%;
  height:100%;
  pointer-events:none;
  z-index:9998;
}

.progress{
  height:8px;
  width:220px;
  background:#edf2f7;
  border-radius:999px;
  overflow:hidden;
  border:1px solid var(--stroke);
  position:relative;
}

.progress > div{
  height:100%;
  width:0%;
  background:linear-gradient(90deg, var(--brand), #60a5fa);
  transition: width .18s ease;
}

.progress.indet::before{
  content:"";
  position:absolute;
  top:0;
  left:-45%;
  height:100%;
  width:40%;
  background:
    linear-gradient(90deg, transparent, rgba(255,255,255,.55), transparent),
    linear-gradient(90deg, var(--brand), #60a5fa);
  animation: slide 1.1s infinite ease-in-out;
}

@keyframes slide {
  0%{ left:-45% }
  50%{ left:65% }
  100%{ left:105% }
}

.spinner{
  width:18px;
  height:18px;
  border-radius:999px;
  border:2px solid rgba(37,99,235,.18);
  border-top-color:var(--brand);
  display:inline-block;
  animation: spin .8s linear infinite;
}

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

.row{
  display:flex;
  flex-wrap:wrap;
  align-items:center;
  gap:12px;
  padding:13px 15px;
  border:1px solid var(--stroke);
  border-radius:16px;
  background:rgba(255,255,255,.96);
  margin-top:10px;
  box-shadow:var(--shadow-soft);
  transition:transform .18s ease, box-shadow .18s ease, border-color .18s ease;
}

.row:hover,
.item:hover{
  transform:translateY(-1px);
  border-color:#bfd0e5;
  box-shadow:0 14px 28px rgba(15,23,42,.08);
}

.row .name{
  flex:1 1 260px;
  overflow:hidden;
  text-overflow:ellipsis;
  white-space:nowrap;
  color:#0f172a;
  font-weight:600;
}

.status{
  display:flex;
  align-items:center;
  gap:8px;
  color:var(--muted);
}

.err{
  color:var(--danger);
  font-weight:800;
}

.hidden{ display:none }

#mergeList, #rotateList, #splitList, #videoList, #compressList{
  margin-top:10px;
}

.item{
  display:flex;
  align-items:center;
  gap:12px;
  padding:12px;
  border:1px solid var(--stroke);
  border-radius:16px;
  background:rgba(255,255,255,.96);
  margin-top:8px;
  box-shadow:var(--shadow-soft);
  transition:transform .18s ease, box-shadow .18s ease, border-color .18s ease;
}

.iname{
  flex:1;
  overflow:hidden;
  text-overflow:ellipsis;
  white-space:nowrap;
  color:#0f172a;
  font-weight:600;
}

.thumb{
  width:64px;
  height:88px;
  border:1px solid var(--stroke);
  border-radius:10px;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  background:#f8fafc;
  color:#475569;
  font-size:12px;
  transition:transform .2s ease;
  overflow:hidden;
}

.thumb img{
  width:100%;
  height:100%;
  object-fit:cover;
}

.thumb canvas{
  width:100%;
  height:100%;
  display:block;
}

.thumb .pdficon{
  width:26px;
  height:26px;
  opacity:.9;
}

.controls{
  display:flex;
  align-items:center;
  gap:6px;
}

.controls .btn{
  padding:6px 10px;
}

.anglev{
  min-width:36px;
  text-align:center;
  color:#334155;
  font-weight:700;
}

input[type="text"], input[type="number"], input[type="url"], textarea, select{
  background:#fff;
  color:#0f172a;
  border:1px solid var(--stroke-strong);
  border-radius:10px;
  padding:8px 10px;
  outline:2px solid transparent;
  outline-offset:2px;
}

input[type="text"]:focus-visible, input[type="number"]:focus-visible, input[type="url"]:focus-visible, textarea:focus-visible, select:focus-visible{
  border-color:rgba(37,99,235,.45);
  box-shadow:0 0 0 4px rgba(37,99,235,.10);
}

.errmsg{
  color:var(--danger);
  font-size:13px;
  margin-top:6px;
  font-weight:700;
}

.small{
  font-size:12px;
  color:var(--muted);
}

.report{
  display:flex;
  flex-wrap:wrap;
  gap:10px;
  align-items:center;
  color:#334155;
  font-size:12px;
}

.badge{
  padding:3px 8px;
  border-radius:999px;
  border:1px solid var(--stroke);
  background:#f8fafc;
}

.badge.good{
  border-color: rgba(37,99,235,.22);
  background:#edf5ff;
}

.badge.warn{
  border-color: rgba(255,123,123,.35);
  background:#fff5f5;
}

.loading-glow{
  background:linear-gradient(90deg, #eff6ff 25%, #dbeafe 50%, #eff6ff 75%);
  background-size:200% 100%;
  animation: shimmer 1.1s linear infinite;
}

.youtube-panel{
  max-width:1160px;
  margin:0 auto;
  padding:24px;
  border:1px solid var(--stroke);
  border-radius:24px;
  background:var(--card);
  box-shadow:var(--shadow-soft);
}

.youtube-inline-row{
  justify-content:center;
  text-align:center;
}

.youtube-link-row{
  gap:14px;
}

.youtube-url-input{
  flex:0 1 560px;
  min-width:280px;
  max-width:560px;
}

.youtube-err{
  max-width:100%;
  text-align:center;
}

.youtube-meta{
  display:grid;
  grid-template-columns:180px minmax(0, 1fr);
  gap:16px;
  align-items:center;
  margin-top:14px;
  padding:14px;
  border:1px solid var(--stroke);
  border-radius:18px;
  background:#fff;
  box-shadow:var(--shadow-soft);
  text-align:left;
}

.youtube-meta.hidden{
  display:none !important;
}

.youtube-meta-thumb{
  width:100%;
  aspect-ratio:16/9;
  object-fit:cover;
  border-radius:14px;
  border:1px solid var(--stroke);
  background:#e2e8f0;
}

.youtube-meta-copy strong{
  display:block;
  font-size:18px;
  line-height:1.3;
  margin-bottom:8px;
}

.youtube-meta-copy span{
  color:var(--muted);
  font-size:13px;
}

.youtube-mode-row{
  margin-top:14px;
}

.youtube-options{
  margin-top:10px;
}

.youtube-progress-row{
  margin-top:14px;
}

.youtube-progress-bar{
  flex:1 1 280px;
  width:auto;
  min-width:220px;
}

.youtube-result{
  margin-top:14px;
  text-align:center;
}

.youtube-result .btn{
  max-width:100%;
  white-space:normal;
  word-break:break-word;
}

@keyframes shimmer{
  0%{ background-position:200% 0; }
  100%{ background-position:-200% 0; }
}

@media (max-width: 900px){
  .hero-grid{ grid-template-columns:1fr; }
}

@media (max-width: 760px){
  .header{
    padding-top:14px;
  }
  .header-top{
    justify-content:center;
    margin-bottom:14px;
  }
  .lang-picker,
  .lang-current,
  .lang-menu{
    width:100%;
  }
  .lang-current{
    width:58px;
    min-width:58px;
  }
  .lang-menu{
    right:auto;
    left:50%;
    transform:translateX(-50%);
  }
  .logo{ width:240px; }
  .brand{ font-size:22px; }
  .card{ padding:18px; border-radius:22px; }
  .tabs{ position:static; }
  .drop{ padding:20px; }
  .hero-title{ font-size:32px; }
  .youtube-meta{ grid-template-columns:1fr; }
  .youtube-inline-row{ justify-content:center; text-align:center; }
  .youtube-err, .youtube-result{ text-align:center; }
}






.cookie-notice{
  position:fixed;
  right:14px;
  bottom:14px;
  z-index:30;
  max-width:min(340px, calc(100vw - 20px));
  display:flex;
  flex-direction:column;
  align-items:flex-start;
  gap:10px;
  padding:12px 14px;
  border:1px solid rgba(219,228,240,.92);
  border-radius:16px;
  background:rgba(255,255,255,.94);
  box-shadow:0 10px 24px rgba(15,23,42,.12);
  backdrop-filter:blur(14px);
}

.cookie-notice-copy{flex:1}
.cookie-notice-copy strong{display:block;margin-bottom:4px;font-size:14px}
.cookie-notice-copy p{margin:0 0 6px;font-size:13px;line-height:1.45;color:var(--muted)}
.cookie-policy-link{color:var(--brand);text-decoration:none;font-weight:700;font-size:13px}
.cookie-policy-link:hover{text-decoration:underline}
.cookie-notice-actions{display:flex;gap:8px;flex-wrap:wrap;justify-content:flex-start;width:100%}
.btn.secondary{background:#eef4fb;color:var(--fg)}
.btn.secondary:hover{background:#e2ebf8}
.cookie-panel{
  position:fixed;
  right:14px;
  bottom:118px;
  z-index:40;
  width:min(360px, calc(100vw - 20px));
}
.cookie-panel-card{
  width:100%;
  background:#fff;
  border-radius:18px;
  border:1px solid var(--stroke);
  box-shadow:0 18px 38px rgba(15,23,42,.16);
  padding:18px;
}
.cookie-panel-head{display:flex;justify-content:space-between;gap:14px;align-items:flex-start}
.cookie-panel-head p{margin:6px 0 0;color:var(--muted);font-size:13px;line-height:1.45}
.cookie-panel-close{border:none;background:transparent;font-size:26px;line-height:1;cursor:pointer;color:var(--muted);padding:0 0 0 8px}
.cookie-option{display:flex;justify-content:space-between;gap:16px;align-items:center;padding:14px 0;border-top:1px solid var(--stroke)}
.cookie-option p{margin:6px 0 0;color:var(--muted);font-size:13px;line-height:1.45}
.cookie-badge{padding:7px 10px;border-radius:999px;background:#e8eef8;color:var(--fg);font-size:12px;font-weight:700;white-space:nowrap}
.cookie-switch{position:relative;display:inline-flex;align-items:center;flex:none}
.cookie-switch input{position:absolute;opacity:0;pointer-events:none}
.cookie-switch span{width:50px;height:30px;border-radius:999px;background:#cbd5e1;display:block;position:relative;transition:background .2s ease}
.cookie-switch span::after{content:"";position:absolute;top:3px;left:3px;width:24px;height:24px;border-radius:999px;background:#fff;box-shadow:0 2px 6px rgba(15,23,42,.14);transition:transform .2s ease}
.cookie-switch input:checked + span{background:var(--brand)}
.cookie-switch input:checked + span::after{transform:translateX(20px)}
.cookie-panel-actions{display:flex;justify-content:space-between;gap:10px;align-items:center;padding-top:14px;border-top:1px solid var(--stroke)}
.cookie-panel-actions .btn{flex:none}
.footer-sep{display:inline-block;margin:0 8px;color:#94a3b8}
@media (max-width:760px){
  .cookie-notice{left:12px;right:12px;bottom:12px;max-width:none}
  .cookie-panel{left:12px;right:12px;bottom:112px;width:auto}
  .cookie-panel-actions{flex-direction:column;align-items:stretch}
  .cookie-footer-link{left:12px;right:12px;bottom:88px;justify-content:center}
}


.cookie-footer-link{
  position:fixed;
  left:14px;
  bottom:14px;
  z-index:25;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  min-height:40px;
  padding:10px 14px;
  border:1px solid rgba(219,228,240,.92);
  border-radius:999px;
  background:rgba(255,255,255,.94);
  box-shadow:0 8px 22px rgba(15,23,42,.10);
  backdrop-filter:blur(14px);
  color:var(--brand);
  text-decoration:none;
  font-weight:700;
  font-size:13px;
}

.cookie-footer-link:hover{
  text-decoration:underline;
}


@media (max-width: 760px){
  body{
    padding-bottom:140px;
  }

  .wrap{
    margin:0 auto 20px;
    padding:0 12px;
  }

  .header{
    padding:12px 12px 6px;
    gap:10px;
  }

  .header-top{
    justify-content:flex-end;
    margin-bottom:6px;
  }

  .logo{
    width:min(240px, 72vw);
    max-width:72vw;
  }

  .hero{
    margin:0 auto 14px;
  }

  .hero-grid{
    grid-template-columns:1fr;
    gap:10px;
    margin:10px auto 0;
  }

  .hero-stat{
    border-radius:16px;
    padding:12px 14px;
  }

  .hero-stat strong{
    font-size:18px;
  }

  .card{
    border-radius:22px;
    padding:14px 12px 18px;
  }

  .tabs{
    top:8px;
    margin:0 0 16px;
    padding:6px;
    gap:6px;
    border-radius:14px;
    scroll-snap-type:x proximity;
    -webkit-overflow-scrolling:touch;
  }

  .tabbtn{
    min-height:42px;
    padding:10px 12px;
    font-size:12px;
    scroll-snap-align:start;
  }

  .title{
    font-size:22px;
    line-height:1.15;
  }

  .sub{
    font-size:14px;
    margin-bottom:14px;
  }

  .drop{
    padding:18px 14px;
    border-radius:18px;
  }

  .drop .icon{
    width:40px;
    height:40px;
    margin-bottom:10px;
  }

  .inline,
  .inputs{
    width:100%;
    flex-direction:column;
    align-items:stretch;
    gap:10px;
  }

  .inputs label,
  .inputs input,
  .inputs select,
  .inputs button,
  .inline button,
  .btn,
  .youtube-url-input,
  #maxmb,
  #every,
  #ranges,
  #sizeMb,
  #protectPassword,
  #protectPassword2,
  #youtubeUrl,
  #instagramUrl,
  #compressQuality,
  #youtubeQuality,
  #youtubeBitrate{
    width:100% !important;
    max-width:none !important;
  }

  .inputs label{
    text-align:left;
  }

  .btn{
    min-height:46px;
    justify-content:center;
  }

  .row,
  .item{
    padding:12px;
    gap:10px;
    align-items:stretch;
  }

  .row .name,
  .item .name{
    flex:1 1 100%;
    white-space:normal;
    word-break:break-word;
    text-align:left;
  }

  .row .progress,
  .item .progress,
  .status,
  .dl,
  .item .btn,
  .row .btn{
    width:100%;
  }

  .status{
    justify-content:flex-start;
  }

  .youtube-inline-row,
  .youtube-mode-row,
  .youtube-options,
  .youtube-panel .inputs{
    align-items:stretch;
    text-align:left;
  }

  .youtube-meta{
    grid-template-columns:1fr;
    gap:12px;
  }

  .youtube-thumb{
    max-width:100%;
    width:100%;
    aspect-ratio:16/9;
    object-fit:cover;
  }

  .removebg-preview-wrap{
    margin-top:14px;
    gap:14px;
  }

  .removebg-strength,
  .removebg-preview-card{
    border-radius:18px;
  }

  .removebg-preview-head{
    flex-direction:column;
    align-items:flex-start;
  }

  .cookie-footer-link{
    display:none;
  }

  .cookie-notice{
    left:12px;
    right:12px;
    bottom:12px;
    max-width:none;
  }

  .cookie-panel{
    left:12px;
    right:12px;
    bottom:112px;
    width:auto;
  }

  .cookie-panel-actions{
    flex-direction:column;
    align-items:stretch;
  }
}

@media (max-width: 480px){
  body{
    padding-bottom:150px;
  }

  .header-top{
    justify-content:center;
  }

  .lang-current{
    width:52px;
    height:52px;
    border-radius:16px;
  }

  .lang-flag-img{
    width:24px;
    height:18px;
  }

  .tabs{
    margin-bottom:14px;
  }

  .tabbtn{
    font-size:11px;
    padding:10px 11px;
  }

  .title{
    font-size:20px;
  }

  .sub,
  .note{
    font-size:13px;
  }

  .card{
    padding:12px 10px 16px;
  }

  .drop{
    padding:16px 12px;
  }

  .cookie-panel-card,
  .cookie-notice{
    border-radius:14px;
  }
}


.btn-featured{
  background:linear-gradient(135deg, #f59e0b, #fbbf24);
  color:#1f2937;
  border-color:#f59e0b;
  box-shadow:0 12px 28px rgba(245,158,11,.28);
}

.btn-featured:hover{
  transform:translateY(-1px);
  box-shadow:0 16px 34px rgba(245,158,11,.34);
}

.youtube-url-textarea{
  min-height:110px;
  resize:vertical;
  padding:12px 14px;
}

.youtube-batch-hint{
  margin:12px 0 0;
  text-align:left;
}

.youtube-meta.simple{
  grid-template-columns:1fr;
}

.youtube-batch-list{
  margin-top:14px;
  display:grid;
  gap:10px;
}

.youtube-batch-item{
  padding:12px;
  border:1px solid var(--stroke);
  border-radius:16px;
  background:#fff;
  box-shadow:var(--shadow-soft);
  text-align:left;
}

.youtube-batch-item-top{
  display:flex;
  justify-content:space-between;
  gap:12px;
  align-items:flex-start;
}

.youtube-batch-item-top strong{
  font-size:14px;
  line-height:1.35;
}

.youtube-batch-item-top span{
  color:var(--muted);
  font-size:12px;
  white-space:nowrap;
}

.youtube-batch-item-url{
  margin-top:6px;
  color:var(--muted);
  font-size:12px;
  word-break:break-all;
}

.youtube-batch-item-actions{
  margin-top:10px;
  display:flex;
  gap:8px;
  flex-wrap:wrap;
}

/* --- ADVANCED UI (TOASTS, SPINNERS, THEME) --- */

.toast-container {
  position: fixed;
  top: 80px;
  right: 20px;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  gap: 10px;
  pointer-events: none;
}

.toast {
  background: var(--card);
  color: var(--fg);
  border: 1px solid var(--stroke);
  padding: 14px 20px;
  border-radius: 12px;
  box-shadow: 0 10px 30px -5px rgba(0,0,0,0.15);
  font-size: 14px;
  font-weight: 500;
  display: flex;
  align-items: center;
  gap: 10px;
  pointer-events: auto;
  transform: translateX(120%);
  opacity: 0;
  transition: transform 0.4s cubic-bezier(0.2, 0.8, 0.2, 1), opacity 0.4s ease;
}

.toast.show {
  transform: translateX(0);
  opacity: 1;
}

.toast.error {
  border-left: 4px solid var(--danger);
}

.toast.success {
  border-left: 4px solid #10b981;
}

.toast.info {
  border-left: 4px solid var(--brand);
}

.btn.loading {
  position: relative;
  color: transparent !important;
  pointer-events: none;
}

.btn.loading::after {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 20px;
  height: 20px;
  margin-top: -10px;
  margin-left: -10px;
  border: 2px solid rgba(255,255,255,0.3);
  border-top-color: #fff;
  border-radius: 50%;
  animation: spinner 0.6s linear infinite;
}

@keyframes spinner {
  to { transform: rotate(360deg); }
}

#themeToggleBtn {
  background: transparent;
  border: none;
  color: var(--muted);
  font-size: 20px;
  cursor: pointer;
  padding: 8px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s, color 0.2s;
}

#themeToggleBtn:hover {
  background: var(--soft);
  color: var(--fg);
}

#installAppBtn {
  background: var(--card);
  border: 1px solid var(--stroke);
  color: var(--brand);
  padding: 6px 14px;
  border-radius: 99px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  transition: background-color .2s ease, border-color .2s ease, color .2s ease, box-shadow .2s ease, transform .2s ease;
  box-shadow: var(--shadow-soft);
}

#installAppBtn:hover {
  border-color: var(--brand);
  transform: translateY(-1px);
}

/* --- DARK MODE HOTFIX FOR HARDCODED COLORS --- */
:root[data-theme="dark"] .hero-stat,
:root[data-theme="dark"] .card,
:root[data-theme="dark"] .lang-current,
:root[data-theme="dark"] .lang-menu,
:root[data-theme="dark"] .footer,
:root[data-theme="dark"] .btn.alt,
:root[data-theme="dark"] .cookie-notice,
:root[data-theme="dark"] .cookie-panel-card,
:root[data-theme="dark"] .removebg-strength,
:root[data-theme="dark"] .removebg-preview-card,
:root[data-theme="dark"] .youtube-batch-item,
:root[data-theme="dark"] .cookie-footer-link {
  background: var(--card) !important;
  color: var(--fg) !important;
  border-color: var(--stroke) !important;
}

:root[data-theme="dark"] .checkerboard {
  background-color: var(--card) !important;
  background-image: 
    linear-gradient(45deg, var(--soft) 25%, transparent 25%),
    linear-gradient(-45deg, var(--soft) 25%, transparent 25%),
    linear-gradient(45deg, transparent 75%, var(--soft) 75%),
    linear-gradient(-45deg, transparent 75%, var(--soft) 75%) !important;
}

:root[data-theme="dark"] .lang-current:hover,
:root[data-theme="dark"] .btn.alt:hover,
:root[data-theme="dark"] .cookie-footer-link:hover {
  background: var(--soft) !important;
}



/* ===== Mobile UI fixes (May 2026) ===== */
img, svg, canvas { max-width: 100%; }

.youtube-url-input,
textarea.youtube-url-textarea,
#youtubeClipUrl {
  width: 100%;
  max-width: 100%;
}

#youtubeUrl {
  min-height: 110px;
}

#youtubeClipUrl {
  max-width: 620px;
  margin: 0 auto;
}

.media-grid {
  align-items: stretch;
}

@media (max-width: 900px) {
  .card { padding: 18px 12px; border-radius: 18px; }
  .wrap { padding: 0 10px; }
  .hero-grid { grid-template-columns: 1fr; gap: 10px; }
  .media-grid { grid-template-columns: 1fr; gap: 12px; }
  .youtube-panel, .instagram-card, .media-download-card {
    padding: 14px;
    border-radius: 16px;
  }
  .inputs { gap: 8px; }
  .btn { min-height: 44px; width: 100%; }
  .youtube-inline-row { flex-direction: column; align-items: stretch; }
  .youtube-inline-row > * { width: 100% !important; max-width: 100% !important; }
}

@media (max-width: 640px) {
  .title { font-size: 22px; }
  .sub { font-size: 14px; line-height: 1.45; }
  .main-tabs { gap: 6px; padding: 4px; }
  .tool-tabs { margin-top: 14px; padding-top: 14px; }
  .main-tab { padding: 10px 12px; font-size: 13px; }
  .tool-tab { padding: 9px 10px; font-size: 12px; }
  .drop { padding: 22px 12px; border-radius: 16px; }
  #youtubeUrl { min-height: 92px; }
  #youtubeClipUrl { max-width: 100%; }
}


/* skeleton */
.skeleton{ position:relative; min-height:72px; border-radius:14px; background:linear-gradient(90deg,#e2e8f0 25%, #f1f5f9 37%, #e2e8f0 63%); background-size:400% 100%; animation:sh 1.2s ease infinite; }
.skeleton *{ visibility:hidden !important; }
@keyframes sh{ 0%{background-position:100% 0} 100%{background-position:0 0} }

@media (max-width: 760px){
  #tab-instagram-tools .btn, #tab-youtube-clip .btn { width:100%; }
  #tab-instagram-tools [style*="grid-template-columns"]{ grid-template-columns:1fr !important; }
}


/* Center media single panel */
#tab-youtube .media-grid{
  grid-template-columns: minmax(0, 980px);
  justify-content: center;
}
#tab-youtube .media-download-card{
  margin: 0 auto;
}
#tab-youtube .media-tool-title,
#tab-youtube .youtube-batch-hint,
#tab-youtube #youtubeStatus,
#tab-youtube #youtubeErr,
#tab-youtube #youtubeMeta,
#tab-youtube .youtube-result{
  text-align: center !important;
}


/* clip url normalize */
#tab-youtube-clip .youtube-panel{
  max-width: 980px;
  margin: 0 auto;
}
#youtubeClipUrl{
  display:block;
  width:100%;
  max-width:100%;
  height:46px;
  padding:10px 12px;
  border-radius:12px;
}
@media (max-width:640px){
  #youtubeClipUrl{ height:44px; }
}


/* clip input hard reset */
#tab-youtube-clip #youtubeClipUrl.clip-url-input{
  display:block !important;
  width:100% !important;
  max-width:760px !important;
  height:46px !important;
  min-height:46px !important;
  max-height:46px !important;
  line-height:24px !important;
  padding:10px 12px !important;
  margin:0 auto !important;
  border-radius:12px !important;
  resize:none !important;
  flex:0 0 auto !important;
}
@media (max-width:640px){
  #tab-youtube-clip #youtubeClipUrl.clip-url-input{
    max-width:100% !important;
    height:44px !important;
    min-height:44px !important;
    max-height:44px !important;
  }
}


.media-icon-tab{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  gap:8px;
}
.media-icon-tab svg{
  flex:0 0 auto;
}
.tool-tab.active.media-icon-tab svg[fill="#e1306c"]{
  fill:#fff;
}


/* ===== UI audit consolidation 2026-05-04 ===== */
.wrap{
  max-width:1280px;
}
.card{
  padding:28px;
}
.hero-grid{
  max-width:900px;
}
.nav-shell{
  max-width:980px;
  margin-bottom:24px;
}
.tool-tabs{
  gap:10px;
}
.tool-tab:empty::before{
  content:"Baixar v?deos";
}
.media-brand-title{
  display:flex;
  align-items:center;
  justify-content:center;
  gap:12px;
}
.media-tool-shell{
  width:min(100%, 1040px);
  margin:0 auto;
}
.media-tool-shell-narrow{
  width:min(100%, 980px);
}
.media-panel-clean{
  width:100%;
  margin:0 auto;
  padding:22px;
  border-radius:18px;
  text-align:left;
}
.media-tool-title{
  text-align:center;
  margin:0 0 8px;
  font-size:21px;
  letter-spacing:0;
}
.media-field-stack{
  display:grid;
  gap:8px;
  width:100%;
}
.media-field-stack .small{
  min-height:16px;
  text-align:center;
}
.youtube-url-textarea{
  width:100%;
  min-height:108px;
  max-height:220px;
  resize:vertical;
  border-radius:12px;
  padding:12px 14px;
}
.clip-url-input,
.social-url-input{
  display:block;
  width:100%;
  height:46px;
  min-height:46px;
  max-height:46px;
  border-radius:12px;
  padding:10px 12px;
  line-height:24px;
}
#tab-youtube-clip #youtubeClipUrl.clip-url-input{
  max-width:100% !important;
}
.media-action-strip{
  display:grid;
  grid-template-columns:auto auto minmax(180px, 1fr);
  gap:12px;
  align-items:center;
  margin-top:14px;
  padding:14px;
  border-radius:14px;
  background:var(--soft);
}
.media-action-strip label{
  display:flex;
  align-items:center;
  justify-content:center;
  gap:6px;
  font-weight:700;
}
.media-action-strip .btn{
  width:100%;
}
.media-options-panel{
  margin-top:10px;
  padding:12px 14px;
  border-radius:14px;
  background:var(--soft);
}
.media-options-panel .inputs{
  margin-top:0;
}
.media-options-panel select,
.clip-control-grid select,
.clip-control-grid input{
  width:100%;
}
.clip-control-grid{
  display:grid;
  grid-template-columns:auto minmax(220px, 1fr) auto minmax(92px, 120px) auto minmax(92px, 120px);
  gap:10px;
  align-items:center;
  margin-top:12px;
}
.clip-control-grid label{
  font-weight:700;
  white-space:nowrap;
}
.media-command-row{
  display:flex;
  justify-content:center;
  margin-top:14px;
}
.media-command-row .btn{
  min-width:180px;
}
.instagram-action-grid{
  display:grid;
  grid-template-columns:repeat(2, minmax(0, 1fr));
  gap:10px;
  margin-top:12px;
}
.instagram-action-grid .btn:last-child{
  grid-column:1 / -1;
}
.youtube-meta{
  max-width:100%;
  overflow:hidden;
}
.youtube-meta-copy{
  min-width:0;
}
.youtube-meta-copy strong,
.youtube-meta-copy span{
  overflow-wrap:anywhere;
}
.skeleton{
  min-height:84px;
  border:1px solid var(--stroke);
}
@media (max-width: 900px){
  .card{
    padding:18px 12px;
  }
  .nav-shell{
    margin-bottom:20px;
  }
  .media-panel-clean{
    padding:16px;
  }
  .media-action-strip{
    grid-template-columns:1fr 1fr;
  }
  .media-action-strip .btn{
    grid-column:1 / -1;
  }
  .clip-control-grid{
    grid-template-columns:1fr 1fr;
  }
  .clip-control-grid label{
    align-self:end;
  }
  .clip-control-grid label:first-child,
  .clip-control-grid select{
    grid-column:1 / -1;
  }
}
@media (max-width: 640px){
  .wrap{
    padding:0 8px;
  }
  .card{
    padding:14px 10px;
    border-radius:16px;
  }
  .hero{
    margin-bottom:12px;
  }
  .hero-grid{
    margin-top:10px;
  }
  .hero-stat{
    padding:11px 12px;
  }
  .hero-stat strong{
    font-size:17px;
  }
  .main-tabs,
  .tool-tabs{
    padding-bottom:6px;
  }
  .main-tab,
  .tool-tab{
    min-height:42px;
  }
  .title{
    font-size:22px;
  }
  .sub{
    margin-bottom:12px;
  }
  .media-brand-title svg{
    width:24px;
    height:24px;
  }
  .media-panel-clean{
    padding:14px;
    border-radius:14px;
  }
  .youtube-url-textarea{
    min-height:92px;
  }
  .clip-url-input,
  .social-url-input{
    height:44px;
    min-height:44px;
    max-height:44px;
  }
  .media-action-strip,
  .clip-control-grid,
  .instagram-action-grid{
    grid-template-columns:1fr;
  }
  .media-command-row .btn,
  .instagram-action-grid .btn{
    width:100%;
  }
  .youtube-meta{
    grid-template-columns:1fr;
    text-align:center;
  }
  .youtube-meta-thumb{
    margin:0 auto;
  }
}


/* ===== UI audit final polish 2026-05-04 ===== */
.cookie-notice .btn{
  width:auto;
}
.cookie-notice-actions{
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:8px;
}
.cookie-notice-actions #cookieAccept{
  grid-column:1 / -1;
}
@media (max-width: 640px){
  body{
    padding-bottom:104px;
  }
  .cookie-notice{
    left:10px;
    right:10px;
    bottom:10px;
    max-width:none;
    gap:8px;
    padding:10px;
    border-radius:14px;
  }
  .cookie-notice-copy p{
    display:none;
  }
  .cookie-notice-copy strong{
    margin-bottom:2px;
  }
  .cookie-notice-actions{
    grid-template-columns:1fr 1fr 1fr;
  }
  .cookie-notice-actions #cookieAccept{
    grid-column:auto;
  }
  .cookie-notice .btn{
    width:100%;
    min-height:40px;
    padding:9px 10px;
    font-size:12px;
  }
  .cookie-policy-link{
    font-size:12px;
  }
  .tool-tabs{
    gap:7px;
  }
  .tool-tab{
    flex:0 0 auto;
  }
}
@media (max-width: 390px){
  .cookie-notice-actions{
    grid-template-columns:1fr;
  }
  .cookie-notice-actions #cookieAccept{
    grid-column:1;
  }
}


/* ===== UI audit cookie correction 2026-05-04 ===== */
@media (max-width: 640px){
  .cookie-notice-actions{
    grid-template-columns:1fr 1fr;
  }
  .cookie-notice-actions #cookieAccept{
    grid-column:1 / -1;
  }
  .cookie-notice-actions .btn{
    min-width:0;
    white-space:normal;
  }
}


/* ===== UI audit mobile main nav 2026-05-04 ===== */
@media (max-width: 640px){
  .main-tabs{
    display:grid;
    grid-template-columns:repeat(2, minmax(0, 1fr));
    overflow:visible;
  }
  .main-tab{
    width:100%;
    min-width:0;
    white-space:normal;
    line-height:1.15;
  }
  .main-tab-label{
    overflow-wrap:anywhere;
  }
}


/* ===== UI audit mobile label wrapping 2026-05-04 ===== */
@media (max-width: 640px){
  .main-tabs .main-tab{
    min-width:0 !important;
    width:100% !important;
    white-space:normal !important;
  }
  .main-tabs .main-tab-label{
    white-space:normal !important;
    overflow-wrap:normal;
    word-break:normal;
  }
}


/* ===== Retro web 90s/00s skin 2026-05-04 ===== */
:root{
  --brand:#003f9e;
  --brand-strong:#001f58;
  --bg:#d8e4f4;
  --fg:#06152f;
  --muted:#314c73;
  --card:#f8fbff;
  --stroke:#5f7da8;
  --stroke-strong:#284b80;
  --soft:#d7e5f8;
  --soft-2:#edf5ff;
  --shadow:6px 6px 0 rgba(0,31,88,.22);
  --shadow-soft:3px 3px 0 rgba(0,31,88,.16);
  --glow:0 0 0 3px rgba(255,213,0,.35);
  --danger:#b00020;
  --accent:#ffd500;
  --accent-2:#00a6a6;
}

html,
body{
  background-color:#c8d7ea;
  background-image:
    linear-gradient(45deg, rgba(255,255,255,.30) 25%, transparent 25%),
    linear-gradient(-45deg, rgba(255,255,255,.30) 25%, transparent 25%),
    linear-gradient(45deg, transparent 75%, rgba(255,255,255,.30) 75%),
    linear-gradient(-45deg, transparent 75%, rgba(255,255,255,.30) 75%);
  background-size:28px 28px;
  background-position:0 0, 0 14px, 14px -14px, -14px 0;
}

body{
  font-family:Verdana, Geneva, Tahoma, sans-serif;
}

body::before{
  height:180px;
  background:linear-gradient(180deg, rgba(0,63,158,.16), transparent);
}

.card,
.hero-stat,
.youtube-panel,
.removebg-strength,
.removebg-preview-card,
.cookie-notice,
.cookie-panel-card,
.cookie-footer-link,
.lang-current,
.lang-menu{
  background:#f8fbff;
  border:2px solid var(--stroke-strong);
  border-radius:2px !important;
  box-shadow:var(--shadow-soft);
}

.card{
  box-shadow:var(--shadow);
}

.logo{
  filter:drop-shadow(4px 4px 0 rgba(0,31,88,.18));
}

.hero-stat{
  background:linear-gradient(180deg, #ffffff 0%, #e8f1ff 100%);
}

.hero-stat strong,
.title,
.media-tool-title{
  color:#001f58;
  text-shadow:1px 1px 0 #fff;
}

.main-tabs,
.tool-tabs{
  border-radius:2px !important;
}

.main-tabs{
  background:#adc4e4;
  border:2px solid #284b80;
  padding:5px;
}

.main-tab,
.tool-tab{
  border-radius:2px !important;
  color:#001f58;
  font-weight:700;
}

.main-tab.active,
.tool-tab.active,
.btn{
  background:linear-gradient(180deg, #1d70ff 0%, #003f9e 100%);
  color:#fff;
  border:2px solid #001f58;
  box-shadow:3px 3px 0 rgba(0,31,88,.28);
  text-shadow:1px 1px 0 rgba(0,0,0,.35);
}

.main-tab.active{
  background:linear-gradient(180deg, #ffffff 0%, #dceaff 100%);
  color:#001f58;
  text-shadow:none;
}

.tool-tab,
.btn.alt,
.btn.secondary{
  background:linear-gradient(180deg, #ffffff 0%, #dceaff 100%);
  border:2px solid #5f7da8;
  color:#001f58;
  box-shadow:2px 2px 0 rgba(0,31,88,.18);
}

.btn:hover,
.tool-tab:hover,
.btn.alt:hover,
.btn.secondary:hover{
  transform:translate(-1px,-1px);
  box-shadow:4px 4px 0 rgba(0,31,88,.24);
}

.btn:active,
.tool-tab:active{
  transform:translate(1px,1px);
  box-shadow:1px 1px 0 rgba(0,31,88,.22);
}

.drop,
.youtube-options,
.media-options-panel,
.media-action-strip,
.youtube-mode-row{
  background:#e8f1ff;
  border:2px dashed #5f7da8;
  border-radius:2px !important;
}

.drop.dragover{
  background:#fff7bf;
  border-color:#003f9e;
}

.drop .icon{
  color:#003f9e;
}

input[type="text"],
input[type="number"],
input[type="url"],
input[type="password"],
textarea,
select{
  background:#ffffff;
  border:2px inset #adc4e4;
  border-radius:0 !important;
  color:#06152f;
  font-family:"Courier New", Courier, monospace;
}

input[type="text"]:focus-visible,
input[type="number"]:focus-visible,
input[type="url"]:focus-visible,
input[type="password"]:focus-visible,
textarea:focus-visible,
select:focus-visible{
  border-color:#003f9e;
  box-shadow:0 0 0 3px #ffd500;
}

.youtube-meta,
.youtube-batch-item,
.row,
.item{
  background:#ffffff;
  border:2px solid #adc4e4;
  border-radius:2px !important;
}

.progress{
  background:#adc4e4;
  border:1px solid #284b80;
  border-radius:0 !important;
}

.progress > div,
.youtube-progress-bar > div{
  background:repeating-linear-gradient(45deg, #003f9e 0 8px, #00a6a6 8px 16px);
}

.media-brand-title svg{
  filter:drop-shadow(1px 1px 0 #fff) saturate(1.2);
}

.cookie-policy-link,
.cookie-footer-link,
.footer-link{
  color:#003f9e;
  text-decoration:underline;
}

.skeleton{
  background:repeating-linear-gradient(90deg, #dceaff 0 18px, #f8fbff 18px 36px);
  background-size:200% 100%;
}

.lang-current,
.lang-option,
.lang-flag-img,
.badge,
.cookie-badge,
.youtube-meta-thumb,
.thumb{
  border-radius:2px !important;
}

@media (max-width:640px){
  .card,
  .hero-stat,
  .youtube-panel,
  .cookie-notice,
  .drop{
    border-radius:2px !important;
  }
  .main-tabs{
    gap:5px;
  }
}

:root[data-theme="dark"]{
  --brand:#8fb8ff;
  --brand-strong:#eaf2ff;
  --bg:#07111f;
  --fg:#f4f8ff;
  --muted:#b7c7dd;
  --card:#101d31;
  --stroke:#42628f;
  --stroke-strong:#7fa7dc;
  --soft:#172942;
  --soft-2:#0d1a2d;
  --accent:#ffd500;
  --accent-2:#4fd1c5;
}


/* ===== Windows XP skin 2026-05-04 ===== */
:root{
  --brand:#245edb;
  --brand-strong:#003399;
  --bg:#7db6ff;
  --fg:#071b45;
  --muted:#2f4f7d;
  --card:#ece9d8;
  --stroke:#7f9db9;
  --stroke-strong:#0a246a;
  --soft:#dbe8fb;
  --soft-2:#f6f7fb;
  --shadow:7px 7px 0 rgba(0,35,102,.18);
  --shadow-soft:3px 3px 0 rgba(0,35,102,.15);
  --glow:0 0 0 2px rgba(255,199,60,.75);
  --danger:#a40000;
  --accent:#73d216;
  --accent-2:#ffc73c;
}

html,
body{
  background-color:#6fb1ff;
  background-image:
    radial-gradient(circle at 72% 16%, rgba(255,255,255,.86) 0 34px, transparent 35px),
    radial-gradient(circle at 62% 20%, rgba(255,255,255,.55) 0 22px, transparent 23px),
    linear-gradient(180deg, #77b9ff 0%, #bfe1ff 52%, #7ec26d 53%, #43a044 100%);
  background-attachment:fixed;
}

body{
  font-family:Tahoma, Verdana, Geneva, sans-serif;
  color:var(--fg);
}

body::before{
  height:100%;
  background:
    linear-gradient(120deg, transparent 0 54%, rgba(255,255,255,.18) 54% 56%, transparent 56%),
    linear-gradient(165deg, transparent 0 62%, rgba(53,130,55,.25) 62% 100%);
  opacity:.9;
}

.header-top{
  padding-right:4px;
}

.logo{
  filter:drop-shadow(3px 4px 0 rgba(0,35,102,.18));
}

.card{
  position:relative;
  padding-top:44px;
  background:#ece9d8;
  border:2px solid #0a246a;
  border-radius:7px 7px 3px 3px !important;
  box-shadow:var(--shadow);
}

.card::before{
  content:"MeloTools - Painel de ferramentas";
  position:absolute;
  left:0;
  right:0;
  top:0;
  height:30px;
  display:flex;
  align-items:center;
  padding:0 12px;
  color:#fff;
  font-weight:700;
  font-size:13px;
  text-shadow:1px 1px 0 rgba(0,0,0,.45);
  background:linear-gradient(180deg, #3f8cff 0%, #245edb 48%, #0a3cba 100%);
  border-radius:4px 4px 0 0;
  box-shadow:inset 0 1px 0 rgba(255,255,255,.65);
}

.hero-stat,
.youtube-panel,
.removebg-strength,
.removebg-preview-card,
.cookie-notice,
.cookie-panel-card,
.cookie-footer-link,
.lang-current,
.lang-menu{
  background:#ece9d8;
  border:2px solid;
  border-color:#ffffff #808080 #808080 #ffffff;
  border-radius:2px !important;
  box-shadow:var(--shadow-soft);
}

.hero-stat{
  background:linear-gradient(180deg,#fff 0%,#ece9d8 100%);
}

.hero-stat strong,
.title,
.media-tool-title{
  color:#071b45;
  text-shadow:1px 1px 0 #fff;
}

.main-tabs{
  background:#d4d0c8;
  border:2px solid;
  border-color:#808080 #ffffff #ffffff #808080;
  border-radius:0 !important;
  padding:5px;
}

.main-tab,
.tool-tab{
  font-family:Tahoma, Verdana, Geneva, sans-serif;
  color:#071b45;
  border-radius:3px 3px 0 0 !important;
  font-weight:700;
}

.main-tab.active{
  background:linear-gradient(180deg,#ffffff 0%,#ece9d8 100%);
  color:#071b45;
  border:2px solid;
  border-color:#ffffff #808080 #ece9d8 #ffffff;
  box-shadow:none;
}

.tool-tab,
.btn.alt,
.btn.secondary{
  background:linear-gradient(180deg,#ffffff 0%,#d7d3c7 100%);
  border:2px solid;
  border-color:#ffffff #707070 #707070 #ffffff;
  color:#071b45;
  box-shadow:1px 1px 0 rgba(0,0,0,.20);
}

.tool-tab.active,
.btn{
  background:linear-gradient(180deg,#79a8ff 0%,#245edb 45%,#0b3aaa 100%);
  border:2px solid;
  border-color:#bcd4ff #001f75 #001f75 #bcd4ff;
  color:#fff;
  box-shadow:1px 1px 0 rgba(0,0,0,.35);
  text-shadow:1px 1px 0 rgba(0,0,0,.55);
}

.btn:hover,
.tool-tab:hover,
.btn.alt:hover,
.btn.secondary:hover{
  filter:brightness(1.04);
  transform:none;
  box-shadow:1px 1px 0 rgba(0,0,0,.35);
}

.btn:active,
.tool-tab:active{
  border-color:#001f75 #bcd4ff #bcd4ff #001f75;
  transform:translate(1px,1px);
  box-shadow:none;
}

.drop,
.youtube-options,
.media-options-panel,
.media-action-strip,
.youtube-mode-row{
  background:#f5f4ea;
  border:2px solid;
  border-color:#808080 #ffffff #ffffff #808080;
  border-radius:2px !important;
}

.drop.dragover{
  background:#fff6bf;
  border-color:#245edb;
}

.drop .icon{
  color:#245edb;
}

input[type="text"],
input[type="number"],
input[type="url"],
input[type="password"],
textarea,
select{
  background:#ffffff;
  border:2px solid;
  border-color:#808080 #ffffff #ffffff #808080;
  border-radius:0 !important;
  color:#071b45;
  font-family:"Courier New", Courier, monospace;
}

input[type="text"]:focus-visible,
input[type="number"]:focus-visible,
input[type="url"]:focus-visible,
input[type="password"]:focus-visible,
textarea:focus-visible,
select:focus-visible{
  outline:1px dotted #000;
  border-color:#245edb;
  box-shadow:0 0 0 2px #ffc73c;
}

.youtube-meta,
.youtube-batch-item,
.row,
.item{
  background:#ffffff;
  border:2px solid;
  border-color:#808080 #ffffff #ffffff #808080;
  border-radius:0 !important;
}

.progress{
  background:#d4d0c8;
  border:2px solid;
  border-color:#808080 #ffffff #ffffff #808080;
  border-radius:0 !important;
}

.progress > div,
.youtube-progress-bar > div{
  background:linear-gradient(180deg,#73d216,#3d9b1f);
}

.cookie-policy-link,
.cookie-footer-link,
.footer-link{
  color:#003399;
  text-decoration:underline;
}

.skeleton{
  background:repeating-linear-gradient(90deg,#d4d0c8 0 16px,#f5f4ea 16px 32px);
  background-size:200% 100%;
}

.lang-current,
.lang-option,
.lang-flag-img,
.badge,
.cookie-badge,
.youtube-meta-thumb,
.thumb{
  border-radius:2px !important;
}

.cookie-notice .btn.secondary{
  background:linear-gradient(180deg,#ffffff 0%,#d7d3c7 100%);
}

@media (max-width:640px){
  .card{
    padding-top:40px;
    border-radius:6px 6px 2px 2px !important;
  }
  .card::before{
    height:28px;
    font-size:12px;
  }
  .hero-stat,
  .youtube-panel,
  .cookie-notice,
  .drop{
    border-radius:2px !important;
  }
}

:root[data-theme="dark"]{
  --brand:#8fb8ff;
  --brand-strong:#eaf2ff;
  --bg:#07111f;
  --fg:#f4f8ff;
  --muted:#b7c7dd;
  --card:#101d31;
  --stroke:#42628f;
  --stroke-strong:#7fa7dc;
  --soft:#172942;
  --soft-2:#0d1a2d;
  --accent:#ffc73c;
  --accent-2:#73d216;
}


/* ===== Windows XP text fitting 2026-05-04 ===== */
html,
body,
button,
input,
select,
textarea,
.btn,
.tabbtn,
.main-tab,
.tool-tab{
  font-family:Tahoma, "MS Sans Serif", Geneva, Verdana, sans-serif !important;
}

button,
.btn,
.tabbtn,
.main-tab,
.tool-tab,
.cookie-notice .btn,
.instagram-action-grid .btn,
.media-command-row .btn{
  white-space:normal !important;
  overflow-wrap:anywhere;
  word-break:normal;
  line-height:1.18;
  text-align:center;
}

.main-tab,
.tool-tab{
  min-width:0;
  max-width:100%;
}

.main-tab-label{
  display:block;
  white-space:normal !important;
  overflow-wrap:anywhere;
  line-height:1.15;
}

.tool-tabs{
  align-items:stretch;
}

.tool-tab{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  min-height:44px;
  padding:9px 14px;
}

.main-tab{
  display:flex;
  align-items:center;
  justify-content:center;
  min-height:48px;
  padding:8px 10px;
}

.btn{
  min-height:42px;
  padding:9px 14px;
}

.cookie-notice-actions .btn{
  min-width:0;
  padding-left:8px;
  padding-right:8px;
}

@media (max-width:640px){
  .main-tabs{
    grid-template-columns:repeat(2, minmax(0, 1fr));
  }
  .main-tab{
    font-size:12px;
    min-height:52px;
    padding:8px 6px;
  }
  .tool-tab{
    font-size:12px;
    min-height:42px;
    padding:8px 10px;
    flex:0 0 auto;
    max-width:min(68vw, 220px);
  }
  .tool-tabs{
    overflow-x:auto;
    flex-wrap:nowrap;
  }
  .cookie-notice .btn{
    font-size:11px;
  }
  .instagram-action-grid .btn,
  .media-command-row .btn{
    width:100%;
  }
}

@media (max-width:380px){
  .main-tab{
    font-size:11px;
  }
  .tool-tab{
    font-size:11px;
    max-width:74vw;
  }
}


/* ===== Dark mode removed 2026-05-04 ===== */
#themeToggleBtn{ display:none !important; }
html[data-theme="dark"]{ color-scheme:light; }


/* ===== XP background swap 2026-05-04 ===== */
html,
body{
  background-color:#6fa9ee;
  background-image:
    radial-gradient(circle at 72% 14%, rgba(255,255,255,.92) 0 36px, transparent 37px),
    radial-gradient(circle at 63% 19%, rgba(255,255,255,.58) 0 24px, transparent 25px),
    linear-gradient(180deg, #72b3ff 0%, #bcdfff 50%, #79c55c 51%, #3fa238 100%);
  background-attachment:fixed;
}

body::before{
  height:100%;
  background:
    linear-gradient(120deg, transparent 0 55%, rgba(255,255,255,.18) 55% 57%, transparent 57%),
    linear-gradient(170deg, transparent 0 63%, rgba(70,150,61,.24) 63% 100%);
  opacity:.95;
}


/* ===== Windows XP design review 2026-05-04 ===== */
.wrap{ max-width:1280px; }

.card{ border:2px solid #0a246a !important; border-radius:7px 7px 3px 3px !important; background:#ece9d8 !important; }
.card::before{ content:"MeloTools - Painel de ferramentas"; letter-spacing:0; font-family:Tahoma,"MS Sans Serif",Verdana,sans-serif; }

.main-tab,.tool-tab,.btn,.btn.alt,.btn.secondary,input,select,textarea{ font-family:Tahoma,"MS Sans Serif",Verdana,sans-serif !important; letter-spacing:0 !important; }

.main-tabs{ border:2px solid #7f9db9 !important; background:linear-gradient(180deg,#c4d6ef 0%, #9fb7da 100%) !important; }
.main-tab{ min-height:44px; border:1px solid transparent; }
.main-tab.active{ border:2px solid !important; border-color:#ffffff #808080 #ece9d8 #ffffff !important; background:linear-gradient(180deg,#ffffff 0%, #ece9d8 100%) !important; }

.tool-tabs{ border-top:1px solid #7f9db9; padding-top:16px; }
.tool-tab{ min-height:42px; padding:8px 16px !important; }

.btn,.tool-tab.active{ border-radius:10px !important; }
.btn.alt,.btn.secondary,.tool-tab{ border-radius:8px !important; }

.youtube-panel,.removebg-strength,.removebg-preview-card{ background:#f3f0e4 !important; border:2px solid !important; border-color:#ffffff #808080 #808080 #ffffff !important; }

input[type="text"],input[type="number"],input[type="url"],input[type="password"],textarea,select{ background:#fff !important; border:2px solid !important; border-color:#808080 #ffffff #ffffff #808080 !important; border-radius:0 !important; }

.progress{ border:1px solid #5e7ea8 !important; background:#c5d4e8 !important; }
.progress > div,.youtube-progress-bar > div{ background:linear-gradient(180deg,#72d24c 0%, #3a9a1f 100%) !important; }

.cookie-notice{ border:2px solid #0a246a !important; border-radius:4px !important; }

@media (max-width:640px){
  .main-tab,.tool-tab,.btn{ white-space:normal !important; line-height:1.15 !important; overflow-wrap:anywhere !important; }
  .main-tabs{ grid-template-columns:repeat(2,minmax(0,1fr)) !important; }
  .tool-tabs{ overflow-x:auto; flex-wrap:nowrap !important; }
}


/* ===== Windows XP footer alignment 2026-05-04 ===== */
.footer{
  margin-top:18px;
  padding:8px 12px;
  border:2px solid;
  border-color:#ffffff #808080 #808080 #ffffff;
  background:linear-gradient(180deg,#f8f6ee 0%, #e5e0d3 100%);
  color:#1a2b4d;
  font-family:Tahoma,"MS Sans Serif",Verdana,sans-serif !important;
  font-size:12px;
  line-height:1.3;
  text-align:left;
  border-radius:2px !important;
  box-shadow:1px 1px 0 rgba(0,0,0,.18);
}

.footer-link{
  color:#003399 !important;
  text-decoration:underline;
  font-weight:700;
}

.footer-link:hover{
  color:#001f75 !important;
}

.footer-sep{
  color:#5e6f8f !important;
  margin:0 6px !important;
}

@media (max-width:640px){
  .footer{
    text-align:center;
    font-size:11px;
    padding:7px 8px;
  }
}

/* XP alignment normalization */
.hero,
.hero .title,
.hero .sub,
.main-tabs,
.tool-tabs,
.media-tool-title,
.note,
.youtube-meta,
.youtube-result,
.youtube-err,
#clipStatus,
#clipResult,
#igStatus,
#igResult {
  text-align: center;
}

.youtube-panel,
.media-download-card,
.media-options-panel,
.instagram-card,
.cookie-panel-card,
.removebg-strength,
.removebg-preview-card,
.youtube-batch-hint,
.youtube-options,
.media-field-stack,
.media-field-stack-compact {
  text-align: left;
}

.youtube-panel p,
.media-download-card p,
.media-options-panel p,
.instagram-card p,
.removebg-preview-card p,
.removebg-strength p,
label,
.small {
  text-align: left;
}

.youtube-inline-row,
.media-command-row,
.clip-control-grid,
.instagram-action-grid,
.media-action-strip {
  align-items: center;
}

.youtube-url-textarea,
.clip-url-input,
.social-url-input {
  text-align: left;
}

/* XP login screen background canonical */
html,
body{
  background-color:#5f83dc !important;
  background-image:
    linear-gradient(180deg, #0b3397 0 92px, #93b4ea 92px 94px, #5f83dc 94px calc(100% - 142px), #2449b9 calc(100% - 142px) 100%) !important,
    radial-gradient(ellipse at 6% 24%, rgba(225,238,255,.76) 0 14%, rgba(183,208,250,.34) 24%, rgba(95,131,220,0) 48%) !important,
    radial-gradient(ellipse at 58% 26%, rgba(255,255,255,.12) 0 20%, rgba(95,131,220,0) 44%) !important,
    linear-gradient(90deg, rgba(255,255,255,.18) 49.95%, rgba(255,255,255,.04) 50%, rgba(255,255,255,.18) 50.05%) !important;
  background-repeat:no-repeat !important;
  background-size:100% 100%,100% 100%,100% 100%,100% 100% !important;
  background-attachment:fixed !important;
}

body::before,
body::after{
  content:none !important;
  display:none !important;
}

body{
  margin:0 !important;
  padding-bottom:0 !important;
}

/* XP image background hard override */
html,
body{
  background:#5f83dc url('/static/xp-login-bg.svg') center center / cover no-repeat fixed !important;
}

body::before,
body::after{
  content:none !important;
  display:none !important;
}

/* Logo shadow removal final */
.logo,
.logo:hover,
.logo:focus,
.logo:active{
  filter:none !important;
  box-shadow:none !important;
  text-shadow:none !important;
}

/* XP UI polish final */
html,body,
button,input,select,textarea{
  font-family:Tahoma,"MS Sans Serif",Verdana,sans-serif !important;
  letter-spacing:0 !important;
}

.card,
.drop,
.youtube-panel,
.media-download-card,
.media-options-panel,
.instagram-card,
.removebg-strength,
.removebg-preview-card,
.cookie-notice,
.cookie-panel-card,
.footer,
.hero-stat,
.lang-menu,
.lang-current,
.toast,
.youtube-batch-list .item{
  border-radius:2px !important;
  box-shadow:1px 1px 0 rgba(0,0,0,.20) !important;
}

.main-tabs,
.tool-tabs,
.nav-shell{
  border-radius:2px !important;
}

.btn,
.tabbtn,
.main-tab,
.tool-tab,
.btn.alt,
.btn.secondary{
  border-radius:2px !important;
  text-shadow:none !important;
  box-shadow:1px 1px 0 rgba(0,0,0,.26) !important;
}

input[type="text"],
input[type="number"],
input[type="url"],
input[type="password"],
textarea,
select{
  border-radius:0 !important;
  border-width:2px !important;
  border-style:solid !important;
  border-color:#808080 #ffffff #ffffff #808080 !important;
  box-shadow:none !important;
  background:#ffffff !important;
}

.title,
.sub,
.media-brand-title,
.media-tool-title,
.hero,
.hero-stat{
  text-align:center !important;
}

.note,
.small,
.youtube-panel p,
.instagram-card p,
.media-options-panel p,
label,
.footer,
.cookie-notice-copy,
.cookie-panel-head p,
.cookie-option p{
  text-align:left !important;
}

.youtube-err,
.youtube-result,
#youtubeStatus,
#clipStatus,
#clipResult,
#igStatus,
#igResult,
#videoStatus,
#mergeStatus,
#rotateStatus,
#splitStatus,
#compressStatus,
#protectStatus,
#removeBgStatus{
  text-align:center !important;
}

.youtube-inline-row,
.media-command-row,
.clip-control-grid,
.instagram-action-grid,
.media-action-strip,
.inputs{
  align-items:center !important;
}

.logo,
.logo:hover,
.logo:focus,
.logo:active{
  filter:none !important;
  box-shadow:none !important;
  transform:none !important;
}

@media (max-width:760px){
  .title{ font-size:24px !important; }
  .sub{ font-size:16px !important; }
  .main-tab,.tool-tab,.btn{ font-size:14px !important; }
}

/* XP mobile micro polish */
@media (max-width: 900px){
  .wrap{ padding:0 10px 16px !important; }
  .card{ padding:12px 10px 14px !important; }
  .hero{ margin:0 auto 10px !important; }
  .hero-grid{ gap:8px !important; }
  .hero-stat{ padding:8px 9px !important; }
}

@media (max-width: 760px){
  .header{ padding:10px 10px 6px !important; }
  .logo{ width:min(300px, 90vw) !important; }

  .main-tabs,
  .tool-tabs{
    gap:6px !important;
    margin-bottom:8px !important;
  }

  .main-tab,
  .tool-tab,
  .btn,
  .btn.alt,
  .btn.secondary{
    min-height:38px !important;
    padding:8px 10px !important;
    font-size:13px !important;
    line-height:1.2 !important;
    white-space:normal !important;
    word-break:break-word !important;
  }

  .section{ padding-top:2px !important; }
  .title{ font-size:22px !important; line-height:1.18 !important; margin-bottom:8px !important; }
  .sub{ font-size:15px !important; line-height:1.3 !important; margin-bottom:10px !important; }

  .drop,
  .youtube-panel,
  .media-download-card,
  .instagram-card,
  .media-options-panel,
  .removebg-strength,
  .removebg-preview-card{
    padding:10px !important;
  }

  .inputs,
  .youtube-inline-row,
  .media-command-row,
  .clip-control-grid,
  .instagram-action-grid,
  .media-action-strip{
    gap:8px !important;
  }

  input[type="text"],
  input[type="number"],
  input[type="url"],
  input[type="password"],
  textarea,
  select{
    min-height:38px !important;
    font-size:14px !important;
    padding:7px 8px !important;
  }

  textarea.youtube-url-textarea,
  .clip-url-input,
  .social-url-input{
    min-height:42px !important;
  }

  #youtubeOptions .inputs,
  #clipQualityWrap,
  .clip-quality-control,
  .media-field-stack,
  .media-field-stack-compact{
    width:100% !important;
  }

  .cookie-notice{
    padding:8px !important;
    gap:6px !important;
  }

  .footer{
    padding:8px 10px 10px !important;
    font-size:12px !important;
    line-height:1.35 !important;
  }
}

@media (max-width: 480px){
  .main-tab,
  .tool-tab{ font-size:12px !important; }
  .title{ font-size:20px !important; }
  .sub{ font-size:14px !important; }
  .btn{ font-size:12px !important; }
  .hero-stat strong{ font-size:13px !important; }
  .hero-stat span{ font-size:11px !important; }
}


/* Language menu overlay fix */
.header{ position: relative; z-index: 12000 !important; }
.header-top{ position: relative; z-index: 12010 !important; }
.lang-picker{ position: relative; z-index: 12020 !important; }
.lang-menu{ z-index: 12030 !important; }
.wrap, .card, .nav-shell{ position: relative; z-index: 1 !important; }
