/* PixelKit - shared styles (matches Stitch design system) */
:root{
  --primary:#2563EB; --primary-hover:#1D4ED8; --primary-soft:#EFF6FF; --on-primary-soft:#1E40AF;
  --accent:#0D9488; --accent-soft:#F0FDFA; --on-accent-soft:#0F766E;
  --bg:#FFFFFF; --text:#0F172A; --muted:#64748B; --surface:#F8FAFC; --border:#E2E8F0; --border-strong:#CBD5E1;
  --success:#16A34A; --success-soft:#DCFCE7; --warning:#F59E0B;
  --radius:12px; --shadow:0 1px 2px rgba(15,23,42,.05);
}
*{box-sizing:border-box}
svg{width:1em;height:1em;flex:none}
.brand-mark svg{width:20px;height:20px}
.menu-btn svg{width:22px;height:22px}
.badge svg{width:16px;height:16px}
.hero-art .preview svg{width:64px;height:48px}
.arrow-circle svg{width:18px;height:18px}
.check svg{width:16px;height:16px}
.icon-tile svg{width:24px;height:24px}
.card-link svg,.btn-link svg{width:18px;height:18px}
.dropzone svg{width:48px;height:48px}
.privacy-note svg{width:16px;height:16px}
.article-thumb svg{width:60px;height:60px}
.article-hero svg{width:90px;height:90px}
html{scroll-behavior:smooth}
body{margin:0;background:var(--bg);color:var(--text);font-family:Inter,system-ui,-apple-system,"Segoe UI",sans-serif;font-size:15px;line-height:1.6;-webkit-font-smoothing:antialiased}
a{color:inherit;text-decoration:none}
img{max-width:100%}
.container{max-width:1200px;margin:0 auto;padding:0 24px}

/* Header */
.site-header{position:sticky;top:0;z-index:40;background:var(--bg);border-bottom:1px solid var(--border)}
.header-inner{height:64px;display:flex;align-items:center;justify-content:space-between;gap:16px}
.brand{display:flex;align-items:center;gap:10px;font-size:20px;font-weight:600;letter-spacing:-.2px}
.brand-mark{width:36px;height:36px;border-radius:8px;background:var(--primary);display:grid;place-items:center;color:#fff}
.brand-mark svg{width:20px;height:20px}
.main-nav{display:flex;align-items:center;gap:32px}
.main-nav a{color:var(--muted);font-size:14px;font-weight:600;transition:color .15s}
.main-nav a:hover,.main-nav a.active{color:var(--text)}
.header-actions{display:flex;align-items:center;gap:12px}
.menu-btn{display:none;width:42px;height:42px;border:1px solid var(--border);border-radius:8px;background:var(--bg);color:var(--muted);align-items:center;justify-content:center;cursor:pointer}
.menu-btn svg{width:22px;height:22px}

/* Buttons */
.btn{display:inline-flex;align-items:center;justify-content:center;gap:8px;height:42px;padding:0 20px;border-radius:10px;font-size:14px;font-weight:600;cursor:pointer;border:1px solid transparent;transition:background .15s,border-color .15s,color .15s;white-space:nowrap}
.btn-primary{background:var(--primary);color:#fff}
.btn-primary:hover{background:var(--primary-hover)}
.btn-primary:disabled{background:#E2E8F0;color:#94A3B8;cursor:not-allowed}
.btn-outline{background:#fff;border-color:var(--border-strong);color:var(--text)}
.btn-outline:hover{border-color:var(--primary);color:var(--primary)}
.btn-link{height:42px;display:inline-flex;align-items:center;gap:6px;color:var(--primary);font-weight:600;font-size:14px;padding:0 8px}
.btn-sm{height:34px;padding:0 14px;font-size:13px}
.btn-wide{width:100%}

/* Hero */
.hero{padding:48px 0 40px}
.hero-grid{display:grid;grid-template-columns:7fr 5fr;gap:40px;align-items:center}
.hero h1{font-size:44px;line-height:52px;letter-spacing:-.8px;margin:0 0 16px;font-weight:700}
.hero p.lede{font-size:16px;line-height:26px;color:var(--muted);max-width:540px;margin:0 0 24px}
.badge{display:inline-flex;align-items:center;gap:8px;padding:6px 14px;border-radius:999px;background:var(--accent-soft);color:var(--on-accent-soft);font-size:12px;font-weight:600;margin-bottom:24px}
.hero-cta{display:flex;flex-wrap:wrap;align-items:center;gap:16px}
.hero-art{background:var(--surface);border:1px solid var(--border);border-radius:12px;padding:28px;display:flex;align-items:center;justify-content:center}
.hero-art-row{display:flex;align-items:center;gap:16px;width:100%;max-width:420px;justify-content:space-between}
.file-card{flex:1;min-width:0;background:#fff;border:1px solid var(--border);border-radius:12px;padding:14px;box-shadow:var(--shadow);position:relative}
.file-card .preview{aspect-ratio:4/3;border-radius:6px;margin-bottom:12px;display:grid;place-items:center}
.file-card .preview.blue{background:var(--primary-soft);color:var(--primary)}
.file-card .preview.teal{background:var(--accent-soft);color:var(--accent)}
.file-card .preview svg{width:64px;height:48px}
.file-card .fname{font-size:12px;font-weight:600;display:block}
.file-card .fsize{font-size:12px;color:var(--muted)}
.file-card .fsize.ok{color:var(--on-success-soft);font-weight:600}
.check{position:absolute;top:-10px;right:-10px;width:28px;height:28px;border-radius:50%;background:var(--success);color:#fff;display:grid;place-items:center;box-shadow:var(--shadow)}
.arrow-circle{width:36px;height:36px;flex:none;border-radius:50%;background:#fff;border:1px solid var(--border);display:grid;place-items:center;color:var(--primary)}

/* Ad placeholders */
.ad-wrap{padding:0 0 40px}
.ad{background:var(--surface);border:1px dashed var(--border-strong);border-radius:12px;display:flex;align-items:center;justify-content:center;position:relative;color:var(--muted);font-size:13px}
.ad-banner{width:728px;height:90px;max-width:100%;margin:0 auto}
.ad-box{width:300px;height:250px;margin:32px auto}
.ad-mobile{display:none;width:320px;height:50px;margin:0 auto}
.ad-tag{position:absolute;top:6px;right:10px;font-size:12px;color:var(--muted)}
.ad-note{text-align:center;font-size:13px;color:var(--muted);margin:-16px 0 40px}

/* Sections */
.section{padding:40px 0}
.section.on-surface{background:var(--surface);border-top:1px solid var(--border);border-bottom:1px solid var(--border)}
.section-head{margin-bottom:32px}
.section-head h2{font-size:32px;line-height:40px;letter-spacing:-.5px;margin:0 0 8px}
.section-head p{color:var(--muted);margin:0;display:flex;justify-content:space-between;align-items:center;gap:16px}
.section-head p a{color:var(--primary);font-size:14px;font-weight:600}
.grid{display:grid;gap:24px}
.grid-tools{grid-template-columns:repeat(3,1fr)}
.grid-3{grid-template-columns:repeat(3,1fr)}
.card{border:1px solid var(--border);border-radius:12px;background:#fff;padding:24px;display:flex;flex-direction:column;gap:20px;transition:border-color .15s}
a.card:hover{border-color:var(--primary)}
.icon-tile{width:44px;height:44px;border-radius:8px;background:var(--primary-soft);color:var(--primary);display:grid;place-items:center}
.icon-tile.teal{background:var(--accent-soft);color:var(--accent)}
.icon-tile svg{width:24px;height:24px}
.card h3{font-size:16px;margin:0 0 4px}
.card p{margin:0;color:var(--muted);font-size:14px}
.card .card-link{display:flex;align-items:center;gap:6px;color:var(--primary);font-size:14px;font-weight:600;margin-top:auto}
.value-card{border:0;background:transparent;padding:0;gap:12px}
.value-card p{font-size:14px}

/* Blog */
.grid-articles{grid-template-columns:repeat(3,1fr)}
.article-card{border:1px solid var(--border);border-radius:12px;overflow:hidden;background:#fff;display:flex;flex-direction:column}
.article-card:hover{border-color:var(--primary)}
.article-thumb{height:170px;display:grid;place-items:center;border-bottom:1px solid var(--border)}
.article-thumb.blue{background:var(--primary-soft);color:var(--primary)}
.article-thumb.teal{background:var(--accent-soft);color:var(--accent)}
.article-thumb svg{width:60px;height:60px}
.article-body{padding:20px;display:flex;flex-direction:column;gap:8px;flex:1}
.tag{display:inline-flex;align-self:flex-start;padding:2px 8px;border-radius:999px;background:var(--accent-soft);color:var(--on-accent-soft);font-size:11px;font-weight:600}
.article-body h3{font-size:16px;line-height:24px;margin:0}
.article-body p{margin:0;color:var(--muted);font-size:14px}
.article-body .meta{font-size:12px;color:var(--muted);margin-top:auto}
.featured{display:grid;grid-template-columns:1fr 1fr;border:1px solid var(--border);border-radius:12px;overflow:hidden;background:#fff}
.featured .article-thumb{height:100%;min-height:220px;border-bottom:0;border-right:1px solid var(--border)}
.featured .article-body{padding:28px}
.featured h3{font-size:28px;line-height:36px}
.chips{display:flex;gap:8px;flex-wrap:wrap;margin:0 0 24px}
.chip{height:32px;padding:0 14px;border-radius:999px;border:1px solid var(--border-strong);background:#fff;color:var(--muted);font-size:13px;font-weight:600;cursor:pointer}
.chip.active{background:var(--primary);border-color:var(--primary);color:#fff}
.load-more{margin:32px auto 0;display:flex}

/* Tool page */
.tool-page{padding-bottom:48px}
.crumb{font-size:13px;color:var(--muted);margin:20px 0 24px}
.crumb a:hover{color:var(--primary)}
.crumb span{margin:0 8px;color:var(--border-strong)}
.page-head{text-align:center;margin-bottom:28px}
.page-head h1{font-size:44px;line-height:52px;letter-spacing:-.8px;margin:0 0 10px}
.page-head p{color:var(--muted);font-size:16px;margin:0}
.tool-shell{max-width:780px;margin:0 auto;border:1px solid var(--border);border-radius:16px;padding:24px;box-shadow:var(--shadow)}
.dropzone{border:2px dashed var(--border-strong);border-radius:12px;background:var(--surface);min-height:190px;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:8px;text-align:center;padding:24px;cursor:pointer;transition:border-color .15s,background .15s}
.dropzone.dragover{border-color:var(--primary);background:var(--primary-soft)}
.dropzone svg{width:48px;height:48px;color:var(--primary);margin-bottom:4px}
.dropzone strong{font-size:15px}
.dropzone small{font-size:13px;color:var(--muted)}
.privacy-note{display:flex;align-items:center;justify-content:center;gap:8px;font-size:13px;color:var(--on-accent-soft);margin:16px 0}
.controls{background:var(--surface);border:1px solid var(--border);border-radius:12px;padding:18px;display:flex;flex-direction:column;gap:14px}
.control-row{display:flex;align-items:center;justify-content:space-between;gap:16px;flex-wrap:wrap}
.control-row label{font-size:14px;font-weight:600}
.control-row .hint{font-size:13px;color:var(--muted);width:100%}
input[type=range]{width:240px;accent-color:var(--primary)}
input[type=number],input[type=text],input[type=email],select,textarea{height:42px;padding:0 12px;border:1px solid var(--border-strong);border-radius:8px;font:inherit;font-size:14px;background:#fff;color:var(--text)}
textarea{height:110px;padding:12px;resize:vertical}
input:focus,select:focus,textarea:focus{outline:2px solid var(--primary-soft);border-color:var(--primary)}
.check-label{display:flex;align-items:center;gap:8px;font-size:14px;font-weight:500}
.check-label input{width:16px;height:16px;accent-color:var(--primary)}
.convert-btn{margin-top:16px}
.error-msg{margin-top:12px;color:#B91C1C;background:#FEF2F2;border:1px solid #FECACA;border-radius:8px;padding:10px 14px;font-size:14px}
.steps{display:grid;grid-template-columns:repeat(3,1fr);gap:16px;margin:20px auto 0;max-width:780px}
.step{display:flex;align-items:center;gap:10px;background:var(--surface);border:1px solid var(--border);border-radius:12px;padding:14px 16px;font-size:14px;font-weight:600}
.step b{width:24px;height:24px;border-radius:6px;background:var(--primary-soft);color:var(--primary);display:grid;place-items:center;font-size:12px;flex:none}
.results{margin-top:20px;display:none}
.results.show{display:block}
.results h2{font-size:20px;margin:0 0 14px;color:var(--success)}
.result-row{display:flex;align-items:center;gap:14px;border:1px solid var(--border);border-radius:10px;padding:10px 14px;margin-bottom:10px;background:#fff}
.result-row img{width:52px;height:52px;object-fit:cover;border-radius:8px;border:1px solid var(--border)}
.result-info{flex:1;min-width:0}
.result-info strong{display:block;font-size:14px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.result-info span{font-size:13px;color:var(--muted)}
.result-info .newsize{color:var(--success);font-weight:600}
.result-actions{display:flex;gap:8px;align-items:center}
.badge-done{font-size:12px;color:var(--success);font-weight:600;background:var(--success-soft);padding:3px 10px;border-radius:999px}

.content-section{max-width:780px;margin:56px auto 0}
.content-section h2{font-size:24px;line-height:32px;margin:32px 0 12px}
.content-section p{color:var(--muted);font-size:15px;line-height:26px}
.content-section ol,.content-section ul{color:var(--muted);line-height:26px;padding-left:24px}
details.faq{border:1px solid var(--border);border-radius:10px;margin-bottom:10px;background:#fff}
details.faq summary{cursor:pointer;padding:14px 18px;font-weight:600;font-size:15px;list-style:none;display:flex;justify-content:space-between;align-items:center}
details.faq summary::-webkit-details-marker{display:none}
details.faq summary::after{content:"+";color:var(--muted);font-size:18px}
details.faq[open] summary::after{content:"−"}
details.faq .faq-body{padding:0 18px 16px;color:var(--muted);font-size:14px;line-height:24px}
.callout{background:var(--primary-soft);border-left:4px solid var(--primary);border-radius:8px;padding:14px 18px;color:var(--on-primary-soft);font-size:14px;margin:20px 0}
.related{margin-top:40px}
.related h2{font-size:20px;margin:0 0 16px}
.related-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:16px}
.related-grid .card{padding:18px;gap:8px}

/* Article page */
.article-wrap{max-width:720px;margin:0 auto;padding-bottom:56px}
.article-wrap h1{font-size:40px;line-height:48px;letter-spacing:-.6px;margin:16px 0}
.byline{display:flex;align-items:center;gap:10px;color:var(--muted);font-size:13px;margin-bottom:24px}
.avatar{width:32px;height:32px;border-radius:50%;background:var(--primary);color:#fff;display:grid;place-items:center;font-size:11px;font-weight:700}
.article-hero{height:280px;border-radius:12px;background:var(--primary-soft);color:var(--primary);display:grid;place-items:center;margin-bottom:28px}
.article-content h2{font-size:26px;line-height:34px;margin:32px 0 12px}
.article-content p{font-size:16px;line-height:28px;color:#334155}
.article-content ol,.article-content ul{font-size:16px;line-height:28px;color:#334155;padding-left:24px}
.article-content table{width:100%;border-collapse:collapse;margin:24px 0;font-size:14px;line-height:22px}
.article-content th,.article-content td{border:1px solid var(--border);padding:10px 12px;text-align:left;vertical-align:top}
.article-content th{background:var(--surface);font-weight:600;color:var(--text)}
.article-content td{color:var(--muted)}
.article-content .ad{margin:32px 0}

/* Simple pages */
.simple{max-width:820px;margin:0 auto;padding:48px 0 64px}
.simple h1{font-size:40px;line-height:48px;margin:0 0 12px}
.simple .lede{font-size:17px;color:var(--muted);margin:0 0 32px}
.simple h2{font-size:22px;margin:32px 0 10px}
.simple p{color:var(--muted)}
.toc{position:sticky;top:88px}
.toc a{display:block;font-size:14px;color:var(--muted);padding:4px 0}
.toc a:hover{color:var(--primary)}
.two-col{display:grid;grid-template-columns:240px 1fr;gap:48px}
.form-grid{display:grid;gap:16px;max-width:620px}
.form-grid label{display:block;font-size:14px;font-weight:600;margin-bottom:6px}
.form-grid input,.form-grid select,.form-grid textarea{width:100%}
.side-card{border:1px solid var(--border);border-radius:12px;background:var(--surface);padding:24px}
.side-card h3{margin:0 0 12px;font-size:16px}
.side-card p,.side-card a{font-size:14px;color:var(--muted);display:block;margin-bottom:8px}
.side-card a:hover{color:var(--primary)}

/* Footer */
.site-footer{background:var(--surface);border-top:1px solid var(--border);padding:48px 0 24px;margin-top:auto}
.footer-grid{display:grid;grid-template-columns:repeat(4,1fr);gap:24px}
.footer-col h4{font-size:14px;margin:0 0 14px}
.footer-col a,.footer-col p{display:block;font-size:14px;color:var(--muted);margin:0 0 9px}
.footer-col a:hover{color:var(--primary)}
.footer-bottom{border-top:1px solid var(--border);margin-top:40px;padding-top:20px;display:flex;justify-content:space-between;color:var(--muted);font-size:13px;gap:16px;flex-wrap:wrap}

/* Cookie bar */
.cookie-bar{position:fixed;left:0;right:0;bottom:0;z-index:50;background:#fff;border-top:1px solid var(--border);box-shadow:0 -4px 20px rgba(15,23,42,.08);padding:14px 24px;display:flex;align-items:center;justify-content:center;gap:16px;flex-wrap:wrap;font-size:14px;color:var(--muted)}
.cookie-bar.hidden{display:none}
.cookie-bar a{color:var(--primary);text-decoration:underline}
.cookie-actions{display:flex;gap:8px}
.cookie-settings{max-width:1200px;width:100%;display:none;font-size:13px;color:var(--muted)}
.cookie-settings.show{display:block}

/* Responsive */
@media(max-width:900px){
  .hero-grid{grid-template-columns:1fr}
  .hero-art{display:none}
  .hero h1{font-size:34px;line-height:42px}
  .page-head h1{font-size:34px;line-height:42px}
  .grid-tools,.grid-3,.grid-articles,.related-grid{grid-template-columns:repeat(2,1fr)}
  .featured{grid-template-columns:1fr}
  .featured .article-thumb{border-right:0;border-bottom:1px solid var(--border)}
  .two-col{grid-template-columns:1fr}
  .toc{display:none}
}
@media(max-width:700px){
  .main-nav{display:none;position:absolute;top:64px;left:0;right:0;background:#fff;border-bottom:1px solid var(--border);padding:16px 24px;flex-direction:column;align-items:flex-start;gap:14px}
  .main-nav.open{display:flex}
  .menu-btn{display:flex}
  .header-actions .btn-primary{display:none}
  .ad-banner{display:none}
  .ad-mobile{display:flex}
  .grid-tools,.grid-3,.grid-articles,.related-grid,.steps{grid-template-columns:1fr}
  .footer-grid{grid-template-columns:repeat(2,1fr)}
  .tool-shell{padding:16px}
  .control-row{align-items:flex-start;flex-direction:column}
  input[type=range]{width:100%}
  .article-wrap h1{font-size:30px;line-height:38px}
  .page-head h1{font-size:30px;line-height:38px}
  .simple h1{font-size:30px;line-height:38px}
  .result-row{flex-wrap:wrap}
}
