/* Schalliol Automation — site-wide styles
   Two modes: warm (services/home) and cool (software). Same backbone. */

:root {
  --ink:        #1B1714;
  --ink-2:      #4A413A;
  --mute:       #6B6359;
  --line:       #EFE9DF;
  --line-soft:  #F4EFE6;
  --warm-bg:    #FAF7F2;
  --warm-bg-2:  #F2EBDF;
  --white:      #FFFFFF;
  --copper:     #B0541A;
  --copper-2:   #8A4014;
  --copper-tint:#FBE9D6;
  --slate:      #0A2540;
  --slate-2:    #1A3A5C;
  --teal:       #0E8F8F;

  --display: "Fraunces", "Times New Roman", Georgia, serif;
  --sans: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Inter", system-ui, sans-serif;

  --radius: 14px;
  --radius-sm: 8px;
  --shadow-1: 0 1px 2px rgba(27,23,20,.04), 0 8px 24px rgba(27,23,20,.06);
  --shadow-2: 0 2px 6px rgba(27,23,20,.06), 0 18px 50px rgba(27,23,20,.10);
  --max: 1180px;
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.55;
  color: var(--ink);
  background: var(--warm-bg);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img { max-width: 100%; display: block; }
a { color: var(--copper); text-decoration: none; }
a:hover { color: var(--copper-2); }

h1, h2, h3, h4 { font-family: var(--display); font-weight: 500; letter-spacing: -0.01em; color: var(--ink); margin: 0 0 .5em; }
h1 { font-size: clamp(2.4rem, 5.2vw, 4.2rem); line-height: 1.05; letter-spacing: -0.025em; }
h2 { font-size: clamp(1.7rem, 3vw, 2.4rem); line-height: 1.15; letter-spacing: -0.02em; }
h3 { font-size: 1.25rem; line-height: 1.3; }
p  { margin: 0 0 1rem; color: var(--ink-2); }

.eyebrow {
  font-family: var(--sans);
  font-size: .78rem;
  font-weight: 600;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--copper);
  margin: 0 0 1rem;
}

/* ---------- Top nav ---------- */
.nav {
  position: sticky;
  top: 0;
  z-index: 30;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px clamp(20px, 4vw, 40px);
  background: rgba(250, 247, 242, .92);
  backdrop-filter: saturate(140%) blur(10px);
  -webkit-backdrop-filter: saturate(140%) blur(10px);
  border-bottom: 1px solid var(--line);
}
.nav.cool { background: rgba(255,255,255,.92); border-bottom-color: #E5EBF2; }

.brand { display: inline-flex; align-items: center; gap: 10px; color: var(--ink); font-weight: 600; }
.brand-crest {
  width: auto;
  height: 30px;
  display: block;
  flex-shrink: 0;
}
.site-footer .brand-crest { height: 26px; }
.brand-name { font-family: var(--sans); font-size: 1rem; letter-spacing: -.005em; }

.nav nav { display: flex; gap: clamp(14px, 2.4vw, 28px); align-items: center; }
.nav nav a {
  color: var(--ink-2);
  font-size: .94rem;
  font-weight: 500;
  letter-spacing: -.005em;
  padding: 6px 0;
}
.nav nav a:hover { color: var(--ink); }
.nav nav a.cta-mini {
  color: var(--white);
  background: var(--copper);
  padding: 8px 14px;
  border-radius: 999px;
  font-weight: 600;
}
.nav nav a.cta-mini:hover { background: var(--copper-2); color: var(--white); }
.cool .nav-cta { color: var(--white); background: var(--slate); }
.cool .nav-cta:hover { background: var(--slate-2); }

/* ---------- Buttons ---------- */
.cta {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 13px 22px;
  border-radius: 999px;
  font-weight: 600;
  font-size: .98rem;
  letter-spacing: -.005em;
  transition: transform .12s ease, background .12s ease, color .12s ease;
}
.cta.primary { background: var(--copper); color: var(--white); }
.cta.primary:hover { background: var(--copper-2); color: var(--white); transform: translateY(-1px); }
.cta.secondary { background: rgba(27,23,20,.06); color: var(--ink); }
.cta.secondary:hover { background: rgba(27,23,20,.10); color: var(--ink); }
.cta.ghost { color: var(--ink); border: 1px solid var(--line); background: transparent; }
.cta.ghost:hover { border-color: var(--ink); color: var(--ink); }
.cta.cool { background: var(--slate); color: var(--white); }
.cta.cool:hover { background: var(--slate-2); color: var(--white); }

/* ---------- Containers ---------- */
.wrap { max-width: var(--max); margin: 0 auto; padding: 0 clamp(20px, 4vw, 40px); }
section { padding: clamp(64px, 9vw, 120px) 0; }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  padding: 0;
  background: var(--warm-bg);
  overflow: hidden;
}
.hero-inner {
  position: relative;
  display: grid;
  grid-template-columns: 1.05fr .95fr;
  gap: clamp(30px, 4vw, 60px);
  align-items: center;
  max-width: var(--max);
  margin: 0 auto;
  padding: clamp(60px, 8vw, 110px) clamp(20px, 4vw, 40px) clamp(80px, 9vw, 130px);
}
.hero-copy h1 { margin-bottom: .35em; }
.hero-copy .lede {
  font-size: clamp(1.05rem, 1.4vw, 1.2rem);
  color: var(--ink-2);
  max-width: 36em;
  line-height: 1.55;
  margin-bottom: 1.6rem;
}
.hero-cta-row { display: flex; flex-wrap: wrap; gap: 12px; margin-bottom: 1.2rem; }
.hero-meta {
  display: flex; flex-wrap: wrap; gap: 18px;
  font-size: .85rem; color: var(--mute);
}
.hero-meta .dot { width: 4px; height: 4px; border-radius: 50%; background: var(--copper); display: inline-block; margin-right: 8px; vertical-align: middle; }

.hero-photo {
  position: relative;
  border-radius: var(--radius);
  overflow: hidden;
  aspect-ratio: 4/5;
  box-shadow: var(--shadow-2);
  background: #1c1816;
}
.hero-photo .slide {
  position: absolute; inset: 0;
  opacity: 0;
  transition: opacity 1.2s ease;
}
.hero-photo .slide.is-active { opacity: 1; }
.hero-photo .slide img { width: 100%; height: 100%; object-fit: cover; }
.hero-photo::after {
  content: "";
  position: absolute; inset: 0;
  background: linear-gradient(180deg, transparent 60%, rgba(27,23,20,.55) 100%);
  pointer-events: none;
  z-index: 2;
}
.hero-photo .credit {
  position: absolute; left: 18px; bottom: 16px; right: 18px;
  color: rgba(255,255,255,.92);
  font-size: .82rem; letter-spacing: .02em;
  display: flex; justify-content: space-between; gap: 12px;
  z-index: 3;
}
.hero-photo .credit [data-credit-text] {
  transition: opacity .4s ease;
}
@media (prefers-reduced-motion: reduce) {
  .hero-photo .slide { transition: none; }
}

@media (max-width: 880px) {
  .hero-inner { grid-template-columns: 1fr; }
  .hero-photo { aspect-ratio: 4/3; order: 2; }
}

/* ---------- Section heads ---------- */
.section-head { max-width: 720px; margin: 0 auto clamp(36px, 5vw, 60px); text-align: center; }
.section-head .lede { color: var(--ink-2); font-size: 1.05rem; }
.section-head.left { text-align: left; margin-left: 0; }

/* ---------- Service grid ---------- */
.services { background: var(--white); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.service-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
}
.service {
  background: var(--white);
  padding: 32px 28px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  min-height: 200px;
  transition: background .15s ease;
}
.service:hover { background: var(--warm-bg); }
.service .icon {
  width: 36px; height: 36px;
  color: var(--copper);
  margin-bottom: 6px;
}
.service .icon svg { width: 100%; height: 100%; stroke: currentColor; fill: none; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
.service h3 { font-family: var(--sans); font-size: 1.05rem; font-weight: 600; letter-spacing: -.01em; margin-bottom: 4px; }
.service p { font-size: .94rem; margin: 0; color: var(--ink-2); }

@media (max-width: 880px) {
  .service-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 560px) {
  .service-grid { grid-template-columns: 1fr; }
}

/* ---------- Work / project gallery ---------- */
.work { background: var(--warm-bg); }
.work-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  grid-auto-rows: 220px;
  gap: 14px;
}
.work-grid figure {
  margin: 0;
  border-radius: var(--radius);
  overflow: hidden;
  position: relative;
  background: #2a2520;
  box-shadow: var(--shadow-1);
}
.work-grid figure img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s ease; }
.work-grid figure:hover img { transform: scale(1.04); }
.work-grid figure.tall { grid-row: span 2; }
.work-grid figure.wide { grid-column: span 2; }
.work-grid figcaption {
  position: absolute; bottom: 12px; left: 14px; right: 14px;
  color: rgba(255,255,255,.95);
  font-size: .88rem;
  letter-spacing: .01em;
  text-shadow: 0 1px 8px rgba(0,0,0,.5);
  display: flex; align-items: center; gap: 8px;
}
.work-grid figcaption::before {
  content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--copper);
}
@media (max-width: 880px) {
  .work-grid { grid-template-columns: 1fr 1fr; grid-auto-rows: 180px; }
  .work-grid figure.tall { grid-row: auto; }
  .work-grid figure.wide { grid-column: span 2; }
}

/* ---------- Brands strip ---------- */
.brands { background: var(--white); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.brands-grid {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 1px;
  background: var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--line);
}
.brands-grid span {
  padding: 22px 16px;
  background: var(--white);
  font-family: var(--sans);
  font-size: .88rem;
  font-weight: 500;
  color: var(--ink-2);
  letter-spacing: -.005em;
  text-align: center;
  display: flex; align-items: center; justify-content: center;
  min-height: 70px;
}
@media (max-width: 880px) { .brands-grid { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 480px) { .brands-grid { grid-template-columns: repeat(2, 1fr); } }

/* ---------- Software band (transitions warm → cool) ---------- */
.software-band {
  background: linear-gradient(180deg, var(--warm-bg) 0%, #F1ECE4 100%);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid #E5DFD3;
}
.software-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 22px;
  margin-top: 36px;
}
.software-card {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 28px;
  display: flex; flex-direction: column;
  box-shadow: var(--shadow-1);
  position: relative;
  overflow: hidden;
}
.software-card.featured {
  background: linear-gradient(135deg, var(--slate) 0%, #14304d 60%, #1f4f78 100%);
  color: var(--white);
  border-color: transparent;
}
.software-card.featured h3,
.software-card.featured p { color: var(--white); }
.software-card.featured p { color: rgba(255,255,255,.82); }
.software-card .pill {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: .72rem; font-weight: 600; letter-spacing: .12em; text-transform: uppercase;
  padding: 4px 10px; border-radius: 999px;
  background: rgba(11,164,164,.16); color: var(--teal);
  align-self: flex-start; margin-bottom: 14px;
}
.software-card.featured .pill { background: rgba(255,255,255,.14); color: rgba(255,255,255,.95); }
.software-card .pill.soon { background: rgba(176,84,26,.12); color: var(--copper); }
.software-card h3 { font-family: var(--sans); font-size: 1.4rem; font-weight: 600; margin-bottom: 6px; letter-spacing: -.01em; }
.software-card p { font-size: .98rem; margin-bottom: 18px; }
.software-card .card-cta { margin-top: auto; display: flex; gap: 10px; flex-wrap: wrap; }
.software-card.featured .card-cta .cta.primary { background: var(--white); color: var(--slate); }
.software-card.featured .card-cta .cta.primary:hover { background: rgba(255,255,255,.9); color: var(--slate); }
.software-card.featured .card-cta .cta.ghost { color: rgba(255,255,255,.95); border-color: rgba(255,255,255,.3); }

@media (max-width: 760px) { .software-grid { grid-template-columns: 1fr; } }

/* ---------- Approach / about strip ---------- */
.approach { background: var(--white); }
.approach-grid {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 22px;
}
.approach-card {
  padding: 28px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--warm-bg);
}
.approach-card .num {
  font-family: var(--display);
  font-size: 1.6rem;
  color: var(--copper);
  margin-bottom: 6px;
}
.approach-card h3 { font-family: var(--sans); font-size: 1.05rem; font-weight: 600; margin-bottom: 6px; }
.approach-card p { font-size: .94rem; margin: 0; }
@media (max-width: 760px) { .approach-grid { grid-template-columns: 1fr; } }

/* ---------- Contact ---------- */
.contact { background: var(--warm-bg); }
.contact-inner {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 40px;
  align-items: start;
}
.contact-card {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 28px;
  box-shadow: var(--shadow-1);
}
.contact-card h3 { font-family: var(--sans); font-size: 1rem; font-weight: 600; letter-spacing: .04em; text-transform: uppercase; color: var(--mute); margin-bottom: 14px; }
.contact-card .big { font-family: var(--display); font-size: 1.6rem; line-height: 1.25; color: var(--ink); }
.contact-card a { color: var(--ink); }
.contact-card a:hover { color: var(--copper); }
.contact-list { list-style: none; padding: 0; margin: 14px 0 0; display: grid; gap: 10px; }
.contact-list li { font-size: .96rem; color: var(--ink-2); }
.contact-list li strong { color: var(--ink); display: inline-block; min-width: 80px; }

@media (max-width: 760px) { .contact-inner { grid-template-columns: 1fr; } }

/* ---------- Footer ---------- */
.site-footer {
  background: var(--ink);
  color: rgba(255,255,255,.7);
  padding: 50px 0 30px;
}
.site-footer .wrap { display: flex; flex-direction: column; gap: 24px; }
.site-footer .row { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 16px; }
.site-footer .brand { color: var(--white); }
.site-footer .brand .brand-name { color: var(--white); }
.site-footer nav { display: flex; gap: 20px; }
.site-footer nav a { color: rgba(255,255,255,.7); font-size: .92rem; }
.site-footer nav a:hover { color: var(--white); }
.site-footer .fine { font-size: .82rem; color: rgba(255,255,255,.5); margin: 0; }
.site-footer .copy { font-size: .82rem; color: rgba(255,255,255,.5); }

/* ---------- Cool / software hub variants ---------- */
body.cool { background: var(--white); }
body.cool .hero { background: linear-gradient(180deg, #F4F7FB 0%, var(--white) 100%); }
body.cool .eyebrow { color: var(--teal); }
body.cool .software-band { background: var(--white); border: none; }
body.cool .approach { background: #F8FAFD; }
body.cool .approach-card { background: var(--white); border-color: #E5EBF2; }
body.cool .approach-card .num { color: var(--teal); }
body.cool .cta.primary { background: var(--slate); }
body.cool .cta.primary:hover { background: var(--slate-2); }
body.cool .software-card .pill.soon { background: rgba(176,84,26,.12); color: var(--copper); }
body.cool .software-card.shipped { border-color: var(--teal); }

/* ---------- Tools list (open utilities) ---------- */
.tools { background: var(--white); }
.tools-list { display: grid; gap: 0; border-top: 1px solid #E5EBF2; }
.tool-row {
  display: grid;
  grid-template-columns: 1fr 2fr auto;
  gap: 24px;
  align-items: center;
  padding: 20px 0;
  border-bottom: 1px solid #E5EBF2;
}
.tool-row .name { font-family: var(--sans); font-weight: 600; font-size: 1.02rem; color: var(--ink); }
.tool-row .desc { font-size: .96rem; color: var(--ink-2); }
.tool-row .tag {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: .76rem; font-weight: 600; letter-spacing: .1em; text-transform: uppercase;
  padding: 4px 10px; border-radius: 999px;
  background: #F4F7FB; color: var(--slate);
}
.tool-row .tag.beta  { background: rgba(176,84,26,.12); color: var(--copper); }
.tool-row .tag.shipping { background: rgba(11,143,143,.14); color: var(--teal); }
@media (max-width: 760px) {
  .tool-row { grid-template-columns: 1fr; gap: 6px; }
}
