:root {
  --bg-canvas: #f7f5f0;
  --bg-surface: #ffffff;
  --bg-surface-hover: #fcfcfc;
  --text-primary: #111111;
  --text-muted: #555555;
  --accent-primary: #d62828;
  --accent-secondary: #9a1b1b;
  --border-subtle: #eaddd7;
  
  --ease-kinetic: cubic-bezier(0.16, 1, 0.3, 1);
  --shadow-elevation: 0 12px 32px -4px rgba(17, 17, 17, 0.15);
  --glow-accent: 0 0 24px -4px rgba(214, 40, 40, 0.4);
}

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

body, html {
  margin: 0;
  padding: 0;
  font-family: Charter, Cambria, Georgia, serif;
  background-color: var(--bg-canvas);
  color: var(--text-primary);
  line-height: 1.6;
  overflow-wrap: anywhere;
  hyphens: auto;
  scroll-behavior: smooth;
}

h1, h2, h3, h4, h5, h6 {
  margin-top: 0;
  line-height: 1.2;
  font-weight: bold;
}

a {
  color: var(--text-primary);
  text-decoration: none;
  transition: color 0.3s var(--ease-kinetic);
}

a:hover {
  color: var(--accent-primary);
}

img {
  max-width: 100%;
  height: auto;
  border-radius: 20px;
  object-fit: cover;
  display: block;
}

.label-caps {
  font-variant-caps: small-caps;
  font-weight: bold;
  letter-spacing: 0.05em;
  text-transform: lowercase;
}

/* Container */
.container {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 24px;
}

.text-container {
  max-width: 72ch;
  margin: 0 auto;
}

/* Header */
header {
  position: static;
  background: transparent;
  padding: 24px 0;
  z-index: 100;
}

.header-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.logo {
  font-size: 1.25rem;
  font-weight: bold;
  color: var(--text-primary);
}

.nav-links {
  display: flex;
  gap: 32px;
}

.nav-links a {
  font-variant-caps: small-caps;
  font-weight: bold;
  font-size: 1.1rem;
}

#mobile-toggle {
  display: none;
  background: none;
  border: none;
  font-size: 2rem;
  color: var(--text-primary);
  cursor: pointer;
  padding: 0 10px;
}

@media (max-width: 768px) {
  .nav-links {
    display: none;
    position: absolute;
    top: 80px;
    left: 0;
    width: 100%;
    background: var(--bg-surface);
    flex-direction: column;
    padding: 24px;
    box-shadow: var(--shadow-elevation);
    text-align: center;
    z-index: 200;
  }
  .nav-links.active {
    display: flex;
  }
  #mobile-toggle {
    display: block;
  }
}

/* Button */
.btn {
  display: inline-block;
  background: var(--accent-primary);
  color: #fff;
  border: none;
  padding: 14px 32px;
  border-radius: 50px;
  font-variant-caps: small-caps;
  font-weight: bold;
  font-size: 1.1rem;
  cursor: pointer;
  transition: transform 0.4s var(--ease-kinetic), box-shadow 0.4s var(--ease-kinetic), background 0.4s var(--ease-kinetic);
}

.btn:hover {
  background: var(--accent-secondary);
  color: #fff;
  transform: translateY(-3px) scale(1.02);
  box-shadow: var(--shadow-elevation), var(--glow-accent);
}

/* Hero Section */
.hero {
  padding: 80px 0;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  align-items: center;
}

.hero h1 {
  font-size: 3.5rem;
  margin-bottom: 24px;
}

.hero p {
  font-size: 1.25rem;
  color: var(--text-muted);
  margin-bottom: 32px;
}

.hero-images {
  position: relative;
  height: 450px;
  width: 100%;
}

.hero-img {
  position: absolute;
  border-radius: 20px;
  object-fit: cover;
  box-shadow: var(--shadow-elevation);
  transition: transform 0.6s var(--ease-kinetic);
}

.hero-images:hover .hero-img-1 { transform: scale(1.02) translate(-10px, -10px); }
.hero-images:hover .hero-img-2 { transform: scale(1.02) translate(10px, 10px); }

.hero-img-1 {
  width: 65%;
  height: 75%;
  top: 0;
  left: 0;
  z-index: 1;
}

.hero-img-2 {
  width: 55%;
  height: 65%;
  bottom: 0;
  right: 5%;
  z-index: 2;
}

.hero-img-3 {
  width: 45%;
  height: 55%;
  top: 15%;
  right: -5%;
  z-index: 3;
}

@media (max-width: 1024px) {
  .hero { grid-template-columns: 1fr; text-align: center; }
  .hero-images { max-width: 600px; margin: 0 auto; }
}

@media (max-width: 480px) {
  .hero h1 { font-size: 2.5rem; }
  .hero-images { height: 300px; }
}

/* Sections & Clip-Paths */
.section-band {
  padding: 100px 0;
}

.bg-alt {
  background-color: var(--bg-surface);
}

.clip-curve {
  clip-path: ellipse(150% 100% at 50% 100%);
  margin-bottom: -50px;
  padding-bottom: 150px;
}

.clip-diagonal {
  clip-path: polygon(0 0, 100% 5vw, 100% 100%, 0 calc(100% - 5vw));
  margin-top: -5vw;
  padding-top: calc(100px + 5vw);
  padding-bottom: calc(100px + 5vw);
}

/* Cards Engine */
.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 32px;
  margin-top: 48px;
}

.machinery-card {
  background: var(--bg-surface);
  border-radius: 20px;
  padding: 24px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.05);
  position: relative;
  transition: transform 0.4s var(--ease-kinetic), box-shadow 0.4s var(--ease-kinetic);
  display: flex;
  flex-direction: column;
}

.machinery-card:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-elevation);
}

.machinery-card img {
  width: 100%;
  height: 220px;
  margin-bottom: 24px;
}

.card-badge {
  position: absolute;
  top: 10px;
  right: 10px;
  background: var(--accent-primary);
  color: #fff;
  padding: 6px 16px;
  border-radius: 50px;
  font-variant-caps: small-caps;
  font-weight: bold;
  font-size: 0.9rem;
  z-index: 10;
  box-shadow: 0 4px 8px rgba(0,0,0,0.2);
}

.machinery-card h3 {
  margin-bottom: 12px;
}

.machinery-card p {
  color: var(--text-muted);
  flex-grow: 1;
}

/* Bento Grid */
.bento-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  grid-template-rows: auto;
  gap: 24px;
  margin-top: 48px;
}

.bento-item {
  background: var(--bg-surface);
  border-radius: 20px;
  padding: 32px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.05);
  position: relative;
  overflow: hidden;
}

.bento-item:nth-child(1) { grid-column: span 2; grid-row: span 2; }
.bento-item:nth-child(2) { grid-column: span 2; }
.bento-item:nth-child(3) { grid-column: span 1; }
.bento-item:nth-child(4) { grid-column: span 1; }

@media (max-width: 768px) {
  .bento-grid { grid-template-columns: 1fr; }
  .bento-item:nth-child(1), .bento-item:nth-child(2), .bento-item:nth-child(3), .bento-item:nth-child(4) { grid-column: span 1; grid-row: auto; }
}

/* Tables / Matrices */
.table-wrapper {
  overflow-x: auto;
  margin: 40px 0;
  background: var(--bg-surface);
  border-radius: 20px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.05);
  padding: 24px;
}

table {
  width: 100%;
  border-collapse: collapse;
  min-width: 600px;
}

th, td {
  padding: 16px;
  text-align: left;
  border-bottom: 1px solid var(--border-subtle);
}

th {
  font-variant-caps: small-caps;
  color: var(--text-muted);
}

/* Forms */
.rugged-form {
  background: var(--bg-surface);
  padding: 40px;
  border-radius: 20px;
  box-shadow: var(--shadow-elevation);
  margin-top: 40px;
}

.form-group {
  margin-bottom: 24px;
}

.form-group label {
  display: block;
  margin-bottom: 8px;
  font-weight: bold;
}

.form-group input, .form-group select, .form-group textarea {
  width: 100%;
  padding: 16px;
  border: 2px solid var(--border-subtle);
  border-radius: 12px;
  font-family: inherit;
  font-size: 1rem;
  background: var(--bg-canvas);
  color: var(--text-primary);
  transition: border-color 0.3s var(--ease-kinetic);
}

.form-group input:focus, .form-group select:focus, .form-group textarea:focus {
  outline: none;
  border-color: var(--text-primary);
}

/* Animations */
.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: all 0.8s var(--ease-kinetic);
}

.reveal-visible {
  opacity: 1;
  transform: translateY(0);
}

/* Footer */
footer {
  background: var(--text-primary);
  color: #fff;
  padding: 80px 0 40px;
  margin-top: 80px;
}

.footer-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 48px;
  margin-bottom: 48px;
}

.footer-col h4 {
  font-variant-caps: small-caps;
  color: var(--border-subtle);
  margin-bottom: 24px;
}

.footer-col a {
  display: block;
  color: #ccc;
  margin-bottom: 12px;
}

.footer-col a:hover {
  color: var(--accent-primary);
}

.footer-legal {
  border-top: 1px solid rgba(255,255,255,0.1);
  padding-top: 24px;
  text-align: center;
  font-size: 0.9rem;
  color: #888;
}

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