/* ============================================================
   DAVID MARTIN DI MAGGIO — Author Site
   Design system extracted directly from the source PowerPoint.
   Single continuous page, consistent background throughout
   (no gradient — this design intentionally differs from the
   author's other site, which fades the background per section).
   ============================================================ */

:root{
  --charcoal: #4e4e4e;       /* header background */
  --charcoal-deep: #3a3a3a;
  --page-bg: #f0f0f0;        /* consistent page background, all sections */
  --ink: #2b2b2b;            /* primary text on light background */
  --ink-soft: #55575b;       /* body copy gray, sampled from source */
  --line: rgba(0,0,0,.12);
  --gold-light: #ebcd99;     /* button gradient - sampled directly from deck */
  --gold-dark: #bca287;
  --white: #ffffff;

  --display: Calibri, 'Helvetica Neue', Helvetica, Arial, sans-serif;
  --serif: 'Times New Roman', Times, serif;
  --quote-font: Palatino, 'Palatino Linotype', 'Book Antiqua', Georgia, serif;

  --maxw: 1240px;
}

*, *::before, *::after{ box-sizing: border-box; }

html{ scroll-behavior: smooth; }

#home, #book, #author, #news, #contact{ scroll-margin-top: 90px; }

body{
  margin:0;
  font-family: var(--display);
  color: var(--ink-soft);
  background: var(--page-bg) url('v2/bg-texture.jpg') top center / cover no-repeat fixed;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

img{ max-width:100%; display:block; }
a{ color:inherit; text-decoration:none; }
h1,h2,h3{ font-family: var(--display); font-weight:700; margin:0 0 .5em; }
p{ margin:0 0 1em; }

.wrap{ max-width: var(--maxw); margin:0 auto; padding: 0 40px; }

.skip-link{
  position:absolute; left:-9999px; top:0; z-index:1000;
  background:#000; color:#fff; padding:14px 24px;
  font-family: var(--display); font-weight:600; font-size:14px;
  border-radius:0 0 6px 0;
}
.skip-link:focus{ left:0; }

/* ---------- persistent header ---------- */
.site-header.no-transition{ transition:none !important; }
.site-header{
  position: fixed; top:33px; left:0; right:0; z-index:200;
  display:flex; align-items:center; justify-content:space-between;
  padding: 14px 40px;
  background: var(--charcoal) url('v2/header-texture.jpg') center / cover no-repeat;
  min-height: 70px;
  opacity:0; pointer-events:none; transform:translateY(-100%);
  transition:opacity .25s ease, transform .25s ease;
}
.site-header.solid{
  opacity:1; pointer-events:auto; transform:translateY(0);
}
.hero-bar{
  position:relative; width:100vw; left:50%; margin-left:-50vw;
  display:flex; align-items:center; justify-content:space-between;
  padding: 14px 40px;
  background: var(--charcoal) url('v2/header-texture.jpg') center / cover no-repeat;
  min-height: 70px;
  box-sizing:border-box;
}
.hero-bar-nav{ display:flex; gap:36px; }
.hero-bar-nav a{
  color:#fff; font-family: var(--display); font-size:19px; letter-spacing:.02em;
  text-transform:uppercase; white-space:nowrap;
  transition: opacity .2s ease;
}
.hero-bar-nav a:focus-visible, .main-nav a:focus-visible{
  outline: 2px solid #fff; outline-offset:3px;
}
.hero-bar-nav a:hover{ opacity:.75; }
.brand{
  display:flex; flex-direction:column; align-items:center;
  color:#fff; font-family: var(--display); text-align:center;
}
.brand small{
  display:block; font-size:14.95px; font-weight:700; letter-spacing:.4em;
  text-transform:uppercase;
  margin-bottom:0;
}
.brand span{
  display:block; font-size:44px; font-weight:700; letter-spacing:.01em;
  line-height:1.05;
  text-transform:uppercase;
  margin-top:-9px;
}
.main-nav{ display:flex; gap:36px; }
.main-nav a{
  color:#fff; font-family: var(--display); font-size:19px; letter-spacing:.02em;
  text-transform:uppercase;
  white-space:nowrap;
  transition: opacity .2s ease;
}
.main-nav a:hover{ opacity:.75; }

.nav-toggle{
  display:none; flex-direction:column; justify-content:center; gap:5px;
  width:34px; height:34px; background:none; border:none; cursor:pointer; padding:0;
}
.nav-toggle span{ display:block; width:100%; height:2px; background:#fff; }

/* ---------- buttons ---------- */
.btn-row{ display:flex; gap:18px; flex-wrap:wrap; margin-top:8px; }
.btn{
  display:inline-block; padding:15px 34px;
  font-family: var(--display); font-size:14px; letter-spacing:.03em;
  text-transform:uppercase;
  border-radius:2px; text-align:center;
  transition: transform .15s ease, box-shadow .15s ease;
}
.btn:focus-visible{
  outline: 3px solid #1a1a1a; outline-offset:2px;
}
.btn-primary, .btn-secondary{
  background: linear-gradient(180deg, var(--gold-light) 0%, var(--gold-dark) 100%);
  color:#3c2d1e;
}
.btn:hover{ transform: translateY(-1px); box-shadow: 0 6px 16px rgba(0,0,0,.18); }

/* ---------- hero ---------- */
.hero{ padding: 33px 0 20px; overflow:visible; position:relative; }
.hero-pos-wrap{
  max-width: var(--maxw); margin:0 auto; padding:0 40px;
  position:relative;
}
.hero-grid{
  display:grid; grid-template-columns: 1.1fr .9fr; gap:60px; align-items:center;
  margin-top:90px;
}
.hero-cover{
  position:absolute; top:74px; right:87px; width:34.47%;
  z-index:60;
}
.hero-cover-spacer{
  width:93%;
  padding-bottom:128.38%; /* padding % is relative to parent width, adjusted for the 93% element width */
  visibility:hidden;
}
.tagline{
  font-family: var(--serif); font-style:italic; font-weight:548.35;
  font-size: clamp(15px, 2.99vw, 39.47px); line-height:1.35; color: #202020;
  text-align:right; margin:0 0 58px; margin-left:-25px;
  transform: translateX(15%) translateY(-80px);
}
.hero-intro{ font-size: clamp(15px, 1.15vw, 18px); line-height:1.75; max-width:567px; margin-right:-7px; text-align:left; font-family: var(--display); margin-top:-72px; }
.hero .btn-row{ justify-content:flex-start; margin-top:39px; gap:39.375px; }
.hero-cover img{
  width:100%; height:auto; border-radius:2px;
}

/* ---------- generic section ---------- */
.section{ padding: 70px 0; border-top:1px solid var(--line); }
#book{ position:relative; overflow:visible; }
.two-col{ position:relative; }
#author .body-copy{ margin-left:-120px; }
.book-cover-spacer2{
  width:93%;
  padding-bottom:128.38%;
  visibility:hidden;
}
.book-cover-rise{
  position:absolute; top:-54px; right:87px; width:34.47%;
  z-index:10;
}
.book-cover-rise.raised{ z-index:250; }
.book-cover-rise img{ width:100%; height:auto; display:block; }
#book{ padding-bottom: 140px; }
#news{ padding-bottom: 318px; }
.section-title{
  font-size:30px; color: var(--ink); text-transform:uppercase; letter-spacing:.04em;
  margin-bottom:28px;
}
.body-copy p{ font-size:17px; line-height:1.8; font-family: var(--display); }
#author .body-copy p:first-child{ margin-top:-9px; }
.lede{ font-size:17px; line-height:1.75; max-width:620px; font-family: var(--display); }
.human-authored-row{
  display:flex; align-items:flex-start; gap:14px;
  margin-top:50px;
}
.human-authored-badge{ width:49.3px; height:auto; flex-shrink:0; }
.human-authored-text{
  font-size:16px; line-height:1.5; font-family: var(--display); color: var(--ink-soft);
  margin:0;
}
@media (max-width:720px){
  .human-authored-row{ margin-top:40px; }
}

.two-col{
  display:grid; grid-template-columns: 1.3fr 1fr; gap:60px; align-items:start;
}
.two-col.reverse{ grid-template-columns: 1fr 1.3fr; }
.two-col.reverse .col-media{ order:-1; }
.two-col > *{ min-width:0; }

.col-media img{ width:100%; height:auto; border-radius:2px; box-shadow: 10px 16px 32px -8px rgba(0,0,0,.3); }
.col-media img[data-edit-id="book-cover-img"]{ box-shadow:none; }

.author-media{ max-width:340px; }
.photo-frame img{ width:100%; height:auto; }
.frame-label{
  margin-top:14px; font-size:12px; letter-spacing:.1em; text-transform:uppercase;
  font-family: var(--display); color: var(--ink-soft);
}

/* ---------- news + events placeholder ---------- */
.news-placeholder-grid{
  display:grid; grid-template-columns: repeat(3, 1fr); gap:28px; margin-top:36px;
}
.news-card{
  background: rgba(255,255,255,.55);
  border: 1px solid var(--line);
  border-radius:4px; padding:28px 26px;
}
.news-card-tag{
  display:inline-block; font-family: var(--display); font-size:11px; font-weight:700;
  letter-spacing:.08em; text-transform:uppercase; color:#3c2d1e;
  background: linear-gradient(180deg, var(--gold-light), var(--gold-dark));
  padding:5px 12px; border-radius:20px; margin-bottom:14px;
}
.news-card h3{ font-size:19px; color: var(--ink); margin-bottom:8px; }
.news-card p{ font-size:15px; margin:0; }

/* ---------- contact ---------- */
.contact-form{ margin-top:30px; max-width:520px; }
.field{ margin-bottom:20px; }
.field label{
  display:block; font-family: var(--display); font-size:12px; font-weight:700;
  letter-spacing:.08em; text-transform:uppercase; color: var(--ink-soft); margin-bottom:8px;
}
.field input, .field textarea{
  width:100%; font-family: var(--display); font-size:15px; color: var(--ink);
  padding:13px 14px; border:1px solid rgba(0,0,0,.25); border-radius:2px;
  background: rgba(255,255,255,.5);
}
.field input::placeholder, .field textarea::placeholder{ color: rgba(0,0,0,.4); }
.field input:focus, .field textarea:focus{
  outline: 2px solid var(--gold-dark); outline-offset:2px; border-color: var(--gold-dark);
}
.contact-form .btn{ border:none; cursor:pointer; font-size:14px; }

.col-aside{ padding-top:76px; }
.eyebrow{
  font-family: var(--display); font-size:12px; font-weight:700; letter-spacing:.08em;
  text-transform:uppercase; color: var(--ink-soft); margin-bottom:6px;
}
.contact-email{ font-size:16px; color: var(--ink); margin-bottom:36px; margin-top:-1.5px; }
.social-row{ display:flex; gap:14px; }
.social-row img{ width:40px; height:40px; }
.social-row a{ transition: opacity .2s ease; }
.social-row a:hover{ opacity:.7; }

/* ---------- footer ---------- */
.site-footer{ padding:30px 0; border-top:1px solid var(--line); }
.footer-copy{ font-size:13px; color: var(--ink-soft); margin:0; text-align:center; }

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 980px){
  .hero-grid{ grid-template-columns:1fr; margin-top:0; }
  .tagline{ font-size:43.7px; text-align:left; transform:none; }
  .hero-intro{ text-align:left; margin-left:0; margin-right:0; max-width:100%; }
  .hero .btn-row{ justify-content:flex-start; }
  .hero-pos-wrap{ position:static; padding:0; }
  .hero-cover{ max-width:320px; margin:40px auto 0; position:static; }
  .hero-cover-spacer{ display:none; }

  .two-col, .two-col.reverse{ grid-template-columns:1fr; }
  .two-col.reverse .col-media{ order:0; }
  .author-media{ max-width:280px; }
  #author .body-copy{ margin-left:0; }

  .news-placeholder-grid{ grid-template-columns:1fr; }
  .col-aside{ padding-top:36px; }
}

@media (max-width: 720px){
  .wrap{ padding:0 22px; }
  .site-header{ padding:12px 22px; flex-wrap:wrap; opacity:1; pointer-events:auto; transform:translateY(0); position:relative; top:0; }
  .hero-bar{ display:none; }
  .hero{ padding-top:40px; }
  .book-cover-rise{ position:static; max-width:280px; margin:0 auto 30px; width:100%; z-index:auto; }
  .book-cover-spacer2{ display:none; }
  .brand span{ font-size:21px; }

  .nav-toggle{ display:flex; }
  .main-nav{
    display:none; flex-direction:column; gap:16px;
    width:100%; margin-top:14px; padding-top:14px;
    border-top:1px solid rgba(255,255,255,.2);
  }
  .main-nav.open{ display:flex; }

  .tagline{ font-size:34.5px; }
  .btn-row{ flex-direction:column; }
  .btn{ text-align:center; }
}
