/* DanEst Timber — redesigned
   Subject: Estonian timber / wood processing & machine building
   Palette derived from the company's world: bark, timber, pine, birch, sawdust
   Type: Zilla Slab (stamped woodcut display) / Inter (body) / IBM Plex Mono (spec tags)
*/

:root {
  --bark: #2b2118;
  --timber: #8a5a2b;
  --timber-deep: #6b431f;
  --pine: #4e6b3a;
  --birch: #f4ecdd;
  --sawdust: #c9a66b;
  --ash: #e7ddcb;
  --paper: #fbf6ec;

  --maxw: 1080px;
  --radius: 4px;

  --font-display: "Zilla Slab", Georgia, "Times New Roman", serif;
  --font-body: "Inter", system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
  --font-mono: "IBM Plex Mono", ui-monospace, SFMono-Regular, Menlo, monospace;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--bark);
  background: var(--birch);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

a { color: var(--timber-deep); text-decoration: none; }
a:hover { text-decoration: underline; }

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

/* ---------- Top bar ---------- */
.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(251, 246, 236, 0.92);
  backdrop-filter: blur(6px);
  border-bottom: 1px solid var(--ash);
}
.topbar-inner {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0.75rem 1.25rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}
.brand {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  font-family: var(--font-mono);
  font-weight: 600;
  letter-spacing: 0.04em;
  color: var(--bark);
}
.brand img {
  height: 38px;
  width: auto;
  display: block;
}
.brand .brand-name { font-size: 0.95rem; line-height: 1.1; }
.brand .brand-name small { display:block; font-size:0.62rem; letter-spacing:0.18em; color: var(--timber-deep); }

.nav {
  display: flex;
  gap: 1.4rem;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.nav a { color: var(--bark); }
.nav a:hover { color: var(--timber-deep); text-decoration: none; }

/* ---------- Hero with wood-grain signature ---------- */
.hero {
  position: relative;
  color: var(--birch);
  background: var(--bark);
  overflow: hidden;
  padding: 5.5rem 1.25rem 6rem;
}
.grain {
  position: absolute;
  inset: 0;
  pointer-events: none;
  opacity: 0.9;
}
.grain svg { width: 100%; height: 100%; display: block; }

.hero-inner {
  position: relative;
  z-index: 2;
  max-width: var(--maxw);
  margin: 0 auto;
}
.eyebrow {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--sawdust);
  margin: 0 0 1.1rem;
}
.hero h1 {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(2.6rem, 7vw, 5rem);
  line-height: 0.98;
  margin: 0 0 0.6rem;
  letter-spacing: -0.01em;
}
.hero h1 .stamp {
  display: block;
  font-size: 0.42em;
  letter-spacing: 0.22em;
  color: var(--sawdust);
  font-weight: 500;
  margin-top: 0.6rem;
}
.hero p.lead {
  max-width: 46ch;
  font-size: 1.12rem;
  color: var(--ash);
  margin: 1.4rem 0 0;
}
.hero-actions {
  margin-top: 2.2rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.8rem;
}
.btn {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 0.82rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 0.85rem 1.4rem;
  border-radius: var(--radius);
  border: 1px solid transparent;
  cursor: pointer;
}
.btn-primary { background: var(--sawdust); color: var(--bark); }
.btn-primary:hover { background: #d8b878; text-decoration: none; }
.btn-ghost { border-color: var(--sawdust); color: var(--sawdust); }
.btn-ghost:hover { background: rgba(201,166,107,0.12); text-decoration: none; }

/* ---------- Sections ---------- */
.section {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 4.5rem 1.25rem;
}
.section + .section { padding-top: 0; }

.section-head { margin-bottom: 2.4rem; }
.section-tag {
  font-family: var(--font-mono);
  font-size: 0.74rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--pine);
  margin: 0 0 0.6rem;
}
.section h2 {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(1.8rem, 4vw, 2.6rem);
  margin: 0;
  line-height: 1.05;
}
.section p { max-width: 62ch; }

/* Profile / cards grid */
.cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 1.25rem;
}
.card {
  background: var(--paper);
  border: 1px solid var(--ash);
  border-top: 3px solid var(--timber);
  border-radius: var(--radius);
  padding: 1.6rem 1.5rem;
}
.card h3 {
  font-family: var(--font-display);
  font-size: 1.25rem;
  margin: 0 0 0.5rem;
}
.card p { margin: 0; color: var(--timber-deep); font-size: 0.96rem; }

/* Activities list */
.acts {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1.25rem;
}
.act {
  padding: 1.5rem 0;
  border-top: 1px solid var(--ash);
}
.act .label {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--pine);
}
.act h3 {
  font-family: var(--font-display);
  font-size: 1.4rem;
  margin: 0.4rem 0 0.5rem;
}
.act p { margin: 0; }

/* Contacts */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
}
.contact-block {
  background: var(--paper);
  border: 1px solid var(--ash);
  border-radius: var(--radius);
  padding: 1.8rem 1.6rem;
}
.contact-block h3 {
  font-family: var(--font-display);
  font-size: 1.35rem;
  margin: 0 0 0.2rem;
}
.contact-block .role {
  font-family: var(--font-mono);
  font-size: 0.74rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--pine);
  margin: 0 0 1rem;
}
.contact-block dl {
  margin: 0;
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 0.35rem 0.9rem;
  font-size: 0.95rem;
}
.contact-block dt {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--timber);
  align-self: center;
}
.contact-block dd { margin: 0; }

.address-box {
  margin-top: 2rem;
  background: var(--bark);
  color: var(--birch);
  border-radius: var(--radius);
  padding: 1.8rem 1.6rem;
}
.address-box .label {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--sawdust);
  margin: 0 0 0.8rem;
}
.address-box address {
  font-style: normal;
  line-height: 1.8;
}
.address-box a { color: var(--sawdust); }

/* ---------- Footer ---------- */
.footer {
  background: var(--bark);
  color: var(--ash);
  padding: 2.6rem 1.25rem;
}
.footer-inner {
  max-width: var(--maxw);
  margin: 0 auto;
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  align-items: center;
  justify-content: space-between;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  letter-spacing: 0.04em;
}
.footer a { color: var(--sawdust); }

/* ---------- Responsive ---------- */
@media (max-width: 720px) {
  .nav { display: none; }
  .contact-grid { grid-template-columns: 1fr; }
  .hero { padding: 4rem 1.25rem 4.5rem; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { animation: none !important; transition: none !important; }
}
