:root {
  --primary: #1675AF;
  --primary-dark: #0E4F78;
  --accent: #17A2B8;
  --text-dark: #0B0F19;
  --bg-light: #FFFFFF;
  --bg-soft: #F4F8FB;
}
*{box-sizing:border-box}
html,body{
  -webkit-text-size-adjust: 100%;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
height:100%}
html{scroll-behavior:smooth}
body{
  -webkit-text-size-adjust: 100%;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;

  margin:0;
  font-family: ui-sans-serif,system-ui,-apple-system,Segoe UI,Roboto,Helvetica,Arial,"Apple Color Emoji","Segoe UI Emoji";
  color:var(--text);
  background: radial-gradient(1200px 600px at 10% -10%, rgba(56,189,248,.25), transparent 60%),
              radial-gradient(1000px 700px at 90% 10%, rgba(34,197,94,.22), transparent 55%),
              var(--bg);
  line-height:1.6;
}
a{color:inherit}
.container{max-width:1100px;margin:0 auto;padding:0 18px}
/* header */
header{
  position:sticky; top:0; z-index:50;
  backdrop-filter: blur(10px);
  background: rgba(11,15,25,.72);
  border-bottom:1px solid var(--border);
}
.nav{
  display:flex; align-items:center; justify-content:space-between;
  padding:10px 0;
  gap:12px;
}
.brand{display:flex; align-items:center; gap:12px; text-decoration:none; min-width:210px}
.brand img{
  width:56px; height:56px; object-fit:contain;
  border-radius:14px;
  background:#fff;
  padding:6px;
  box-shadow: 0 6px 18px rgba(0,0,0,.25);
}
.brand .name{display:flex; flex-direction:column; line-height:1.1}
.brand .name strong{font-size:18px; letter-spacing:.2px}
.brand .name span{font-size:12px;color:var(--muted)}
.nav-actions{display:flex; align-items:center; gap:10px; flex-wrap:wrap; justify-content:flex-end}
.btn{
  border:1px solid var(--border);
  background: rgba(17,24,39,.7);
  color:var(--text);
  padding:10px 12px;
  border-radius:999px;
  text-decoration:none;
  display:inline-flex; align-items:center; gap:8px;
  box-shadow: 0 8px 24px rgba(0,0,0,.2);
  -webkit-tap-highlight-color: transparent;
}
.btn:active{transform: translateY(1px)}
.lang{
  display:inline-flex; border:1px solid var(--border); border-radius:999px; overflow:hidden;
  background: rgba(17,24,39,.65);
}
.lang a{
  border:0; padding:10px 12px; color:var(--text);
  background:transparent; cursor:pointer; font-weight:800; font-size:12px;
  text-decoration:none; display:inline-flex; align-items:center; justify-content:center;
  min-width:44px; /* thumb target */
}
.lang a.active{background: linear-gradient(90deg, rgba(34,197,94,.35), rgba(56,189,248,.32));}
/* hero */
.hero{padding:34px 0 18px}
.hero-grid{display:grid; grid-template-columns: 1.1fr .9fr; gap:18px; align-items:stretch}
.card{background: rgba(17,24,39,.68); border:1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow)}
.hero-left{padding:26px}
.kicker{display:inline-flex; gap:10px; align-items:center; font-size:12px; color:var(--muted)}
.dot{width:8px; height:8px; border-radius:50%; background: linear-gradient(90deg, var(--brand), var(--brand2))}
h1{margin:10px 0 10px; font-size:40px; line-height:1.08}
.lead{color:#cbd5e1; font-size:16px; margin:0 0 18px}
.pills{display:flex; gap:10px; flex-wrap:wrap; margin-top:12px}
.pill{border:1px solid var(--border); background: rgba(2,6,23,.35); color:#dbeafe; padding:8px 10px; border-radius:999px; font-size:12px}
.hero-right{padding:12px; display:flex; flex-direction:column; gap:12px}
.hero-gallery{display:grid; grid-template-columns: repeat(2,1fr); gap:10px}
.hero-gallery img{width:100%; height:150px; object-fit:cover; border-radius:16px; border:1px solid var(--border)}
.quick{padding:16px}
.quick h3{margin:0 0 8px; font-size:14px; color:#e2e8f0}
.quick .row{display:flex; gap:10px; flex-wrap:wrap; font-size:13px; color:#cbd5e1}
.quick a{color:#e2e8f0; text-decoration:none; border-bottom:1px dashed rgba(226,232,240,.4)}
/* sections */
section{padding:24px 0}
.section-head{display:flex; align-items:flex-end; justify-content:space-between; gap:10px; margin-bottom:14px}
.section-head h2{margin:0; font-size:22px}
.section-head p{margin:0;color:var(--muted);font-size:13px; max-width:560px}
.grid-2{display:grid; grid-template-columns: 1fr 1fr; gap:14px}
.box{padding:18px}
ul.clean{margin:0; padding-left:18px; color:#dbeafe}
ul.clean li{margin:8px 0}
/* services */
.services{display:grid; grid-template-columns: repeat(3,1fr); gap:12px}
.service{padding:16px}
.service strong{display:block; margin-bottom:6px}
.service span{color:var(--muted); font-size:13px}
/* gallery */
.gallery{display:grid; grid-template-columns: repeat(5,1fr); gap:10px}
.gallery img{width:100%; height:155px; object-fit:cover; border-radius:16px; border:1px solid var(--border); cursor:pointer}
/* contact */
.contact-grid{display:grid; grid-template-columns: 1fr 1fr; gap:14px}
.form{padding:18px}
.field{display:flex; flex-direction:column; gap:6px; margin-bottom:12px}
label{font-size:12px; color:var(--muted)}
input,textarea{
  width:100%;
  border:1px solid var(--border);
  border-radius:14px;
  padding:12px 12px;
  background: rgba(2,6,23,.35);
  color:var(--text);
  outline:none;
  font-size:16px; /* prevent iOS zoom */
}
textarea{min-height:120px; resize:vertical}
.submit{
  width:100%;
  border:0;
  background: linear-gradient(90deg, rgba(34,197,94,.95), rgba(56,189,248,.92));
  color:#081018;
  padding:14px 14px;
  border-radius:14px;
  font-weight:900;
  cursor:pointer;
  font-size:16px;
}
small.help{display:block;color:var(--muted); margin-top:8px}
.map{padding:0; overflow:hidden}
.map iframe{width:100%; height:100%; min-height:360px; border:0; display:block}
/* footer */
footer{padding:22px 0 40px; color:var(--muted); font-size:12px}
.footer-row{display:flex; justify-content:space-between; gap:10px; flex-wrap:wrap}
/* modal */
.modal{position:fixed; inset:0; background: rgba(0,0,0,.7); display:none; align-items:center; justify-content:center; padding:18px; z-index:200}
.modal.open{display:flex}
.modal img{max-width:min(1000px, 96vw); max-height:86vh; border-radius:18px; border:1px solid rgba(255,255,255,.18)}
/* responsive */
@media (max-width: 900px){
  .hero-grid{grid-template-columns:1fr}
  h1{font-size:34px}
  .gallery{grid-template-columns: repeat(3,1fr)}
  .services{grid-template-columns:1fr}
  .grid-2, .contact-grid{grid-template-columns:1fr}
  .hero-gallery img{height:170px}
  .brand .name span{display:none}
}
@media (max-width: 480px){
  .gallery{grid-template-columns: repeat(2,1fr)}
  .brand img{width:50px;height:50px}
  .hero{padding:26px 0 12px}
  h1{font-size:30px}
  .btn{padding:10px 11px}
}

/* iOS/Android safe areas */
header{padding-top: env(safe-area-inset-top);}
footer{padding-bottom: calc(40px + env(safe-area-inset-bottom));}
.container{padding-left: calc(18px + env(safe-area-inset-left)); padding-right: calc(18px + env(safe-area-inset-right));}

/* =========================
   Theme (Light/Dark Mode)
   ========================= */
:root{
  /* Light (default) */
  --bg: #f7fbff;
  --surface: #ffffff;
  --surface-2: #f1f6fb;
  --text: #0b1220;
  --muted: #475569;
  --border: rgba(22,117,175,.18);

  --primary: #1675AF;      /* from logo */
  --primary-dark: #0E4F78;
  --accent: #17A2B8;
  --shadow: 0 12px 35px rgba(2, 8, 23, .12);
}

html[data-theme="dark"]{
  --bg: #0b0f19;
  --surface: #0f172a;
  --surface-2: #111827;
  --text: #e5e7eb;
  --muted: #94a3b8;
  --border: rgba(148,163,184,.18);

  --primary: #1675AF;
  --primary-dark: #0E4F78;
  --accent: #17A2B8;
  --shadow: 0 12px 35px rgba(0,0,0,.35);
}

/* Auto dark if user prefers, unless they chose explicitly */
@media (prefers-color-scheme: dark){
  html:not([data-theme="light"]):not([data-theme="dark"]) {
    --bg: #0b0f19;
    --surface: #0f172a;
    --surface-2: #111827;
    --text: #e5e7eb;
    --muted: #94a3b8;
    --border: rgba(148,163,184,.18);

    --primary: #1675AF;
    --primary-dark: #0E4F78;
    --accent: #17A2B8;
    --shadow: 0 12px 35px rgba(0,0,0,.35);
  }
}

/* Apply variables */
body{
  background: radial-gradient(1200px 600px at 10% -10%, rgba(23,162,184,.18), transparent 60%),
              radial-gradient(1000px 700px at 90% 10%, rgba(22,117,175,.18), transparent 55%),
              var(--bg) !important;
  color: var(--text) !important;
}

.card{
  background: var(--surface) !important;
  border: 1px solid var(--border) !important;
  box-shadow: var(--shadow) !important;
}

header{
  background: rgba(255,255,255,.7);
  border-bottom: 1px solid var(--border);
}
html[data-theme="dark"] header{
  background: rgba(11,15,25,.72);
}

.kicker, .section-head p, label, small.help, .brand .name span{
  color: var(--muted) !important;
}

.lead, .quick .row, .service span{color: var(--muted) !important;}

a{ color: var(--primary); }
a:hover{ color: var(--primary-dark); }

.btn{background: rgba(22,117,175,.10); border: 1px solid var(--border); color: var(--text) !important;}
.btn:hover{background: rgba(22,117,175,.16);}

.submit{
  background: linear-gradient(90deg, var(--primary), var(--accent)) !important;
  color: #06101b !important;
}

input, textarea{
  background: var(--surface-2) !important;
  border: 1px solid var(--border) !important;
  color: var(--text) !important;
}

.pill{background: rgba(22,117,175,.10) !important; border: 1px solid var(--border) !important; color: var(--text) !important;}

footer{
  background: transparent !important;
  color: var(--muted) !important;
  border-top: 1px solid var(--border);
}


/* ===== Light mode text fix (explicit black text) ===== */
html:not([data-theme="dark"]) .info,
html:not([data-theme="dark"]) .info *,
html:not([data-theme="dark"]) .section-head h2,
html:not([data-theme="dark"]) .section-head p,
html:not([data-theme="dark"]) .box ul li,
html:not([data-theme="dark"]) .box p,
html:not([data-theme="dark"]) .box strong,
html:not([data-theme="dark"]) .contact-grid,
html:not([data-theme="dark"]) footer,
html:not([data-theme="dark"]) .address,
html:not([data-theme="dark"]) .address * {
  color: #000000 !important;
}



/* keep buttons readable */
html:not([data-theme="dark"]) .btn,
html:not([data-theme="dark"]) .submit {
  color: #000000 !important;
}

/* ===== Contrast fix for Safari (avoid black text on auto-dark) ===== */
/* Force pure black text ONLY in explicit light mode */
html[data-theme="light"] body,
html[data-theme="light"] body *{
  color:#000000 !important;
}

/* If user has not chosen dark mode and OS is light, keep text pure black */
@media (prefers-color-scheme: light){
  html:not([data-theme="dark"]) body,
  html:not([data-theme="dark"]) body *{
    color:#000000 !important;
  }
}

/* Ensure dark mode keeps readable light text */
html[data-theme="dark"] body,
html[data-theme="dark"] body *{
  color: var(--text) !important;
}

/* =========================
   Scroll Hamburger Menu
   ========================= */
#menuBtn{
  display:none;
  width:44px;
  height:44px;
  border-radius:12px;
  border:1px solid var(--border);
  background: rgba(22,117,175,.12);
  align-items:center;
  justify-content:center;
  font-size:18px;
  line-height:1;
}
#menuBtn:hover{ background: rgba(22,117,175,.18); }

/* Drawer */
#mobileMenuOverlay{
  position:fixed;
  inset:0;
  background: rgba(0,0,0,.45);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  display:none;
  z-index:9998;
}
#mobileMenu{
  position:fixed;
  top: calc(12px + env(safe-area-inset-top));
  right: 12px;
  left: 12px;
  max-width: 520px;
  margin: 0 auto;
  background: var(--surface);
  border:1px solid var(--border);
  border-radius: 18px;
  box-shadow: var(--shadow);
  padding: 14px;
  display:none;
  z-index:9999;
}
#mobileMenu .menuGrid{
  display:grid;
  gap:10px;
}
#mobileMenu .menuRow{
  display:flex;
  gap:10px;
  flex-wrap:wrap;
}
#mobileMenu .menuTitle{
  font-weight:700;
  margin: 4px 0 8px;
}
#mobileMenu .closeRow{
  display:flex;
  justify-content:space-between;
  align-items:center;
  margin-bottom: 8px;
}
#mobileMenu .closeBtn{
  width:44px;height:44px;border-radius:12px;
  border:1px solid var(--border);
  background: rgba(22,117,175,.10);
  display:flex;align-items:center;justify-content:center;
  font-size:18px;
}

/* When header is scrolled: show hamburger, hide full actions */
header.is-scrolled .nav-actions > a.btn,
header.is-scrolled .nav-actions .lang,
header.is-scrolled .nav-actions #themeToggle{
  display:none !important;
}
header.is-scrolled .nav-actions #menuBtn{
  display:flex !important;
}

/* =========================
   Floating hamburger (premium)
   ========================= */
header.is-scrolled .nav-actions #menuBtn{
  position: fixed;
  right: 14px;
  bottom: calc(14px + env(safe-area-inset-bottom));
  z-index: 10000;
  width: 54px;
  height: 54px;
  border-radius: 16px;
  font-size: 22px;
  box-shadow: var(--shadow);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

/* Make sure it doesn't push layout */
header.is-scrolled .nav-actions{
  position: relative;
}


/* Hide floating button while menu is open */
body.menu-open #menuBtn{ opacity:0; pointer-events:none; }
