:root {
  --ink: #111827;
  --muted: #667085;
  --line: #d9e0ea;
  --paper: #f4f6f9;
  --white: #fff;
  --navy: #101827;
  --steel: #253347;
  --red: #d94135;
  --gold: #d79a28;
  --blue: #2563eb;
  --shadow: 0 22px 60px rgba(16, 24, 39, .12);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  min-height: 100vh;
  margin: 0;
  display: flex;
  flex-direction: column;
  color: var(--ink);
  background: var(--paper);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, Segoe UI, Arial, sans-serif;
}
main { flex: 1; }
a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; }

.site-header, .admin-top {
  position: sticky;
  top: 0;
  z-index: 20;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 24px;
  min-height: 86px;
  padding: 14px clamp(18px, 4vw, 72px);
  background: rgba(244, 246, 249, .9);
  border-bottom: 1px solid rgba(217, 224, 234, .86);
  backdrop-filter: blur(18px);
}
.brand { display: inline-flex; align-items: center; gap: 12px; font-size: 19px; color: var(--ink); }
.brand span, .brand-mark {
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  border-radius: 8px;
  color: #fff;
  font-weight: 950;
  background: linear-gradient(135deg, #e14534 0%, #d89b2b 100%);
  box-shadow: 0 16px 38px rgba(217, 65, 53, .24);
}
.main-nav { display: flex; justify-content: center; gap: 8px; }
.main-nav a, .lang-switch a, .admin-top nav a {
  display: inline-flex;
  align-items: center;
  min-height: 42px;
  padding: 0 14px;
  border-radius: 8px;
  color: #475467;
  font-weight: 800;
  font-size: 15px;
}
.main-nav a.active, .main-nav a:hover, .lang-switch a.active, .admin-top nav a:hover {
  color: var(--ink);
  background: #fff;
  box-shadow: 0 12px 28px rgba(16, 24, 39, .08);
}
.lang-switch { display: flex; gap: 5px; justify-content: flex-end; }
.menu-toggle { display: none; width: 44px; height: 44px; border: 1px solid var(--line); border-radius: 8px; background: #fff; font-size: 21px; }

.hero {
  min-height: calc(100vh - 86px);
  display: grid;
  grid-template-columns: minmax(0, .95fr) minmax(360px, 1.05fr);
  gap: clamp(28px, 6vw, 84px);
  align-items: center;
  padding: clamp(48px, 7vw, 92px) clamp(18px, 5vw, 84px) clamp(34px, 5vw, 60px);
  background:
    linear-gradient(120deg, rgba(16, 24, 39, .94), rgba(37, 51, 71, .9) 48%, rgba(244, 246, 249, .94) 48.2%),
    #111827;
  overflow: hidden;
}
.hero-copy { color: #fff; }
.hero-copy h1 {
  max-width: 780px;
  margin: 0;
  font-size: clamp(42px, 6vw, 86px);
  line-height: .96;
  letter-spacing: 0;
}
.hero-copy p:not(.eyebrow) {
  max-width: 640px;
  color: #d9e2ee;
  font-size: clamp(18px, 2vw, 22px);
  line-height: 1.68;
}
.eyebrow {
  margin: 0 0 14px;
  color: var(--gold);
  font-size: 12px;
  font-weight: 950;
  text-transform: uppercase;
  letter-spacing: .12em;
}
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 30px; }
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 50px;
  padding: 0 22px;
  border: 1px solid var(--line);
  border-radius: 8px;
  font-weight: 900;
  cursor: pointer;
}
.btn.primary { border-color: var(--red); color: #fff; background: var(--red); box-shadow: 0 18px 38px rgba(217, 65, 53, .26); }
.btn.ghost { color: var(--steel); background: #fff; }
.hero .btn.ghost { color: #fff; border-color: rgba(255,255,255,.34); background: rgba(255,255,255,.08); }
.hero-media { align-self: stretch; display: grid; place-items: center; }
.hero-media img {
  width: min(680px, 100%);
  min-height: 390px;
  object-fit: cover;
  border: 10px solid #fff;
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  padding: 0 clamp(18px, 5vw, 84px);
  background: #dde4ee;
}
.stats div { padding: clamp(24px, 4vw, 42px); background: #fff; }
.stats strong { display: block; font-size: clamp(34px, 5vw, 58px); line-height: 1; }
.stats span { display: block; margin-top: 8px; color: var(--muted); font-weight: 850; }

.services, .cards-section, .contact, .page-head, .content-narrow, .process, .quality-band {
  padding: clamp(54px, 7vw, 98px) clamp(18px, 5vw, 84px);
}
.section-title { max-width: 760px; margin-bottom: 30px; }
.section-title h2, .page-head h1, .contact h1, .admin-form h1 {
  margin: 0;
  font-size: clamp(34px, 4vw, 58px);
  line-height: 1.04;
  letter-spacing: 0;
}
.service-grid, .card-grid, .process-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}
.service-grid article, .post-card, .login-card, .admin-form, .admin-list, .contact-panel, .process-grid article {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 16px 44px rgba(16, 24, 39, .07);
  overflow: hidden;
}
.service-grid img { width: 100%; aspect-ratio: 16 / 10; object-fit: cover; }
.service-grid h3, .service-grid p { margin-left: 22px; margin-right: 22px; }
.service-grid h3, .process-grid h3 { font-size: 24px; line-height: 1.14; }
.service-grid p, .post-card p, .split p, .content-narrow p, .contact p, .process-grid p {
  color: var(--muted);
  line-height: 1.72;
}
.process { background: #fff; }
.process-grid article { padding: 26px; }
.process-grid span { color: var(--red); font-size: 15px; font-weight: 950; }

.quality-band {
  display: grid;
  grid-template-columns: minmax(0, .95fr) minmax(320px, .75fr);
  gap: 30px;
  align-items: center;
  color: #fff;
  background: linear-gradient(135deg, #111827, #26354a);
}
.quality-band h2 { max-width: 780px; margin: 0; font-size: clamp(34px, 4vw, 58px); line-height: 1.04; }
.quality-band ul { display: grid; gap: 12px; margin: 0; padding: 0; list-style: none; }
.quality-band li { padding: 14px 16px; border: 1px solid rgba(255,255,255,.18); border-radius: 8px; background: rgba(255,255,255,.08); font-weight: 800; }

.post-card a { display: grid; height: 100%; }
.post-card img { width: 100%; aspect-ratio: 16 / 11; object-fit: cover; background: #d7dde5; }
.post-card div { padding: 22px; }
.post-card time { color: var(--red); font-weight: 950; font-size: 13px; }
.post-card h3 { margin: 8px 0; font-size: 23px; line-height: 1.14; }
.post-card span { color: var(--blue); font-weight: 950; }

.split, .detail-hero {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(24px, 5vw, 64px);
  align-items: center;
  padding: clamp(48px, 7vw, 92px) clamp(18px, 5vw, 84px);
}
.split img, .detail-hero img { width: 100%; border-radius: 8px; box-shadow: var(--shadow); }
.split h2, .detail-hero h1 { margin: 0; font-size: clamp(36px, 5vw, 70px); line-height: 1; }
.detail-hero { color: #fff; background: var(--navy); }
.detail-hero p:not(.eyebrow) { color: #d9e2ee; font-size: 20px; line-height: 1.6; }
.content-narrow { width: min(960px, 100%); margin: auto; font-size: 21px; background: #fff; }

.contact {
  min-height: 62vh;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(320px, 420px);
  gap: 28px;
  align-items: center;
  background: linear-gradient(135deg, #fff, #edf1f6);
}
.contact-panel { display: grid; gap: 14px; padding: 28px; font-size: 20px; font-weight: 900; }

footer {
  display: grid;
  grid-template-columns: 1fr auto auto;
  align-items: center;
  gap: 24px;
  padding: 28px clamp(18px, 5vw, 84px);
  color: #fff;
  background: var(--navy);
}
footer span { color: #d7dfeb; }
footer a { font-weight: 900; }

.login-shell { min-height: 100vh; display: grid; place-items: center; padding: 20px; background: radial-gradient(circle at 25% 15%, rgba(217,65,53,.18), transparent 30%), #eef2f6; }
.login-card { width: min(420px, 100%); padding: 28px; }
.login-card h1 { margin: 16px 0 24px; }
label { display: grid; gap: 8px; margin-bottom: 16px; font-weight: 900; color: #344054; }
input, textarea, select { width: 100%; border: 1px solid var(--line); border-radius: 8px; padding: 13px 14px; font: inherit; background: #fff; }
textarea { resize: vertical; }
.alert { padding: 12px; border-radius: 8px; color: #9f1f17; background: #fff0ee; }
.admin-body { background: #eef2f6; }
.admin-layout { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(320px, .85fr); gap: 22px; padding: 28px clamp(18px, 4vw, 54px); }
.admin-form, .admin-list { padding: 24px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.language-tabs { display: flex; gap: 8px; margin: 16px 0; }
.language-tabs button { width: 48px; height: 42px; border: 1px solid var(--line); border-radius: 8px; background: #fff; font-weight: 900; cursor: pointer; }
.language-tabs button.active { color: #fff; border-color: var(--steel); background: var(--steel); }
.lang-panel { display: none; padding: 0; border: 0; }
.lang-panel.active { display: block; }
.admin-item { display: grid; grid-template-columns: 86px 1fr auto; gap: 14px; align-items: center; padding: 12px 0; border-bottom: 1px solid var(--line); }
.admin-item img { width: 86px; height: 64px; object-fit: cover; border-radius: 8px; }
.admin-item span { display: block; margin-top: 4px; color: var(--muted); font-size: 13px; }
.admin-item nav { display: flex; gap: 10px; font-weight: 900; }
.danger { color: var(--red); }
.empty { color: var(--muted); font-weight: 800; }
.install-warning { display: none; }

@media (max-width: 1040px) {
  .site-header { grid-template-columns: auto auto; }
  .menu-toggle { display: block; justify-self: end; }
  .main-nav { display: none; grid-column: 1 / -1; flex-direction: column; align-items: stretch; }
  .main-nav.open { display: flex; }
  .lang-switch { grid-column: 1 / -1; justify-content: flex-start; }
  .hero, .split, .detail-hero, .contact, .quality-band, .admin-layout { grid-template-columns: 1fr; }
  .hero { min-height: auto; background: linear-gradient(135deg, #111827, #27364b); }
  .service-grid, .card-grid, .process-grid, .stats { grid-template-columns: 1fr; }
}

@media (max-width: 560px) {
  .site-header { min-height: 76px; }
  .brand strong { font-size: 17px; }
  .hero-copy h1 { font-size: 39px; }
  .hero-media img { min-height: 250px; border-width: 6px; }
  .form-row, .admin-item, footer { grid-template-columns: 1fr; }
}
