* { box-sizing: border-box; }
:root { color-scheme: light; --ink: #183248; --muted: #566878; --line: #e2e8ed; --blue: #b7def8; }
body { margin: 0; background: #f4f7fa; color: var(--ink); font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif; font-size: 1rem; line-height: 1.6; }
button, a { -webkit-tap-highlight-color: transparent; }
button { font: inherit; }
a { color: #225c83; text-underline-offset: 3px; }
a:hover { color: #123951; }
a:focus-visible, button:focus-visible { outline: 3px solid #267bbb; outline-offset: 5px; }
[hidden] { display: none !important; }
.masthead { background: #142f43; color: white; border-bottom: 3px solid #a6d9fb; }
.masthead-inner { max-width: 1120px; margin: auto; padding: 22px 40px; display: flex; align-items: center; justify-content: space-between; gap: 24px; }
.brand { display: flex; align-items: center; gap: 10px; font-weight: 750; font-size: 1.4rem; letter-spacing: -.025em; }
.brand svg { width: 25px; height: 25px; color: var(--blue); }
.personal-label { font-size: .875rem; color: #c7d6e0; }
.page { max-width: 1120px; margin: auto; padding: 52px 40px 28px; }
.page-heading { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 24px; margin-bottom: 34px; }
.page-heading > div { min-width: 0; flex: 1 1 16rem; }
.eyebrow { margin: 0 0 10px; color: #517084; font-size: .75rem; font-weight: 700; letter-spacing: .15em; }
h1 { overflow-wrap: anywhere; margin: 0; font-size: clamp(2.1rem, 4vw, 3rem); line-height: 1.14; letter-spacing: -.045em; font-weight: 720; }
h1 span { color: #408bb5; }
.intro { margin: 14px 0 0; color: var(--muted); }
.count { white-space: nowrap; color: #516979; font-size: .875rem; margin-bottom: 4px; padding: 5px 13px; border: 1px solid #dce5ec; border-radius: 30px; }
.collection { display: grid; gap: 24px; }
.tip-card { display: grid; grid-template-columns: 270px minmax(0, 1fr); background: white; border: 1px solid var(--line); border-radius: 16px; box-shadow: 0 8px 32px #19384a08; }
.cover-wrap { position: relative; background: #152f40; border-radius: 15px 0 0 15px; overflow: hidden; display: flex; align-items: center; }
.cover { display: block; width: 100%; height: auto; object-fit: contain; }
.cover-error { position: absolute; inset: 0; display: grid; place-items: center; color: white; padding: 20px; text-align: center; }
.card-content { padding: 25px 32px 20px; min-width: 0; }
.card-top { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.category { display: inline-flex; align-items: center; gap: 7px; font-size: .875rem; font-weight: 600; color: #305e7a; background: #edf5fb; border-radius: 6px; padding: 5px 10px; }
.category svg { width: 17px; height: 17px; }
.explanation-wrap { position: relative; flex-shrink: 0; }
.explanation-button { width: 42px; height: 42px; display: grid; place-items: center; border: 1px solid #cbdae4; border-radius: 50%; color: #225c83; background: #f3f8fc; cursor: pointer; }
.explanation-button:hover:not(:disabled) { background: #e4f1fa; }
.explanation-button:disabled { color: #9ca9b2; background: #f5f6f7; border-color: #e6eaee; cursor: default; }
.explanation-button svg { width: 23px; height: 23px; }
.title-row { display: flex; align-items: baseline; flex-wrap: wrap; gap: 13px; margin: 9px 0 19px; }
.tip-title { margin: 0; font-size: 2rem; font-weight: 700; letter-spacing: -.035em; line-height: 1.25; overflow-wrap: anywhere; }
.year { color: var(--muted); font-size: 1rem; }
.field-label { margin: 0 0 9px; color: var(--muted); font-size: .875rem; }
.people { display: flex; flex-wrap: wrap; gap: 8px; margin: 0; padding: 0; list-style: none; }
.person { display: inline-flex; align-items: center; gap: 8px; font-size: .875rem; padding: 4px 12px 4px 5px; border-radius: 30px; background: #f4f6f8; color: #314b5f; }
.initial { display: grid; place-items: center; width: 25px; height: 25px; border-radius: 50%; background: #deebf5; color: #35546b; font-size: .75rem; font-weight: 650; }
.person:nth-child(2n) .initial { background: #e5e5f2; color: #555477; }
.person:nth-child(3n) .initial { background: #e1ece9; color: #3f645c; }
.availability { border-top: 1px solid var(--line); margin-top: 23px; padding-top: 18px; }
.region { display: inline-block; margin-left: 5px; font-size: .75rem; color: #667b88; }
.region::before { content: "· "; }
.availability-summary { font-size: 1rem; font-weight: 650; margin: 0 0 5px; }
.availability-details { color: var(--muted); font-size: .875rem; line-height: 1.6; margin: 0; max-width: 54ch; }
.kobo-plus { color: var(--ink); font-size: .875rem; margin: 8px 0; }
.watch-options { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 16px; }
.watch-link { display: inline-flex; flex-wrap: wrap; max-width: 100%; overflow-wrap: anywhere; align-items: center; gap: 8px; border-radius: 7px; border: 1px solid #c9dce9; padding: 8px 14px; font-size: .875rem; font-weight: 600; text-decoration: none; background: #f7fbfe; }
.watch-link:hover { background: #ebf5fc; border-color: #8fb5ce; }
.option-type { font-size: .75rem; color: #566e80; font-weight: 400; }
.card-footer { display: flex; justify-content: space-between; align-items: baseline; flex-wrap: wrap; gap: 8px 16px; border-top: 1px solid var(--line); padding-top: 12px; margin-top: 21px; color: #677985; font-size: .75rem; }
.source-links { display: flex; flex-wrap: wrap; gap: 12px; }
.source-links a { color: #566e80; }
.footer { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px 20px; padding-top: 28px; color: #637683; font-size: .8125rem; }
.explanation-popover { position: absolute; top: 52px; right: 0; width: 320px; max-width: calc(100vw - 60px); padding: 19px; color: var(--ink); background: white; border: 1px solid #cfdae2; border-radius: 12px; box-shadow: 0 12px 40px #102b4326; z-index: 10; }
.popover-heading { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.popover-heading h3 { margin: 0; font-size: 1rem; }
.close-popover { background: transparent; border: none; color: #566878; padding: 0; width: 32px; height: 32px; font-size: 1.5rem; cursor: pointer; }
.explanation-text { white-space: pre-wrap; overflow-wrap: anywhere; font-size: 1rem; margin: 10px 0 0; }
.empty { color: var(--muted); border: 1px dashed #c8d5de; padding: 32px; border-radius: 12px; }
@media (max-width: 760px) {
  .page { padding: 36px 24px 24px; }
  .masthead-inner { padding: 18px 24px; }
  .tip-card { grid-template-columns: 190px minmax(0, 1fr); }
  .card-content { padding: 20px; }
  .cover-wrap { align-items: flex-start; }
  .title-row { margin-top: 13px; }
  .card-footer { gap: 8px; }
}
@media (max-width: 560px) {
  .page { padding: 30px 20px 24px; }
  .masthead-inner { padding: 16px 20px; }
  .page-heading { align-items: flex-start; gap: 12px; margin-bottom: 25px; }
  .count { margin-top: 0; align-self: center; }
  h1 { font-size: 2rem; }
  .intro { max-width: 24ch; }
  .tip-card { grid-template-columns: minmax(0, 1fr); }
  .cover-wrap { border-radius: 15px 15px 0 0; justify-content: center; padding: 20px; }
  .cover { width: min(100%, 205px); border-radius: 3px; box-shadow: 0 5px 24px #0005; }
  .card-content { padding: 20px 23px; }
  .tip-title { font-size: 1.85rem; }
  .footer { flex-direction: column; padding-top: 22px; }
}
@media (prefers-reduced-motion: no-preference) { .watch-link, .explanation-button { transition: background-color .15s, border-color .15s; } }
@media print { body { background: white; } .masthead { color: black; background: white; } .explanation-button { display: none; } .tip-card { break-inside: avoid; box-shadow: none; } }
