/*
Theme Name: Macomb Bookkeeping
Theme URI: https://macombbookkeeping.com/
Author: Macomb Bookkeeping, LLC
Description: One-page theme for Macomb Bookkeeping. Edit phone, email, price, and hours in Appearance > Customize > Business Details.
Version: 1.1.0
Requires at least: 6.0
Requires PHP: 7.4
License: GPL-2.0-or-later
Text Domain: macomb-bookkeeping
*/

/* Layout: ledger-paper sections on white, framed by deep forest-green bands (hero, pricing, footer) taken from the original site. */
:root {
  --forest: #173b2c;        /* original hero/footer green */
  --forest-deep: #0f2a1f;
  --green: #1d7a32;         /* original button/logo green */
  --green-bright: #2fa64a;
  --gold: #f2c230;          /* the price highlight from the original price card */
  --paper: #ffffff;
  --paper-2: #f3f7f3;
  --ink: #14211a;
  --ink-soft: #4a5a50;
  --rule: #dbe5dd;
  --on-forest: #f2f7f3;
  --on-forest-soft: #b9cfc0;
  --card: #ffffff;
  --shadow: 0 1px 2px rgb(15 42 31 / .06), 0 8px 24px rgb(15 42 31 / .08);

  --f-display: "Bricolage Grotesque", "Segoe UI", system-ui, sans-serif;
  --f-body: "Figtree", "Segoe UI", system-ui, sans-serif;
  --f-mono: "IBM Plex Mono", ui-monospace, "SFMono-Regular", Menlo, monospace;

  --wrap: 1160px;
  --radius: 14px;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --forest: #0e2419; --forest-deep: #0a1b13;
    --green: #3fae58; --green-bright: #5cc874; --gold: #f5cc4e;
    --paper: #0f1713; --paper-2: #142019; --ink: #e6efe8; --ink-soft: #a3b6a9;
    --rule: #26362c; --on-forest: #eaf3ec; --on-forest-soft: #a8c2b0;
    --card: #17231c; --shadow: 0 1px 2px rgb(0 0 0 / .3), 0 8px 24px rgb(0 0 0 / .35);
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --forest: #0e2419; --forest-deep: #0a1b13;
  --green: #3fae58; --green-bright: #5cc874; --gold: #f5cc4e;
  --paper: #0f1713; --paper-2: #142019; --ink: #e6efe8; --ink-soft: #a3b6a9;
  --rule: #26362c; --on-forest: #eaf3ec; --on-forest-soft: #a8c2b0;
  --card: #17231c; --shadow: 0 1px 2px rgb(0 0 0 / .3), 0 8px 24px rgb(0 0 0 / .35);
  color-scheme: dark;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } *, *::before, *::after { animation: none !important; transition: none !important; } }
[hidden] { display: none !important; }
img { max-width: 100%; }
body {
  margin: 0;
  background: var(--paper); color: var(--ink);
  font-family: var(--f-body); font-size: 1.0625rem; line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
body::before { content: ""; position: fixed; inset: 0 0 auto; height: env(safe-area-inset-top, 0px); z-index: 10; background: var(--paper); }
h1, h2, h3 { font-family: var(--f-display); line-height: 1.1; text-wrap: balance; margin: 0; letter-spacing: -0.015em; }
p { margin: 0; }
a { color: inherit; }
:focus-visible { outline: 3px solid var(--green-bright); outline-offset: 3px; border-radius: 6px; }

.wrap {
  max-width: var(--wrap); margin-inline: auto;
  padding-left: max(16px, env(safe-area-inset-left, 0px));
  padding-right: max(16px, env(safe-area-inset-right, 0px));
}
@media (min-width: 720px) { .wrap { padding-left: max(32px, env(safe-area-inset-left, 0px)); padding-right: max(32px, env(safe-area-inset-right, 0px)); } }

.eyebrow {
  font-family: var(--f-mono); font-size: .78rem; font-weight: 500;
  letter-spacing: .12em; text-transform: uppercase; color: var(--green);
}
.btn {
  display: inline-flex; align-items: center; gap: .5rem;
  font: 600 1rem/1 var(--f-body); text-decoration: none; cursor: pointer;
  padding: .95rem 1.4rem; border-radius: 999px; border: 2px solid transparent;
  transition: transform .15s ease, background-color .15s ease;
}
.btn:hover { transform: translateY(-1px); }
.btn-primary { background: var(--green-bright); color: #08200f; }
.btn-primary:hover { background: var(--gold); }
.btn-ghost { border-color: color-mix(in srgb, var(--on-forest) 40%, transparent); color: var(--on-forest); background: transparent; }
.btn-ghost:hover { border-color: var(--on-forest); }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: env(safe-area-inset-top, 0px); z-index: 20;
  background: color-mix(in srgb, var(--paper) 92%, transparent);
  backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--rule);
}
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding-block: .8rem; }
.brand { display: flex; align-items: center; gap: .6rem; text-decoration: none; color: var(--ink); }
.brand svg { width: 46px; height: 40px; flex: none; }
.brand-name { font-family: var(--f-display); font-weight: 700; font-size: 1.15rem; line-height: 1.05; }
.brand-name small { display: block; font-family: var(--f-mono); font-weight: 400; font-size: .66rem; letter-spacing: .14em; text-transform: uppercase; color: var(--ink-soft); }
.nav { display: flex; align-items: center; gap: 1.6rem; }
.nav a { text-decoration: none; font-weight: 500; font-size: .97rem; color: var(--ink-soft); }
.nav a:hover { color: var(--green); }
.nav .btn { color: #08200f; padding: .65rem 1.1rem; font-size: .95rem; white-space: nowrap; }
@media (max-width: 480px) { .nav .btn { padding: .6rem .85rem; font-size: .85rem; } .brand-name { font-size: 1rem; } .brand svg { width: 38px; height: 34px; } }
@media (max-width: 860px) { .nav a:not(.btn) { display: none; } }

/* ---------- Hero ---------- */
.hero { background: var(--forest); color: var(--on-forest); position: relative; overflow: hidden; }
.hero::after {
  /* faint ledger rules */
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background-image: repeating-linear-gradient(to bottom, transparent 0 35px, color-mix(in srgb, var(--on-forest) 6%, transparent) 35px 36px);
}
.hero .wrap { position: relative; z-index: 1; display: grid; grid-template-columns: 1.1fr .9fr; gap: clamp(2rem, 5vw, 4.5rem); align-items: center; padding-block: clamp(3rem, 7vw, 5.5rem); }
@media (max-width: 900px) { .hero .wrap { grid-template-columns: 1fr; } }
.hero .eyebrow { color: var(--gold); }
.hero h1 { font-size: clamp(2.5rem, 6vw, 4.4rem); font-weight: 800; margin-top: 1rem; }
.hero h1 em { font-style: normal; color: var(--green-bright); }
.hero-lede { margin-top: 1.25rem; font-size: 1.18rem; color: var(--on-forest-soft); max-width: 34rem; }
.hero-cta { margin-top: 2rem; display: flex; flex-wrap: wrap; gap: .8rem; }
.hero-facts { margin-top: 2.2rem; display: flex; flex-wrap: wrap; gap: .5rem 1.5rem; font-size: .93rem; color: var(--on-forest-soft); list-style: none; padding: 0; }
.hero-facts li { display: flex; align-items: center; gap: .45rem; }
.hero-facts svg { width: 18px; height: 18px; color: var(--green-bright); flex: none; }

/* Reconciliation card */
.recon {
  min-width: 0; background: var(--card); color: var(--ink); border-radius: var(--radius);
  box-shadow: 0 30px 60px rgb(0 0 0 / .3); overflow: hidden;
  transform: rotate(1.2deg);
}
.recon-head { display: flex; justify-content: space-between; align-items: baseline; gap: 1rem; padding: 1.1rem 1.4rem; border-bottom: 1px solid var(--rule); }
.recon-title { font-family: var(--f-display); font-size: 1.05rem; font-weight: 700; }
.recon-head span { font-family: var(--f-mono); font-size: .78rem; color: var(--ink-soft); white-space: nowrap; }
.recon table { width: 100%; border-collapse: collapse; font-size: .95rem; font-variant-numeric: tabular-nums; }
.recon td { padding: .62rem 1.4rem; border-bottom: 1px dashed var(--rule); }
.recon td:last-child { text-align: right; font-family: var(--f-mono); white-space: nowrap; }
.recon tr.sub td { color: var(--ink-soft); padding-left: 2.2rem; font-size: .9rem; }
.recon tr.total td { font-weight: 700; border-bottom: 2px solid var(--ink); }
.recon-foot { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: 1rem 1.4rem; background: var(--paper-2); }
.recon-foot b { font-family: var(--f-mono); font-size: 1.05rem; }
.stamp {
  display: inline-flex; align-items: center; gap: .4rem; font-family: var(--f-mono); font-size: .78rem; font-weight: 500;
  letter-spacing: .1em; text-transform: uppercase; color: var(--green);
  border: 2px solid var(--green); border-radius: 6px; padding: .3rem .6rem; transform: rotate(-4deg);
  animation: stamp .5s .6s cubic-bezier(.2,1.6,.4,1) both;
}
@keyframes stamp { from { transform: rotate(-4deg) scale(1.6); opacity: .2; } to { transform: rotate(-4deg) scale(1); opacity: 1; } }
.recon-note { font-size: .8rem; color: var(--on-forest-soft); margin-top: .8rem; text-align: center; }

/* ---------- Credentials ---------- */
.creds { border-bottom: 1px solid var(--rule); background: var(--paper); }
.creds .wrap { padding-block: 2.2rem; display: grid; grid-template-columns: auto 1fr; gap: 1rem 2.5rem; align-items: center; }
@media (max-width: 760px) { .creds .wrap { grid-template-columns: 1fr; } }
.creds-list { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1rem; list-style: none; padding: 0; margin: 0; }
@media (max-width: 760px) { .creds-list { grid-template-columns: 1fr; } }
.creds-list li { display: flex; gap: .8rem; align-items: flex-start; min-width: 0; }
.creds-list svg { width: 34px; height: 34px; flex: none; color: var(--green); }
.creds-list strong { display: block; font-size: 1rem; }
.creds-list span { font-size: .88rem; color: var(--ink-soft); }

/* ---------- Sections ---------- */
section.block .wrap { padding-block: clamp(3.5rem, 8vw, 6rem); }
.section-head { max-width: 44rem; margin-bottom: 2.75rem; }
.section-head h2 { font-size: clamp(2rem, 4vw, 2.9rem); font-weight: 800; margin-top: .6rem; }
.section-head p { margin-top: 1rem; color: var(--ink-soft); font-size: 1.1rem; }

/* Services */
.services-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 330px), 1fr)); border-top: 1px solid var(--rule); border-left: 1px solid var(--rule); }
.svc { min-width: 0; padding: 1.75rem 1.6rem 1.9rem; border-right: 1px solid var(--rule); border-bottom: 1px solid var(--rule); display: grid; grid-template-rows: auto auto 1fr; gap: .55rem; transition: background-color .2s ease; }
.svc:hover { background: var(--paper-2); }
.svc-code { font-family: var(--f-mono); font-size: .75rem; color: var(--ink-soft); letter-spacing: .06em; }
.svc h3 { font-size: 1.28rem; font-weight: 700; }
.svc p { color: var(--ink-soft); font-size: .98rem; }
.svc ul { margin: .5rem 0 0; padding: 0; list-style: none; display: grid; gap: .3rem; font-size: .93rem; color: var(--ink-soft); }
.svc li { display: flex; gap: .5rem; }
.svc li::before { content: "✓"; color: var(--green); font-weight: 700; flex: none; }
.svc.featured { background: var(--paper-2); }
.svc.featured h3 { color: var(--green); }

/* Pricing */
.pricing { background: var(--forest-deep); color: var(--on-forest); }
.pricing .eyebrow { color: var(--gold); }
.pricing .section-head p { color: var(--on-forest-soft); }
.price-grid { display: grid; grid-template-columns: 1.15fr .85fr; gap: 2rem; align-items: stretch; }
@media (max-width: 880px) { .price-grid { grid-template-columns: 1fr; } }
.invoice { background: var(--card); color: var(--ink); border-radius: var(--radius); overflow: hidden; min-width: 0; }
.invoice-top { display: flex; justify-content: space-between; align-items: center; gap: 1rem; padding: 1.4rem 1.6rem; border-bottom: 1px solid var(--rule); flex-wrap: wrap; }
.invoice-top h3 { font-size: 1.3rem; }
.invoice-top span { font-family: var(--f-mono); font-size: .8rem; color: var(--ink-soft); }
.invoice ol { list-style: none; margin: 0; padding: .4rem 1.6rem; }
.invoice li { display: grid; grid-template-columns: 2.2rem 1fr auto; gap: .8rem; align-items: center; padding: 1rem 0; border-bottom: 1px dashed var(--rule); }
.invoice li:last-child { border-bottom: 0; }
.invoice li svg { width: 26px; height: 26px; color: var(--green); }
.invoice li b { font-weight: 600; }
.invoice li small { display: block; color: var(--ink-soft); font-size: .88rem; }
.invoice li .inc { font-family: var(--f-mono); font-size: .75rem; letter-spacing: .08em; text-transform: uppercase; color: var(--green); }
.invoice-total { display: flex; align-items: baseline; justify-content: space-between; gap: 1rem; flex-wrap: wrap; padding: 1.4rem 1.6rem; background: var(--forest); color: var(--on-forest); }
.invoice-total span { font-weight: 600; }
.invoice-total .amt { font-family: var(--f-display); font-weight: 800; font-size: clamp(2.6rem, 6vw, 3.4rem); color: var(--gold); line-height: 1; font-variant-numeric: tabular-nums; }
.invoice-total .amt small { font-size: 1rem; font-weight: 600; color: var(--on-forest-soft); }
.price-side { display: grid; gap: 1rem; align-content: start; }
.side-card { border: 1px solid color-mix(in srgb, var(--on-forest) 18%, transparent); border-radius: var(--radius); padding: 1.4rem 1.5rem; }
.side-card h3 { font-size: 1.15rem; margin-bottom: .5rem; }
.side-card p { color: var(--on-forest-soft); font-size: .98rem; }
.side-card ul { margin: .6rem 0 0; padding: 0; list-style: none; display: grid; gap: .35rem; color: var(--on-forest-soft); font-size: .96rem; }
.side-card li::before { content: "+ "; color: var(--green-bright); font-family: var(--f-mono); }

/* About */
.about-grid { display: grid; grid-template-columns: .8fr 1.2fr; gap: clamp(2rem, 5vw, 4rem); align-items: start; }
@media (max-width: 860px) { .about-grid { grid-template-columns: 1fr; } }
.profile { background: var(--paper-2); border-radius: var(--radius); padding: 2rem; display: grid; gap: 1.2rem; min-width: 0; }
.monogram { width: 84px; height: 84px; border-radius: 50%; background: var(--forest); color: var(--gold); display: grid; place-items: center; font-family: var(--f-display); font-weight: 800; font-size: 2rem; }
.profile h3 { font-size: 1.5rem; }
.profile .role { color: var(--ink-soft); font-size: .95rem; margin-top: .2rem; }
.profile dl { margin: 0; display: grid; gap: .9rem; }
.profile dt { font-family: var(--f-mono); font-size: .72rem; letter-spacing: .1em; text-transform: uppercase; color: var(--ink-soft); }
.profile dd { margin: .15rem 0 0; font-weight: 500; }
.about-copy { display: grid; gap: 1.1rem; max-width: 40rem; font-size: 1.1rem; }
.about-h2 { font-size: clamp(2rem, 4vw, 2.9rem); font-weight: 800; }
.about-copy .lead { font-family: var(--f-display); font-size: clamp(1.4rem, 2.6vw, 1.75rem); font-weight: 500; line-height: 1.35; color: var(--ink); }
.about-copy p { color: var(--ink-soft); }

/* Contact */
.contact { background: var(--paper-2); }
.contact-grid { display: grid; grid-template-columns: 1.1fr .9fr; gap: 2rem; align-items: start; }
@media (max-width: 860px) { .contact-grid { grid-template-columns: 1fr; } }
.contact-cards { display: grid; gap: 1rem; }
.c-card { background: var(--card); border: 1px solid var(--rule); border-radius: var(--radius); padding: 1.3rem 1.4rem; display: grid; grid-template-columns: 44px 1fr auto; gap: 1rem; align-items: center; min-width: 0; }
.c-card .ic { width: 44px; height: 44px; border-radius: 12px; background: color-mix(in srgb, var(--green) 14%, transparent); color: var(--green); display: grid; place-items: center; }
.c-card .ic svg { width: 22px; height: 22px; }
.c-card .label { font-family: var(--f-mono); font-size: .72rem; letter-spacing: .1em; text-transform: uppercase; color: var(--ink-soft); }
.c-card .val { font-weight: 600; font-size: 1.12rem; user-select: all; overflow-wrap: anywhere; }
.c-card .val a { text-decoration: none; }
.copy { font: 600 .85rem var(--f-body); background: transparent; color: var(--green); border: 1.5px solid var(--rule); border-radius: 999px; padding: .45rem .85rem; cursor: pointer; white-space: nowrap; }
.copy:hover { border-color: var(--green); }
@media (max-width: 440px) { .c-card { grid-template-columns: 44px 1fr; } .copy { grid-column: 2; justify-self: start; } }
.hours { background: var(--forest); color: var(--on-forest); border-radius: var(--radius); padding: 1.6rem; }
.hours h3 { font-size: 1.3rem; margin-bottom: 1rem; }
.hours table { width: 100%; border-collapse: collapse; font-variant-numeric: tabular-nums; }
.hours td { padding: .55rem 0; border-bottom: 1px solid color-mix(in srgb, var(--on-forest) 14%, transparent); }
.hours td:last-child { text-align: right; color: var(--on-forest-soft); }
.hours tr.closed td:last-child { color: var(--gold); }
.hours p { margin-top: 1rem; font-size: .92rem; color: var(--on-forest-soft); }
.area { margin-top: 1rem; display: flex; flex-wrap: wrap; gap: .4rem; }
.area span { font-size: .82rem; padding: .3rem .65rem; border-radius: 999px; background: color-mix(in srgb, var(--on-forest) 10%, transparent); }

/* Footer */
.site-footer { background: var(--forest-deep); color: var(--on-forest-soft); font-size: .92rem; }
.site-footer .wrap { padding-block: 2.5rem; display: flex; flex-wrap: wrap; justify-content: space-between; gap: 1.5rem; align-items: center; }
.site-footer .brand { color: var(--on-forest); }
.site-footer .brand-name small { color: var(--on-forest-soft); }
.foot-links { display: flex; flex-wrap: wrap; gap: 1.2rem; }
.foot-links a { text-decoration: none; }
.foot-links a:hover { color: var(--on-forest); }
.foot-nap { font-style: normal; display: grid; gap: .15rem; }
.foot-nap a { text-decoration: none; color: var(--on-forest); }

/* FAQ */
.faq-list { display: grid; gap: .75rem; max-width: 52rem; }
.faq-list details { border: 1px solid var(--rule); border-radius: var(--radius); background: var(--card); }
.faq-list summary { cursor: pointer; list-style: none; display: flex; justify-content: space-between; align-items: center; gap: 1rem; padding: 1.15rem 1.4rem; font-family: var(--f-display); font-weight: 700; font-size: 1.12rem; }
.faq-list summary::-webkit-details-marker { display: none; }
.faq-list summary::after { content: "+"; font-family: var(--f-mono); font-size: 1.3rem; color: var(--green); flex: none; transition: transform .2s ease; }
.faq-list details[open] summary::after { transform: rotate(45deg); }
.faq-list details p { padding: 0 1.4rem 1.3rem; color: var(--ink-soft); max-width: 46rem; }

.toast { position: fixed; left: 50%; bottom: calc(1.5rem + env(safe-area-inset-bottom, 0px)); transform: translateX(-50%); background: var(--ink); color: var(--paper); padding: .7rem 1.1rem; border-radius: 999px; font-weight: 600; font-size: .92rem; z-index: 30; }

/* ---------- WordPress ---------- */
.admin-bar .site-header { top: calc(32px + env(safe-area-inset-top, 0px)); }
@media (max-width: 782px) { .admin-bar .site-header { top: calc(46px + env(safe-area-inset-top, 0px)); } }
@media (max-width: 600px) { .admin-bar .site-header { top: env(safe-area-inset-top, 0px); } }
.screen-reader-text { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(1px, 1px, 1px, 1px); white-space: nowrap; }
.entry-wrap .wrap { padding-block: clamp(3rem, 7vw, 5rem); }
.entry { max-width: 46rem; }
.entry + .entry { margin-top: 3rem; padding-top: 3rem; border-top: 1px solid var(--rule); }
.entry-title { font-size: clamp(2rem, 4vw, 2.8rem); font-weight: 800; }
.entry-title a { text-decoration: none; }
.entry-meta { margin-top: .5rem; font-family: var(--f-mono); font-size: .8rem; color: var(--ink-soft); }
.entry-content { margin-top: 1.5rem; display: grid; gap: 1rem; }
.entry-content h2 { font-size: 1.6rem; margin-top: 1rem; }
.entry-content h3 { font-size: 1.25rem; margin-top: .5rem; }
.entry-content a { color: var(--green); }
.entry-content ul, .entry-content ol { margin: 0; padding-left: 1.3rem; }
.entry-content img { height: auto; border-radius: 8px; }
.nav-links { margin-top: 2.5rem; display: flex; gap: 1rem; }
