/* ReBP rebar design – www.rebarbp.org */

:root {
  --blue: #1878e5;
  --blue-dark: #1355a4;
  --green: #6fd34a;
  --orange: #ff8330;
  --bg: #ffffff;
  --bg-alt: #f3f6fa;
  --text: #1b2430;
  --muted: #5a6776;
  --line: #dde3ea;
  --card: #ffffff;
  --shadow: 0 1px 2px rgba(16, 32, 56, .06), 0 8px 24px rgba(16, 32, 56, .08);
  --radius: 12px;
  --wrap: 1160px;
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #11161d;
    --bg-alt: #171e27;
    --text: #e6ebf1;
    --muted: #9aa7b6;
    --line: #2a3440;
    --card: #1a222c;
    --blue: #4b9bf5;
    --shadow: 0 1px 2px rgba(0, 0, 0, .3), 0 8px 24px rgba(0, 0, 0, .35);
    color-scheme: dark;
  }
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 72px; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 16px/1.6 "Segoe UI", system-ui, -apple-system, Roboto, "Helvetica Neue", Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--blue); }
code {
  font: .9em Consolas, "SFMono-Regular", Menlo, monospace;
  background: var(--bg-alt);
  border: 1px solid var(--line);
  border-radius: 4px;
  padding: 0 .3em;
  white-space: nowrap;
}
h1, h2, h3 { line-height: 1.2; margin: 0 0 .5em; }
h2 { font-size: clamp(1.6rem, 3vw, 2.2rem); }
h3 { font-size: 1.1rem; }

.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 20px; }
.narrow { max-width: 820px; }

/* ---------- butoane ---------- */
.btn {
  display: inline-block;
  background: var(--blue);
  color: #fff;
  text-decoration: none;
  font-weight: 600;
  padding: .75em 1.3em;
  border-radius: 8px;
  border: 2px solid var(--blue);
  cursor: pointer;
  font-size: 1rem;
  transition: background .15s, transform .15s;
}
.btn:hover { background: var(--blue-dark); border-color: var(--blue-dark); }
.btn:active { transform: translateY(1px); }
.btn-ghost { background: transparent; color: var(--blue); }
.btn-ghost:hover { background: var(--blue); color: #fff; }
.btn-small { padding: .4em .9em; font-size: .95rem; }

/* ---------- bara de sus ---------- */
.topbar {
  position: sticky; top: 0; z-index: 20;
  background: color-mix(in srgb, var(--bg) 92%, transparent);
  backdrop-filter: saturate(1.4) blur(8px);
  border-bottom: 1px solid var(--line);
}
.topbar-inner { display: flex; align-items: center; justify-content: space-between; height: 64px; }
.brand img { width: 120px; border-radius: 6px; }
.nav { display: flex; align-items: center; gap: 22px; }
.nav a:not(.btn) { color: var(--text); text-decoration: none; font-weight: 500; }
.nav a:not(.btn):hover { color: var(--blue); }
.nav .btn { color: #fff; }
.menu-btn { display: none; background: none; border: 0; padding: 8px; cursor: pointer; }
.menu-btn span { display: block; width: 24px; height: 2px; background: var(--text); margin: 5px 0; }

/* ---------- prezentare ---------- */
.hero {
  padding: 56px 0 64px;
  background:
    radial-gradient(1000px 400px at 85% -10%, color-mix(in srgb, var(--blue) 14%, transparent), transparent 70%),
    var(--bg);
}
.hero-grid { display: grid; grid-template-columns: 5fr 7fr; gap: 48px; align-items: center; }
.eyebrow {
  display: inline-block; margin: 0 0 14px;
  font-size: .85rem; font-weight: 600; letter-spacing: .04em; text-transform: uppercase;
  color: var(--blue);
}
.hero h1 { font-size: clamp(2rem, 4.2vw, 3.1rem); letter-spacing: -.01em; }
.lead { font-size: 1.15rem; color: var(--muted); margin: 0 0 28px; }
.lead strong { color: var(--text); }
.hero-cta { display: flex; flex-wrap: wrap; gap: 12px; margin-bottom: 28px; }
.hero-facts { list-style: none; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 8px 22px; color: var(--muted); font-size: .95rem; }
.hero-facts b { color: var(--text); }
.hero-shot { margin: 0; }
.hero-shot img {
  border-radius: 10px; border: 1px solid var(--line); box-shadow: var(--shadow);
  cursor: zoom-in;
}
.hero-shot figcaption { margin-top: 10px; font-size: .85rem; color: var(--muted); text-align: center; }

/* ---------- bandă ---------- */
.band { background: var(--blue); color: #fff; padding: 36px 0; }
.band-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; }
.band p { margin: 0; opacity: .92; }
.h-small { font-size: 1.25rem; }
.band .h-small::before {
  content: ""; display: inline-block; width: 10px; height: 10px; border-radius: 2px;
  background: var(--green); margin-right: 10px; vertical-align: middle;
}
.band-grid > div:last-child .h-small::before { background: var(--orange); }

/* ---------- secțiuni ---------- */
.section { padding: 80px 0; }
.section-alt { background: var(--bg-alt); }
.section-lead { color: var(--muted); font-size: 1.08rem; max-width: 760px; margin: 0 0 32px; }
.section-lead strong { color: var(--text); }

/* ierarhia */
.flow {
  list-style: none; padding: 0; margin: 0 0 40px;
  display: grid; grid-template-columns: repeat(6, 1fr); gap: 0;
  counter-reset: none;
}
.flow li {
  position: relative; padding: 14px 16px 14px 18px;
  background: var(--card); border: 1px solid var(--line);
  margin-right: -1px;
}
.flow li:first-child { border-radius: 10px 0 0 10px; }
.flow li:last-child { border-radius: 0 10px 10px 0; }
.flow li span { display: block; font-weight: 700; }
.flow li em { display: block; font-style: normal; color: var(--muted); font-size: .9rem; }
.flow li:not(:last-child)::after {
  content: "›"; position: absolute; right: -9px; top: 50%; transform: translateY(-50%);
  z-index: 1; width: 18px; height: 18px; line-height: 16px; text-align: center;
  background: var(--blue); color: #fff; border-radius: 50%; font-weight: 700; font-size: 14px;
}

.steps { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.step { padding: 4px 0; }
.step b {
  display: inline-grid; place-items: center; width: 34px; height: 34px; border-radius: 50%;
  background: color-mix(in srgb, var(--blue) 14%, transparent); color: var(--blue);
  margin-bottom: 10px;
}
.step p { color: var(--muted); margin: 0; }

/* funcții */
.features { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.feature {
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 22px 22px 20px; border-top: 3px solid var(--blue);
}
.feature:nth-child(3n+2) { border-top-color: var(--green); }
.feature:nth-child(3n) { border-top-color: var(--orange); }
.feature p { color: var(--muted); margin: 0; }

/* capturi */
.tabs { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 18px; }
.tabs button {
  font: inherit; font-weight: 600; font-size: .95rem;
  padding: .5em 1em; border-radius: 999px; cursor: pointer;
  background: var(--bg-alt); color: var(--text); border: 1px solid var(--line);
}
.tabs button[aria-selected="true"] { background: var(--blue); color: #fff; border-color: var(--blue); }
.tab-panel img {
  border-radius: 10px; border: 1px solid var(--line); box-shadow: var(--shadow);
  cursor: zoom-in; width: 100%;
}
.tab-panel p { color: var(--muted); max-width: 900px; margin: 16px 0 0; }
.tab-panel p b { color: var(--text); }

/* rapoarte */
.reports { display: grid; grid-template-columns: repeat(2, 1fr); gap: 28px; }
.report { margin: 0; }
.report img {
  background: #fff; border: 1px solid var(--line); border-radius: 6px; box-shadow: var(--shadow);
  cursor: zoom-in; width: 100%;
}
.report-tall img { max-height: 520px; width: auto; margin: 0 auto; }
.report figcaption { margin-top: 12px; color: var(--muted); font-size: .95rem; }
.report figcaption b { color: var(--text); }

/* licențe */
.plans { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; align-items: stretch; }
.plan {
  display: flex; flex-direction: column;
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 26px;
}
.plan-main { border: 2px solid var(--blue); box-shadow: var(--shadow); }
.plan h3 { font-size: 1.35rem; margin-bottom: 2px; }
.plan-sub { color: var(--muted); margin: 0 0 16px; }
.plan ul { padding-left: 1.1em; margin: 0 0 22px; flex: 1; }
.plan li { margin-bottom: 6px; }
.plan .btn { align-self: flex-start; }
.req { margin-top: 40px; max-width: 820px; }
.req p { color: var(--muted); }
.link-doc { font-weight: 600; }
.link-doc::before { content: "⬇ "; }

/* întrebări */
details {
  background: var(--card); border: 1px solid var(--line); border-radius: 10px;
  padding: 0 20px; margin-bottom: 12px;
}
summary { cursor: pointer; font-weight: 600; padding: 16px 0; list-style-position: outside; }
details p { color: var(--muted); margin: 0 0 18px; }

/* contact */
.contact-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; align-items: start; }
.contact-list { list-style: none; padding: 0; margin: 0 0 20px; }
.contact-list li { display: flex; gap: 16px; padding: 12px 0; border-bottom: 1px solid var(--line); font-size: 1.1rem; }
.contact-list span { width: 90px; color: var(--muted); flex: none; }
.contact-list a { font-weight: 600; text-decoration: none; }
.note { color: var(--muted); font-size: .95rem; }
.contact-form {
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 26px; box-shadow: var(--shadow);
}
.contact-form label { display: block; font-weight: 600; font-size: .95rem; margin-bottom: 14px; }
.contact-form input, .contact-form select, .contact-form textarea {
  display: block; width: 100%; margin-top: 6px;
  font: inherit; font-weight: 400; color: var(--text);
  background: var(--bg); border: 1px solid var(--line); border-radius: 8px; padding: .6em .75em;
}
.contact-form input:focus, .contact-form select:focus, .contact-form textarea:focus {
  outline: 2px solid color-mix(in srgb, var(--blue) 40%, transparent); border-color: var(--blue);
}
.contact-form [aria-invalid="true"] { border-color: #d64545; }
.form-hint { color: var(--muted); font-size: .85rem; margin: 10px 0 0; }

/* subsol */
.footer { border-top: 1px solid var(--line); padding: 28px 0; color: var(--muted); font-size: .92rem; }
.footer-inner { display: flex; align-items: center; gap: 20px; flex-wrap: wrap; }
.footer-inner img { border-radius: 5px; }
.footer p { margin: 0; }
.footer-inner p:last-child { margin-left: auto; }

/* mărire imagine */
.lightbox {
  position: fixed; inset: 0; z-index: 50; background: rgba(8, 12, 18, .9);
  display: grid; place-items: center; padding: 24px; cursor: zoom-out;
}
.lightbox[hidden] { display: none; }
.lightbox img { max-width: 100%; max-height: 100%; width: auto; border-radius: 6px; background: #fff; }
.lightbox-close {
  position: absolute; top: 12px; right: 16px; font-size: 36px; line-height: 1;
  background: none; border: 0; color: #fff; cursor: pointer;
}

/* ---------- ecrane mici ---------- */
@media (max-width: 980px) {
  .hero-grid, .contact-grid { grid-template-columns: 1fr; }
  .features, .plans { grid-template-columns: 1fr 1fr; }
  .steps { grid-template-columns: 1fr 1fr; }
  .flow { grid-template-columns: repeat(3, 1fr); gap: 8px; }
  .flow li { border-radius: 10px !important; margin: 0; }
  .flow li::after { display: none; }
}
@media (max-width: 760px) {
  .menu-btn { display: block; }
  .nav {
    display: none; position: absolute; top: 64px; left: 0; right: 0;
    flex-direction: column; align-items: stretch; gap: 0;
    background: var(--bg); border-bottom: 1px solid var(--line); padding: 8px 20px 16px;
  }
  .nav.open { display: flex; }
  .nav a { padding: 10px 0; }
  .nav .btn { text-align: center; margin-top: 8px; }
  .band-grid, .features, .plans, .reports, .steps { grid-template-columns: 1fr; }
  .flow { grid-template-columns: 1fr 1fr; }
  .section { padding: 56px 0; }
  .hero { padding-top: 32px; }
  .footer-inner p:last-child { margin-left: 0; }
}
