/* Infinity Engineering: site styles that sit alongside Tailwind utilities */
:root {
  --topsoil: #5E4632; --clay: #A9744A; --silt: #C7A47A; --sand: #E4D2A8; --rock: #8A979D;
}
html { -webkit-text-size-adjust: 100%; }
:focus-visible { outline: 3px solid #F2B705; outline-offset: 2px; }
img { max-width: 100%; height: auto; }

/* Strata strip: a thin cross-section that closes every page header */
.strata-edge {
  position: absolute; left: 0; right: 0; bottom: 0; height: 8px;
  background: linear-gradient(90deg, var(--topsoil) 0 16%, var(--clay) 16% 38%, var(--silt) 38% 60%, var(--sand) 60% 80%, var(--rock) 80% 100%);
}

/* Borehole log (home hero) */
.borehole { --h-scale: 1; }
.borehole-grid { display: grid; grid-template-columns: 3.75rem 1fr; }
.bh-ruler { position: relative; }
.bh-tick { position: absolute; right: .6rem; transform: translateY(-50%); font-size: .75rem; color: rgba(255,255,255,.65); font-variant-numeric: tabular-nums; white-space: nowrap; }
.bh-tick::after { content: ""; position: absolute; left: calc(100% + .25rem); top: 50%; width: .4rem; border-top: 1px solid rgba(255,255,255,.45); }
.bh-column { position: relative; border-left: 2px solid rgba(255,255,255,.5); }
.bh-layer { position: relative; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: .25rem .75rem; padding: 0 1rem; color: #fff; overflow: hidden; transform-origin: top; }
.bh-layer + .bh-layer { border-top: 1px solid rgba(18,38,46,.35); }
.bh-layer strong { font-family: Archivo, system-ui, sans-serif; font-weight: 700; font-size: 1rem; text-shadow: 0 1px 2px rgba(0,0,0,.35); }
.bh-layer span { font-size: .875rem; text-shadow: 0 1px 2px rgba(0,0,0,.35); }
.bh-topsoil { background-color: var(--topsoil); background-image: radial-gradient(rgba(0,0,0,.25) 1px, transparent 1.5px); background-size: 9px 9px; }
.bh-clay { background-color: var(--clay); background-image: repeating-linear-gradient(0deg, rgba(0,0,0,.14) 0 1px, transparent 1px 9px); }
.bh-sand { background-color: #A98A55; background-image: radial-gradient(rgba(255,255,255,.35) 1.2px, transparent 1.6px); background-size: 12px 12px; }
.bh-rock { background-color: #5F6E75; background-image: linear-gradient(135deg, rgba(255,255,255,.12) 25%, transparent 25% 50%, rgba(255,255,255,.12) 50% 75%, transparent 75%); background-size: 22px 22px; }
.bh-sample { position: absolute; left: -2px; transform: translate(-50%, -50%); width: 14px; height: 14px; border-radius: 50%; background: #F2B705; border: 3px solid #12262E; }
.bh-flag { position: absolute; left: 1.1rem; transform: translateY(-50%); background: #F2B705; color: #12262E; font: 700 .75rem/1 Archivo, sans-serif; padding: .35rem .55rem; border-radius: 2px; white-space: nowrap; }
@media (prefers-reduced-motion: no-preference) {
  .bh-layer { animation: bh-drill 900ms cubic-bezier(.2,.7,.2,1) both; }
  .bh-layer:nth-child(2) { animation-delay: 160ms; } .bh-layer:nth-child(3) { animation-delay: 320ms; } .bh-layer:nth-child(4) { animation-delay: 480ms; }
  .bh-sample, .bh-flag { animation: bh-pop 400ms 1100ms ease-out both; }
  @keyframes bh-drill { from { transform: scaleY(0); opacity: .2; } to { transform: scaleY(1); opacity: 1; } }
  @keyframes bh-pop { from { opacity: 0; } to { opacity: 1; } }
}

/* Article / rich text */
.prose-ies { font-size: 1.0625rem; line-height: 1.75; color: #1d2f36; max-width: 72ch; }
.prose-ies > * + * { margin-top: 1.1em; }
.prose-ies h2 { font-family: Archivo, system-ui, sans-serif; font-weight: 800; font-size: 1.6rem; line-height: 1.25; margin-top: 1.8em; color: #12262E; }
.prose-ies h3 { font-family: Archivo, system-ui, sans-serif; font-weight: 700; font-size: 1.25rem; margin-top: 1.5em; color: #12262E; }
.prose-ies ul { list-style: disc; padding-left: 1.4em; } .prose-ies ol { list-style: decimal; padding-left: 1.4em; }
.prose-ies li + li { margin-top: .35em; }
.prose-ies a { color: #12262E; text-decoration: underline; text-decoration-color: #F2B705; text-decoration-thickness: 2px; text-underline-offset: 3px; }
.prose-ies blockquote { border-left: 4px solid #F2B705; padding-left: 1rem; color: #52646B; }
.prose-ies img { border-radius: 4px; }
.prose-ies table { width: 100%; border-collapse: collapse; display: block; overflow-x: auto; }
.prose-ies th, .prose-ies td { border: 1px solid #D3D9D8; padding: .5rem .75rem; text-align: left; }
.prose-ies th { background: #ECEEED; }

/* Gallery */
.masonry { column-gap: .75rem; columns: 1; }
@media (min-width: 480px) { .masonry { columns: 2; } }
@media (min-width: 900px) { .masonry { columns: 3; } }
@media (min-width: 1200px) { .masonry { columns: 4; } }
.masonry > * { break-inside: avoid; margin-bottom: .75rem; }
dialog.lightbox { border: 0; padding: 0; background: transparent; max-width: 96vw; max-height: 96vh; }
dialog.lightbox::backdrop { background: rgba(18,38,46,.92); }

.form-msg.ok { color: #047857; } .form-msg.err { color: #be123c; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto !important; } * { transition-duration: .01ms !important; } }
