/* ============================================
   Mark Flanighan — Main Stylesheet
   ============================================ */

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

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

:root {
  --white:   #F7F6F2;
  --black:   #1A1A1A;
  --ink:     #1B3A5C;
  --mid:     #6B7280;
  --rule:    #D6D3CC;
  --max-w:   1100px;
  --pad:     clamp(1.5rem, 4vw, 4rem);
}

html { font-size: 18px; scroll-behavior: smooth; }

body {
  font-family: 'Inter', sans-serif;
  background: var(--white);
  color: var(--black);
  line-height: 1.75;
  border-left: 3px solid var(--ink);
  min-height: 100vh;
}

/* Typography */
h1, h2, h3, h4 { font-family: 'Playfair Display', serif; line-height: 1.2; color: var(--black); }
h1 { font-size: clamp(1.9rem, 5vw, 2.8rem); font-weight: 700; margin-bottom: 1rem; }
h2 { font-size: clamp(1.3rem, 3vw, 1.75rem); font-weight: 600; margin-bottom: 0.75rem; margin-top: 2rem; }
h3 { font-size: 1.1rem; font-weight: 600; margin-bottom: 0.5rem; margin-top: 1.5rem; }
p  { margin-bottom: 1.2rem; }
p:last-child { margin-bottom: 0; }
a  { color: var(--ink); text-underline-offset: 3px; }
a:hover { color: var(--black); }
strong { font-weight: 600; }

ul, ol { margin: 0 0 1.2rem 1.5rem; }
li { margin-bottom: 0.35rem; }

blockquote {
  border-left: 3px solid var(--ink);
  padding-left: 1.25rem;
  margin: 1.5rem 0;
  color: var(--mid);
  font-style: italic;
}

/* Layout */
.container { max-width: var(--max-w); margin: 0 auto; padding: 0 var(--pad); }

/* Header */
.site-header {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 1.75rem var(--pad);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
}

.site-logo img { height: 44px; width: auto; display: block; }
.site-logo { text-decoration: none; }

.site-nav { display: flex; gap: 1.75rem; list-style: none; flex-wrap: wrap; }
.site-nav a {
  font-size: 0.82rem;
  font-weight: 500;
  color: var(--mid);
  text-decoration: none;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  transition: color 0.2s;
}
.site-nav a:hover, .site-nav a.active { color: var(--black); }

.header-rule { border: none; border-top: 1px solid var(--rule); }

/* Hero */
.hero {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: clamp(2.5rem, 7vw, 5rem) var(--pad) clamp(2rem, 5vw, 3.5rem);
}

.eyebrow {
  display: block;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink);
  margin-bottom: 1rem;
}

.hero-lead { font-size: 1.05rem; color: var(--mid); max-width: 52ch; margin-bottom: 2rem; }

.cta-group { display: flex; gap: 1rem; flex-wrap: wrap; align-items: center; }

/* Buttons */
.btn {
  display: inline-block;
  padding: 0.65rem 1.4rem;
  font-family: 'Inter', sans-serif;
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.03em;
  text-decoration: none;
  border-radius: 2px;
  transition: all 0.2s;
  cursor: pointer;
  border: none;
}
.btn-primary { background: var(--ink); color: var(--white); border: 2px solid var(--ink); }
.btn-primary:hover { background: var(--black); border-color: var(--black); color: var(--white); }
.btn-ghost { background: transparent; color: var(--ink); border: 2px solid var(--rule); }
.btn-ghost:hover { border-color: var(--ink); color: var(--black); }
.btn-submit {
  background: var(--ink);
  color: var(--white);
  padding: 0.75rem 2rem;
  font-size: 0.9rem;
  border: 2px solid var(--ink);
  width: 100%;
  margin-top: 0.5rem;
}
.btn-submit:hover { background: var(--black); border-color: var(--black); }

/* Sections */
.section { max-width: var(--max-w); margin: 0 auto; padding: clamp(2rem, 5vw, 3.5rem) var(--pad); }
.section-rule { border: none; border-top: 1px solid var(--rule); max-width: var(--max-w); margin: 0 auto; }

/* Service Cards */
.services-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 2rem; margin-top: 2rem; }
.service-card { border-top: 2px solid var(--ink); padding-top: 1.1rem; }
.service-card h3 { font-size: 1rem; margin: 0 0 0.4rem; }
.service-card p { font-size: 0.88rem; color: var(--mid); margin-bottom: 0.9rem; }
.service-card .link-arrow { font-size: 0.82rem; font-weight: 600; text-decoration: none; color: var(--ink); }
.service-card .link-arrow::after { content: ' →'; }
.service-card .link-arrow:hover { color: var(--black); }

/* Process list */
.process-list { list-style: none; margin: 1.5rem 0 0; }
.process-list li { display: grid; grid-template-columns: 2.5rem 1fr; gap: 1rem; padding: 1.4rem 0; border-bottom: 1px solid var(--rule); }
.process-list li:last-child { border-bottom: none; }
.process-num { font-family: 'Playfair Display', serif; font-size: 1.4rem; font-weight: 700; color: var(--rule); line-height: 1; padding-top: 0.25rem; }
.process-content h3 { font-size: 0.95rem; margin: 0 0 0.3rem; }
.process-content p { font-size: 0.88rem; color: var(--mid); margin: 0; }

/* Images */
.page-image { width: 100%; height: auto; display: block; margin: 1.5rem 0; border-radius: 2px; }
.page-image-half { max-width: 360px; width: 100%; height: auto; display: block; margin: 1.5rem 0; }

/* Blog list */
.blog-list { list-style: none; margin: 1.5rem 0 0; }
.blog-item { padding: 1.4rem 0; border-bottom: 1px solid var(--rule); }
.blog-item:last-child { border-bottom: none; }
.blog-date { display: block; font-size: 0.75rem; color: var(--mid); text-transform: uppercase; letter-spacing: 0.06em; margin-bottom: 0.3rem; }
.blog-item h2 { font-size: 1.1rem; margin: 0 0 0.35rem; }
.blog-item h2 a { text-decoration: none; color: var(--black); }
.blog-item h2 a:hover { color: var(--ink); }
.blog-item p { font-size: 0.88rem; color: var(--mid); margin: 0; }

/* Post */
.post-header { max-width: var(--max-w); margin: 0 auto; padding: clamp(2rem, 5vw, 4rem) var(--pad) 1.5rem; }
.post-meta { display: block; font-size: 0.78rem; color: var(--mid); margin-bottom: 0.75rem; }
.post-body { max-width: var(--max-w); margin: 0 auto; padding: 0 var(--pad) clamp(3rem, 6vw, 5rem); }
.post-body h2 { margin-top: 2.5rem; }
.post-body h3 { margin-top: 1.75rem; }

/* Contact form */
.contact-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 3rem; margin-top: 2rem; }
.contact-details p { margin-bottom: 0.6rem; font-size: 0.95rem; }
.contact-details a { font-weight: 500; }

.form-group { margin-bottom: 1.1rem; }
.form-group label { display: block; font-size: 0.8rem; font-weight: 600; letter-spacing: 0.04em; text-transform: uppercase; color: var(--mid); margin-bottom: 0.4rem; }
.form-group input,
.form-group textarea,
.form-group select {
  width: 100%;
  padding: 0.65rem 0.85rem;
  font-family: 'Inter', sans-serif;
  font-size: 0.95rem;
  color: var(--black);
  background: #fff;
  border: 1px solid var(--rule);
  border-radius: 2px;
  transition: border-color 0.2s;
  appearance: none;
}
.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus { outline: none; border-color: var(--ink); }
.form-group textarea { min-height: 130px; resize: vertical; }

.form-notice { font-size: 0.82rem; color: var(--mid); margin-top: 0.5rem; }
.form-success { display: none; background: #e8f4e8; border: 1px solid #4caf50; padding: 1rem; border-radius: 2px; color: #2e7d32; margin-top: 1rem; font-size: 0.9rem; }
.form-error   { display: none; background: #fdecea; border: 1px solid #ef5350; padding: 1rem; border-radius: 2px; color: #c62828; margin-top: 1rem; font-size: 0.9rem; }

/* Contact strip */
.contact-strip { background: var(--ink); padding: clamp(2rem, 5vw, 3.5rem) var(--pad); }
.contact-strip-inner { max-width: var(--max-w); margin: 0 auto; display: flex; justify-content: space-between; align-items: center; gap: 2rem; flex-wrap: wrap; }
.contact-strip h2 { color: #F7F6F2; font-size: clamp(1.1rem, 3vw, 1.5rem); margin: 0; }
.contact-strip p { color: rgba(247,246,242,0.7); font-size: 0.88rem; margin: 0.3rem 0 0; }
.contact-strip .btn-primary { background: var(--white); color: var(--ink); border-color: var(--white); white-space: nowrap; }
.contact-strip .btn-primary:hover { background: #ede; color: var(--black); }

/* Footer */
.site-footer { max-width: var(--max-w); margin: 0 auto; padding: 1.75rem var(--pad); display: flex; justify-content: space-between; align-items: center; gap: 1rem; flex-wrap: wrap; }
.footer-copy { font-size: 0.78rem; color: var(--mid); }
.footer-links { display: flex; gap: 1.5rem; list-style: none; }
.footer-links a { font-size: 0.78rem; color: var(--mid); text-decoration: none; }
.footer-links a:hover { color: var(--black); }

/* Social icons */
.social-links { display: flex; gap: 1rem; list-style: none; }
.social-links a { color: var(--mid); text-decoration: none; font-size: 0.82rem; font-weight: 500; }
.social-links a:hover { color: var(--ink); }

/* Tables */
table { width: 100%; border-collapse: collapse; margin: 1.5rem 0; font-size: 0.9rem; }
th { background: var(--ink); color: var(--white); padding: 0.65rem 0.85rem; text-align: left; font-family: 'Inter', sans-serif; font-size: 0.8rem; font-weight: 600; letter-spacing: 0.04em; text-transform: uppercase; }
td { padding: 0.65rem 0.85rem; border-bottom: 1px solid var(--rule); vertical-align: top; }
tr:last-child td { border-bottom: none; }
tr:nth-child(even) td { background: rgba(0,0,0,0.02); }

/* Responsive */
@media (max-width: 640px) {
  body { border-left: none; border-top: 3px solid var(--ink); }
  .site-header { flex-direction: column; align-items: flex-start; gap: 1rem; }
  .site-nav { gap: 1rem; }
  .contact-grid { grid-template-columns: 1fr; gap: 2rem; }
  .contact-strip-inner { flex-direction: column; align-items: flex-start; }
  .site-footer { flex-direction: column; align-items: flex-start; }
}

@media (prefers-reduced-motion: reduce) { * { transition: none !important; } }

/* Hero two-column layout */
.hero-inner {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 3rem;
  align-items: center;
}

.hero-image img {
  width: 260px;
  height: 260px;
  object-fit: cover;
  object-position: center top;
  border-radius: 2px;
  display: block;
  filter: grayscale(15%);
}

@media (max-width: 640px) {
  .hero-inner {
    grid-template-columns: 1fr;
  }
  .hero-image {
    display: none;
  }
}

/* Contact strip heading — span not h tag */
.strip-heading {
  display: block;
  font-family: 'Playfair Display', serif;
  font-size: clamp(1.1rem, 3vw, 1.5rem);
  font-weight: 700;
  color: #F7F6F2;
  line-height: 1.2;
  margin-bottom: 0.3rem;
}

/* Blog post titles in lists — p not h tag */
.blog-title {
  font-family: 'Playfair Display', serif;
  font-size: 1.05rem;
  font-weight: 700;
  line-height: 1.3;
  margin-bottom: 0.3rem;
}

.blog-title a {
  text-decoration: none;
  color: var(--black);
}

.blog-title a:hover { color: var(--ink); }

/* ── Header overrides: full-width ink blue ── */
.site-header-wrap {
  background: var(--ink);
  border-bottom: none;
  width: 100%;
}

.site-header {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 1.25rem var(--pad);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
  background: transparent;
}

.site-logo-text {
  font-family: 'Playfair Display', serif;
  font-size: 1.2rem;
  font-weight: 700;
  color: #F7F6F2;
  text-decoration: none;
  letter-spacing: -0.01em;
}

.site-nav a {
  color: rgba(247,246,242,0.7);
}

.site-nav a:hover,
.site-nav a.active {
  color: #F7F6F2;
}

.header-rule {
  display: none;
}

@media (max-width: 640px) {
  body { border-left: none; border-top: none; }
  .site-header-wrap { border-top: 3px solid var(--ink); }
}
