/* ===== CONTENT PAGES - Backlinko-style long-form layout ===== */

/* Reset & Base */
*,*::before,*::after{margin:0;padding:0;box-sizing:border-box}
html{scroll-behavior:smooth;font-size:16px}
body{font-family:'Inter',system-ui,-apple-system,sans-serif;color:#0d0d0d;background:#fff;line-height:1.6;-webkit-font-smoothing:antialiased}
img,svg{max-width:100%;display:block}
a{text-decoration:none;color:inherit}
ul,ol{list-style:none}

/* ===== NAV ===== */
.nav{position:fixed;top:0;left:0;width:100%;z-index:100;padding:16px 0;transition:all .3s;background:rgba(255,255,255,.95);backdrop-filter:blur(12px);box-shadow:0 1px 0 rgba(0,0,0,.06)}
.nav__inner{max-width:1140px;margin:0 auto;padding:0 24px;display:flex;align-items:center;justify-content:space-between}
.nav__logo{font-size:1.5rem;font-weight:800;letter-spacing:-.03em;color:#0d0d0d}
.nav__logo span{color:#0D55FF}
.nav__links{display:flex;gap:32px}
.nav__links a{font-size:.88rem;font-weight:500;color:#555;transition:color .2s}
.nav__links a:hover{color:#0D55FF}
.nav__cta{display:inline-flex}
.nav__hamburger{display:none;flex-direction:column;gap:5px;background:none;border:none;cursor:pointer;padding:4px}
.nav__hamburger span{width:22px;height:2px;background:#0d0d0d;border-radius:2px;transition:all .3s}
.btn{display:inline-flex;align-items:center;gap:8px;font-size:.95rem;font-weight:600;padding:14px 32px;border-radius:10px;border:none;cursor:pointer;transition:all .25s ease;font-family:'Inter',system-ui,-apple-system,sans-serif}
.btn--primary{background:#0D55FF;color:#fff}
.btn--primary:hover{background:#0a47d6;transform:translateY(-1px);box-shadow:0 8px 30px rgba(13,85,255,.25)}
.btn--sm{font-size:.85rem;padding:10px 22px;border-radius:8px}
.btn--lg{padding:16px 36px;font-size:1rem}
.btn svg{width:18px;height:18px}

/* ===== ARTICLE HERO ===== */
.article-hero{padding:120px 0 60px;background:#f8f8f8;border-bottom:1px solid #eee}
.article-hero__inner{max-width:760px;margin:0 auto;padding:0 24px}
.article-hero__breadcrumb{display:flex;align-items:center;gap:8px;font-size:.8rem;color:#888;margin-bottom:24px;flex-wrap:wrap}
.article-hero__breadcrumb a{color:#0D55FF;font-weight:500}
.article-hero__breadcrumb a:hover{text-decoration:underline}
.article-hero__breadcrumb svg{width:12px;height:12px;color:#ccc}
.article-hero__tag{display:inline-block;font-size:.7rem;font-weight:600;letter-spacing:.08em;text-transform:uppercase;padding:5px 14px;border-radius:100px;background:rgba(13,85,255,.08);color:#0D55FF;margin-bottom:16px}
.article-hero h1{font-size:clamp(2rem,4.5vw,3rem);font-weight:800;line-height:1.15;letter-spacing:-.03em;color:#0d0d0d;margin-bottom:16px}
.article-hero__sub{font-size:1.1rem;color:#555;line-height:1.7;max-width:640px}
.article-hero__meta{display:flex;align-items:center;gap:16px;margin-top:24px;padding-top:24px;border-top:1px solid #e0e0e0;font-size:.85rem;color:#888}
.article-hero__meta strong{color:#0d0d0d}

/* ===== ARTICLE BODY ===== */
.article{max-width:760px;margin:0 auto;padding:60px 24px 100px}

/* Desktop: Sticky sidebar TOC layout */
@media(min-width:1100px){
  .article{max-width:1080px;display:grid;grid-template-columns:220px minmax(0,720px);column-gap:48px;justify-content:center}
  .article>*{grid-column:2;min-width:0}
  .toc{grid-column:1;grid-row:1/span 200;position:sticky;top:90px;align-self:start;max-height:calc(100vh - 120px);overflow-y:auto;margin-bottom:0;padding:20px 20px;border-radius:12px;background:#fafafa;border:1px solid #eee;scrollbar-width:thin;scrollbar-color:rgba(0,0,0,.1) transparent}
  .toc::-webkit-scrollbar{width:4px}
  .toc::-webkit-scrollbar-track{background:transparent}
  .toc::-webkit-scrollbar-thumb{background:rgba(0,0,0,.12);border-radius:4px}
  .toc .toc__title{font-size:.72rem;margin-bottom:14px;color:#aaa}
  .toc ul li a{font-size:.84rem;padding:5px 0 5px 14px;line-height:1.45;border-left:2px solid #e0e0e0;color:#777;font-weight:500}
  .toc ul li a:hover{color:#0D55FF;border-left-color:#0D55FF;background:rgba(13,85,255,.03)}
}

/* Typography */
.article h2{font-size:clamp(1.5rem,3vw,2rem);font-weight:700;letter-spacing:-.02em;line-height:1.2;margin:56px 0 20px;color:#0d0d0d;padding-top:16px}
.article h3{font-size:clamp(1.15rem,2vw,1.4rem);font-weight:700;letter-spacing:-.01em;line-height:1.25;margin:40px 0 14px;color:#0d0d0d}
.article h4{font-size:1.05rem;font-weight:600;margin:28px 0 10px;color:#0d0d0d}
.article p{font-size:1.05rem;color:#333;line-height:1.85;margin-bottom:20px}
.article p strong{color:#0d0d0d;font-weight:600}
.article a{color:#0D55FF;font-weight:500;text-decoration:underline;text-decoration-color:rgba(13,85,255,.3);text-underline-offset:3px;transition:text-decoration-color .2s}
.article a:hover{text-decoration-color:#0D55FF}

/* Lists */
.article ul,.article ol{margin:0 0 24px 0;padding-left:0}
.article ul li,.article ol li{font-size:1.05rem;color:#333;line-height:1.8;padding:6px 0 6px 28px;position:relative}
.article ul li::before{content:'';position:absolute;left:4px;top:16px;width:8px;height:8px;border-radius:50%;background:#0D55FF;opacity:.5}
.article ol{counter-reset:ol-counter}
.article ol li{counter-increment:ol-counter}
.article ol li::before{content:counter(ol-counter) '.';position:absolute;left:0;top:6px;font-weight:700;color:#0D55FF;font-size:.95rem}

/* ===== TABLE OF CONTENTS ===== */
.toc{background:#f8f8f8;border:1px solid #eee;border-radius:14px;padding:28px 32px;margin-bottom:48px}
.toc__title{font-size:.85rem;font-weight:700;text-transform:uppercase;letter-spacing:.08em;color:#888;margin-bottom:16px}
.toc ul{margin:0;padding:0}
.toc ul li{padding:0;position:static}
.toc ul li::before{content:none !important}
.toc ul li a{font-size:.92rem;font-weight:500;color:#444;display:block;padding:7px 0;transition:all .2s;text-decoration:none;border-bottom:none}
.toc ul li a:hover{color:#0D55FF;text-decoration:none}
.toc__list{display:flex;flex-direction:column;gap:8px}
.toc__list a{font-size:.95rem;font-weight:500;color:#333;padding:6px 0;display:flex;align-items:center;gap:10px;transition:color .2s}
.toc__list a:hover{color:#0D55FF}
.toc__list a::before{content:'';width:6px;height:6px;border-radius:50%;background:#0D55FF;opacity:.3;flex-shrink:0}

/* ===== CALLOUT BOXES ===== */
.callout{border-radius:14px;padding:28px 28px;margin:32px 0;display:flex;gap:16px}
.callout__icon{width:36px;height:36px;border-radius:10px;display:flex;align-items:center;justify-content:center;flex-shrink:0}
.callout__body{flex:1}
.callout__body strong{display:block;font-size:.95rem;margin-bottom:6px}
.callout__body p{font-size:.95rem;margin-bottom:0;line-height:1.7}

/* Definition box */
.callout--def{background:rgba(13,85,255,.04);border:1px solid rgba(13,85,255,.12)}
.callout--def .callout__icon{background:rgba(13,85,255,.1)}
.callout--def .callout__icon svg{color:#0D55FF}

/* Pro tip */
.callout--tip{background:rgba(16,185,129,.04);border:1px solid rgba(16,185,129,.15)}
.callout--tip .callout__icon{background:rgba(16,185,129,.1)}
.callout--tip .callout__icon svg{color:#10B981}

/* Warning */
.callout--warn{background:rgba(245,158,11,.04);border:1px solid rgba(245,158,11,.15)}
.callout--warn .callout__icon{background:rgba(245,158,11,.1)}
.callout--warn .callout__icon svg{color:#F59E0B}

/* Example */
.callout--example{background:rgba(139,92,246,.04);border:1px solid rgba(139,92,246,.12)}
.callout--example .callout__icon{background:rgba(139,92,246,.1)}
.callout--example .callout__icon svg{color:#8B5CF6}

/* ===== KEY TAKEAWAY BOX ===== */
.key-takeaway{background:#0a0a0a;border-radius:14px;padding:32px;margin:40px 0;color:#f5f5f5}
.key-takeaway__label{font-size:.7rem;font-weight:600;text-transform:uppercase;letter-spacing:.1em;color:#5B93FF;margin-bottom:12px}
.article .key-takeaway p{color:rgba(255,255,255,.7);font-size:1rem;line-height:1.8;margin-bottom:0}
.article .key-takeaway p strong,.article .key-takeaway strong{color:#f5f5f5;font-weight:700}

/* ===== STEP SECTIONS ===== */
.step-block{margin:40px 0;padding:32px;background:#f8f8f8;border-radius:14px;border:1px solid #eee}
.step-block__num{display:inline-flex;align-items:center;justify-content:center;width:36px;height:36px;border-radius:50%;background:#0D55FF;color:#fff;font-size:.85rem;font-weight:700;margin-bottom:16px}
.step-block h3{font-size:1.2rem;margin:0 0 12px;color:#0d0d0d}
.step-block p{font-size:1rem;color:#555;line-height:1.8;margin-bottom:0}
.step-block ul{margin-top:12px;margin-bottom:0}

/* ===== SVG ILLUSTRATIONS ===== */
.article-svg{margin:40px auto;max-width:640px;background:#f8f8f8;border-radius:14px;border:1px solid #eee;padding:32px;overflow:hidden}
.article-svg figcaption{text-align:center;font-size:.82rem;color:#888;margin-top:16px;font-weight:500}

/* ===== COMPARISON TABLE ===== */
.content-table{width:100%;border-collapse:collapse;margin:32px 0;border-radius:12px;overflow:hidden;border:1px solid #eee}
.content-table thead{background:#0a0a0a}
.content-table th{padding:14px 20px;font-size:.82rem;font-weight:600;text-transform:uppercase;letter-spacing:.06em;color:#f5f5f5;text-align:left}
.content-table td{padding:14px 20px;font-size:.95rem;color:#333;border-bottom:1px solid #eee;line-height:1.6}
.content-table tr:last-child td{border-bottom:none}
.content-table tr:nth-child(even){background:#fafafa}
.content-table .highlight-cell{color:#0D55FF;font-weight:600}

/* ===== QUOTE BLOCK ===== */
.article blockquote{border-left:3px solid #0D55FF;padding:16px 24px;margin:32px 0;background:#f8f8f8;border-radius:0 12px 12px 0}
.article blockquote p{font-size:1rem;color:#444;font-style:italic;margin-bottom:0}
.article blockquote cite{display:block;margin-top:8px;font-size:.85rem;color:#888;font-style:normal;font-weight:500}

/* ===== INLINE CODE & HIGHLIGHT ===== */
.article code{background:rgba(13,85,255,.06);color:#0D55FF;padding:2px 8px;border-radius:6px;font-size:.9rem;font-family:'SF Mono',Monaco,monospace}
.text-highlight{background:linear-gradient(transparent 60%,rgba(13,85,255,.12) 60%);font-weight:600}

/* ===== IMAGE / SCREENSHOT PLACEHOLDER ===== */
.screenshot{margin:32px 0;border-radius:14px;overflow:hidden;border:1px solid #eee;box-shadow:0 4px 20px rgba(0,0,0,.04)}
.screenshot img{width:100%;display:block}
.screenshot__caption{text-align:center;padding:12px;font-size:.82rem;color:#888;background:#fafafa}

/* ===== AUTHOR BIO ===== */
.author-box{display:flex;gap:20px;align-items:flex-start;background:#f8f8f8;border:1px solid #eee;border-radius:14px;padding:28px;margin:48px 0}
.author-box__avatar{width:64px;height:64px;border-radius:50%;background:#0D55FF;display:flex;align-items:center;justify-content:center;flex-shrink:0;font-size:1.4rem;font-weight:700;color:#fff}
.author-box__info{flex:1}
.author-box__name{font-size:1rem;font-weight:700;color:#0d0d0d;margin-bottom:2px}
.author-box__name a{color:#0D55FF;text-decoration:none}
.author-box__name a:hover{text-decoration:underline}
.author-box__role{font-size:.82rem;color:#888;margin-bottom:8px}
.author-box__bio{font-size:.9rem;color:#555;line-height:1.7;margin:0}
@media(max-width:768px){.author-box{flex-direction:column;align-items:center;text-align:center}}

/* ===== BOTTOM CTA ===== */
.article-cta{background:#0a0a0a;border-radius:16px;padding:48px 40px;margin:56px 0 0;text-align:center;color:#f5f5f5}
.article-cta h2{font-size:clamp(1.4rem,3vw,1.8rem);font-weight:700;margin:0 0 12px;color:#f5f5f5;letter-spacing:-.02em}
.article-cta p{font-size:1rem;color:rgba(255,255,255,.5);line-height:1.7;margin-bottom:24px;max-width:480px;margin-left:auto;margin-right:auto}
.article-cta .btn--primary{color:#fff;text-decoration:none}
.article-cta .btn--primary:hover{background:#3d7aff;color:#fff}

/* ===== RELATED ARTICLES ===== */
.related{margin-top:64px;padding-top:48px;border-top:1px solid #eee}
.related__title{font-size:1.1rem;font-weight:700;margin-bottom:24px}
.related__grid{display:grid;grid-template-columns:repeat(2,1fr);gap:16px}
.related__card{display:block;padding:20px;border:1px solid #eee;border-radius:12px;transition:all .25s}
.related__card:hover{border-color:#0D55FF;box-shadow:0 4px 16px rgba(13,85,255,.06);transform:translateY(-2px)}
.related__card h4{font-size:.95rem;font-weight:600;color:#0d0d0d;margin-bottom:6px;line-height:1.3}
.related__card p{font-size:.82rem;color:#888;line-height:1.5;margin:0}

/* ===== FOOTER ===== */
.footer{background:#0a0a0a;color:#f5f5f5;padding:64px 0 32px}
.footer .container{max-width:1140px;margin:0 auto;padding:0 24px}
.footer__inner{display:grid;grid-template-columns:2fr 1fr 1fr 1fr;gap:48px;margin-bottom:48px}
.footer__brand .nav__logo{color:#f5f5f5}
.footer__brand p{color:rgba(255,255,255,.4);font-size:.9rem;margin-top:12px;max-width:280px;line-height:1.7}
.footer__col h4{font-size:.8rem;text-transform:uppercase;letter-spacing:.08em;color:rgba(255,255,255,.3);margin-bottom:20px}
.footer__col a{display:block;font-size:.9rem;color:rgba(255,255,255,.6);margin-bottom:12px;transition:color .2s}
.footer__col a:hover{color:#5B93FF}
.footer__bottom{border-top:1px solid rgba(255,255,255,.08);padding-top:24px;display:flex;justify-content:space-between;align-items:center}
.footer__bottom p{font-size:.8rem;color:rgba(255,255,255,.3)}

/* ===== RESPONSIVE ===== */
@media(max-width:768px){
  .article-hero{padding:100px 0 48px}
  .article-hero h1{font-size:clamp(1.6rem,6vw,2.2rem)}
  .article{padding:40px 20px 80px}
  .article p,.article ul li,.article ol li{font-size:1rem}
  .toc{padding:20px 24px}
  .callout{flex-direction:column;gap:12px;padding:20px}
  .step-block{padding:24px 20px}
  .article-svg{padding:20px}
  .content-table{font-size:.85rem}
  .content-table th,.content-table td{padding:10px 14px}
  .article-cta{padding:36px 24px}
  .related__grid{grid-template-columns:1fr}
  .nav__links,.nav__cta{display:none}
  .nav__hamburger{display:flex}
  .footer__inner{grid-template-columns:1fr}
  .footer__bottom{flex-direction:column;gap:16px;text-align:center}
}
