/* ============================================
   MacKnowItAll.com — Premium, clean, white
   ============================================ */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&display=swap');

:root {
  --color-bg: #ffffff;
  --color-text: #1d1d1f;
  --color-text-muted: #6e6e73;
  --color-btn: #1d1d1f;
  --color-btn-hover: #000000;
  --color-border: #e5e5e5;
  --color-footer-bg: #1d1d1f;
  --font-body: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --font-heading: -apple-system, BlinkMacSystemFont, 'SF Pro Display', 'SF Pro Text', 'Helvetica Neue', sans-serif;
  --transition: 0.25s ease;
}

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

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.7;
  color: var(--color-text-muted);
  background: var(--color-bg);
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: var(--color-text);
  text-decoration: none;
}

a:hover {
  color: var(--color-btn-hover);
}

/* --- Sticky Navigation --- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: #ffffff;
  padding-top: 20px;
}

@media (min-width: 1px) {
  .site-header {
    padding-bottom: 16px;
  }
  .page-home .site-header {
    padding-bottom: 0;
  }
}

.site-header .inner {
  max-width: 980px;
  margin: 0 auto;
  padding: 0 28px;
  min-height: 80px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

/* Home: full-width nav with more space; center nav with middle of logo */
.page-home .site-header .inner {
  max-width: none;
  padding: 0 48px;
  min-height: 240px;
  align-items: center;
}
.page-home .site-header nav {
  align-self: center;
}
.page-home .site-header .nav-links {
  align-items: center;
}

.logo {
  display: inline-block;
  line-height: 0;
  font-size: 0;
}
.logo img {
  height: 80px;
  width: auto;
  display: block;
}
.page-home .logo img {
  height: 240px;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 2rem;
  list-style: none;
  margin: 0;
  padding: 0;
}

.nav-links a {
  color: var(--color-text);
  font-size: 0.95rem;
  font-weight: 500;
  position: relative;
  padding: 0.25em 0;
}
.nav-links a::after {
  content: '';
  position: absolute;
  left: 0;
  bottom: 0;
  width: 0;
  height: 2px;
  background: var(--color-text);
  transition: width var(--transition);
}
.nav-links a:hover::after,
.nav-links a:focus::after {
  width: 100%;
}

.nav-toggle {
  display: none;
  background: none;
  border: none;
  padding: 8px;
  cursor: pointer;
  color: var(--color-text);
}

/* --- Hero --- */
.hero {
  min-height: 60vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 120px 28px 140px;
  background: #ffffff;
  position: relative;
}

/* Services page: tighter hero spacing */
.page-services .hero {
  min-height: auto;
  padding-top: 40px;
  padding-bottom: 20px;
}

.services-hero {
  padding-bottom: 0;
}

.services-list {
  padding-top: 0;
}

.services-hero + .services-list {
  padding-top: 20px !important;
  margin-top: 0 !important;
}
.hero.has-bg-image {
  background: #ffffff center/cover no-repeat;
  background-image: url('../images/hero-bg.jpg');
}

.hero-content {
  max-width: 640px;
  position: relative;
  z-index: 1;
}

.hero-title {
  font-family: var(--font-heading);
  font-size: 38px;
  font-weight: 700;
  line-height: 1.05;
  margin: 0 0 0.5em;
  letter-spacing: -0.02em;
  color: var(--color-text);
  opacity: 0;
  animation: heroSlideIn 0.8s ease forwards;
}
.hero-subtitle {
  font-size: 20px;
  color: var(--color-text-muted);
  margin: 0 0 1.75em;
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
  line-height: 1.5;
  opacity: 0;
  animation: heroSlideIn 0.8s ease 0.15s forwards;
}
.hero .cta-wrap {
  opacity: 0;
  animation: heroSlideIn 0.8s ease 0.3s forwards;
}

@keyframes heroSlideIn {
  from {
    opacity: 0;
    transform: translateY(24px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* --- Buttons --- */
.btn {
  display: inline-block;
  padding: 14px 32px;
  font-family: var(--font-body);
  font-size: 1rem;
  font-weight: 600;
  text-align: center;
  border: none;
  border-radius: 50px;
  cursor: pointer;
  transition: background var(--transition), transform 0.15s ease, box-shadow var(--transition);
}
.btn:focus {
  outline: 2px solid var(--color-text);
  outline-offset: 2px;
}
.btn:active {
  transform: scale(0.98);
}

.btn-primary {
  background: var(--color-btn);
  color: #fff;
}
.btn-primary:hover {
  background-color: #333333;
  color: #ffffff !important;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.15);
}

.about-cta .btn {
  padding: 16px 32px;
  font-size: 16px;
  min-width: 160px;
  text-align: center;
}
.btn-primary:active {
  background: var(--color-btn-hover);
}

.btn-secondary {
  background: var(--color-text);
  color: #fff;
}
.btn-secondary:hover {
  background: var(--color-btn-hover);
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.15);
}

.btn-outline {
  background: #ffffff;
  color: var(--color-text);
  border: 2px solid var(--color-text);
  padding: 16px 32px;
}
.btn-outline:hover {
  background: var(--color-text);
  color: #ffffff;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.15);
}

/* --- Trust bar --- */
.trust-bar {
  text-align: center;
  padding: 28px 28px;
  background: #ffffff;
  font-size: 15px;
  color: var(--color-text-muted);
  border-top: 1px solid var(--color-border);
  border-bottom: 1px solid var(--color-border);
}

/* --- Sections --- */
.section {
  padding: 120px 28px;
  max-width: 980px;
  margin: 0 auto;
}

.section-title {
  font-family: var(--font-heading);
  font-size: 42px;
  font-weight: 700;
  text-align: center;
  margin: 0 0 1rem;
  letter-spacing: -0.02em;
  color: var(--color-text);
}
.section-subtitle {
  text-align: center;
  color: var(--color-text-muted);
  margin: 0 0 4rem;
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
  font-size: 17px;
  line-height: 1.7;
}

.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}
.reveal.revealed {
  opacity: 1;
  transform: translateY(0);
}

/* --- About page (rebuilt) --- */
.about-hero {
  padding-top: 80px;
  padding-bottom: 0;
  text-align: center;
  margin-bottom: 20px;
}

.about-headshot {
  width: 220px;
  height: 220px;
  border-radius: 50%;
  object-fit: cover;
  margin: 0 auto 10px;
  background: var(--color-border);
}

.about-name {
  font-family: var(--font-heading);
  font-size: 42px;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--color-text);
  margin: 0 0 4px;
  line-height: 1.1;
}

.about-role {
  margin: 0 0 8px;
  color: var(--color-text-muted);
  font-size: 17px;
}

.about-bio {
  max-width: 700px;
  margin: 8px auto 0;
  padding-top: 0;
  font-size: 18px;
  line-height: 1.8;
  color: var(--color-text-muted);
  text-align: left;
}
.about-bio p {
  margin: 4px 0 1.2em;
  text-align: left;
}
.about-bio p:last-child {
  margin-bottom: 0;
}

.dot-divider {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 8px;
  margin: 8px auto 4px;
}
.dot-divider span {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background-color: #3a7d1e;
  display: inline-block;
}

.cred-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 24px;
  max-width: 900px;
  margin: 0 auto;
}
.cred-card {
  display: flex;
  gap: 16px;
  align-items: center;
  padding: 22px 24px;
  border-radius: 14px;
  background: #ffffff;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.06);
}
.cred-icon {
  font-size: 28px;
  line-height: 1;
}
.cred-title {
  font-family: var(--font-heading);
  font-weight: 700;
  color: var(--color-text);
  font-size: 1.1rem;
}
.cred-subtitle {
  color: var(--color-text-muted);
  font-size: 0.95rem;
  margin-top: 2px;
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 28px;
  max-width: 980px;
  margin: 0 auto;
  text-align: center;
}
.stat-number {
  font-family: var(--font-heading);
  font-size: 22px;
  font-weight: 600;
  color: var(--color-text);
  letter-spacing: -0.01em;
}
.stat-label {
  margin-top: 8px;
  color: var(--color-text-muted);
  font-size: 13px;
  line-height: 1.5;
}

.about-cta {
  text-align: center;
  margin: 120px 0 0;
  display: flex;
  justify-content: center;
  gap: 16px;
  flex-wrap: wrap;
}

/* About: tighten vertical spacing between sections on all viewports */
.page-about .about-bio-section {
  padding-top: 8px;
  padding-bottom: 30px;
}
.page-about .about-creds-section {
  padding-top: 8px;
}
.page-about .stats-section {
  padding-top: 30px;
  padding-bottom: 30px;
}

/* --- Home page: hero statement + image grid --- */
.page-home .hero-statement {
  text-align: center;
  font-size: 18px;
  letter-spacing: 0.15em;
  color: #1d1d1f;
  text-transform: uppercase;
  padding: 80px 24px;
  margin: 0;
}

.page-home .image-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0;
  width: 100%;
  max-width: none;
  padding: 0;
  margin: 0;
}

.page-home .image-grid-col {
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.page-home .image-grid-col a {
  display: block;
  line-height: 0;
}

.page-home .image-grid-col img {
  width: 100%;
  height: auto;
  display: block;
  vertical-align: bottom;
}

.grid-item {
  position: relative;
  overflow: hidden;
  display: block;
  height: 400px;
}
.grid-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.4s ease;
}

.grid-item:nth-child(1) img {
  object-position: center bottom;
}

.page-home .image-grid-col:nth-child(2) .grid-item:nth-child(3) img {
  object-position: center bottom;
}

img[src="images/apple1.jpg"] {
  object-position: center top;
}
.grid-item:hover img {
  transform: scale(1.03);
}
.grid-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: rgba(0, 0, 0, 0.55);
  color: white;
  padding: 16px 20px;
  font-size: 15px;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  opacity: 0;
  transition: opacity 0.3s ease;
}
.grid-item:hover .grid-overlay {
  opacity: 1;
}

@media (max-width: 600px) {
  .page-home .image-grid {
    grid-template-columns: 1fr 1fr;
  }
  .page-home .site-header .inner {
    padding: 0 24px;
  }
}

/* --- Home: How I Can Help (text list, no cards) --- */
.help-list {
  max-width: 640px;
  margin: 0 auto;
  text-align: center;
}
.help-item {
  margin-bottom: 72px;
}
.help-item:last-child {
  margin-bottom: 0;
}
.help-item-title {
  font-family: var(--font-heading);
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--color-text);
  margin: 0 0 0.5em;
}
.help-item-desc {
  font-size: 17px;
  color: var(--color-text-muted);
  line-height: 1.7;
  margin: 0;
}

/* --- Services: text list (no cards) --- */
.services-list {
  max-width: 720px;
  margin: 0 auto;
}
.service-item {
  padding: 48px 0;
  border-bottom: 1px solid var(--color-border);
}
.service-item:first-child {
  padding-top: 0;
}
.service-item:last-child {
  border-bottom: none;
}
.service-item-title {
  font-family: var(--font-heading);
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--color-text);
  margin: 0 0 0.5em;
}
.service-item-desc {
  font-size: 17px;
  color: var(--color-text-muted);
  line-height: 1.7;
  margin: 0 0 1rem;
}
.service-item .btn {
  margin-top: 0.25rem;
}

.pricing-note {
  text-align: center;
  margin-top: 64px;
  padding-top: 48px;
  border-top: 1px solid var(--color-border);
  font-size: 17px;
  color: var(--color-text-muted);
  line-height: 1.7;
}

/* --- CTA strip --- */
.cta-strip {
  text-align: center;
  padding: 120px 28px;
  background: #ffffff;
  border-top: 1px solid var(--color-border);
}
.cta-strip .section-title {
  margin-bottom: 1.25rem;
}
.cta-strip .btn {
  margin-top: 0.5rem;
}

/* --- Footer --- */
.site-footer {
  background: var(--color-footer-bg);
  padding: 20px 28px;
  border-top: none;
}
.site-footer .inner {
  max-width: 980px;
  margin: 0 auto;
  text-align: center;
}
.footer-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 1.5rem;
  list-style: none;
  margin: 0 0 1.5rem;
  padding: 0;
}
.footer-links a {
  color: rgba(255, 255, 255, 0.85);
  font-size: 0.9rem;
}
.footer-links a:hover {
  color: #ffffff;
}
.footer-social {
  display: flex;
  justify-content: center;
  gap: 1rem;
  margin-bottom: 10px;
}
.footer-social a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  color: rgba(255, 255, 255, 0.85);
  padding: 0;
}
.footer-social a:hover {
  color: #ffffff;
}
.footer-copy {
  font-size: 13px;
  color: rgba(255, 255, 255, 0.6);
  margin: 0;
}

/* --- Forms --- */
.form-group {
  margin-bottom: 1.5rem;
}
.form-group label {
  display: block;
  font-weight: 500;
  margin-bottom: 0.4em;
  font-size: 0.95rem;
  color: var(--color-text);
}
.form-group input,
.form-group select,
.form-group textarea {
  width: 100%;
  padding: 14px 16px;
  font-family: var(--font-body);
  font-size: 1rem;
  border: 1px solid var(--color-border);
  border-radius: 8px;
  background: #ffffff;
  color: var(--color-text);
  transition: border-color var(--transition), box-shadow var(--transition);
}
.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--color-text);
  box-shadow: 0 0 0 2px rgba(29, 29, 31, 0.15);
}
.form-group textarea {
  min-height: 140px;
  resize: vertical;
}
.contact-form {
  max-width: 520px;
  margin: 0 auto 2rem;
}
.contact-form .btn {
  width: 100%;
  padding: 16px;
}

.contact-info {
  max-width: 520px;
  margin: 0 auto;
  padding: 32px 0 0;
  font-size: 17px;
  color: var(--color-text-muted);
  line-height: 1.7;
  border-top: 1px solid var(--color-border);
}
.contact-info p {
  margin: 0 0 0.5em;
}
.contact-info a {
  color: var(--color-text);
  font-weight: 500;
}
.contact-info a:hover {
  color: var(--color-btn-hover);
}

/* --- About --- */
.about-grid {
  display: grid;
  grid-template-columns: 1fr 1.4fr;
  gap: 64px;
  align-items: start;
  max-width: 900px;
  margin: 0 auto;
}
.profile-photo-wrap {
  position: sticky;
  top: 100px;
}
.profile-photo {
  width: 100%;
  aspect-ratio: 1;
  border-radius: 50%;
  object-fit: cover;
  background: var(--color-border);
  border: 4px solid #fff;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.08);
}
.bio-text {
  font-size: 17px;
  line-height: 1.7;
  color: var(--color-text-muted);
}
.bio-text p {
  margin: 0 0 1em;
}
.bio-text h3 {
  font-family: var(--font-heading);
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--color-text);
  margin: 2rem 0 0.75em;
}
.exp-list {
  list-style: none;
  padding: 0;
  margin: 1rem 0;
}
.exp-list li {
  padding: 0.4em 0;
  padding-left: 1.5em;
  position: relative;
  color: var(--color-text-muted);
}
.exp-list li::before {
  content: '•';
  position: absolute;
  left: 0;
  color: var(--color-text);
  font-weight: bold;
}
.why-macs {
  margin-top: 2rem;
  padding: 32px 0;
  border-top: 1px solid var(--color-border);
}
.why-macs h3 {
  margin-top: 0;
}

/* --- News grid --- */
.news-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 28px;
}
.news-card {
  background: #ffffff;
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid var(--color-border);
  transition: box-shadow var(--transition);
  display: flex;
  flex-direction: column;
}
.news-card:hover {
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.06);
}
.news-card img {
  width: 100%;
  height: 160px;
  object-fit: cover;
  background: var(--color-border);
}
.news-card-body {
  padding: 24px;
  flex: 1;
  display: flex;
  flex-direction: column;
}
.news-card-title {
  font-family: var(--font-heading);
  font-size: 1.1rem;
  font-weight: 600;
  margin: 0 0 0.5em;
  line-height: 1.35;
  color: var(--color-text);
}
.news-card-meta {
  font-size: 0.85rem;
  color: var(--color-text-muted);
  margin-top: auto;
  padding-top: 0.5em;
}
.news-card-meta span + span::before {
  content: ' · ';
}
.news-card .link-read {
  margin-top: 0.75em;
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--color-text);
}
.news-card .link-read:hover {
  color: var(--color-btn-hover);
}

.loading-spinner {
  display: inline-block;
  width: 40px;
  height: 40px;
  border: 3px solid var(--color-border);
  border-top-color: var(--color-text);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}
@keyframes spin {
  to { transform: rotate(360deg); }
}
.news-loading,
.news-error {
  text-align: center;
  padding: 80px 28px;
  color: var(--color-text-muted);
  font-size: 17px;
}

/* --- Thank you --- */
.thank-you-content {
  text-align: center;
  padding: 120px 28px;
  max-width: 480px;
  margin: 0 auto;
}
.thank-you-content .section-title {
  margin-bottom: 1rem;
}
.thank-you-content p {
  color: var(--color-text-muted);
  margin-bottom: 1.5rem;
  font-size: 17px;
  line-height: 1.7;
}

/* --- Intake note --- */
.intake-note {
  background: #ffffff;
  border: 1px solid var(--color-border);
  border-radius: 8px;
  padding: 20px 24px;
  margin-bottom: 2.5rem;
  font-size: 17px;
  color: var(--color-text-muted);
  line-height: 1.7;
}

/* --- Mobile --- */
@media (max-width: 768px) {
  .hero-statement {
    font-size: 0.6rem;
  }
  .page-home .hero-statement {
    font-size: 13px;
    padding: 24px 16px;
  }
  .site-header .inner {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
  }
  .site-header .logo {
    grid-column: 2;
    justify-self: center;
  }
  .nav-toggle {
    grid-column: 3;
    justify-self: end;
  }
  .image-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
  }
  .grid-item {
    height: 200px;
  }
  .hero-title {
    font-size: 28px;
  }
  .hero-subtitle {
    font-size: 18px;
  }
  .section-title {
    font-size: 32px;
  }
  /* About: tighter, more connected mobile spacing */
  .page-about .section {
    padding: 40px 28px;
  }
  .page-about .about-hero {
    padding-top: 40px;
    padding-bottom: 24px;
  }
  .page-about .about-headshot {
    margin-bottom: 12px;
  }
  .page-about .about-name {
    margin-bottom: 6px;
  }
  .page-about .about-bio p {
    margin-bottom: 0.9em;
  }
  .page-about .cred-grid {
    gap: 16px;
  }
  .page-about .cred-card {
    padding: 18px 18px;
  }
  .page-about .stats-grid {
    gap: 16px;
  }
  .page-about .about-cta {
    margin-top: 28px;
  }
  .about-name {
    font-size: 34px;
  }
  .about-bio {
    font-size: 17px;
    line-height: 1.75;
    text-align: left;
  }
  .cred-grid {
    grid-template-columns: 1fr;
  }
  .stats-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .page-about .about-cta {
    margin-top: 120px !important;
  }
  .about-hero {
    padding-bottom: 0 !important;
    margin-bottom: 0 !important;
  }
  .about-bio {
    padding-top: 0 !important;
    margin-top: 0 !important;
  }
  section.section {
    padding-top: 24px !important;
    padding-bottom: 24px !important;
  }
  .nav-links {
    position: fixed;
    top: 80px;
    left: 0;
    right: 0;
    background: #ffffff;
    flex-direction: column;
    padding: 24px;
    gap: 0;
    border-bottom: 1px solid var(--color-border);
    transform: translateY(-100%);
    opacity: 0;
    visibility: hidden;
    transition: transform 0.3s ease, opacity 0.3s ease, visibility 0.3s;
  }
  .nav-links.is-open {
    transform: translateY(0);
    opacity: 1;
    visibility: visible;
  }
  .nav-links li {
    width: 100%;
    border-bottom: 1px solid var(--color-border);
  }
  .nav-links a {
    display: block;
    padding: 14px 0;
  }
  .nav-toggle {
    display: block;
    margin-right: 20px;
  }
  .hero {
    min-height: 50vh;
    padding: 80px 28px 100px;
  }
  .section {
    padding: 80px 28px;
  }
  .help-item {
    margin-bottom: 56px;
  }
  .cta-strip {
    padding: 80px 28px;
  }
  .about-grid {
    grid-template-columns: 1fr;
    gap: 48px;
  }
  .profile-photo-wrap {
    position: static;
    max-width: 260px;
    margin: 0 auto;
  }
}

@media (max-width: 375px) {
  .site-header .inner {
    padding: 0 20px;
  }
  .section,
  .hero,
  .trust-bar,
  .cta-strip {
    padding-left: 20px;
    padding-right: 20px;
  }
  .site-footer {
    padding-left: 20px;
    padding-right: 20px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  .reveal {
    opacity: 1;
    transform: none;
  }
  .hero-title,
  .hero-subtitle,
  .hero .cta-wrap {
    opacity: 1;
    animation: none;
  }
}
