:root {
  --navy: #061c3f;
  --navy-2: #0a315e;
  --blue: #1263ad;
  --gold: #c48b25;
  --gold-light: #e8bb68;
  --paper: #f4f7fb;
  --ink: #10223d;
  --muted: #5d6d82;
  --line: #dce4ef;
  --white: #fff;
  --danger: #a02c2c;
  --success: #185d3c;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; background: var(--paper); color: var(--ink); font-family: Arial, Helvetica, sans-serif; }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; }
button, a, input, select, textarea { outline-offset: 3px; }

.site-header {
  position: sticky; top: 0; z-index: 30; min-height: 78px; padding: 10px clamp(18px, 4vw, 64px);
  display: grid; grid-template-columns: minmax(260px, 1fr) auto auto; align-items: center; gap: 28px;
  background: rgba(255,255,255,.96); border-bottom: 1px solid rgba(6,28,63,.1); backdrop-filter: blur(16px);
}
.brand { display: flex; align-items: center; gap: 14px; min-width: 0; font-weight: 800; color: var(--navy); font-size: 13px; letter-spacing: .02em; }
.logo-crop { width: 150px; height: 54px; overflow: hidden; display: block; flex: 0 0 auto; }
.logo-crop img { width: 185px; height: 57px; max-width: none; object-fit: cover; object-position: left center; }
.site-header nav { display: flex; align-items: center; gap: 24px; color: #233d5c; font-size: 14px; font-weight: 700; }
.site-header nav a:hover { color: var(--blue); }
.languages { display: flex; padding: 3px; gap: 2px; background: #edf2f8; border-radius: 999px; }
.languages button { border: 0; background: transparent; color: #6b7a8f; border-radius: 999px; padding: 7px 10px; font-size: 11px; font-weight: 800; cursor: pointer; }
.languages button.active { color: white; background: var(--navy); }

.hero {
  position: relative; overflow: hidden; display: grid; grid-template-columns: minmax(0, 1.45fr) minmax(300px, .55fr); gap: 54px;
  padding: clamp(70px, 8vw, 118px) clamp(24px, 7vw, 108px) 84px; color: white;
  background: radial-gradient(circle at 85% 10%, rgba(30,101,173,.45), transparent 32%), linear-gradient(135deg, #041735 0%, #082b57 68%, #0c4176 100%);
}
.hero::after { content: ''; position: absolute; width: 720px; height: 720px; right: -280px; top: -300px; border: 1px solid rgba(232,187,104,.45); border-radius: 50%; box-shadow: 0 0 0 80px rgba(232,187,104,.06), 0 0 0 160px rgba(18,99,173,.08); pointer-events: none; }
.hero-copy, .hero-card { position: relative; z-index: 1; }
.eyebrow { margin: 0 0 14px; color: var(--gold); font-size: 13px; font-weight: 900; letter-spacing: .15em; text-transform: uppercase; }
.hero .eyebrow, .status-panel .eyebrow { color: var(--gold-light); }
h1 { max-width: 850px; margin: 0; font-size: clamp(48px, 7vw, 92px); line-height: .98; letter-spacing: -.055em; }
.lead { max-width: 760px; margin: 28px 0 0; color: #d6e3f4; font-size: clamp(18px, 2vw, 22px); line-height: 1.65; }
.actions { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 34px; }
.button { min-height: 50px; padding: 14px 22px; border: 0; border-radius: 14px; display: inline-flex; align-items: center; justify-content: center; font-weight: 800; cursor: pointer; transition: transform .18s ease, box-shadow .18s ease, background .18s ease; }
.button:hover { transform: translateY(-1px); }
.button:disabled { opacity: .65; cursor: wait; transform: none; }
.button.primary { background: linear-gradient(135deg, #dba43e, var(--gold)); color: var(--navy); box-shadow: 0 12px 32px rgba(0,0,0,.16); }
.button.ghost { color: white; border: 1px solid rgba(255,255,255,.35); background: rgba(255,255,255,.06); }
.button.gold { width: 100%; background: var(--gold); color: var(--navy); }
.button.outline { border: 1px solid var(--line); background: white; color: var(--navy); }
.trust { display: flex; flex-wrap: wrap; gap: 20px; margin-top: 32px; color: #dbe7f4; font-size: 14px; font-weight: 700; }
.trust b { font-weight: 700; }
.hero-card { align-self: end; padding: 30px; border: 1px solid rgba(232,187,104,.45); border-radius: 26px; background: rgba(255,255,255,.08); box-shadow: 0 20px 60px rgba(0,0,0,.25); backdrop-filter: blur(12px); }
.card-kicker { margin: 0 0 24px; color: var(--gold-light); font-weight: 900; letter-spacing: .2em; }
.hero-card-title { margin: 0 0 12px; font-size: 24px; font-weight: 900; }
.hero-card a { display: block; margin-top: 9px; color: #e5eef8; font-weight: 700; }
.emergency { margin-top: 24px; padding: 16px; border-radius: 14px; background: rgba(0,0,0,.2); color: #d9e4f2; font-size: 13px; line-height: 1.55; }

.section-shell { max-width: 1280px; margin: 0 auto; padding: 88px 34px; }
.section-heading { max-width: 720px; margin-bottom: 36px; }
.section-heading.narrow { max-width: 880px; }
.section-heading h2, .principles h2 { margin: 0; color: var(--navy); font-size: clamp(34px, 5vw, 58px); line-height: 1.05; letter-spacing: -.04em; }
.section-heading > p:last-child { color: var(--muted); font-size: 18px; line-height: 1.65; }
.service-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.service-grid article { min-height: 230px; padding: 28px; border: 1px solid var(--line); border-radius: 24px; background: white; box-shadow: 0 14px 40px rgba(22,50,86,.06); }
.service-grid article > span { color: var(--gold); font-size: 13px; font-weight: 900; letter-spacing: .15em; }
.service-grid h3 { margin: 34px 0 12px; color: var(--navy); font-size: 21px; }
.service-grid p { margin: 0; color: var(--muted); line-height: 1.62; }

.portal { border-top: 1px solid var(--line); }
.portal-layout { display: grid; grid-template-columns: minmax(0, 1fr) 350px; gap: 24px; align-items: start; }
.request-form { padding: 34px; border-radius: 28px; background: white; border: 1px solid var(--line); box-shadow: 0 18px 55px rgba(22,50,86,.08); }
fieldset { margin: 0; padding: 0 0 32px; border: 0; }
fieldset + fieldset { padding-top: 32px; border-top: 1px solid var(--line); }
legend { margin-bottom: 22px; color: var(--navy); font-size: 20px; font-weight: 900; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
label { display: flex; flex-direction: column; gap: 9px; color: #29415f; font-size: 14px; font-weight: 800; }
label.wide, .wide { grid-column: 1 / -1; }
input, select, textarea { width: 100%; border: 1px solid #cbd7e5; border-radius: 12px; background: #fbfcfe; color: var(--ink); padding: 13px 14px; transition: border .15s ease, box-shadow .15s ease; }
input, select { min-height: 50px; }
textarea { resize: vertical; line-height: 1.5; }
input:focus, select:focus, textarea:focus { border-color: var(--blue); box-shadow: 0 0 0 3px rgba(18,99,173,.13); }
small { color: var(--muted); font-weight: 400; line-height: 1.45; }
.honeypot { position: absolute !important; left: -10000px !important; width: 1px !important; height: 1px !important; opacity: 0 !important; }
.file-drop { position: relative; min-height: 140px; padding: 28px; align-items: center; justify-content: center; text-align: center; border: 1.5px dashed #9db1ca; border-radius: 18px; background: #f6f9fd; cursor: pointer; }
.file-drop input { position: absolute; inset: 0; opacity: 0; cursor: pointer; }
.file-drop strong { color: var(--blue); font-size: 18px; }
.file-drop span { max-width: 560px; color: var(--muted); font-weight: 400; line-height: 1.5; }
.file-list { margin: 14px 0 0; padding: 0; list-style: none; }
.file-list li { display: flex; justify-content: space-between; gap: 12px; padding: 10px 12px; border-bottom: 1px solid var(--line); color: #344a65; font-size: 13px; }
.file-list li span { color: var(--muted); }
.file-list .file-error { color: var(--danger); }
.security-note { display: flex; gap: 12px; margin-top: 18px; padding: 16px; border-radius: 14px; background: #fff7e7; color: #75571d; }
.security-note strong { width: 26px; height: 26px; flex: 0 0 auto; display: grid; place-items: center; border-radius: 50%; background: var(--gold); color: var(--navy); }
.security-note p { margin: 0; font-size: 13px; line-height: 1.55; }
.checks { display: grid; gap: 14px; margin: 4px 0 24px; }
.checks label { flex-direction: row; align-items: flex-start; font-weight: 500; line-height: 1.55; }
.checks input { width: 20px; min-height: 20px; height: 20px; margin: 2px 0 0; accent-color: var(--blue); flex: 0 0 auto; }
.privacy-link { margin: -8px 0 20px; font-size: 13px; }
.privacy-link a { color: var(--blue); text-decoration: underline; }
.submit { width: 100%; }
.form-message { margin-top: 18px; }
.error, .status-error { padding: 14px; border-radius: 12px; background: #fff0f0; color: var(--danger); line-height: 1.5; }
.success { display: grid; gap: 8px; padding: 18px; border-radius: 14px; background: #e9f7ef; color: var(--success); }
.success b { font-size: 24px; letter-spacing: .04em; overflow-wrap: anywhere; }

.status-panel { position: sticky; top: 102px; padding: 28px; border-radius: 26px; background: var(--navy); color: white; box-shadow: 0 18px 55px rgba(6,28,63,.22); }
.status-panel h2 { margin: 0; font-size: 34px; letter-spacing: -.03em; }
.status-panel > p:not(.eyebrow) { color: #c7d7ea; line-height: 1.55; }
.status-panel form { display: grid; gap: 16px; margin-top: 25px; }
.status-panel label { color: #dce8f5; }
.status-panel input { background: rgba(255,255,255,.98); color: var(--ink); }
.status-error { background: rgba(255,90,90,.14); color: #ffd5d5; }
.status-success { display: grid; gap: 8px; margin-top: 18px; padding: 16px; border: 1px solid rgba(232,187,104,.42); border-radius: 14px; background: rgba(232,187,104,.12); }
.status-success span { color: #c8d8ea; font-size: 12px; text-transform: uppercase; letter-spacing: .12em; }
.status-success strong { color: var(--gold-light); font-size: 22px; }
.status-success p { margin: 0; color: #eef4fb; line-height: 1.55; white-space: pre-wrap; }
.status-contact { display: grid; gap: 8px; margin-top: 28px; padding-top: 20px; border-top: 1px solid rgba(255,255,255,.15); }
.status-contact span { color: #c7d7ea; font-size: 13px; }
.status-contact a { color: var(--gold-light); font-weight: 800; }

.principles { display: grid; grid-template-columns: .55fr 1.45fr; gap: 50px; align-items: center; }
.principle-list { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; }
.principle-list span { padding: 14px 16px; border-radius: 12px; background: white; border: 1px solid var(--line); color: #334a67; font-weight: 700; }
footer { display: flex; justify-content: space-between; gap: 30px; padding: 42px clamp(24px, 7vw, 108px); background: #04152f; color: white; }
footer > div { display: grid; gap: 8px; }
footer span, footer a { color: #c1d0e2; font-size: 14px; }

.install-page, .admin-login-page { min-height: 100vh; display: grid; place-items: center; padding: 30px; background: radial-gradient(circle at top right, #0a4078, transparent 38%), #041735; }
.install-card, .login-card { width: min(820px, 100%); padding: clamp(28px, 5vw, 52px); border-radius: 28px; background: white; box-shadow: 0 30px 90px rgba(0,0,0,.3); }
.login-card { width: min(480px, 100%); }
.install-logo { width: min(360px, 100%); max-height: 110px; object-fit: contain; object-position: left center; }
.install-card h1, .login-card h1 { margin: 8px 0 14px; color: var(--navy); font-size: clamp(34px, 5vw, 54px); line-height: 1; letter-spacing: -.04em; }
.install-card > p, .login-card > p { color: var(--muted); line-height: 1.6; }
.install-form { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; margin-top: 28px; }
.install-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 26px; }

.admin-body { min-height: 100vh; background: #edf2f8; }
.admin-header { display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 16px clamp(20px, 4vw, 56px); background: var(--navy); color: white; }
.admin-brand { display: flex; align-items: center; gap: 14px; font-weight: 900; }
.admin-brand img { width: 135px; height: 48px; object-fit: cover; object-position: left center; background: white; border-radius: 8px; }
.admin-nav { display: flex; align-items: center; gap: 16px; }
.admin-nav a { color: #d8e5f3; font-weight: 700; }
.admin-nav form { margin: 0; }
.admin-nav button { border: 1px solid rgba(255,255,255,.35); border-radius: 10px; background: transparent; color: white; padding: 9px 12px; cursor: pointer; }
.admin-main { max-width: 1360px; margin: 0 auto; padding: 38px 26px 70px; }
.admin-heading { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; margin-bottom: 24px; }
.admin-heading h1 { margin: 0; color: var(--navy); font-size: clamp(34px, 5vw, 58px); letter-spacing: -.04em; }
.stats { display: grid; grid-template-columns: repeat(5, 1fr); gap: 12px; margin-bottom: 24px; }
.stat { padding: 18px; border-radius: 16px; background: white; border: 1px solid var(--line); }
.stat span { display: block; color: var(--muted); font-size: 12px; }
.stat strong { display: block; margin-top: 6px; color: var(--navy); font-size: 28px; }
.admin-filters { display: grid; grid-template-columns: minmax(240px, 1fr) 220px auto; gap: 12px; margin-bottom: 18px; }
.admin-panel { overflow: hidden; border: 1px solid var(--line); border-radius: 18px; background: white; box-shadow: 0 12px 35px rgba(22,50,86,.06); }
.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; }
th, td { padding: 14px 16px; border-bottom: 1px solid var(--line); text-align: left; vertical-align: top; font-size: 14px; }
th { background: #f5f8fc; color: #53677f; font-size: 12px; text-transform: uppercase; letter-spacing: .05em; }
tr:last-child td { border-bottom: 0; }
td a { color: var(--blue); font-weight: 800; }
.badge { display: inline-flex; align-items: center; padding: 6px 9px; border-radius: 999px; background: #eaf1f8; color: var(--navy-2); font-size: 12px; font-weight: 800; }
.badge.urgent { background: #fff0e1; color: #9a4b00; }
.detail-grid { display: grid; grid-template-columns: minmax(0, 1fr) 390px; gap: 22px; }
.detail-card { padding: 26px; border: 1px solid var(--line); border-radius: 18px; background: white; }
.detail-card h2 { margin: 0 0 20px; color: var(--navy); }
.detail-list { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.detail-item span { display: block; color: var(--muted); font-size: 12px; }
.detail-item strong, .detail-item p { display: block; margin: 5px 0 0; overflow-wrap: anywhere; white-space: pre-wrap; }
.detail-item.wide { grid-column: 1 / -1; }
.admin-form { display: grid; gap: 16px; }
.attachment-list { margin: 0; padding: 0; list-style: none; }
.attachment-list li { padding: 12px 0; border-bottom: 1px solid var(--line); }
.attachment-list a { color: var(--blue); font-weight: 800; }
.notice { padding: 14px; border-radius: 12px; background: #e9f7ef; color: var(--success); }

@media (max-width: 980px) {
  .site-header { grid-template-columns: 1fr auto; }
  .site-header nav { display: none; }
  .hero { grid-template-columns: 1fr; }
  .hero-card { max-width: 560px; }
  .service-grid { grid-template-columns: repeat(2, 1fr); }
  .portal-layout, .detail-grid { grid-template-columns: 1fr; }
  .status-panel { position: static; }
  .stats { grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 640px) {
  .site-header { padding: 8px 14px; gap: 8px; }
  .brand > span:last-child { display: none; }
  .logo-crop { width: 122px; }
  .logo-crop img { width: 150px; height: 48px; }
  .languages button { padding: 6px 8px; }
  .hero { padding: 58px 22px 64px; gap: 34px; }
  h1 { font-size: 50px; }
  .hero-card { padding: 22px; }
  .section-shell { padding: 64px 20px; }
  .service-grid, .form-grid, .principles, .install-form, .detail-list { grid-template-columns: 1fr; }
  .service-grid article { min-height: auto; }
  .request-form { padding: 22px 18px; border-radius: 22px; }
  .principle-list { grid-template-columns: 1fr; }
  footer, .admin-header, .admin-heading { flex-direction: column; align-items: flex-start; }
  .stats { grid-template-columns: 1fr 1fr; }
  .admin-filters { grid-template-columns: 1fr; }
}

@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } .button { transition: none; } }
