/* Mulligan Memo print stylesheet.
   Linked on every page as <link rel="stylesheet" href="/styles/print.css" media="print">, AFTER
   article.css, so it wins ties. Goal: a reader prints a reference chart and gets the chart and
   the words around it on plain white paper, with none of the site chrome.

   Rules of thumb used below:
   - Hiding is by class/element, never by "everything except". The yardage card prints its own
     two-up sheet from article.css (.yc-*); nothing here may fight that, so no blanket hiding of
     inputs, no display overrides on .wrap/.ahead/.tldr, and tables exclude .yc-table.
   - The calculators on these pages (.gsc, .gaplab) print their RESULT if the reader has used
     them, never the empty input form.
   - Selectors that article.css already forces with !important get !important here too. */

@page { size: letter portrait; margin: 0.5in; }

/* ---- page + type ---------------------------------------------------------------- */
html, body {
  background: #fff !important;
  color: #000 !important;
  height: auto !important;
  overflow: visible !important;
  margin: 0 !important;
  padding: 0 !important;
}
body {
  font-size: 10.5pt !important;
  line-height: 1.4 !important;
  -webkit-print-color-adjust: economy;
  print-color-adjust: economy;
}
* {
  box-shadow: none !important;
  text-shadow: none !important;
  background-image: none !important;
  animation: none !important;
  transition: none !important;
}
/* flatten the screen "paper" look; table highlights are put back below */
article, .wrap, .copy, .post-head, .post-body, section, figure, .frame, .tldr, .callout, .quote, .pull,
.pick, .glance, .gsc, .gsc-out, .gaplab, .byline, header {
  background: transparent !important;
}
p, li, dd, blockquote { color: #000 !important; orphans: 3; widows: 3; }
p, li, dd { font-size: 10.5pt !important; line-height: 1.4 !important; max-width: none !important; }
.wrap, article.wrap, .copy, .post-head, .post-body {
  max-width: none !important;
  width: auto !important;
  margin-left: 0 !important;
  margin-right: 0 !important;
  padding-left: 0 !important;
  padding-right: 0 !important;
  float: none !important;
}
h1, h2, h3, h4, h5, h6, .title, .kick, .eyebrow, .dek, .byline, .crumb, figcaption, .src, .note, .for {
  color: #000 !important;
}
h1, h1.title { font-size: 21pt !important; line-height: 1.15 !important; margin: 0 0 6pt !important; }
.dek { font-size: 11.5pt !important; line-height: 1.35 !important; margin: 0 0 10pt !important; }
h2 { font-size: 14pt !important; line-height: 1.2 !important; margin: 16pt 0 5pt !important; }
h3 { font-size: 11.5pt !important; line-height: 1.25 !important; margin: 11pt 0 4pt !important; }
h1, h2, h3, h4, summary { break-after: avoid; page-break-after: avoid; }
h2 .kick { display: block; font-size: 7.5pt !important; letter-spacing: 0.12em; text-transform: uppercase; margin-bottom: 1pt; }
p, ul, ol { margin-top: 0; margin-bottom: 6pt; }
.tldr { border: 0 !important; border-left: 2.5pt solid #000 !important; padding: 2pt 0 2pt 9pt !important; margin: 8pt 0 10pt !important; }
.tldr .h { font-size: 8pt !important; letter-spacing: 0.12em; text-transform: uppercase; font-weight: 700; }
.tldr, .callout, .gsc, .frame, figure, details, .signup-box { border-radius: 0 !important; }
.callout { border: 0 !important; border-left: 2pt solid #000 !important; padding: 2pt 0 2pt 9pt !important; margin: 8pt 0 !important; break-inside: avoid; }
.tldr p { margin-bottom: 0; font-size: 10.5pt !important; line-height: 1.4 !important; max-width: none !important; }
/* article.css hides .tldr in print (its yardage-card block is not scoped to that page). The short
   answer is worth printing on every chart page, so put it back everywhere except the yardage card. */
article:not(:has(.yc-sheet)) .tldr, article:not(:has(.yc-sheet)) .ahead { display: block !important; }
.ahead { border: 0 !important; padding: 0 !important; margin: 0 0 6pt !important; }
.ahead .crumb { font-size: 8pt !important; letter-spacing: 0.1em; text-transform: uppercase; }
blockquote, .quote, .pull { font-size: 10.5pt !important; line-height: 1.35 !important; margin: 6pt 0 8pt !important;
  padding: 0 0 0 10pt !important; border: 0 !important; border-left: 2pt solid #000 !important; break-inside: avoid; }

/* ---- links: text only, no URLs, no underline tricks ------------------------------ */
a, a:link, a:visited, a.inline {
  color: #000 !important;
  text-decoration: none !important;
}
a[href]::after, a[href]::before { content: none !important; }
abbr[title]::after { content: none !important; }

/* ---- hidden when printing --------------------------------------------------------- */
.mm-topbar, .mm-nav, .mm-search, .mm-mobile-row, .mm-menu-label, .mm-nav-toggle,
footer, .fdisc, .disclose, .crumbs, nav[aria-label="Breadcrumb"],
.toc, details.toc, nav[aria-label="On this page"],
aside.buy, .buy, .buybox, .signup-box, .foot-sub, .foot-sub-form, .foot-sub-msg,
.related, .share, .social, .comments, #comments, .newsletter,
.chart-tools, .no-print,
.cta, a.cta, .cta-mini, .cta-pair, .cta-sec, .cta-note, .bag-prompt, .bag-inline-btn,
th.g-go, td.g-go,
.gl-bar, .gl-inputs,
button, form, iframe, video, audio, noscript,
.gsc-inputs, .gsc-empty, .lc-toggles, .lf-presets, .lf-rows, .lf-add, .lf-del {
  display: none !important;
}
.sr-only { display: none !important; }

/* calculators: no frame; the result (if the reader ran one) and the footnote print */
.gsc { border: 0 !important; padding: 0 !important; margin: 4pt 0 8pt !important; }
.gsc-out { border: 0 !important; padding: 0 !important; margin: 0 0 4pt !important; }
.gsc-foot { font-size: 8.5pt !important; margin: 4pt 0 0 !important; padding: 0 !important; border: 0 !important; }
.gaplab { border: 0 !important; padding: 0 !important; }

/* ---- FAQ and other <details>: always open ---------------------------------------- */
details > summary {
  list-style: none !important;
  font-weight: 700;
  color: #000 !important;
  cursor: auto;
  padding: 0 !important;
  margin: 8pt 0 2pt !important;
  border: 0 !important;
}
details > summary::-webkit-details-marker { display: none !important; }
details > summary::marker { content: "" !important; }
details > summary::after, details > summary::before { content: none !important; display: none !important; }
details::details-content {
  content-visibility: visible !important;
  display: block !important;
  height: auto !important;
  block-size: auto !important;
}
details { border: 0 !important; padding: 0 !important; margin: 0 !important; }
details > *:not(summary) { margin-left: 0 !important; padding-left: 0 !important; }
details > p { margin: 0 0 6pt; }
.faq details { break-inside: avoid; page-break-inside: avoid; }

/* ---- tables: full width, ruled, header repeats, rows never split ------------------ */
.glance, .copy, figure, figure.fig, .frame, .rc-wrap, .table-wrap, .scroll {
  overflow: visible !important;
}
/* a letter page is 720 CSS px wide, so article.css's phone rules apply in print: undo the
   "table becomes a scrolling block" one */
table:not(.yc-table) {
  display: table !important;
  overflow: visible !important;
  border-radius: 0 !important;
  width: 100% !important;
  max-width: 100% !important;
  min-width: 0 !important;
  table-layout: auto;
  border-collapse: collapse !important;
  border: 0.75pt solid #000 !important;
  margin: 6pt 0 8pt !important;
  font-size: 9.5pt !important;
  line-height: 1.3 !important;
  background: transparent !important;
}
table:not(.yc-table) th,
table:not(.yc-table) td {
  border: 0.5pt solid #000 !important;
  padding: 3pt 5pt !important;
  color: #000 !important;
  background: transparent !important;
  min-width: 0 !important;
  white-space: normal !important;
  overflow-wrap: anywhere;
  vertical-align: top;
  text-align: left;
}
table:not(.yc-table) thead { display: table-header-group; }
table:not(.yc-table) tfoot { display: table-footer-group; }
table:not(.yc-table) tr { break-inside: avoid; page-break-inside: avoid; }
table:not(.yc-table) thead th {
  background: #e9e9e9 !important;
  font-weight: 700;
  -webkit-print-color-adjust: exact;
  print-color-adjust: exact;
}
table:not(.yc-table) td.win, table:not(.yc-table) th.win,
table:not(.yc-table) tr.win td, table:not(.yc-table) tr.pick td {
  background: #efefef !important;
  font-weight: 700;
  -webkit-print-color-adjust: exact;
  print-color-adjust: exact;
}
table caption { color: #000 !important; font-weight: 700; text-align: left; margin-bottom: 3pt; }
table td a, table th a { text-decoration: none !important; }
table td.num, table td.v, table td.n { text-align: right; }

/* ---- figures, charts, images ------------------------------------------------------ */
figure, figure.fig { margin: 8pt 0 10pt !important; padding: 0 !important; border: 0 !important; }
figure { break-inside: avoid; page-break-inside: avoid; }
/* a figure that wraps a long table may split between rows (rows themselves never split) */
figure:has(> table) { break-inside: auto; page-break-inside: auto; }
figure.fig .frame, .frame { border: 0 !important; padding: 0 !important; margin: 0 !important; }
svg, figure svg, figure.fig svg {
  max-width: 100% !important;
  width: 100% !important;
  height: auto !important;
  display: block;
  margin-left: auto;
  margin-right: auto;
}
img, figure img {
  max-width: 100% !important;
  max-height: 5in !important;   /* a tall chart image still fits on one page with its caption */
  width: auto !important;
  height: auto !important;
  object-fit: contain;
  display: block;
  margin-left: auto;
  margin-right: auto;
  break-inside: avoid;
  page-break-inside: avoid;
}
figcaption { font-size: 8.5pt !important; line-height: 1.3 !important; margin-top: 3pt !important; font-style: normal; }
figcaption .src { display: block; font-size: 8pt !important; }

/* ---- the print-only footer line (also kills the screen paper-grain overlay) -------
   On screen body::after is a fixed full-page grain layer. Here it becomes a one-line footer at the
   end of the document. (position:fixed was tried so it would repeat on every page; Chrome puts it
   at the wrong height and drops it from page 1, so it stays a plain block.) */
body::after {
  content: "From mulliganmemo.com" !important;
  display: block !important;
  position: static !important;
  inset: auto !important;
  z-index: auto !important;
  pointer-events: auto !important;
  width: auto !important;
  height: auto !important;
  background: none !important;
  margin: 10pt 0 0 !important;
  padding: 3pt 0 0 !important;
  border-top: 0.5pt solid #000;
  font: 8.5pt/1.2 ui-monospace, "Courier New", monospace !important;
  letter-spacing: 0.06em;
  text-align: center;
  color: #000 !important;
  break-before: avoid;
  page-break-before: avoid;
}
/* the yardage card sheet already carries its own mulliganmemo.com line inside each card */
body:has(.yc-sheet)::after { content: none !important; display: none !important; }

/* table scroll wrappers (scripts/wrap-tables.mjs) print as plain tables */
.tscroll { overflow: visible !important; box-shadow: none !important; border-radius: 0 !important; margin: 8px 0 14px !important; }
.tscroll > table th:first-child, .tscroll > table td:first-child { position: static !important; box-shadow: none !important; }

.more-charts { display: none !important; }
