/* ==========================================================================
   ARTICLE LAYER  —  editorial reading experience on the DECK brand system
   Load AFTER style.css:
     <link rel="stylesheet" href="style.css">
     <link rel="stylesheet" href="article.css">

   Two jobs:
   1. Editorial simplicity  — serif headline, quiet furniture, long measure.
   2. Monetization system   — 8 slot formats, M1 above the fold, the rest
                              auto-rotated every ~300 words by money.js.
   ========================================================================== */

:root{
  --serif:Georgia,"Times New Roman",serif;
  --gold:#C8912F;
  --mon-bd:#DCE6F5;         /* frame around money units                    */
  --mon-bg:#FBFCFE;         /* faint tint so a unit reads as "not article" */
}

/* ==========================================================================
   1 · FOLD BUDGET
   Every rule here exists to get M1 (the lead money unit) fully visible on a
   390x844 phone with no scroll. MEASURED, not estimated:
     top 43 + pills 51 + crumb 30 + h1 92 + byline 44 + lede 136 + gaps 48
     = 444px  ->  M1 starts at 444, is 304 tall, bottom lands at ~748.
   Four things protect that budget. Break any one and the unit drops below
   the fold:
     a) logo 34px, not 124px
     b) no hero image above M1
     c) byline stays on ONE line on mobile
     d) the lede stays at 40-45 words (about 4 lines at 390px)
   There is ~95px of slack. The dek eats 79 of it, which is why it is off
   by default — turn it on with <body data-fold="roomy"> and re-measure.
   ========================================================================== */

/* Both rows ran at 6-7px vertical padding, which left the logo and the
   pills crammed together with no breathing room. 10/12px gives them
   space. It costs 12px of fold, which the budget absorbs: the worst
   article measured 690 against a 734 limit. */
.top{padding:10px 0}
/* 34/30px was the minimum viable size, not the ideal one — bumped up now
   that the fold budget has room. Checked against the tightest article's
   actual measured margin (27-30px at the time) before picking this size:
   +10px eats about a third of that margin, leaving real slack rather than
   running the fold right up against the 734px ceiling again. */
/* Second bump. After the first increase (34->44 / 30->40) the tightest
   articles measured 17-24px of margin, so there is real but limited room
   left -- +6px here, not another +10, specifically so it does not zero
   out the tightest ones. Verified against all 48 individually after this
   change, not sampled, same as every prior logo/H1 change in this file. */
.logoimg{height:50px}                       /* was 124px — the whole problem */
@media(max-width:520px){.logoimg{height:46px}}

.cats{padding:12px 0}
.cats a{padding:7px 14px;font-size:12.5px}

body{padding-bottom:26px}                   /* no sticky dock any more       */

/* ==========================================================================
   2 · EDITORIAL SHELL
   ========================================================================== */

.crumb{font-size:12px;color:var(--soft);padding:10px 0 0;font-weight:600}
.crumb a:hover{color:var(--blue)}
.crumb b{color:var(--green-d)}

article{padding:6px 0 26px}

/* The old kicker chip cost 30px of fold for information the breadcrumb
   already carries. It is kept for section pages, not used on articles. */
.kick{display:inline-block;font:800 10.5px var(--f);letter-spacing:.16em;
  text-transform:uppercase;color:var(--green-d);border-bottom:2px solid var(--green);
  padding-bottom:4px;margin:10px 0 12px}

article h1{font-family:var(--serif);font-size:clamp(26px,6.1vw,40px);line-height:1.13;
  letter-spacing:-.015em;font-weight:700;color:var(--navy);margin:4px 0 9px}

/* OFF by default — it costs 79px and largely repeats the lede.
   <body data-fold="roomy"> turns it back on. */
.dek{display:none;font-family:var(--serif);font-style:italic;font-size:17.5px;
  line-height:1.5;color:var(--muted);margin:0 0 14px}
body[data-fold="roomy"] .dek{display:block}

/* ---- date stamp ---------------------------------------------------------
   Replaces the old byline block. Frees 46px of fold.
   Trade-off worth knowing: this also drops the author and the "expert
   reviewed" mark, which are genuine E-E-A-T signals on an insurance page.
   Fine for paid traffic; re-add the byline on evergreen SEO articles.   */
.stamp{font:600 11.5px var(--f);color:var(--soft);letter-spacing:.02em;
  margin:0 0 14px;padding:0}

/* ---- the lede -----------------------------------------------------------
   This is the content that has to sit above M1 to keep the page compliant:
   the search unit must be complementary to content, not the page's focus.
   HARD LIMIT: 36-40 words. At 390px that is 4 lines / 135px, and the fold
   budget has no room for a fifth. Never filler — a reviewer reads it.    */
.lede{font-size:16.5px;line-height:1.62;color:#33405A;margin:0 0 15px}
.lede b{color:var(--navy)}

/* body copy */
.body p{color:#3A465F;font-size:17.5px;line-height:1.74;margin:0 0 19px}
.body h2{font-family:var(--serif);font-size:clamp(21px,4.4vw,27px);letter-spacing:-.018em;
  color:var(--navy);margin:38px 0 13px;font-weight:700}
.body h3{font-family:var(--serif);font-size:20px;color:var(--navy);margin:28px 0 9px;font-weight:700}
.body ul,.body ol{color:#3A465F;font-size:17.5px;line-height:1.74;padding-left:23px;margin:0 0 19px}
.body li{margin-bottom:8px}
.body b{color:var(--navy)}
.body a:not([class]){color:var(--blue);border-bottom:1px solid rgba(22,104,216,.3)}

/* ---- hero image -------------------------------------------------------
   300x250 source, so the box is 6:5 and the artwork needs no crop.
   Floats LEFT with text wrapping the right side — a plain photo, no
   caption overlay, matching the reference layout rather than a styled
   card. A 16:9 full-bleed hero was ~210px tall on a phone and pushed
   everything down; floated at 300px it sits alongside the opening
   paragraphs instead. Always BELOW M1 — never above it, that costs the
   fold. The gradient span is only the onerror fallback colour: it sits
   behind the <img> and is invisible once the photo loads.             */
.himg{float:left;width:300px;max-width:44%;aspect-ratio:6/5;position:relative;
  overflow:hidden;border-radius:10px;margin:2px 22px 16px 0;box-shadow:var(--d1)}
.himg .g{position:absolute;inset:0;background-size:220% 220%;animation:mv 16s ease-in-out infinite}
.himg img{position:relative;z-index:2;width:100%;height:100%;object-fit:cover;display:block}

/* under 560px a 44% float leaves a text column too narrow to read, so it
   becomes a centred block instead */
@media(max-width:560px){
  .himg{float:none;width:100%;max-width:300px;margin:0 auto 18px}
}

/* the float can still be live when the mid-article unit lands; clearing
   stops the chips wrapping into the gap beside it */
.body .m{clear:both}

.callout{background:var(--bg2);border-left:3px solid var(--green);border-radius:0 10px 10px 0;
  padding:17px 20px;margin:26px 0}
.callout p{margin:0;font-size:15.5px;color:var(--muted)}
.callout b{color:var(--navy)}

.tbl{overflow-x:auto;margin:26px 0;border:1px solid var(--line);border-radius:12px;background:#fff}
.tbl table{border-collapse:collapse;width:100%;font-size:14.5px;min-width:500px}
.tbl th{background:var(--bg2);text-align:left;padding:13px 17px;color:var(--navy);
  font:800 11.5px var(--f);letter-spacing:.08em;text-transform:uppercase;border-bottom:1px solid var(--line)}
.tbl td{padding:13px 17px;border-bottom:1px solid var(--line);color:var(--muted)}
.tbl tr:last-child td{border-bottom:0}

/* reading-progress hairline — cheap, and it measurably lifts scroll depth */
.prog{position:fixed;top:0;left:0;height:3px;width:0;z-index:80;
  background:linear-gradient(90deg,var(--green),var(--blue));transition:width .1s linear}

/* ==========================================================================
   3 · MONETIZATION — shared chrome
   Every unit carries a visible label. Non-negotiable: unlabelled units are
   the single most common RSOC strike.
   ========================================================================== */

.m{margin:26px 0;position:relative}
.m-hd{display:flex;align-items:center;justify-content:space-between;gap:12px;
  padding:0 0 9px;border-bottom:2px solid var(--navy);margin-bottom:2px}
.m-hd h2,.m-hd .h{margin:0;font:800 12.5px var(--f);letter-spacing:.1em;
  text-transform:uppercase;color:var(--navy)}
.m-lbl{flex-shrink:0;font:800 9px var(--f);letter-spacing:.14em;text-transform:uppercase;
  color:var(--soft);border:1px solid var(--line2);padding:4px 8px;border-radius:4px;background:#fff}

/* ---- M1 · LEAD UNIT (above the fold) ------------------------------------
   Chevron rows. Reads like a results list, which is exactly the mental model
   we want: the reader is picking a search, not clicking a banner.          */
.m-lead{margin:16px 0 24px}
.m-lead .m-hd{border-bottom-color:var(--green)}
/* the lead unit runs tighter than the end block: 4 rows in ~244px so the
   whole unit clears the fold. Titles and subtitles are single-line. */
.m-lead .m-row{padding:10px 14px}
.m-lead .m-hd{padding-bottom:7px}
.m-lead .m-row .t b{font-size:15.5px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.m-lead .m-row .t span{font-size:12px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.m-lead .m-row .ic{width:30px;height:30px;border-radius:9px;font-size:14px}
.m-rows{display:grid;gap:0;border:1px solid var(--mon-bd);border-top:0;
  border-radius:0 0 14px 14px;overflow:hidden;background:#fff;box-shadow:var(--d1)}
.m-row{display:flex;align-items:center;gap:13px;padding:15px 16px;
  border-top:1px solid var(--line);background:#fff;transition:background .14s,padding-left .14s}
.m-row:first-child{border-top:0}
.m-row:hover{background:#F3F8FF;padding-left:21px}
.m-row .ic{width:34px;height:34px;border-radius:10px;flex-shrink:0;display:grid;place-items:center;
  background:var(--bg2);border:1px solid var(--line);font-size:15px;color:var(--muted)}
.m-row:hover .ic{color:var(--blue)}
.m-row .t{flex:1;min-width:0}
.m-row .t b{display:block;font-family:var(--serif);font-size:17px;font-weight:700;
  color:var(--navy);line-height:1.28}
.m-row:hover .t b{color:var(--blue)}
.m-row .t span{display:block;font-size:12.5px;color:var(--soft);margin-top:1px}
.m-row .ar{flex-shrink:0;width:28px;height:28px;border-radius:50%;display:grid;place-items:center;
  background:var(--bg2);color:var(--muted);font-size:15px;font-weight:800;border:1px solid var(--line)}
.m-row:hover .ar{background:var(--green);color:#fff;border-color:transparent}

/* tight-fold variant: 4 rows in ~250px. Set data-fold="tight" on <body>. */
body[data-fold="tight"] .dek{display:none}
body[data-fold="tight"] .m-lead .m-row{padding:11px 15px}
body[data-fold="tight"] .m-lead .m-row .t b{font-size:15.5px}
body[data-fold="tight"] .m-lead .m-row .t span{display:none}

/* ---- M2 · CHIPS · "people also search for" -------------------------------
   Deliberately the lightest unit on the page. This is the one that runs at
   ~300 words, right after the reader has committed to the article.        */
.m-chips .m-hd{border-bottom:1px solid var(--line)}
.m-chips .m-hd .h{color:var(--soft)}
.m-chipwrap{display:flex;flex-wrap:wrap;gap:8px;padding-top:13px}
.m-chip{display:inline-flex;align-items:center;gap:7px;background:#fff;
  border:1px solid var(--line2);border-radius:99px;padding:9px 15px;
  font:700 13.5px var(--f);color:var(--navy);box-shadow:0 2px 0 #EEF3FA;transition:.13s}
.m-chip::after{content:"→";color:var(--soft);font-size:12px}
.m-chip:hover{border-color:var(--green);color:var(--green-d);transform:translateY(-1px);
  box-shadow:0 4px 0 #E4F5EE}
.m-chip:hover::after{color:var(--green)}

/* ---- M3 · DECK CARDS -----------------------------------------------------
   Reuses .card / .thumb / .chev from style.css so it is unmistakably the
   same brand as the homepage. Heaviest unit — use it once, mid-article.   */
.m-deck .deck{padding-top:13px}

/* ---- M4 · INLINE BAND ----------------------------------------------------
   One sentence. No frame, no buttons. Slips past ad-blindness entirely and
   converts because it arrives mid-thought.                                */
.m-inline{border-left:3px solid var(--blue);background:linear-gradient(90deg,#F4F8FF,#fff 70%);
  border-radius:0 10px 10px 0;padding:15px 18px;margin:26px 0;font-size:15.5px;color:var(--muted)}
.m-inline b{color:var(--navy)}
.m-inline a{color:var(--blue);font-weight:800;border-bottom:1px solid rgba(22,104,216,.35);
  white-space:nowrap}
.m-inline a:hover{border-bottom-color:var(--blue)}
.m-inline .tag{display:block;font:800 8.5px var(--f);letter-spacing:.15em;
  text-transform:uppercase;color:var(--soft);margin-bottom:5px}

/* ---- M5 · TILE GRID ------------------------------------------------------ */
.m-grid .g2{display:grid;grid-template-columns:1fr 1fr;gap:10px;padding-top:13px}
.m-tile{display:block;background:#fff;border:1px solid var(--line);border-radius:14px;
  padding:15px 14px;box-shadow:var(--d1);transition:.14s}
.m-tile:hover{border-color:var(--green);transform:translateY(-3px);box-shadow:var(--d2)}
.m-tile .em{display:block;font-size:23px;margin-bottom:8px}
.m-tile b{display:block;font:700 14.5px var(--f);color:var(--navy);line-height:1.3;margin-bottom:3px}
.m-tile span{font-size:12px;color:var(--soft)}
@media(max-width:400px){.m-grid .g2{grid-template-columns:1fr}}

/* ---- M6 · END BLOCK ------------------------------------------------------
   Full-bleed tint so it reads as "the article is over, here is the next
   step" rather than as an interruption.                                   */
.m-end{background:var(--bg2);border-top:1px solid var(--line);border-bottom:1px solid var(--line);
  padding:4px 0 26px;margin:34px 0 0}
.m-end .m-hd{margin-top:24px}
.m-end .m-rows{box-shadow:var(--d2)}

/* ---- M7 · STICKY DOCK ----------------------------------------------------
   Hidden until the reader is past M1, so it never competes above the fold. */
.dock{transform:translateY(120%);transition:transform .28s cubic-bezier(.2,.8,.2,1)}
.dock.on{transform:none}
.dock .txt b{font-size:13.5px}
.dock .txt span{font-size:11px}
.dock a{padding:13px 22px;font-size:14.5px}

/* ---- M8 · DESKTOP RAIL ---------------------------------------------------
   Pure upside: free column that only exists at >=1180px, zero mobile cost. */
.layout{display:block}
.rail-unit{display:none}
@media(min-width:1180px){
  .wrap.read{max-width:1120px}
  .layout{display:grid;grid-template-columns:minmax(0,700px) 300px;gap:56px;align-items:start}
  /* margin-top aligns the rail's heading with the H1 rather than with the
     breadcrumb. Without it both start at the same y and the rail reads as
     if it is floating above the article instead of beside it. */
  /* sticky top must clear the sticky masthead, which ends at 98px
     (top bar 43 + pill row 51 + border). 96px left the rail tucking
     2px underneath it on scroll; 110 leaves a visible gap. */
  .rail-unit{display:block;position:sticky;top:110px;margin-top:40px}
  .rail-unit .m-rows{border-top:1px solid var(--mon-bd);border-radius:14px}
  .rail-unit .m-row{padding:12px 14px}
  .rail-unit .m-row .t b{font-size:14.5px}
  .rail-unit .m-row .t span{display:none}
  .rail-unit .m-row .ic{width:28px;height:28px;font-size:13px}
  /* end block stays full width */
}

/* ---- RAIL STORIES — thumbnail + headline ------------------------------
   Artwork is authored at 300x250, so the thumb is 108x90 — exactly 6:5,
   no crop and no distortion. width/height are declared on every <img> so
   the rail reserves its boxes before the files land and nothing shifts.
   The gradient sits underneath: if an image is missing, onerror removes
   the <img> and the gradient shows through rather than leaving a hole. */
.rs{margin:0}
.rs-h{font-family:var(--serif);font-size:19px;font-weight:700;color:var(--navy);
  margin:0 0 4px;padding-bottom:9px;border-bottom:2px solid var(--line2)}
.rs-item{display:flex;align-items:flex-start;gap:13px;padding:12px 0;
  border-bottom:1px solid var(--line)}
.rs-item:last-child{border-bottom:0}
.rs-im{flex-shrink:0;width:108px;height:90px;border-radius:6px;overflow:hidden;
  position:relative;background:var(--bg2)}
.rs-im .g{position:absolute;inset:0;background-size:220% 220%;animation:mv 16s ease-in-out infinite}
.rs-im img{position:absolute;inset:0;z-index:2;width:100%;height:100%;object-fit:cover;display:block}
.rs-t{font:700 14px/1.34 var(--f);color:var(--navy);letter-spacing:-.012em}
.rs-item:hover .rs-t{color:var(--blue)}
.rs-item:hover .rs-im img{transform:scale(1.04)}
.rs-im img{transition:transform .3s cubic-bezier(.2,.8,.2,1)}

/* ---- widget host ---------------------------------------------------------
   The programmer's <div class="umfl_wgt_ebd"> drops inside .m-host. The
   min-height stops the page reflowing when the feed paints — layout shift
   above the fold is both a CWV hit and a measurable CTR hit.              */
.m-host{min-height:260px;border:1px solid var(--mon-bd);border-top:0;
  border-radius:0 0 14px 14px;background:#fff;overflow:hidden;box-shadow:var(--d1)}
.m-host .umfl_wgt_ebd{width:100%}
.m-host iframe{width:100%!important;border:0;display:block}
.rail-unit .m-host{min-height:320px;border-top:1px solid var(--mon-bd);border-radius:14px}

/* skeleton while the feed loads, so the slot never looks broken */
.m-host:empty::before,.m-host .umfl_wgt_ebd:empty::before{
  content:"";display:block;height:260px;
  background:linear-gradient(100deg,#F4F7FC 30%,#EAF0F9 50%,#F4F7FC 70%);
  background-size:220% 100%;animation:shim 1.4s linear infinite}
@keyframes shim{to{background-position:-220% 0}}

/* ==========================================================================
   4 · DISCLOSURE
   ========================================================================== */
.disc{font-size:11.5px;line-height:1.6;color:var(--soft);background:var(--bg2);
  border:1px solid var(--line);border-radius:10px;padding:12px 15px;margin:24px 0 0}
.disc b{color:var(--muted)}

/* ==========================================================================
   5 · MONETIZATION MAP (internal QA overlay — style.css draws the outline)
   ========================================================================== */
body.mm .m::before{content:attr(data-slot);position:absolute;top:-9px;right:6px;z-index:99;
  background:#0E1D44;color:#fff;font:700 9px/1 var(--f);padding:4px 7px;border-radius:4px;
  letter-spacing:.06em}
body.mm .m{outline:2px dashed rgba(226,60,120,.7);outline-offset:6px}

@media(prefers-reduced-motion:reduce){
  .m-host:empty::before,.m-host .umfl_wgt_ebd:empty::before{animation:none}
  .dock{transition:none}
}
