/* ================================
   My Recipe Book Planner - styles.css
   Full file (replace entire file)
   ================================ */

/* --- Reset / Base --- */
* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
img { max-width: 100%; height: auto; display: block; }

:root{
  --bg: #f6f0e7;          /* warm tan */
  --bg-2: #efe6d8;        /* slightly deeper tan */
  --ink: #161616;
  --muted: #4a4a4a;
  --border: rgba(0,0,0,.10);
  --shadow: 0 18px 45px rgba(0,0,0,.18);
  --radius: 18px;

  --green: #2f6b55;
  --green-dark: #255443;

  --btn-radius: 999px;
  --max: 1120px;
}

body{
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
  background: var(--bg);
  color: var(--ink);
  line-height: 1.45;
}

a{
  color: inherit;
  text-decoration: none;
}

.container{
  width: min(var(--max), calc(100% - 48px));
  margin: 0 auto;
}

/* Accessibility */
.skip-link{
  position: absolute;
  left: -9999px;
  top: -9999px;
}
.skip-link:focus{
  left: 16px;
  top: 16px;
  background: #fff;
  padding: 10px 12px;
  border-radius: 10px;
  box-shadow: var(--shadow);
  z-index: 9999;
}

/* --- Header --- */
.site-header{
  background: var(--bg);
  border-bottom: 1px solid var(--border);
}

.header-inner{
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 18px 0;
}

.brand{
  display: inline-flex;
  align-items: center;
  min-width: 220px; /* prevents logo from getting crushed on desktop */
}

.brand-logo{
  height: 100px;      /* desktop logo size */
  width: auto;
  max-width: 520px;
}

.top-nav{
  display: flex;
  align-items: center;
  gap: 22px;
  flex-wrap: nowrap;
}

.top-nav a{
  font-weight: 600;
  color: rgba(0,0,0,.68);
}

.top-nav a:hover{
  color: rgba(0,0,0,.90);
}

.nav-cta{
  background: rgba(47,107,85,.14);
  border: 1px solid rgba(47,107,85,.25);
  color: var(--green-dark);
  padding: 10px 16px;
  border-radius: var(--btn-radius);
  font-weight: 800;
}

/* --- Hero --- */
.hero{
  padding: 42px 0 20px;
}

.hero-grid{
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 34px;
  align-items: start;
}

.hero-copy h1{
  margin: 0 0 12px;
  font-size: clamp(40px, 5.2vw, 64px);
  line-height: 1.02;
  letter-spacing: -0.02em;
}

.lead{
  margin: 0 0 18px;
  color: rgba(0,0,0,.70);
  font-size: 18px;
  max-width: 52ch;
}

.hero-actions{
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
  margin: 18px 0 10px;
}

.btn{
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 14px 18px;
  border-radius: var(--btn-radius);
  font-weight: 900;
  border: 1px solid transparent;
  cursor: pointer;
  line-height: 1;
  white-space: nowrap;
}

.btn-primary{
  background: var(--green);
  color: #fff;
  border-color: rgba(0,0,0,.08);
  box-shadow: 0 10px 22px rgba(47,107,85,.22);
}

.btn-primary:hover{ background: var(--green-dark); }

.btn-secondary{
  background: rgba(0,0,0,.03);
  border-color: rgba(0,0,0,.14);
  color: rgba(0,0,0,.82);
}

.micro{
  margin: 6px 0 0;
  color: rgba(0,0,0,.55);
  font-weight: 600;
}

/* Hero art wrapper */
.hero-art{
  display: flex;
  justify-content: flex-end; /* desktop: right aligned */
  align-items: flex-start;
}

/* HERO GRAPHIC (phones) */
.hero-image{
  width: 85%;
  max-width: 1500px;
  height: auto;

  /* ensure no “box” */
  background: none !important;
  border: none !important;
  box-shadow: none !important;
  border-radius: 0 !important;

  /* keep it from drifting too far right */
  margin-right: 0;
}

/* --- Sections --- */
.section{
  padding: 52px 0;
}

.section.alt{
  background: var(--bg-2);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.section h2{
  margin: 0 0 10px;
  font-size: clamp(28px, 3.1vw, 38px);
  letter-spacing: -0.01em;
}

.section-text{
  margin: 0 0 28px;
  color: rgba(0,0,0,.68);
  max-width: 70ch;
  font-size: 18px;
}

/* --- Cards / Feature Grid --- */
.cards{
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}

.card{
  background: rgba(255,255,255,.55);
  border: 1px solid rgba(0,0,0,.09);
  border-radius: var(--radius);
  padding: 18px 18px 16px;
  box-shadow: 0 10px 22px rgba(0,0,0,.08);
}

.card img{
  width: 100%;
  height: auto;
  border-radius: 14px;
  background: transparent;
  border: 0;
  box-shadow: none;
  margin-bottom: 10px;
}

.card h3{
  margin: 6px 0 6px;
  font-size: 20px;
  letter-spacing: -0.01em;
}

.card p{
  margin: 0;
  color: rgba(0,0,0,.70);
}

/* --- Footer --- */
.footer{
  border-top: 1px solid var(--border);
  padding: 24px 0;
  background: var(--bg);
}

.footer-inner{
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  color: rgba(0,0,0,.62);
  font-weight: 600;
  flex-wrap: wrap;
}

.footer-links{
  display: flex;
  gap: 18px;
  align-items: center;
  justify-content: flex-end;
}

.footer-links a{
  color: rgba(0,0,0,.62);
}
.footer-links a:hover{
  color: rgba(0,0,0,.88);
}

/* --- Blog / Page Layout Helpers (safe defaults) --- */
.page{
  padding: 38px 0 56px;
}

.page h1{
  margin: 0 0 12px;
  font-size: clamp(34px, 4.2vw, 52px);
  line-height: 1.08;
  letter-spacing: -0.02em;
}

.page p{
  color: rgba(0,0,0,.72);
}

/* ================================
   Responsive
   ================================ */

/* Tablet */
@media (max-width: 980px){
  .brand-logo{ height: 90px; }

  .hero-grid{
    grid-template-columns: 1fr;
    gap: 22px;
  }

  .hero-art{
    justify-content: center; /* centered when stacked */
  }

  .hero-image{
    width: 95%;
    max-width: 920px;
  }

  .cards{
    grid-template-columns: repeat(2, 1fr);
  }
}

/* Mobile (this is the main fix for your screenshot) */
@media (max-width: 720px){
  .container{
    width: min(var(--max), calc(100% - 32px));
  }

  /* Header becomes stacked + centered */
  .header-inner{
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 12px;
    padding: 14px 0 12px;
    text-align: center;
  }

  .brand{
    min-width: 0;
    justify-content: center;
  }

  .brand-logo{
    height: 70px;  /* good size on iPhone */
    max-width: 92vw;
  }

  .top-nav{
    width: 100%;
    justify-content: center;
    flex-wrap: wrap;
    gap: 14px 16px;
  }

  .nav-cta{
    padding: 12px 18px;
  }

  /* Hero */
  .hero{
    padding-top: 22px;
  }

  .lead{
    font-size: 17px;
  }

  .btn{
    width: 100%;
    justify-content: center;
    padding: 16px 18px;
  }

  .hero-actions{
    gap: 10px;
  }

  .hero-image{
    width: 100%;
    max-width: 520px;
    margin: 10px auto 0;
  }

  .cards{
    grid-template-columns: 1fr;
  }

  .footer-inner{
    flex-direction: column;
    align-items: center;
    text-align: center;
  }
}

/* Small phones */
@media (max-width: 390px){
  .brand-logo{ height: 64px; }
  .hero-copy h1{ font-size: 40px; }
}