:root {
  color-scheme: light;
  --bg: #fafafa;
  --card: #ffffff;
  --text: #222;
  --muted: #666;
  --accent: #1a7f37; /* green, purposeful */
  --border: #e5e5e5;
  --shadow: 0 10px 28px rgba(0,0,0,0.10);
  --footer-h: 44px;
  --ff-body: system-ui, -apple-system, Segoe UI, Roboto, Ubuntu, Cantarell, "Helvetica Neue", Arial, "Noto Sans", "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol";
  --ff-head: 'Montserrat', system-ui, -apple-system, Segoe UI, Roboto, "Helvetica Neue", Arial, "Noto Sans";
}

* { box-sizing: border-box; }
html, body { height: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--ff-body);
  font-size: 16px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

.app {
  /* height: 100vh;
  display: grid;
  grid-template-rows: auto 1fr; */
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.tabs {
  display: grid;
  grid-auto-flow: column;
  gap: 8px;
  padding: 16px;
  background: var(--bg);
  border-bottom: 1px solid var(--border);
  align-items: center;
}
/* center and narrow overall content */
.tabs,
.panel {
  max-width: 1200px;
  width: 100%;
  margin-left: auto;
  margin-right: auto;
}

.tab {
  appearance: none;
  border: 1px solid var(--border);
  background: var(--card);
  color: var(--text);
  padding: 10px 12px;
  border-radius: 10px;
  font-weight: 600;
  min-height: 44px;
  font-family: var(--ff-head);
  cursor: pointer;
  transition:
    background-color 160ms ease,
    color 160ms ease,
    box-shadow 160ms ease,
    transform 160ms ease,
    border-color 160ms ease;
}

.tab:hover {
  background: #f3faf5;
  border-color: var(--accent);
  box-shadow: 0 4px 10px rgba(0,0,0,0.08);
  transform: translateY(-1px);
}

.tab:active {
  transform: translateY(0);
  box-shadow: 0 2px 6px rgba(0,0,0,0.10);
}

.tab.active {
  border-color: var(--accent);
  box-shadow: inset 0 0 0 2px var(--accent);
  background: #f2fbf6;
}
/* micro pulse animation on tab activation */
.tab.pulse {
  animation: tabPulse 380ms ease-out;
}
@keyframes tabPulse {
  0% { box-shadow: inset 0 0 0 2px var(--accent), 0 0 0 0 rgba(26,127,55,0.0); }
  40% { box-shadow: inset 0 0 0 2px var(--accent), 0 0 0 8px rgba(26,127,55,0.18); }
  100% { box-shadow: inset 0 0 0 2px var(--accent), 0 0 0 0 rgba(26,127,55,0.0); }
}

.panel {
  /* position: relative;
  padding: 40px;
  padding-bottom: calc(40px + var(--footer-h)); */
  position: static;
  padding: 24px 16px;
  flex: 1 0 auto;
}

.view {
  /* position: absolute;
  top: 40px;
  right: 40px;
  left: 40px;
  bottom: calc(40px + var(--footer-h)); */
  display: none;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 18px;
  box-shadow: var(--shadow);
  padding: 14px;
  /* overflow: auto; */ /* SINGLE scroll container per view – now body handles scrolling */
  margin-top: 8px;
}

.view.active { display: block; }

.split {
  display: grid;
  grid-template-columns: 1fr;
  grid-auto-rows: minmax(0,1fr);
  gap: 12px;
  /* height: 100%;  remove fixed height so content can grow naturally */
}

@media (min-width: 560px) {
  .split { grid-template-columns: 1.3fr 0.7fr; }
}

.text {
  /* overflow: auto;  remove inner scrolling to avoid second scrollbar */
  padding: 6px;
}

.text h2 {
  margin: 0 0 12px;
  font-size: 19px;
  position: relative;
  font-family: var(--ff-head);
}

.text h2::after {
  content: "";
  position: absolute;
  left: 0; bottom: -6px;
  width: 64px; height: 3px;
  background: var(--accent);
  border-radius: 2px;
}

.text p {
  margin: 10px 0;
  line-height: 1.5;
}

/* Reference grid */
.refs {
  margin-top: 10px;
}
.refs-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 6px;
}
.refs-grid img {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  border-radius: 8px;
  border: 1px solid var(--border);
  box-shadow: 0 4px 12px rgba(0,0,0,0.06);
}

.bullets {
  margin: 6px 0;
  padding-left: 18px;
}

.bullets li { margin-bottom: 4px; }

.media {
  display: grid;
  grid-template-rows: 1fr auto;
  gap: 8px;
  overflow: hidden;
}

.media.show-full { overflow: visible; place-items: center; }

.media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 10px;
  border: 1px solid var(--border);
}

.media img.rot90 {
  object-fit: contain;
  background: #fff;
  transform: rotate(90deg);
  transform-origin: center;
  max-width: 100%;
  max-height: 100%;
}

.actions { display: flex; gap: 8px; }

.btn {
  appearance: none;
  border: none;
  background: var(--accent);
  color: #fff;
  border-radius: 10px;
  padding: 10px 12px;
  min-height: 44px;
  box-shadow: 0 2px 0 rgba(0,0,0,0.08);
}

/* Carousel */
.carousel {
  position: relative;
  height: 100%;
  border: 1px solid var(--border);
  border-radius: 10px;
  overflow: hidden;
  background: #fff;
}

.car-track {
  display: flex;
  height: 100%;
  transition: transform 280ms ease;
}

.car-track img {
  flex: 0 0 100%;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.car-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 2;
  border: none;
  background: rgba(255,255,255,0.9);
  color: var(--text);
  width: 44px;
  height: 44px;
  border-radius: 22px;
  box-shadow: var(--shadow);
}

.car-btn.prev { left: 8px; }
.car-btn.next { right: 8px; }

/* Upload preview */
.upload {
  display: grid;
  grid-template-columns: 1fr;
  gap: 8px;
}

.preview {
  display: grid;
  grid-auto-flow: column;
  gap: 8px;
}

.preview img {
  width: 100%;
  max-width: 160px;
  height: 100px;
  object-fit: cover;
  border-radius: 8px;
  border: 1px solid var(--border);
}

/* Autosteering rolling stream */
/* .zigwrap {
  display: grid;
  gap: 6px;
  padding-right: 2px;
}

.zz-item {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
  align-items: stretch;
  transform: none;
}

.zz-item img {
  width: 100%;
  height: auto;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  border-radius: 10px;
  border: 1px solid var(--border);
  margin-left: 0;
  justify-self: start;
  box-shadow: 0 6px 18px rgba(0,0,0,0.06);
}

.zz-item .desc {
  background: transparent;
  border: none;
  border-radius: 10px;
  padding: 4px;
  transform: none;
  line-height: 1.5;
}

.zz-item .desc p,
.zz-item .desc li {
  line-height: 1.5;
}

.zz-item .desc h3 { margin: 0 0 4px; }

.zz-item:nth-child(odd) .desc { --dy: 4px; }
.zz-item:nth-child(even) .desc { --dy: -3px; }

.zz-item .mini {
  margin: 4px 0 0;
  padding-left: 14px;
}
.zz-item .mini li { margin-bottom: 2px; } */

/* New, független elrendezés az automata robotkormányzás szekcióhoz */
.auto-intro {
  margin-top: 24px;
  margin-bottom: 8px;
}

.auto-layout {
  display: grid;
  gap: 10px;
}

@media (min-width: 720px) {
  .auto-layout {
    grid-template-columns: minmax(0, 1.1fr) minmax(0, 1.3fr);
    align-items: flex-start;
  }
}

.auto-images {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
}
.auto-images img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 10px;
  border: 1px solid var(--border);
  box-shadow: 0 6px 18px rgba(0,0,0,0.06);
}

/* első kép legyen hangsúlyos nagyobb blokk */
.auto-images img:first-child {
  grid-column: 1 / span 2;
}

/* biztosítsd, hogy a "tractors svea.jpeg" teljes egészében látszódjon az előnézetben */
.auto-images img[src*="tractors svea.jpeg"] {
  object-fit: contain;
  background: #fff;
  grid-column: 1 / span 2;
}

/* új: második kép + alatta a videók teljes soron */
.auto-video-group {
  grid-column: 1 / span 2;
  display: grid;
  gap: 6px;
}
.auto-video-group img {
  width: 100%;
  height: auto;
  border-radius: 10px;
  border: 1px solid var(--border);
  box-shadow: 0 6px 18px rgba(0,0,0,0.06);
}
.auto-video-group video {
  width: 100%;
  height: auto;
  border-radius: 10px;
  border: 1px solid var(--border);
  box-shadow: 0 6px 18px rgba(0,0,0,0.06);
  background: #000;
}

.auto-text {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.auto-block h3 {
  margin: 0 0 4px;
  font-size: 16px;
}

.auto-block ul {
  margin: 0;
  padding-left: 18px;
}

.auto-block ul li {
  margin-bottom: 8px;
}

/* Remove old flip alignment (images always left, text right) */
/* .zz-item.flip { } */

/* Bottom sheet removed */
// .sheet-backdrop, .sheet { display: none; }

.auto-logo {
  display: flex;
  justify-content: center;
  align-items: center;
  margin-top: 4px;
  margin-bottom: 32px;
  gap: 220px;
  flex-wrap: wrap;
}

.auto-logo img {
  height: 120px;
  width: auto;
  object-fit: contain;
}

.brand img {
  height: 64px;
  width: auto;
  object-fit: contain;
}

.media.thumbs {
  display: grid;
  grid-template-columns: 2fr 1.4fr;
  grid-template-rows: 1fr 1fr;
  gap: 4px;
  align-items: stretch;
}

.media.thumbs > img:first-child {
  grid-column: 1;
  grid-row: 1 / span 2;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.media.thumbs .row.two {
  grid-column: 2;
  grid-row: 1 / span 2;
  display: grid;
  grid-template-rows: 1fr 1fr;
  gap: 4px;
}

.media.thumbs img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.media.thumbs .row.two img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.contact {
  margin-top: 14px;
}
.contact p:last-child { margin-top: 10px; }

.contact .highlight {
  position: relative;
  background: #f6fbf8;
  border-left: 4px solid var(--accent);
  border-radius: 12px;
  padding: 10px 12px 12px;
  box-shadow: 0 6px 18px rgba(26,127,55,0.08);
}
/* subtle decorative edge */
.contact .highlight::before {
  content: "";
  position: absolute;
  left: -6px; top: 10px; bottom: 10px;
  width: 6px;
  background: repeating-linear-gradient(
    to bottom,
    rgba(26,127,55,0.18), rgba(26,127,55,0.18) 6px,
    transparent 6px, transparent 12px
  );
  border-top-left-radius: 6px; border-bottom-left-radius: 6px;
}
.contact .highlight .price { font-weight: 600; color: var(--accent); }

.air { height: 10px; }

.quote-inline {
  margin-top: 10px;
}
/* nagyobb, lejjebb tolt Árajánlatkérés gomb az adagolós lapon */
.contact .quote-inline {
  margin-top: 24px;
  font-size: 30px;
  padding: 21px 33px;
}

/* Decorative footer bar */
.deco-line {
  display: none;
}

footer.decor {
  position: static;
  /* left: 0; right: 0; bottom: 0; */ 
  height: var(--footer-h);
  /* softened style */
  background: #f3faf5;
  color: var(--accent);
  display: grid;
  grid-auto-flow: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-weight: 500;
  letter-spacing: 0.1px;
  box-shadow: 0 -4px 12px rgba(0,0,0,0.08);
  border-top: 1px solid rgba(26,127,55,0.25);
}
footer.decor a { color: #0a66ff; }
footer.decor a:visited { color: #0a66ff; }

footer.decor span {
  padding: 0 12px;
  text-align: center;
  font-size: 14px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.quote-btn {
  appearance: none;
  border: none;
  background: var(--accent);
  color: #fff;
  border-radius: 999px;
  padding: 8px 14px;
  font-size: 14px;
  font-weight: 600;
  min-height: 36px;
  cursor: pointer;
  box-shadow: 0 2px 6px rgba(0,0,0,0.12);
}
.quote-btn:active {
  transform: translateY(1px);
  box-shadow: 0 1px 3px rgba(0,0,0,0.16);
}

/* kék háttérrel rendelkező Sveaverken ajánlatkérő gomb */
.quote-btn.quote-inline {
  margin-top: 10px;
}
/* nagyobb, lejjebb tolt Árajánlatkérés gomb az adagolós lapon */
.contact .quote-inline {
  margin-top: 24px;
  font-size: 30px;
  padding: 21px 33px;
}
.quote-btn-blue {
  background: #0a66ff;
}

/* kifejezetten a Sveaverken logó melletti Árajánlatkérés gomb nagyítása – kb. duplára */
#autosteering .auto-logo .quote-btn {
  font-size: 28px;
  padding: 16px 28px;
  min-height: 72px;
}

/* Szántóföldi vegyszerező szekció Árajánlatkérés gombjának nagyítása */
#sprayer .quote-inline {
  font-size: 24px;
  padding: 16px 28px;
  min-height: 60px;
}

/* Ajánlatkérés űrlap (modal) */
.quote-modal {
  position: fixed;
  inset: 0;
  z-index: 1100;
  display: grid;
  place-items: center;
  pointer-events: none;
}
.quote-modal[aria-hidden="true"] {
  opacity: 0;
}
.quote-modal[aria-hidden="false"] {
  pointer-events: auto;
}

.quote-modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,0.55);
}

.quote-modal-content {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 420px;
  margin: 0 16px;
  background: #fff;
  border-radius: 16px;
  box-shadow: 0 16px 40px rgba(0,0,0,0.3);
  padding: 16px 16px 12px;
  transform: translateY(12px);
}

.quote-modal-close {
  position: absolute;
  top: 8px;
  right: 8px;
  appearance: none;
  border: none;
  background: rgba(0,0,0,0.04);
  width: 32px;
  height: 32px;
  border-radius: 16px;
  font-size: 16px;
  cursor: pointer;
}

.quote-modal h2 {
  margin: 0 0 6px;
  font-size: 18px;
  font-family: var(--ff-head);
}

.quote-intro {
  margin: 0 0 10px;
  font-size: 14px;
  color: var(--muted);
}

#quote-form {
  display: grid;
  gap: 8px;
}

#quote-form label {
  display: grid;
  gap: 4px;
  font-size: 14px;
}

#quote-form input,
#quote-form textarea {
  border-radius: 10px;
  border: 1px solid var(--border);
  padding: 8px 10px;
  font-family: var(--ff-body);
  font-size: 14px;
}

#quote-form textarea {
  resize: vertical;
  min-height: 72px;
}

/* ensure the GDPR checkbox is clearly visible in all browsers */
/* EGYÉRTELMŰ, NAGY NÉGYZET – EGYEDI STÍLUS */
#quote-form input[type="checkbox"] {
  /* native megjelenítés kikapcsolása, saját rajzolás jön alább */
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;
}

/* GDPR hozzájárulás blokk – egyedi, jól látható checkbox */
.gdpr-consent {
  display: block;
  font-size: 12px;
}

.gdpr-consent input[type="checkbox"] {
  position: absolute;
  left: 0;
  top: 2px;
  width: 22px;
  height: 22px;
  margin: 0;
  opacity: 0; /* láthatatlan, de kattintható */
  cursor: pointer;
}

.gdpr-consent span {
  position: relative;
  display: block;
  padding-left: 30px; /* hely a négyzetnek */
}

/* üres négyzet rajzolása */
.gdpr-consent span::before {
  content: "";
  position: absolute;
  left: 0;
  top: 2px;
  width: 20px;
  height: 20px;
  border-radius: 4px;
  border: 2px solid var(--accent);
  background: #fff;
  box-sizing: border-box;
}

/* pipás állapot */
.gdpr-consent input[type="checkbox"]:checked + span::before {
  content: "✓";
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  font-weight: 700;
  color: #fff;
  background: var(--accent);
  border-color: var(--accent);
}

.gdpr-consent a {
  color: #0a66ff;
  text-decoration: underline;
}

.quote-submit {
  width: 100%;
  margin-top: 4px;
}

.quote-note {
  margin: 6px 0 0;
  font-size: 12px;
  color: var(--muted);
  text-align: center;
}

/* Lightbox */
.lightbox {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.72);
  display: grid;
  place-items: center;
  padding: 16px;
  z-index: 1000;
  opacity: 0;
  pointer-events: none;
  transition: opacity 180ms ease;
}
.lightbox[aria-hidden="false"] {
  opacity: 1;
  pointer-events: auto;
}
.lightbox img {
  max-width: 100%;
  max-height: 82vh;
  width: auto;
  height: auto;
  border-radius: 10px;
  box-shadow: 0 12px 32px rgba(0,0,0,0.35);
  background: #fff;
}
.lightbox-close {
  position: absolute;
  top: env(safe-area-inset-top, 8px);
  right: 8px;
  appearance: none;
  border: none;
  background: rgba(255,255,255,0.9);
  color: #111;
  width: 44px;
  height: 44px;
  border-radius: 22px;
  font-size: 18px;
  box-shadow: var(--shadow);
}

/* Lightbox video styling */
.lightbox video {
  max-width: 100%;
  max-height: 82vh;
  width: auto;
  height: auto;
  border-radius: 10px;
  box-shadow: 0 12px 32px rgba(0,0,0,0.35);
  background: #000;
  display: none;
}

/* Hover elevate effect for images inside views */
.view img {
  transition: transform 180ms ease, box-shadow 180ms ease;
  will-change: transform, box-shadow;
  position: relative; /* enable caption positioning */
}
.view img:not(.rot90):hover {
  transform: translateY(-2px) scale(1.02);
  box-shadow: 0 12px 24px rgba(0,0,0,0.18);
}

/* creative caption bubble on image hover (uses alt text) */
.view img:not(.rot90)::after {
  content: attr(alt);
  position: absolute;
  left: 8px;
  right: 8px;
  bottom: 8px;
  padding: 6px 10px;
  background: rgba(255,255,255,0.92);
  color: var(--text);
  border: 1px solid var(--border);
  border-radius: 10px;
  box-shadow: 0 6px 18px rgba(0,0,0,0.08);
  font-size: 12px;
  line-height: 1.4;
  opacity: 0;
  transform: translateY(6px);
  pointer-events: none;
  transition: opacity 160ms ease, transform 160ms ease;
}
.view img:not(.rot90):hover::after {
  opacity: 1;
  transform: translateY(0);
}

/* prevent hover/interactivity on Sveaverken logo */
#autosteering .auto-logo img {
  pointer-events: none;
  box-shadow: none;
  transform: none;
}
#autosteering .auto-logo img::after {
  content: none;
}

#autosteering h2 { margin: 0 0 12px; font-size: 19px; position: relative; font-family: var(--ff-head); }
#autosteering h2::after { content: ""; position: absolute; left: 0; bottom: -6px; width: 64px; height: 3px; background: var(--accent); border-radius: 2px; }

/* Checkbox javítása - Kényszerített megjelenítés */
#quote-form input[type="checkbox"] {
  appearance: auto !important;
  -webkit-appearance: checkbox !important; /* Safari/Chrome javítás */
  width: 20px !important; /* Legyen fix mérete */
  height: 20px !important;
  border: 1px solid #999 !important; /* Ha a böngésző levenné a keretet */
  background-color: #fff !important;
  padding: 0 !important;
  margin-top: 2px !important;
  flex-shrink: 0 !important; /* Ne nyomja össze a szöveg */
  display: inline-block !important;
}