/* ===========================================================================
   Linguya — shared stylesheet for magazine article pages.
   Kept as one external file rather than inlined per article: the three pages
   are byte-identical in style, and .htaccess already caches .css for a month,
   so a reader moving between articles downloads this once.
   Tokens mirror linguya-magazine.html exactly so articles feel like the same
   site, not a bolted-on blog.
   =========================================================================== */

:root{
  --royal:#1a3aff;
  --royal-deep:#0a1f8f;
  --royal-dark:#061348;
  --royal-light:#e8edff;
  --ink:#0c1330;
  --muted:#5b6480;
  --bg:#f6f8ff;
  --white:#ffffff;
  --shadow:0 20px 50px rgba(10,31,143,.12);
}
*{margin:0;padding:0;box-sizing:border-box;font-family:'Vazirmatn',sans-serif;}
html{scroll-behavior:smooth;}
body{background:var(--bg);color:var(--ink);line-height:1.9;overflow-x:hidden;}
a{text-decoration:none;color:inherit;}
.container{max-width:1180px;margin:0 auto;padding:0 24px;}
img{display:block;max-width:100%;}

/* ===== HEADER (identical to magazine) ===== */
header{position:sticky;top:0;z-index:100;background:rgba(255,255,255,.92);backdrop-filter:blur(14px);border-bottom:1px solid #e6eaff;box-shadow:0 4px 20px rgba(6,19,72,.06);}
.nav{display:flex;align-items:center;justify-content:space-between;height:68px;gap:16px;}
.logo{display:flex;align-items:center;gap:10px;color:var(--royal-deep);font-weight:900;font-size:20px;}
.logo-mark{width:38px;height:38px;background:linear-gradient(135deg,var(--royal),var(--royal-deep));border-radius:10px;display:grid;place-items:center;color:#fff;font-weight:900;font-size:18px;flex-shrink:0;}
.menu{display:flex;gap:26px;list-style:none;font-weight:600;font-size:15px;}
.menu a{color:var(--muted);transition:.2s;}
.menu a:hover,.menu a.active{color:var(--royal);}
.nav-right{display:flex;align-items:center;gap:10px;}
.btn{display:inline-flex;align-items:center;gap:7px;padding:10px 20px;border-radius:12px;font-weight:700;border:none;cursor:pointer;transition:.22s;font-size:14px;font-family:inherit;}
.btn-primary{background:linear-gradient(135deg,var(--royal),var(--royal-deep));color:#fff;box-shadow:0 8px 20px rgba(26,58,255,.3);}
.btn-primary:hover{transform:translateY(-2px);box-shadow:0 12px 26px rgba(26,58,255,.4);}
.burger{display:none;flex-direction:column;gap:5px;cursor:pointer;background:none;border:none;padding:4px;}
.burger span{width:24px;height:2.5px;background:var(--royal-deep);border-radius:3px;}
@media(max-width:780px){
  .menu{display:none;position:fixed;top:68px;inset-inline:0;background:#fff;flex-direction:column;padding:20px 24px;gap:14px;border-bottom:1px solid #e6eaff;z-index:99;box-shadow:0 10px 30px rgba(0,0,0,.08);}
  .menu.open{display:flex;}
  .burger{display:flex;}
  .nav-cta-text{display:none;}
}

/* ===== ARTICLE HERO ===== */
.art-hero{background:linear-gradient(160deg,#091a66 0%,#061348 55%,#040c33 100%);padding:54px 0 64px;color:#fff;}
.crumbs{font-size:13.5px;color:#a9b8ff;margin-bottom:18px;}
.crumbs a{color:#a9b8ff;transition:.2s;}
.crumbs a:hover{color:#fff;}
.crumbs span{opacity:.55;margin:0 6px;}
.art-chip{display:inline-flex;align-items:center;gap:7px;background:rgba(255,255,255,.13);border:1px solid rgba(255,255,255,.22);color:#dbe3ff;padding:6px 15px;border-radius:100px;font-size:13px;font-weight:700;margin-bottom:16px;}
.art-hero h1{font-size:clamp(25px,4.4vw,42px);font-weight:900;line-height:1.5;max-width:860px;margin-bottom:16px;}
.art-lede{font-size:clamp(15px,2vw,18px);color:#c3ceff;max-width:760px;line-height:1.95;}
.art-meta{display:flex;flex-wrap:wrap;gap:10px 22px;margin-top:26px;font-size:13.5px;color:#a9b8ff;}
.art-meta b{color:#e4eaff;font-weight:700;}

/* ===== LAYOUT ===== */
.art-wrap{display:grid;grid-template-columns:1fr 310px;gap:44px;padding:52px 0 76px;align-items:start;}
@media(max-width:960px){ .art-wrap{grid-template-columns:1fr;gap:34px;} }

.art-body{background:var(--white);border-radius:20px;padding:44px 46px;box-shadow:var(--shadow);}
@media(max-width:600px){ .art-body{padding:28px 22px;border-radius:16px;} }

/* --- the answer box: the first thing a reader (or an answer engine) sees --- */
.answer-box{background:linear-gradient(135deg,#eef2ff,#e3ebff);border:1.5px solid #c9d5ff;border-inline-start:5px solid var(--royal);border-radius:14px;padding:22px 26px;margin-bottom:34px;}
.answer-box .ab-label{font-size:12.5px;font-weight:800;color:var(--royal-deep);letter-spacing:.3px;margin-bottom:8px;display:flex;align-items:center;gap:7px;}
.answer-box p{font-size:16.5px;line-height:1.95;color:#12204d;font-weight:600;}

.art-body h2{font-size:clamp(20px,3vw,26px);font-weight:900;color:var(--royal-deep);margin:42px 0 16px;line-height:1.6;scroll-margin-top:84px;}
.art-body h2:first-of-type{margin-top:0;}
.art-body h3{font-size:clamp(17px,2.4vw,20px);font-weight:800;color:var(--ink);margin:28px 0 12px;line-height:1.6;}
.art-body p{font-size:16px;line-height:2.05;color:#2a3358;margin-bottom:16px;}
.art-body ul,.art-body ol{margin:0 0 18px;padding-inline-start:24px;}
.art-body li{font-size:16px;line-height:2.05;color:#2a3358;margin-bottom:9px;}
.art-body strong{color:var(--royal-deep);font-weight:800;}
.art-body a{color:var(--royal);font-weight:700;border-bottom:1.5px solid #bccaff;}
.art-body a:hover{border-bottom-color:var(--royal);}

/* English fragments inside Persian prose need their own direction */
.en{direction:ltr;display:inline-block;font-weight:700;color:var(--royal-deep);unicode-bidi:isolate;}

.example{background:#f7f9ff;border:1px solid #e2e8ff;border-radius:12px;padding:16px 20px;margin:0 0 18px;}
.example .en-line{direction:ltr;text-align:left;font-size:16px;font-weight:700;color:var(--royal-deep);margin-bottom:5px;unicode-bidi:isolate;}
.example .fa-line{font-size:14.5px;color:var(--muted);}

.callout{background:#fff8ec;border:1px solid #ffe0b0;border-inline-start:5px solid #f59e0b;border-radius:12px;padding:18px 22px;margin:0 0 22px;}
.callout b{color:#92620a;}
.callout p{margin-bottom:0;color:#553c10;font-size:15.5px;}

.tbl-scroll{overflow-x:auto;margin:0 0 22px;-webkit-overflow-scrolling:touch;}
table{width:100%;border-collapse:collapse;min-width:460px;font-size:15px;}
th{background:var(--royal-light);color:var(--royal-deep);font-weight:800;padding:13px 15px;text-align:start;border:1px solid #d5deff;}
td{padding:12px 15px;border:1px solid #e5eaff;color:#2a3358;vertical-align:top;}
tr:nth-child(even) td{background:#fafbff;}

/* ===== FAQ ===== */
.faq-block{margin-top:44px;border-top:2px dashed #dfe6ff;padding-top:34px;}
.faq-item{border:1px solid #e4eaff;border-radius:13px;padding:20px 24px;margin-bottom:14px;background:#fbfcff;}
.faq-item h3{margin:0 0 9px;font-size:16.5px;color:var(--royal-deep);font-weight:800;}
.faq-item p{margin-bottom:0;font-size:15.5px;}

/* ===== CTA ===== */
.art-cta{margin-top:44px;background:linear-gradient(140deg,#0a1f8f,#061348);border-radius:18px;padding:34px 36px;color:#fff;text-align:center;}
.art-cta h3{font-size:clamp(19px,2.8vw,24px);font-weight:900;margin-bottom:10px;color:#fff;}
.art-cta p{color:#bfcbff;font-size:15.5px;margin-bottom:22px;}
.art-cta .btn{background:#fff;color:var(--royal-deep);font-size:15px;padding:13px 30px;}
.art-cta .btn:hover{transform:translateY(-2px);}

/* ===== SIDEBAR ===== */
.side-card{background:var(--white);border-radius:16px;padding:24px 26px;box-shadow:0 10px 30px rgba(10,31,143,.08);margin-bottom:22px;}
.side-card h4{font-size:16px;font-weight:900;color:var(--royal-deep);margin-bottom:16px;}
.toc a{display:block;font-size:14.5px;color:var(--muted);padding:8px 0;border-bottom:1px solid #f0f3ff;transition:.2s;line-height:1.7;}
.toc a:last-child{border-bottom:none;}
.toc a:hover{color:var(--royal);padding-inline-start:5px;}
.rel a{display:block;padding:13px 0;border-bottom:1px solid #f0f3ff;transition:.2s;}
.rel a:last-child{border-bottom:none;}
.rel a:hover{padding-inline-start:5px;}
.rel .r-cat{font-size:11.5px;font-weight:800;color:var(--royal);margin-bottom:4px;}
.rel .r-title{font-size:14.5px;font-weight:700;color:var(--ink);line-height:1.7;}
@media(max-width:960px){ .side-sticky{position:static !important;} }
.side-sticky{position:sticky;top:88px;}

/* ===== FOOTER ===== */
footer{background:var(--royal-dark);color:#c8d2ff;padding:52px 0 26px;margin-top:20px;}
.foot-grid{display:grid;grid-template-columns:1.6fr 1fr 1fr 1.3fr;gap:34px;margin-bottom:34px;}
@media(max-width:860px){ .foot-grid{grid-template-columns:1fr 1fr;gap:26px;} }
@media(max-width:520px){ .foot-grid{grid-template-columns:1fr;} }
.foot-logo{display:flex;align-items:center;gap:10px;color:#fff;font-weight:900;font-size:19px;margin-bottom:13px;}
.foot-mark{width:34px;height:34px;background:linear-gradient(135deg,var(--royal),#4d6bff);border-radius:9px;display:grid;place-items:center;font-size:16px;}
footer p{font-size:14px;line-height:2;opacity:.82;}
footer h4{color:#fff;font-size:15px;margin-bottom:13px;font-weight:800;}
footer a{display:block;font-size:14px;padding:5px 0;opacity:.82;transition:.2s;}
footer a:hover{opacity:1;color:#fff;}
.socials{display:flex;gap:10px;margin-top:14px;}
.socials a{width:36px;height:36px;background:rgba(255,255,255,.1);border-radius:9px;display:grid;place-items:center;padding:0;}
.foot-bottom{border-top:1px solid rgba(255,255,255,.12);padding-top:20px;text-align:center;font-size:13px;opacity:.7;}

/* Skip link for keyboard users — matches the pattern used on index.html */
.skip{position:absolute;inset-inline-start:-9999px;top:0;background:var(--royal);color:#fff;padding:10px 18px;border-radius:0 0 10px 0;z-index:200;font-weight:700;}
.skip:focus{inset-inline-start:0;}
