/* Jorge's Pallets LLC */
:root {
  --c-concrete: #E6E5E1;
  --c-pine: #C8923F;
  --c-pine-light: #E2BE84;
  --c-pine-dark: #9C6E2C;
  --c-ink: #1E2A22;
  --c-freight: #1F4E8C;
  --c-freight-dark: #173D6E;
  --c-white: #FFFFFF;
  --c-muted: #4F5A52;
  --c-line: #C4C3BC;
  --c-on-dark: #D3D8D0;
  --c-error: #A3231A;

  --f-stencil: "Saira Stencil One", "Impact", "Arial Narrow", sans-serif;
  --f-body: "Libre Franklin", system-ui, -apple-system, "Segoe UI", Arial, sans-serif;

  --s-1: 0.25rem; --s-2: 0.5rem; --s-3: 0.75rem; --s-4: 1rem; --s-5: 1.5rem;
  --s-6: 2rem; --s-7: 3rem; --s-8: 4.5rem; --s-9: 6rem;

  --r-none: 0;
  --r-sm: 2px;
  --r-md: 6px;

  --sh-stack: 0 26px 40px -30px rgba(30, 42, 34, 0.75);
  --sh-header: 0 8px 18px -14px rgba(30, 42, 34, 0.5);
  --sh-block: 6px 6px 0 var(--c-ink);

  --header-h: 68px;
  --max-w: 1160px;
  --ease: cubic-bezier(0.2, 0.7, 0.2, 1);
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + var(--s-4)); }
body { margin: 0; font-family: var(--f-body); font-size: 1rem; line-height: 1.6; color: var(--c-ink); background: var(--c-concrete); overflow-x: hidden; }
img { max-width: 100%; display: block; }
a { color: var(--c-freight); text-underline-offset: 3px; }
a:hover { color: var(--c-ink); }
:focus-visible { outline: 3px solid var(--c-freight); outline-offset: 3px; }
h1, h2, h3 { margin: 0; line-height: 1.05; }
h1, h2 { font-family: var(--f-stencil); font-weight: 400; }
h2 { font-size: clamp(2rem, 7.5vw, 3.4rem); }
h3 { font-size: 1.125rem; font-weight: 700; }
p { margin: 0; }

.container { width: 100%; max-width: var(--max-w); margin: 0 auto; padding: 0 var(--s-4); }
.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip-link { position: absolute; left: var(--s-4); top: var(--s-2); z-index: 100; background: var(--c-ink); color: var(--c-white); padding: var(--s-2) var(--s-4); transform: translateY(-160%); }
.skip-link:focus { transform: translateY(0); color: var(--c-white); }

/* Buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; min-height: 48px; padding: var(--s-3) var(--s-5); font: 600 1rem/1.2 var(--f-body); border: 2px solid var(--c-ink); border-radius: var(--r-none); text-decoration: none; cursor: pointer; transition: transform 0.15s var(--ease); }
.btn:active { transform: translate(2px, 2px); }
.btn-primary { background: var(--c-freight); border-color: var(--c-freight); color: var(--c-white); }
.btn-primary:hover { background: var(--c-freight-dark); border-color: var(--c-freight-dark); color: var(--c-white); }
.btn-outline { background: transparent; color: var(--c-ink); }
.btn-outline:hover { background: var(--c-ink); color: var(--c-white); }
.btn-block { width: 100%; }

/* Header */
.site-header { position: sticky; top: 0; z-index: 50; background: var(--c-concrete); border-bottom: 2px solid var(--c-ink); }
.site-header.is-scrolled { box-shadow: var(--sh-header); }
.header-inner { display: flex; align-items: center; justify-content: space-between; gap: var(--s-3); height: var(--header-h); }
.brand { display: flex; align-items: center; gap: var(--s-3); color: var(--c-ink); text-decoration: none; }
.brand:hover { color: var(--c-ink); }
.brand-mark { width: 40px; height: 40px; flex-shrink: 0; }
.brand-text { display: flex; align-items: baseline; gap: var(--s-2); }
.brand-name { font-family: var(--f-stencil); font-size: 1.45rem; line-height: 1; }
.brand-sub { font-size: 0.875rem; font-weight: 600; color: var(--c-muted); }

.burger { width: 48px; height: 48px; flex-shrink: 0; display: inline-flex; flex-direction: column; justify-content: center; align-items: center; gap: 5px; background: var(--c-pine); border: 2px solid var(--c-ink); border-radius: var(--r-none); cursor: pointer; padding: 0; }
.burger-line { width: 22px; height: 3px; background: var(--c-ink); transition: transform 0.2s var(--ease), opacity 0.2s var(--ease); }
.burger[aria-expanded="true"] .burger-line:nth-child(1) { transform: translateY(8px) rotate(45deg); }
.burger[aria-expanded="true"] .burger-line:nth-child(2) { opacity: 0; }
.burger[aria-expanded="true"] .burger-line:nth-child(3) { transform: translateY(-8px) rotate(-45deg); }

.site-nav { position: absolute; left: 0; right: 0; top: 100%; background: var(--c-concrete); border-bottom: 2px solid var(--c-ink); opacity: 0; transform: translateY(-10px); visibility: hidden; transition: opacity 0.2s var(--ease), transform 0.2s var(--ease), visibility 0s linear 0.2s; }
.site-nav.is-open { opacity: 1; transform: translateY(0); visibility: visible; transition: opacity 0.2s var(--ease), transform 0.2s var(--ease); }
.nav-list { list-style: none; margin: 0; padding: var(--s-2) var(--s-4) var(--s-5); }
.nav-list a { display: block; padding: var(--s-3) 0; color: var(--c-ink); font-weight: 600; text-decoration: none; border-bottom: 1px solid var(--c-line); }
.nav-list a:hover { color: var(--c-freight); }
.nav-list li:last-child a { border-bottom: 0; }
.nav-list .nav-cta { margin-top: var(--s-3); text-align: center; background: var(--c-freight); color: var(--c-white); }
.nav-list .nav-cta:hover { background: var(--c-freight-dark); color: var(--c-white); }

/* Hero */
.hero { padding: var(--s-7) 0 0; overflow: hidden; }
.hero-grid { display: grid; gap: var(--s-6); }
.hero-place { display: inline-block; font-weight: 700; padding: var(--s-1) var(--s-3); background: var(--c-pine); margin-bottom: var(--s-4); }
.hero-title { font-size: clamp(2.5rem, 11.5vw, 5rem); line-height: 0.98; max-width: 14ch; }
.lead { margin-top: var(--s-5); color: var(--c-muted); font-size: 1.0625rem; max-width: 54ch; }
.hero-actions { margin-top: var(--s-6); display: flex; flex-wrap: wrap; gap: var(--s-3); }
.hero-actions .btn { flex: 1 1 210px; }

/* Hero yard: pallet stack */
.yard { position: relative; display: flex; flex-direction: column; align-items: center; justify-content: flex-end; min-height: 300px; padding-top: var(--s-5); }
.stack { position: relative; width: min(100%, 300px); display: grid; filter: drop-shadow(var(--sh-stack)); }
.load { display: grid; grid-template-columns: 1.2fr 1fr; gap: 6px; padding: 0 12px; }
.load span { height: 96px; background: var(--c-pine-light); border: 3px solid var(--c-ink); background-image: linear-gradient(180deg, transparent 44%, var(--c-freight) 44% 56%, transparent 56%); }
.load span:nth-child(2) { height: 72px; align-self: end; }
.pallet { position: relative; height: 44px; margin-top: -2px; animation: drop 0.55s var(--ease) both; }
.pallet::before, .pallet::after { content: ""; position: absolute; left: 0; right: 0; background: var(--c-pine); border: 3px solid var(--c-ink); }
.pallet::before { top: 0; height: 15px; background-image: repeating-linear-gradient(90deg, transparent 0 46px, var(--c-pine-dark) 46px 49px); }
.pallet::after { bottom: 0; height: 12px; }
.block { position: absolute; top: 12px; bottom: 9px; width: 34px; background: var(--c-pine-dark); border: 3px solid var(--c-ink); border-top: 0; border-bottom: 0; }
.block:nth-child(1) { left: 6px; }
.block:nth-child(2) { left: 50%; margin-left: -17px; }
.block:nth-child(3) { right: 6px; }
.pallet-1 { animation-delay: 0.1s; }
.pallet-2 { animation-delay: 0.35s; }
.pallet-3 { animation-delay: 0.6s; }
.load { animation: drop 0.55s var(--ease) 0.85s both; }
.dock { width: 100%; height: 26px; margin-top: 0; background: var(--c-ink); background-image: repeating-linear-gradient(-45deg, var(--c-ink) 0 14px, var(--c-pine) 14px 28px); border-top: 4px solid var(--c-ink); }
@keyframes drop { from { opacity: 0; transform: translateY(-48px); } to { opacity: 1; transform: translateY(0); } }

/* Sections */
.section { padding: var(--s-8) 0; }
.section-head { max-width: 640px; margin-bottom: var(--s-6); }
.section-head p { margin-top: var(--s-3); color: var(--c-muted); font-size: 1.0625rem; }

/* Pallets */
.pallet-grid { display: grid; gap: var(--s-7); }
.anatomy { margin: 0; background: var(--c-white); border: 2px solid var(--c-ink); box-shadow: var(--sh-block); padding: var(--s-5) var(--s-4); }
.anatomy-drawing { position: relative; height: 110px; margin: 0 auto var(--s-5); max-width: 380px; }
.a-deck, .a-bottom { position: absolute; left: 0; right: 0; background: var(--c-pine); border: 3px solid var(--c-ink); }
.a-deck { top: 10px; height: 26px; background-image: repeating-linear-gradient(90deg, transparent 0 54px, var(--c-pine-dark) 54px 58px); }
.a-bottom { bottom: 10px; height: 20px; }
.a-block { position: absolute; top: 33px; bottom: 27px; width: 18%; background: var(--c-pine-dark); border-left: 3px solid var(--c-ink); border-right: 3px solid var(--c-ink); }
.a-block-1 { left: 3%; }
.a-block-2 { left: 41%; }
.a-block-3 { right: 3%; }
.a-pocket { position: absolute; top: 44px; height: 30px; width: 16%; border: 2px dashed var(--c-freight); }
.a-pocket-1 { left: 23%; }
.a-pocket-2 { right: 23%; }
.anatomy-key { list-style: none; margin: 0; padding: 0; display: grid; gap: var(--s-3); }
.anatomy-key li { color: var(--c-muted); padding-left: var(--s-4); border-left: 4px solid var(--c-pine); }
.anatomy-key strong { display: block; color: var(--c-ink); }
.anatomy-key li:last-child { border-left-color: var(--c-freight); }
.pallet-work { display: grid; align-content: start; }
.work { padding: var(--s-5) 0; border-top: 2px solid var(--c-ink); }
.work:last-child { border-bottom: 2px solid var(--c-ink); }
.work h3 { font-family: var(--f-stencil); font-weight: 400; font-size: 1.9rem; }
.work p { margin-top: var(--s-2); color: var(--c-muted); max-width: 48ch; }

/* Freight manifest */
.section-freight { background: var(--c-freight); color: var(--c-white); }
.section-freight .section-head p { color: #E3EAF3; }
.freight-grid { display: grid; gap: var(--s-2); }
.manifest { margin: 0; background: var(--c-white); color: var(--c-ink); border: 2px solid var(--c-ink); box-shadow: var(--sh-block); }
.manifest div { display: grid; gap: 2px; padding: var(--s-4); border-bottom: 2px dashed var(--c-line); }
.manifest div:last-child { border-bottom: 0; }
.manifest dt { font-size: 0.875rem; font-weight: 600; color: var(--c-muted); }
.manifest dd { margin: 0; font-family: var(--f-stencil); font-size: 1.5rem; line-height: 1.15; }

/* Request tags */
.request-grid { display: grid; gap: var(--s-2); }
.tags { list-style: none; margin: 0; padding: 0; display: grid; gap: var(--s-4); }
.tags li { position: relative; background: var(--c-white); border: 2px solid var(--c-ink); padding: var(--s-4) var(--s-4) var(--s-4) calc(var(--s-4) + 22px); }
.tags li::before { content: ""; position: absolute; left: var(--s-4); top: 50%; width: 10px; height: 10px; margin-top: -5px; border-radius: 50%; border: 2px solid var(--c-ink); background: var(--c-concrete); }
.tags p { margin-top: var(--s-1); color: var(--c-muted); }

/* Company stamp: signature */
.section-wood { background-color: var(--c-pine); background-image: repeating-linear-gradient(180deg, transparent 0 58px, var(--c-pine-dark) 58px 62px); }
.section-wood .section-head { background: var(--c-concrete); padding: var(--s-4); border: 2px solid var(--c-ink); }
.company-grid { display: grid; gap: var(--s-2); }
.stamp { border: 4px solid var(--c-ink); padding: 6px; background: rgba(255, 255, 255, 0.9); transform: rotate(-1.2deg); }
.stamp-inner { margin: 0; border: 2px solid var(--c-ink); padding: var(--s-4); display: grid; gap: var(--s-3); overflow-wrap: anywhere; }
.stamp-inner div { display: grid; gap: 0; border-bottom: 2px solid var(--c-ink); padding-bottom: var(--s-3); }
.stamp-inner div:last-child { border-bottom: 0; padding-bottom: 0; }
.stamp-inner dt { font-size: 0.875rem; font-weight: 600; color: var(--c-muted); }
.stamp-inner dd { margin: 0; font-family: var(--f-stencil); font-size: 1.35rem; line-height: 1.2; }
.stamp-inner .stamp-name dd { font-size: clamp(1.8rem, 8vw, 2.8rem); line-height: 1; overflow-wrap: normal; }

/* Contact */
.contact-grid { display: grid; gap: var(--s-7); }
.contact-info > p { margin-top: var(--s-3); color: var(--c-muted); max-width: 46ch; }
.contact-list { list-style: none; margin: var(--s-5) 0 0; padding: 0; }
.contact-list li { display: grid; gap: 2px; padding: var(--s-3) 0; border-bottom: 1px solid var(--c-line); }
.contact-list a, .contact-list span:not(.contact-label) { font-weight: 600; overflow-wrap: anywhere; }
.contact-label { font-size: 0.875rem; color: var(--c-muted); }
.form-wrap { background: var(--c-white); border: 2px solid var(--c-ink); box-shadow: var(--sh-block); padding: var(--s-5) var(--s-4); }
.request-form { display: grid; gap: var(--s-4); }
.field { display: grid; gap: var(--s-1); align-content: start; }
.field-pair { display: grid; gap: var(--s-4); }
.field label { font-weight: 600; }
.optional { font-weight: 400; color: var(--c-muted); }
.field input, .field select, .field textarea { width: 100%; min-height: 48px; padding: var(--s-3); font: 400 1rem/1.4 var(--f-body); color: var(--c-ink); background: var(--c-white); border: 2px solid var(--c-muted); border-radius: var(--r-sm); }
.field textarea { resize: vertical; min-height: 120px; }
.field input::placeholder, .field textarea::placeholder { color: #66706A; }
.field input:focus, .field select:focus, .field textarea:focus { outline: 3px solid var(--c-pine); outline-offset: 0; border-color: var(--c-ink); }
.field [aria-invalid="true"] { border-color: var(--c-error); }
.field-error { min-height: 1.2em; font-size: 0.875rem; font-weight: 600; color: var(--c-error); }
.field-check { grid-template-columns: 24px 1fr; column-gap: var(--s-3); }
.field-check input { width: 22px; height: 22px; min-height: 0; margin: 2px 0 0; padding: 0; accent-color: var(--c-freight); }
.field-check label { font-weight: 400; }
.field-check .field-error { grid-column: 1 / -1; }
.form-success { display: grid; gap: var(--s-4); animation: pop-in 0.35s var(--ease) both; }
.form-success[hidden] { display: none; }
.form-success h3 { font-family: var(--f-stencil); font-weight: 400; font-size: 1.7rem; }
.form-success:focus { outline: none; }
@keyframes pop-in { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: translateY(0); } }

/* Legal pages */
.page-hero { padding: var(--s-7) 0 var(--s-6); border-bottom: 2px solid var(--c-ink); background-color: var(--c-pine); background-image: repeating-linear-gradient(180deg, transparent 0 58px, var(--c-pine-dark) 58px 62px); }
.page-hero .container > * { max-width: 640px; }
.page-hero h1 { font-size: clamp(2.4rem, 10vw, 4.2rem); line-height: 1; }
.page-intro { margin-top: var(--s-4); font-size: 1.0625rem; font-weight: 500; }
.updated { display: inline-block; margin-top: var(--s-4); padding: var(--s-1) var(--s-3); background: var(--c-white); border: 2px solid var(--c-ink); font-size: 0.875rem; font-weight: 700; }
.prose { max-width: 760px; overflow-wrap: anywhere; }
.prose h2 { font-size: 1.8rem; margin-top: var(--s-6); }
.prose h2:first-child { margin-top: 0; }
.prose p { margin-top: var(--s-3); max-width: 70ch; }
.id-block { margin-top: var(--s-5); padding: var(--s-4); background: var(--c-white); border: 2px solid var(--c-ink); box-shadow: var(--sh-block); }
.page-404 { min-height: 60vh; }
.nf-code { font-family: var(--f-stencil); font-size: clamp(5rem, 28vw, 10rem); line-height: 0.9; }

/* Footer */
.site-footer { background: var(--c-ink); color: var(--c-on-dark); padding: var(--s-7) 0 var(--s-5); border-top: 8px solid var(--c-pine); }
.site-footer a { color: var(--c-white); }
.site-footer a:hover { color: var(--c-pine-light); }
.footer-top { display: grid; gap: var(--s-5); padding-bottom: var(--s-5); border-bottom: 1px solid rgba(211, 216, 208, 0.3); }
.footer-brand { display: flex; align-items: center; gap: var(--s-3); }
.footer-nav ul { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: var(--s-2) var(--s-5); }
.footer-nav a { font-weight: 600; text-decoration: none; display: inline-block; padding: var(--s-1) 0; }
.legal { padding-top: var(--s-5); font-size: 0.8125rem; line-height: 1.6; color: var(--c-on-dark); overflow-wrap: anywhere; }
.legal-bottom { margin-top: var(--s-3); display: flex; flex-wrap: wrap; justify-content: space-between; gap: var(--s-2) var(--s-5); }
.legal-links { display: flex; gap: var(--s-4); }

@media (min-width: 480px) {
  .container { padding: 0 var(--s-5); }
  .field-pair { grid-template-columns: 1fr 1fr; }
  .form-wrap, .anatomy { padding: var(--s-6) var(--s-5); }
  .hero-actions .btn { flex: 0 0 auto; }
  .stamp-inner { padding: var(--s-5); }
}

@media (min-width: 768px) {
  .section { padding: var(--s-9) 0; }
  .yard { min-height: 360px; }
  .stack { width: 380px; }
  .load span { height: 120px; }
  .load span:nth-child(2) { height: 90px; }
  .pallet { height: 52px; }
  .block { width: 42px; }
  .block:nth-child(2) { margin-left: -21px; }
  .tags { grid-template-columns: 1fr 1fr; }
  .manifest div { grid-template-columns: 200px 1fr; gap: var(--s-4); align-items: baseline; }
  .stamp-inner div { grid-template-columns: 190px 1fr; gap: var(--s-4); align-items: baseline; }
  .stamp-inner .stamp-name { grid-template-columns: 1fr; }
  .contact-list li { grid-template-columns: 120px 1fr; gap: var(--s-4); align-items: baseline; }
  .footer-top { grid-template-columns: 1fr auto; align-items: center; }
}

@media (min-width: 1024px) {
  :root { --header-h: 80px; }
  .burger { display: none; }
  .site-nav { position: static; opacity: 1; transform: none; visibility: visible; background: transparent; border: 0; transition: none; }
  .nav-list { display: flex; align-items: center; gap: var(--s-5); padding: 0; }
  .nav-list a { border: 0; padding: var(--s-2) 0; }
  .nav-list .nav-cta { margin: 0; padding: var(--s-2) var(--s-5); }
  .hero { padding-top: var(--s-8); }
  .hero-grid { grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); align-items: end; gap: var(--s-7); }
  .hero-copy { padding-bottom: var(--s-8); }
  .pallet-grid { grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); gap: var(--s-8); align-items: start; }
  .freight-grid, .request-grid, .company-grid { grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: var(--s-7); align-items: start; }
  .contact-grid { grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); gap: var(--s-8); align-items: start; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: 0.01ms !important; animation-delay: 0ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; }
}
