/* woodwardsystems.com — the whole stylesheet.
 *
 * Replaces the 116 style="" attributes and 8 runtime-only style-hover=""
 * attributes that used to live in the generated index.html. Nothing here may
 * move back inline: the CSP for this vhost has no style-src 'unsafe-inline',
 * so an inline style attribute is a silently unstyled element.
 *
 * The theme palettes below were the `themes` object in the old
 * <script type="text/x-dc"> block, which React wrote onto a wrapper div as an
 * inline style string. They live on :root now, so every var() call in this
 * file can drop the fallback second argument the generated markup carried.
 */

/* ---------- theme ---------- */

:root {
  --font-serif: 'Instrument Serif', Georgia, serif;
  --font-sans:  'Work Sans', system-ui, -apple-system, 'Segoe UI', sans-serif;

  --bg:             #F6F1E7;
  --text:           #211C15;
  --muted:          #4A4234;
  --card:           #FFFFFF;
  --card-border:    rgba(33, 28, 21, 0.08);
  --accent:         #D9663F;
  --accent2:        #E8A458;
  --nav-btn-bg:     #211C15;
  --nav-btn-text:   #F6F1E7;
  --services-bg:    #211C15;
  --services-text:  #F6F1E7;
  --services-muted: #C9C1B2;
  --footer-muted:   #8A8172;
  --tag-bg:         rgba(217, 102, 63, 0.1);
}

:root[data-theme="dark"] {
  --bg:             #17140F;
  --text:           #F3EDE1;
  --muted:          #B7AC98;
  --card:           #221D16;
  --card-border:    rgba(243, 237, 225, 0.1);
  --accent:         #E2794F;
  --accent2:        #E8A458;
  --nav-btn-bg:     #F3EDE1;
  --nav-btn-text:   #17140F;
  --services-bg:    #100D09;
  --services-text:  #F3EDE1;
  --services-muted: #A79C88;
  --footer-muted:   #7A705E;
  --tag-bg:         rgba(226, 121, 79, 0.15);
}

/* ---------- base ---------- */

* { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  background: var(--bg);
}

body {
  margin: 0;
  min-height: 100vh;
  overflow-x: hidden;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-sans);
  transition: background 0.3s ease, color 0.3s ease;
}

::selection { background: #D9663F; color: #F6F1E7; }

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}

/* The theme transition and the smooth anchor scroll are decorative; both are
   motion a reader can have asked not to see. */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
  }
}

/* Shared 1080px column. Per-section padding is set with the section rules. */
.ws-section {
  max-width: 1080px;
  margin: 0 auto;
}

.ws-eyebrow {
  margin: 0 0 14px;
  font-size: 15px;
  font-weight: 600;
  color: var(--accent);
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.ws-eyebrow--alt { color: var(--accent2); }

.ws-h2 {
  margin: 0;
  font-family: var(--font-serif);
  font-weight: 400;
  font-size: 44px;
  line-height: 1.1;
}

/* ---------- buttons ---------- */

.ws-btn {
  display: inline-block;
  border-radius: 99px;
  font-weight: 600;
  text-decoration: none;
  transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

.ws-btn--solid {
  background: var(--nav-btn-bg);
  color: var(--nav-btn-text);
}
.ws-btn--solid:hover { background: var(--accent); color: var(--nav-btn-text); }

.ws-btn--outline {
  background: transparent;
  color: var(--text);
  border: 1.5px solid var(--text);
}
.ws-btn--outline:hover { border-color: var(--accent); color: var(--accent); }

.ws-btn--sm { padding: 10px 18px; font-size: 14px; white-space: nowrap; }
.ws-btn--md { padding: 14px 26px; font-size: 15px; }
.ws-btn--lg { padding: 16px 32px; font-size: 17px; }

/* ---------- nav ---------- */

.ws-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 24px 20px;
}

.ws-logo {
  display: flex;
  align-items: center;
  gap: 9px;
  font-family: var(--font-serif);
  font-size: 24px;
  letter-spacing: 0.2px;
  color: var(--text);
  text-decoration: none;
}
/* The mark's strokes are currentColor, so it follows .ws-logo's color. */
.ws-logo svg { flex-shrink: 0; }
.ws-logo-dot { fill: var(--accent); }

.ws-nav-links {
  display: flex;
  align-items: center;
  gap: 24px;
  flex-shrink: 0;
}

.ws-nav-text-links {
  display: flex;
  align-items: center;
  gap: 24px;
}

.ws-navlink {
  color: var(--text);
  text-decoration: none;
  font-size: 15px;
  font-weight: 500;
  white-space: nowrap;
  transition: color 0.2s ease;
}
.ws-navlink:hover { color: var(--accent); }

/* Was a <div onclick>, so it was not keyboard reachable; it is a real button
   now. The glyph comes from ::before rather than JS so the control is correct
   on first paint and with JS disabled. */
.ws-theme-toggle {
  position: relative;
  display: flex;
  align-items: center;
  flex-shrink: 0;
  width: 52px;
  height: 28px;
  padding: 3px;
  border: 0;
  border-radius: 99px;
  background: var(--card-border);
  cursor: pointer;
}

.ws-theme-knob {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--accent);
  color: var(--nav-btn-text);
  font-size: 12px;
  transform: translateX(0);
  transition: transform 0.25s ease;
}
.ws-theme-knob::before { content: "\2600"; }            /* ☀ */

:root[data-theme="dark"] .ws-theme-knob { transform: translateX(24px); }
:root[data-theme="dark"] .ws-theme-knob::before { content: "\263E"; }  /* ☾ */

/* ---------- hero ---------- */

.ws-hero {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 56px;
  align-items: center;
  padding: 40px 20px 70px;
}

.ws-hero .ws-eyebrow { margin-bottom: 18px; }

.ws-hero-title {
  margin: 0 0 24px;
  font-family: var(--font-serif);
  font-weight: 400;
  font-size: 76px;
  line-height: 1.02;
  letter-spacing: -0.01em;
}
.ws-hero-title em { font-style: italic; color: var(--accent); }

.ws-hero-lede {
  margin: 0 0 32px;
  max-width: 480px;
  font-size: 20px;
  line-height: 1.55;
  color: var(--muted);
}

.ws-hero-actions {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
}

.ws-hero-photo-wrap {
  position: relative;
  display: flex;
  justify-content: center;
}

/* Deliberately not themed — it reads as a physical print in both modes. */
.ws-polaroid {
  max-width: 100%;
  padding: 16px 16px 60px;
  border-radius: 2px;
  background: #FDFBF6;
  box-shadow: 0 30px 60px -15px rgba(0, 0, 0, 0.4),
              0 12px 24px rgba(0, 0, 0, 0.18);
  transform: rotate(-3deg);
}

.ws-hero-photo {
  display: block;
  width: min(280px, 60vw);
  height: min(280px, 60vw);
  object-fit: cover;
  object-position: 50% 25%;
}

.ws-polaroid-caption {
  margin: 14px 0 0;
  font-family: var(--font-serif);
  font-style: italic;
  font-size: 16px;
  text-align: center;
  color: #5B5346;
}

/* ---------- about ---------- */

#about { padding: 30px 20px 70px; }
#about .ws-h2 { line-height: 1.08; }

.ws-about-grid {
  display: grid;
  grid-template-columns: 0.4fr 0.6fr;
  gap: 56px;
}

.ws-about-body {
  font-size: 18px;
  line-height: 1.75;
  font-weight: 400;
  color: var(--muted);
}
.ws-about-body p { margin: 0 0 20px; }
.ws-about-body p:last-child { margin: 0; }

.ws-inline-link {
  color: var(--text);
  font-weight: 600;
  transition: color 0.2s ease;
}
.ws-inline-link:hover { color: var(--accent); }

/* ---------- facts ---------- */

.ws-facts-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
  margin-top: 56px;
}

.ws-card {
  padding: 26px;
  border: 1px solid var(--card-border);
  border-radius: 16px;
  background: var(--card);
}

.ws-fact-icon {
  color: var(--accent);
  margin-bottom: 14px;
}

.ws-fact-title {
  margin: 0 0 8px;
  font-family: var(--font-serif);
  font-size: 22px;
  color: var(--text);
}

.ws-fact-text {
  margin: 0;
  font-size: 15px;
  line-height: 1.55;
  color: var(--muted);
}

/* ---------- work ---------- */

#work { padding: 0 20px 70px; }
#work .ws-h2 { margin: 0 0 40px; max-width: 600px; }

.ws-work-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 28px;
}

.ws-work-link {
  text-decoration: none;
  color: inherit;
}

.ws-work-card {
  border: 1px solid var(--card-border);
  border-radius: 14px;
  overflow: hidden;
  background: var(--card);
}

.ws-work-shot {
  display: block;
  width: 100%;
  height: 220px;
  object-fit: cover;
}

.ws-work-body { padding: 20px 22px; }

.ws-work-title {
  margin: 0 0 4px;
  font-family: var(--font-serif);
  font-size: 21px;
  color: var(--text);
}

.ws-work-meta {
  margin: 0 0 12px;
  font-size: 14px;
  color: var(--muted);
}

.ws-tags {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.ws-tag {
  padding: 5px 10px;
  border-radius: 99px;
  background: var(--tag-bg);
  color: var(--accent);
  font-size: 12px;
  font-weight: 600;
}

/* ---------- services ---------- */

#services {
  padding: 70px 0;
  background: var(--services-bg);
  transition: background 0.3s ease;
}
#services .ws-h2 {
  margin: 0 0 48px;
  max-width: 600px;
  color: var(--services-text);
}

/* The 1px grid gap shows this through as hairline rules between the cards. */
.ws-services-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1px;
  border-radius: 20px;
  overflow: hidden;
  background: rgba(246, 241, 231, 0.12);
}

.ws-service {
  padding: 36px;
  background: var(--services-bg);
}

.ws-service-num {
  margin: 0 0 12px;
  font-size: 13px;
  font-weight: 700;
  color: var(--accent);
}

.ws-service-title {
  margin: 0 0 10px;
  font-family: var(--font-serif);
  font-weight: 400;
  font-size: 26px;
  color: var(--services-text);
}

.ws-service-text {
  margin: 0;
  font-size: 15.5px;
  line-height: 1.6;
  color: var(--services-muted);
}

/* ---------- contact ---------- */

#contact {
  padding: 70px 20px 50px;
  text-align: center;
}
#contact .ws-eyebrow { margin-bottom: 18px; }
#contact .ws-h2 {
  margin: 0 0 24px;
  font-size: clamp(32px, 7vw, 56px);
  line-height: 1.08;
}

.ws-contact-lede {
  margin: 0 auto 36px;
  max-width: 520px;
  font-size: 19px;
  line-height: 1.6;
  color: var(--muted);
}

.ws-rate-note {
  margin: 16px 0 0;
  font-size: 13px;
  color: var(--muted);
}
.ws-rate-note a { color: inherit; }

/* ---------- footer ---------- */

.ws-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 28px 20px;
  border-top: 1px solid var(--card-border);
}

.ws-footer-name {
  margin: 0;
  font-family: var(--font-serif);
  font-size: 18px;
}

.ws-footer-meta {
  margin: 0;
  font-size: 13px;
  color: var(--footer-muted);
}

/* ---------- responsive ---------- */

@media (max-width: 860px) {
  .ws-hero { grid-template-columns: 1fr; gap: 40px; }
  .ws-hero-title { font-size: 56px; }
  .ws-about-grid { grid-template-columns: 1fr; gap: 28px; }
  .ws-facts-grid { grid-template-columns: repeat(2, 1fr); }
  .ws-work-grid { grid-template-columns: 1fr; }
  .ws-services-grid { grid-template-columns: 1fr; }
  .ws-nav-text-links { display: none; }
}

@media (max-width: 520px) {
  .ws-facts-grid { grid-template-columns: 1fr; }
  .ws-hero-title { font-size: 44px; }
  .ws-footer { flex-direction: column; align-items: flex-start; gap: 8px; }
}
