/* PlanitExo marketing site — shared styles */

:root {
  --bg: #0f1117;
  --surface: #161b27;
  --card: #1e2535;
  --border: #2a3348;
  --text: #e8edf5;
  --text2: #8a9bb8;
  --text3: #556070;
  --accent: #3b82f6;
  --accent2: #1d4ed8;
  --green: #22c55e;
  --amber: #f59e0b;
  --red: #ef4444;
  --teal: #14b8a6;
  --max-width: 1120px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }
/* Horgonyra ugráskor a ragadós felső sáv ne takarja el a cél tetejét. */
#funkciok, #dokumentacio { scroll-margin-top: 80px; }

html, body {
  margin: 0;
  min-height: 100%;
}

body {
  background: var(--bg);
  color: var(--text);
  font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
  line-height: 1.5;
}

a { color: inherit; }

img { max-width: 100%; display: block; }

.accent { color: var(--accent); }

/* ---------- language toggle rules ---------- */
/* !important throughout: this on/off toggle must always win over any
   component's own `display` value (e.g. .btn, .feature-copy ul), regardless
   of selector specificity or source order. */
[data-i18n] { display: none !important; }
html[lang="hu"] [data-i18n="hu"] { display: block !important; }
html[lang="en"] [data-i18n="en"] { display: block !important; }
html[lang="hu"] span[data-i18n="hu"],
html[lang="en"] span[data-i18n="en"] { display: inline !important; }
html[lang="hu"] a[data-i18n="hu"],
html[lang="en"] a[data-i18n="en"] { display: inline-flex !important; }
html[lang="hu"] ul[data-i18n="hu"],
html[lang="en"] ul[data-i18n="en"] { display: flex !important; }
html[lang="hu"] li[data-i18n="hu"],
html[lang="en"] li[data-i18n="en"] { display: list-item !important; }

/* ---------- top nav ---------- */
.site-nav {
  position: sticky;
  top: 0;
  z-index: 40;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 16px 24px;
  background: rgba(15, 17, 23, 0.85);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--border);
}

.nav-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  font-weight: 700;
  font-size: 17px;
  color: var(--text);
}

.nav-brand img {
  height: 28px;
  width: auto;
}

.nav-right {
  display: flex;
  align-items: center;
  gap: 14px;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 22px;
  font-size: 14px;
  color: var(--text2);
}

.nav-links a {
  text-decoration: none;
  color: var(--text2);
  transition: color 0.15s;
}

.nav-links a:hover,
.nav-links a.active {
  color: var(--text);
}

.lang-switch {
  display: flex;
  gap: 4px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 3px;
}

.lang-switch button,
.lang-switch a {
  appearance: none;
  border: none;
  background: transparent;
  color: var(--text2);
  font-size: 12px;
  font-weight: 600;
  padding: 5px 10px;
  border-radius: 6px;
  cursor: pointer;
  text-decoration: none;
  transition: background 0.15s, color 0.15s;
}

.lang-switch button.active,
.lang-switch a.active {
  background: var(--accent);
  color: #fff;
}

.lang-switch button:not(.active):hover,
.lang-switch a:not(.active):hover {
  color: var(--text);
  background: var(--card);
}

/* ---------- buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 22px;
  border-radius: 9px;
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  border: 1px solid transparent;
  transition: transform 0.15s, background 0.15s, border-color 0.15s;
}

.btn-primary {
  background: var(--accent);
  color: #fff;
}

.btn-primary:hover {
  background: var(--accent2);
}

.btn-ghost {
  background: transparent;
  border-color: var(--border);
  color: var(--text);
}

.btn-ghost:hover {
  border-color: var(--accent);
  color: var(--accent);
}

/* ---------- layout helpers ---------- */
.wrap {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
}

section {
  padding: 72px 0;
}

.eyebrow {
  color: var(--accent);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  margin: 0 0 14px;
}

h1, h2, h3 { margin: 0; font-weight: 700; letter-spacing: 0.005em; }

h1 { font-size: clamp(30px, 5vw, 46px); line-height: 1.15; }
h2 { font-size: clamp(24px, 3.4vw, 32px); line-height: 1.2; }
h3 { font-size: 18px; }

p { color: var(--text2); }

/* ---------- hero ---------- */
.hero {
  padding: 84px 0 64px;
  text-align: center;
}

.hero .lede {
  max-width: 640px;
  margin: 18px auto 32px;
  font-size: 17px;
  color: var(--text2);
}

.hero-actions {
  display: flex;
  justify-content: center;
  gap: 14px;
  flex-wrap: wrap;
}

/* „Kipróbálom" gomb alatti halvány megjegyzés (hero + záró CTA) */
.try-note {
  margin: 12px 0 0;
  font-size: 12px;
  color: var(--text3);
  text-align: center;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--surface);
  border: 1px solid var(--border);
  color: var(--text3);
  font-size: 12px;
  padding: 7px 14px;
  border-radius: 999px;
  margin-bottom: 22px;
}

.hero-badge .dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--accent);
}

.hero-shot {
  margin: 48px auto 0;
  max-width: 980px;
  border-radius: 14px;
  overflow: hidden;
  border: 1px solid var(--border);
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.5);
}

/* ---------- feature rows ---------- */
.feature-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 56px;
  align-items: center;
}

.feature-row.reverse .feature-copy { order: 2; }
.feature-row.reverse .feature-media { order: 1; }

.feature-media img {
  border-radius: 12px;
  border: 1px solid var(--border);
  box-shadow: 0 16px 48px rgba(0, 0, 0, 0.4);
}

.feature-copy ul {
  margin: 18px 0 0;
  padding: 0;
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.feature-copy li {
  display: flex;
  gap: 10px;
  color: var(--text2);
  font-size: 14.5px;
}

.feature-copy li::before {
  content: '';
  flex: none;
  width: 6px;
  height: 6px;
  margin-top: 8px;
  border-radius: 50%;
  background: var(--accent);
}

.icon-tile {
  width: 46px;
  height: 46px;
  border-radius: 11px;
  background: rgba(59, 130, 246, 0.14);
  color: var(--accent);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 18px;
}

.icon-tile svg { width: 24px; height: 24px; }

/* ---------- OEE mock tiles (decorative, not a real screenshot) ---------- */
.oee-mock {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 26px;
  box-shadow: 0 16px 48px rgba(0, 0, 0, 0.4);
}

.oee-mock-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
}

.oee-mock-tile {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 14px 16px;
}

.oee-mock-tile .label {
  font-size: 10px;
  color: var(--text3);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 8px;
}

.oee-mock-tile .value {
  font-size: 22px;
  font-weight: 700;
}

.oee-mock-bar {
  margin-top: 6px;
  height: 5px;
  border-radius: 3px;
  background: var(--border);
  overflow: hidden;
}

.oee-mock-bar span {
  display: block;
  height: 100%;
  border-radius: 3px;
}

/* ---------- benefits grid ---------- */
.benefits-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 20px;
  margin-top: 36px;
}

.benefit-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 22px;
}

.benefit-card h3 {
  margin-bottom: 8px;
}

.benefit-card p {
  font-size: 14px;
  margin: 0;
}

/* ---------- CTA banner ---------- */
.cta-banner {
  background: linear-gradient(135deg, rgba(59, 130, 246, 0.16), rgba(29, 78, 216, 0.05));
  border: 1px solid var(--border);
  border-radius: 18px;
  padding: 54px 40px;
  text-align: center;
}

.cta-banner .lede {
  max-width: 520px;
  margin: 14px auto 26px;
}

/* ---------- blog cards ---------- */
.blog-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 22px;
  margin-top: 36px;
}

.blog-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 24px;
  text-decoration: none;
  display: flex;
  flex-direction: column;
  gap: 10px;
  transition: border-color 0.15s, transform 0.15s;
}

.blog-card:hover {
  border-color: var(--accent);
  transform: translateY(-2px);
}

.blog-card .date {
  font-size: 12px;
  color: var(--text3);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.blog-card h3 {
  color: var(--text);
}

.blog-card p {
  font-size: 13.5px;
  margin: 0;
}

/* ---------- footer ---------- */
.site-footer {
  border-top: 1px solid var(--border);
  padding: 40px 0 32px;
  margin-top: 40px;
}

.footer-grid {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 24px;
}

.footer-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--text2);
  font-size: 13px;
}

.footer-brand img {
  height: 20px;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 18px;
  font-size: 13px;
}

.footer-links a {
  color: var(--text2);
  text-decoration: none;
}

.footer-links a:hover {
  color: var(--text);
}

.footer-note {
  margin-top: 24px;
  font-size: 12px;
  color: var(--text3);
}

/* ---------- legal / article prose ---------- */
.prose {
  max-width: 760px;
  margin: 0 auto;
  padding: 56px 24px 80px;
}

.prose h1 {
  margin-bottom: 8px;
}

.prose .updated {
  color: var(--text3);
  font-size: 13px;
  margin-bottom: 40px;
}

.prose h2 {
  font-size: 19px;
  margin: 40px 0 12px;
}

.prose p, .prose li {
  color: var(--text2);
  font-size: 14.5px;
  line-height: 1.75;
}

.prose ul {
  padding-left: 20px;
}

.prose strong { color: var(--text); }

.prose .placeholder {
  background: rgba(245, 158, 11, 0.12);
  border: 1px dashed var(--amber);
  color: #f7c873;
  padding: 1px 6px;
  border-radius: 4px;
  font-size: 0.94em;
}

.article-meta {
  color: var(--text3);
  font-size: 13px;
  margin-bottom: 8px;
}

/* ---------- cookie banner ---------- */
.cookie-banner {
  position: fixed;
  left: 16px;
  right: 16px;
  bottom: 16px;
  z-index: 80;
  max-width: 560px;
  margin: 0 auto;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 20px 22px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
  display: none;
}

.cookie-banner.visible { display: block; }

.cookie-banner p {
  font-size: 13px;
  margin: 0 0 14px;
  color: var(--text2);
}

.cookie-banner p a {
  color: var(--accent);
}

.cookie-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.cookie-actions .btn {
  padding: 9px 16px;
  font-size: 13px;
}

/* ---------- responsive ---------- */
@media (max-width: 860px) {
  .site-nav { flex-wrap: wrap; row-gap: 10px; }
  .nav-links { gap: 14px; font-size: 13px; order: 3; width: 100%; justify-content: center; }
  .feature-row,
  .feature-row.reverse {
    grid-template-columns: 1fr;
  }
  .feature-row.reverse .feature-copy,
  .feature-row.reverse .feature-media,
  .feature-row .feature-copy,
  .feature-row .feature-media {
    order: initial;
  }
  section { padding: 52px 0; }
}

/* ---------- dokumentáció-doboz + lebegő ajánló ---------- */
.docs-callout {
  padding: 36px;
  border: 1px solid rgba(59, 130, 246, 0.35);
  border-radius: 18px;
  background: linear-gradient(135deg, rgba(59, 130, 246, 0.12), rgba(59, 130, 246, 0) 70%);
}

.docs-callout .blog-grid { margin-top: 24px; }

.doc-fab {
  position: fixed;
  right: 20px;
  bottom: 20px;
  z-index: 70;
  display: flex;
  align-items: center;
  background: var(--accent);
  border-radius: 999px;
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.45);
  opacity: 0;
  transform: translateY(24px);
  pointer-events: none;
  transition: opacity 0.35s ease, transform 0.35s ease;
}

.doc-fab.show {
  opacity: 1;
  transform: none;
  pointer-events: auto;
  animation: doc-fab-pulse 2.4s ease-out 1s 3;
}

.doc-fab-link {
  color: #fff;
  font-weight: 600;
  font-size: 14px;
  text-decoration: none;
  padding: 13px 8px 13px 20px;
}

.doc-fab-close {
  background: none;
  border: 0;
  color: rgba(255, 255, 255, 0.8);
  font-size: 20px;
  line-height: 1;
  padding: 10px 16px 10px 6px;
  cursor: pointer;
}

.doc-fab-close:hover { color: #fff; }

.cookie-banner.visible ~ .doc-fab { bottom: 190px; }

@keyframes doc-fab-pulse {
  0% { box-shadow: 0 12px 32px rgba(0, 0, 0, 0.45), 0 0 0 0 rgba(59, 130, 246, 0.65); }
  100% { box-shadow: 0 12px 32px rgba(0, 0, 0, 0.45), 0 0 0 18px rgba(59, 130, 246, 0); }
}

@media (max-width: 720px) {
  .docs-callout { padding: 24px 18px; }
  .doc-fab { right: 12px; bottom: 12px; }
}

@media (prefers-reduced-motion: reduce) {
  .doc-fab { transition: none; }
  .doc-fab.show { animation: none; }
}

/* ---------- görgetősáv — sötét témához igazítva ---------- */
html { scrollbar-width: thin; scrollbar-color: var(--text3) var(--bg); }
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-track { background: var(--bg); }
::-webkit-scrollbar-thumb { background: var(--border); border-radius: 8px; border: 2px solid var(--bg); }
::-webkit-scrollbar-thumb:hover { background: var(--text3); }

/* ---------- blog article extras ---------- */
.prose ol {
  padding-left: 22px;
}

.prose ol li {
  margin-bottom: 8px;
}

.prose a:not(.btn) {
  color: var(--accent);
}

.prose figure {
  margin: 32px 0;
}

.prose figure img {
  display: block;
  width: 100%;
  height: auto;
  border: 1px solid var(--border);
  border-radius: 12px;
}

.prose figcaption {
  color: var(--text3);
  font-size: 13px;
  margin-top: 8px;
  text-align: center;
}

.article-cta {
  margin-top: 48px;
  padding: 32px 24px;
  border: 1px solid var(--border);
  border-radius: 16px;
  background: linear-gradient(135deg, rgba(59, 130, 246, 0.16), rgba(29, 78, 216, 0.05));
  text-align: center;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
}

.article-cta p {
  flex-basis: 100%;
  margin: 0 0 4px;
  color: var(--text);
  font-weight: 600;
}
/* ---------- prose tables ---------- */
.prose table {
  width: 100%;
  border-collapse: collapse;
  margin: 24px 0;
  font-size: 13.5px;
}

.prose th, .prose td {
  text-align: left;
  vertical-align: top;
  padding: 10px 12px;
  border-bottom: 1px solid var(--border);
  color: var(--text2);
  line-height: 1.55;
}

.prose thead th {
  color: var(--text);
  font-weight: 600;
  border-bottom: 1px solid var(--text3);
}

.prose tbody th {
  color: var(--text);
  font-weight: 600;
}

@media (max-width: 720px) {
  .prose table { display: block; overflow-x: auto; }
}
