/* atwarm.com — Jenna Whitlock
   Personal-finance & pokies blog with a warm, plain-English voice.
   Light mode, rounded humanist typography, hand-drawn SVG accents. */

:root {
  --bg: #faf6ee;
  --bg-warm: #f5e5b8;
  --bg-warm-2: #f7ecc9;
  --paper: #ffffff;
  --rose: #c88a8a;
  --rose-deep: #a86868;
  --rose-soft: #efd7d7;
  --sage: #4a5f42;
  --sage-light: #7d9174;
  --sage-mist: #dfe6da;
  --brown: #3a2f1e;
  --brown-mid: #6a5a44;
  --brown-fade: #8a7860;
  --line: #e5dcc4;
  --line-soft: #eee5cf;
  --sun: #e8a838;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: "Verdana", "Nunito", "Trebuchet MS", "Helvetica Neue", Arial, sans-serif;
  font-size: 17px;
  line-height: 1.72;
  color: var(--brown);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}

/* Rounded humanist heading stack. Uses system geometric sans for a friendly feel. */
h1, h2, h3, h4, h5 {
  font-family: "Nunito", "Avenir Next Rounded", "Verdana", "Trebuchet MS", sans-serif;
  color: var(--sage);
  letter-spacing: -0.2px;
}

/* ============ MASTHEAD ============ */
.masthead {
  background: var(--bg);
  border-bottom: 2px dotted var(--rose);
  padding: 0;
}
.masthead-inner {
  max-width: 1120px;
  margin: 0 auto;
  padding: 24px 32px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 30px;
  flex-wrap: wrap;
}
.brand {
  text-decoration: none;
  color: var(--sage);
  display: flex;
  align-items: center;
  gap: 12px;
}
.brand-mark {
  width: 44px;
  height: 44px;
  background: var(--rose);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-weight: 800;
  font-size: 22px;
  font-family: "Nunito", sans-serif;
  flex-shrink: 0;
  box-shadow: 2px 2px 0 var(--sage);
}
.brand-name {
  font-size: 26px;
  font-weight: 800;
  color: var(--sage);
  line-height: 1;
}
.brand-tag {
  font-size: 12px;
  color: var(--brown-fade);
  font-style: italic;
  display: block;
  margin-top: 3px;
  font-family: "Georgia", serif;
}
.mainnav {
  display: flex;
  gap: 20px;
  flex-wrap: wrap;
}
.mainnav a {
  color: var(--sage);
  text-decoration: none;
  font-family: "Nunito", "Verdana", sans-serif;
  font-size: 15px;
  font-weight: 700;
  padding: 6px 14px;
  border-radius: 20px;
  transition: background .15s, color .15s;
}
.mainnav a:hover, .mainnav a[aria-current="page"] {
  background: var(--rose-soft);
  color: var(--rose-deep);
}

/* ============ HERO ============ */
.hero {
  background: var(--bg-warm);
  border-bottom: 2px dotted var(--rose);
  padding: 60px 0 70px;
  position: relative;
  overflow: hidden;
}
.hero-inner {
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 32px;
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 50px;
  align-items: center;
}
.hero-doodle-1, .hero-doodle-2 {
  position: absolute;
  opacity: 0.6;
  pointer-events: none;
}
.hero-doodle-1 { top: 20px; right: 8%; width: 60px; }
.hero-doodle-2 { bottom: 30px; left: 5%; width: 70px; }

.eyebrow {
  font-family: "Georgia", serif;
  font-style: italic;
  font-size: 15px;
  color: var(--rose-deep);
  margin: 0 0 16px;
  display: flex;
  align-items: center;
  gap: 10px;
}
.eyebrow svg { width: 20px; height: 20px; }

h1.headline {
  font-family: "Nunito", "Avenir Next Rounded", sans-serif;
  font-weight: 900;
  font-size: 46px;
  line-height: 1.08;
  color: var(--sage);
  margin: 0 0 20px;
  letter-spacing: -0.5px;
}
h1.headline .rose { color: var(--rose-deep); }
h1.headline .underline {
  background: linear-gradient(to top, var(--rose-soft) 0%, var(--rose-soft) 40%, transparent 40%);
  padding: 0 2px;
}
.standfirst {
  font-size: 19px;
  line-height: 1.55;
  color: var(--brown);
  margin: 0 0 24px;
}
.hero-meta {
  font-size: 14px;
  color: var(--brown-fade);
  display: flex;
  gap: 20px;
  flex-wrap: wrap;
  font-family: "Georgia", serif;
  font-style: italic;
}
.hero-meta strong { color: var(--sage); font-weight: 700; font-family: "Nunito", sans-serif; font-style: normal; }

.hero-image {
  border-radius: 20px;
  overflow: hidden;
  box-shadow: 6px 6px 0 var(--sage);
  aspect-ratio: 4/3;
  position: relative;
  transform: rotate(-1deg);
}
.hero-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* ============ ARTICLE ============ */
.page {
  max-width: 780px;
  margin: 0 auto;
  padding: 60px 32px 30px;
}

.article > p {
  margin: 0 0 20px;
  font-size: 17px;
  line-height: 1.72;
  color: var(--brown);
}
.article > p a {
  color: var(--rose-deep);
  font-weight: 700;
  text-decoration: underline;
  text-decoration-color: var(--rose);
  text-decoration-thickness: 2px;
  text-underline-offset: 3px;
}
.article > p a:hover {
  color: var(--sage);
  text-decoration-color: var(--sage);
}

/* Big rounded H2 */
h2 {
  font-family: "Nunito", "Avenir Next Rounded", sans-serif;
  font-weight: 800;
  font-size: 28px;
  line-height: 1.2;
  color: var(--sage);
  margin: 50px 0 16px;
  display: flex;
  align-items: baseline;
  gap: 12px;
}
h2::before {
  content: "";
  display: inline-block;
  width: 14px;
  height: 14px;
  background: var(--rose);
  border-radius: 50%;
  flex-shrink: 0;
  transform: translateY(-2px);
}

h3 {
  font-family: "Nunito", sans-serif;
  font-weight: 700;
  font-size: 21px;
  color: var(--sage);
  margin: 32px 0 8px;
}

ul, ol {
  margin: 0 0 24px;
  padding-left: 24px;
  font-size: 17px;
  line-height: 1.7;
  color: var(--brown);
}
li { margin-bottom: 10px; }
ul li::marker { color: var(--rose); }
ol li::marker { color: var(--sage); font-weight: 700; }

/* Highlight boxes — plain-English callouts */
.tip-box {
  background: var(--sage-mist);
  border-left: 5px solid var(--sage);
  border-radius: 0 14px 14px 0;
  padding: 20px 24px;
  margin: 26px 0;
  position: relative;
}
.tip-box::before {
  content: "";
  position: absolute;
  top: -14px;
  left: 20px;
  width: 32px;
  height: 32px;
  background: var(--sage);
  border-radius: 50%;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23faf6ee' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M9 11a3 3 0 016 0c0 3-3 4-3 6M12 21v-1'/%3E%3C/svg%3E");
  background-size: 24px;
  background-position: center;
  background-repeat: no-repeat;
}
.tip-box h4 {
  margin: 0 0 8px;
  font-size: 15px;
  color: var(--sage);
  text-transform: uppercase;
  letter-spacing: 0.6px;
  font-weight: 800;
}
.tip-box p { margin: 0 0 8px; color: var(--brown); }
.tip-box p:last-child { margin-bottom: 0; }

.warn-box {
  background: var(--rose-soft);
  border-left: 5px solid var(--rose);
  border-radius: 0 14px 14px 0;
  padding: 20px 24px;
  margin: 26px 0;
  position: relative;
}
.warn-box::before {
  content: "";
  position: absolute;
  top: -14px;
  left: 20px;
  width: 32px;
  height: 32px;
  background: var(--rose);
  border-radius: 50%;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23faf6ee' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M12 9v4M12 17h.01M10.29 3.86L1.82 18a2 2 0 001.71 3h16.94a2 2 0 001.71-3L13.71 3.86a2 2 0 00-3.42 0z'/%3E%3C/svg%3E");
  background-size: 22px;
  background-position: center;
  background-repeat: no-repeat;
}
.warn-box h4 {
  margin: 0 0 8px;
  font-size: 15px;
  color: var(--rose-deep);
  text-transform: uppercase;
  letter-spacing: 0.6px;
  font-weight: 800;
}
.warn-box p { margin: 0 0 8px; color: var(--brown); }
.warn-box p:last-child { margin-bottom: 0; }

/* Pull quote */
.pullquote {
  font-family: "Georgia", serif;
  font-style: italic;
  font-size: 22px;
  line-height: 1.4;
  color: var(--sage);
  padding: 28px 0 28px 30px;
  border-left: 4px solid var(--rose);
  margin: 32px 0;
  position: relative;
}
.pullquote::before {
  content: "“";
  position: absolute;
  left: -8px;
  top: -12px;
  font-size: 60px;
  color: var(--rose);
  font-family: Georgia, serif;
  line-height: 1;
}
.pullquote-attrib {
  display: block;
  font-family: "Nunito", sans-serif;
  font-style: normal;
  font-size: 14px;
  color: var(--brown-fade);
  margin-top: 12px;
  font-weight: 700;
}
.pullquote-attrib::before { content: "— "; color: var(--rose); }

/* Gallery image — soft rounded card feel */
.article-image {
  margin: 34px 0;
  border-radius: 18px;
  overflow: hidden;
  box-shadow: 5px 5px 0 var(--sage-mist);
}
.article-image img { width: 100%; height: auto; display: block; }
.article-image figcaption {
  padding: 12px 18px;
  font-family: "Georgia", serif;
  font-style: italic;
  font-size: 14px;
  color: var(--brown-fade);
  background: var(--paper);
  line-height: 1.5;
}

/* Step cards for beginner guides */
.step-card {
  background: var(--paper);
  border: 1.5px solid var(--line);
  border-radius: 18px;
  padding: 22px 24px;
  margin: 20px 0;
  display: grid;
  grid-template-columns: 44px 1fr;
  gap: 18px;
  align-items: start;
}
.step-num {
  background: var(--sun);
  color: var(--brown);
  border-radius: 50%;
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: "Nunito", sans-serif;
  font-weight: 900;
  font-size: 22px;
}
.step-card h3 {
  margin: 0 0 6px;
  color: var(--sage);
  font-size: 19px;
}
.step-card p {
  margin: 0 0 8px;
  font-size: 16px;
  line-height: 1.65;
  color: var(--brown);
}
.step-card p:last-child { margin-bottom: 0; }

/* Author bio */
.author-bio {
  background: var(--paper);
  border-radius: 20px;
  padding: 26px;
  margin: 40px 0 20px;
  display: grid;
  grid-template-columns: 100px 1fr;
  gap: 22px;
  box-shadow: 4px 4px 0 var(--sage-mist);
}
.author-bio img {
  width: 100px;
  height: 100px;
  object-fit: cover;
  border-radius: 50%;
  border: 3px solid var(--rose);
}
.author-bio h4 {
  margin: 0 0 4px;
  font-family: "Nunito", sans-serif;
  font-weight: 800;
  font-size: 20px;
  color: var(--sage);
}
.author-bio .role {
  font-family: "Georgia", serif;
  font-style: italic;
  font-size: 14px;
  color: var(--rose-deep);
  margin: 0 0 10px;
}
.author-bio p {
  margin: 0;
  font-size: 15px;
  line-height: 1.6;
  color: var(--brown-mid);
}

/* TOC */
.toc {
  background: var(--bg-warm-2);
  border-radius: 16px;
  padding: 24px 28px;
  margin: 32px 0;
  position: relative;
}
.toc::before {
  content: "";
  position: absolute;
  top: -12px;
  left: 26px;
  padding: 3px 12px;
  background: var(--sage);
  color: var(--bg);
  border-radius: 12px;
  font-family: "Nunito", sans-serif;
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  content: "What's in this post";
}
.toc ol {
  margin: 4px 0 0;
  padding: 0;
  list-style: none;
  columns: 2;
  column-gap: 30px;
  font-family: "Nunito", "Verdana", sans-serif;
  font-size: 15px;
}
.toc li {
  break-inside: avoid;
  margin-bottom: 8px;
  padding-left: 18px;
  position: relative;
}
.toc li::before {
  content: "❤";
  position: absolute;
  left: 0;
  color: var(--rose);
  font-size: 11px;
  top: 3px;
}
.toc a {
  color: var(--sage);
  text-decoration: none;
  border-bottom: 1px dotted var(--sage-light);
  padding-bottom: 1px;
}
.toc a:hover { color: var(--rose-deep); border-bottom-color: var(--rose); }

/* FAQ */
.faq { margin: 32px 0; }
.faq details {
  background: var(--paper);
  border: 1.5px solid var(--line);
  border-radius: 14px;
  padding: 0;
  margin-bottom: 12px;
}
.faq summary {
  padding: 18px 50px 18px 22px;
  cursor: pointer;
  list-style: none;
  position: relative;
  font-family: "Nunito", sans-serif;
  font-weight: 700;
  font-size: 17px;
  color: var(--sage);
  line-height: 1.35;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "+";
  position: absolute;
  right: 20px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 24px;
  color: var(--rose);
  font-family: "Nunito", sans-serif;
  font-weight: 900;
  line-height: 1;
  transition: transform .2s;
}
.faq details[open] summary::after { content: "−"; }
.faq details[open] {
  border-color: var(--rose);
  background: var(--rose-soft);
}
.faq details p {
  margin: 0 22px 18px;
  color: var(--brown);
  font-size: 15.5px;
  line-height: 1.65;
}

/* Breadcrumbs */
.breadcrumbs {
  max-width: 780px;
  margin: 0 auto;
  padding: 24px 32px 0;
  font-family: "Nunito", sans-serif;
  font-size: 13px;
  color: var(--brown-fade);
}
.breadcrumbs a {
  color: var(--rose-deep);
  text-decoration: none;
  font-weight: 700;
}
.breadcrumbs a:hover { color: var(--sage); }
.breadcrumbs .sep { margin: 0 8px; color: var(--brown-fade); }

/* Related posts */
.related {
  margin: 50px 0 30px;
  padding: 30px 0 0;
  border-top: 2px dotted var(--rose);
}
.related h3 {
  margin: 0 0 20px;
  font-family: "Nunito", sans-serif;
  font-size: 21px;
  color: var(--sage);
  font-weight: 800;
}
.related-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 20px;
}
.related-item {
  background: var(--paper);
  border: 1.5px solid var(--line);
  border-radius: 16px;
  padding: 20px;
  transition: box-shadow .2s;
}
.related-item:hover { box-shadow: 4px 4px 0 var(--rose-soft); }
.related-item .tag {
  display: inline-block;
  background: var(--sage-mist);
  color: var(--sage);
  font-family: "Nunito", sans-serif;
  font-size: 11px;
  font-weight: 800;
  padding: 3px 10px;
  border-radius: 12px;
  margin-bottom: 10px;
  text-transform: uppercase;
  letter-spacing: 0.4px;
}
.related-item a {
  color: var(--sage);
  text-decoration: none;
  font-family: "Nunito", sans-serif;
  font-weight: 800;
  font-size: 17px;
  line-height: 1.25;
  display: block;
}
.related-item a:hover { color: var(--rose-deep); }
.related-item p {
  font-size: 14px;
  color: var(--brown-mid);
  margin: 8px 0 0;
  line-height: 1.5;
}

/* Disclosure */
.disclosure {
  background: var(--bg-warm-2);
  border-radius: 16px;
  padding: 22px 26px;
  margin: 32px 0;
  font-size: 14.5px;
  line-height: 1.6;
  color: var(--brown);
}
.disclosure h4 {
  font-family: "Nunito", sans-serif;
  font-weight: 800;
  font-size: 14px;
  color: var(--rose-deep);
  letter-spacing: 0.4px;
  margin: 0 0 10px;
  text-transform: uppercase;
}
.disclosure p { margin: 0 0 8px; }
.disclosure p:last-child { margin-bottom: 0; }
.disclosure a { color: var(--rose-deep); font-weight: 700; }
.badge-18 {
  display: inline-block;
  background: var(--rose);
  color: white;
  font-family: "Nunito", sans-serif;
  font-weight: 900;
  padding: 3px 9px;
  border-radius: 8px;
  margin-right: 10px;
  font-size: 12.5px;
  letter-spacing: 0.4px;
}

/* ============ FOOTER ============ */
.masthead-foot {
  background: var(--sage);
  color: var(--bg);
  margin-top: 50px;
  padding: 0;
}
.masthead-foot-inner {
  max-width: 1120px;
  margin: 0 auto;
  padding: 44px 32px 24px;
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 40px;
}
.masthead-foot h5 {
  font-family: "Nunito", sans-serif;
  font-weight: 800;
  font-size: 14px;
  color: var(--bg-warm);
  letter-spacing: 0.5px;
  margin: 0 0 12px;
  text-transform: uppercase;
}
.masthead-foot p {
  font-size: 14.5px;
  line-height: 1.6;
  margin: 0 0 8px;
  color: var(--sage-mist);
}
.masthead-foot a {
  color: var(--bg-warm);
  text-decoration: underline;
  text-decoration-color: rgba(245,229,184,0.4);
  font-weight: 700;
}
.masthead-foot a:hover { color: var(--paper); }
.masthead-foot ul {
  list-style: none;
  padding: 0;
  margin: 0;
  font-size: 14.5px;
  font-family: "Nunito", sans-serif;
}
.masthead-foot li { margin-bottom: 8px; }
.footer-baseline {
  border-top: 1px solid rgba(245,229,184,0.2);
  padding: 20px 32px;
  max-width: 1120px;
  margin: 0 auto;
  font-family: "Nunito", sans-serif;
  font-size: 13px;
  color: var(--sage-mist);
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 10px;
}

/* Contact form */
.contact-form {
  display: grid;
  gap: 16px;
  background: var(--paper);
  padding: 28px;
  border-radius: 18px;
  margin: 20px 0;
  box-shadow: 5px 5px 0 var(--sage-mist);
}
.contact-form label {
  font-family: "Nunito", sans-serif;
  font-weight: 700;
  font-size: 14px;
  color: var(--sage);
  margin-bottom: 3px;
  display: block;
}
.contact-form input, .contact-form textarea {
  border: 1.5px solid var(--line);
  background: var(--bg);
  padding: 12px 14px;
  font-family: "Verdana", sans-serif;
  font-size: 16px;
  color: var(--brown);
  width: 100%;
  border-radius: 10px;
}
.contact-form input:focus, .contact-form textarea:focus {
  outline: none;
  border-color: var(--rose);
  background: var(--paper);
}
.contact-form textarea { min-height: 140px; resize: vertical; }
.contact-form button {
  background: var(--rose);
  color: white;
  border: none;
  padding: 14px 26px;
  font-family: "Nunito", sans-serif;
  font-weight: 800;
  font-size: 15px;
  letter-spacing: 0.3px;
  cursor: pointer;
  border-radius: 30px;
  justify-self: start;
  box-shadow: 3px 3px 0 var(--sage);
  transition: transform .1s, box-shadow .1s;
}
.contact-form button:hover {
  transform: translate(-1px, -1px);
  box-shadow: 4px 4px 0 var(--sage);
}
.contact-form button:active {
  transform: translate(1px, 1px);
  box-shadow: 1px 1px 0 var(--sage);
}

/* Responsive */
@media (max-width: 900px) {
  .hero-inner { grid-template-columns: 1fr; gap: 30px; }
  h1.headline { font-size: 36px; }
  .standfirst { font-size: 17px; }
  h2 { font-size: 24px; }
  .toc ol { columns: 1; }
  .masthead-foot-inner { grid-template-columns: 1fr; gap: 24px; }
  .author-bio { grid-template-columns: 80px 1fr; gap: 18px; }
  .author-bio img { width: 80px; height: 80px; }
  .step-card { grid-template-columns: 36px 1fr; gap: 14px; padding: 18px 20px; }
  .step-num { width: 36px; height: 36px; font-size: 18px; }
}
@media (max-width: 560px) {
  h1.headline { font-size: 28px; }
  .brand-name { font-size: 22px; }
  h2 { font-size: 21px; }
  .masthead-inner { padding: 18px 20px; }
  .hero { padding: 44px 0 50px; }
  .hero-inner { padding: 0 20px; }
  .page { padding: 44px 20px 30px; }
  .breadcrumbs { padding: 20px 20px 0; }
  .pullquote { font-size: 18px; padding-left: 22px; }
}

/* Print */
@media print {
  body { background: white; color: black; }
  .masthead, .masthead-foot, .footer-baseline, .mainnav, .contact-form, .hero-doodle-1, .hero-doodle-2 { display: none; }
  a { color: black; text-decoration: underline; }
  .hero { background: white; border-bottom: 1px solid black; }
  h2::before { background: black; }
}

/* Focus */
a:focus-visible, button:focus-visible, summary:focus-visible, input:focus-visible, textarea:focus-visible {
  outline: 3px solid var(--rose);
  outline-offset: 2px;
}

/* Selection */
::selection {
  background: var(--rose-soft);
  color: var(--brown);
}
