:root{
  --bg:#f6f7fb;
  --card:#ffffff;
  --text:#111827;
  --muted:#6b7280;
  --border:#e5e7eb;
  --shadow:0 12px 30px rgba(0,0,0,.08);
  --radius:18px;
}

*{box-sizing:border-box}
body{
  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:var(--bg);
}

.page{
  min-height:100vh;
  display:flex;
  align-items:center;
  justify-content:center;
  padding:24px;
}

.card{
  width:min(560px, 100%);
  background:var(--card);
  border:1px solid var(--border);
  border-radius:var(--radius);
  box-shadow:var(--shadow);
  padding:26px;
}

.logo{
  width:48px;height:48px;
  border-radius:999px;
  display:flex;
  align-items:center;
  justify-content:center;
  background:#fde68a;
  margin:0 auto 8px;
  font-size:22px;
}

h1{
  margin:8px 0 8px;
  text-align:center;
  font-size:24px;
}

.sub{
  margin:0 0 16px;
  text-align:center;
  color:var(--muted);
  line-height:1.35;
}

.field{ margin:14px 0; }
label{
  display:block;
  font-size:14px;
  color:#374151;
  margin:0 0 6px;
}

select, input{
  width:100%;
  padding:12px 12px;
  border:1px solid var(--border);
  border-radius:12px;
  outline:none;
  font-size:15px;
  background:#fff;
}

.grid2{
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:12px;
}

.primary, .secondary{
  width:100%;
  border:none;
  border-radius:14px;
  padding:12px 14px;
  font-size:15px;
  cursor:pointer;
}

.primary{
  background:#111827;
  color:#fff;
}
.primary:disabled{
  opacity:.5;
  cursor:not-allowed;
}
.secondary{
  background:#f3f4f6;
  color:#111827;
  border:1px solid var(--border);
}

.note{
  margin:16px 0 0;
  color:var(--muted);
  font-size:12px;
  line-height:1.35;
}

.geocoder{
  width:100%;
}
.geocoder .mapboxgl-ctrl-geocoder{
  min-width:100%;
  max-width:100%;
  border-radius:12px;
  border:1px solid var(--border);
  box-shadow:none;
}
.geocoder .mapboxgl-ctrl-geocoder--input{
  height:44px;
  font-size:15px;
}

.hintrow{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
  margin-top:8px;
}
.linkbtn{
  border:none;
  background:transparent;
  color:#111827;
  text-decoration:underline;
  cursor:pointer;
  padding:0;
  font-size:13px;
  text-align:left;
  white-space:nowrap;
}
.status{
  font-size:12px;
}
.muted{ color:var(--muted); }

.result{
  margin-top:12px;
  padding:12px 12px;
  border-radius:12px;
  border:1px dashed var(--border);
  min-height:20px;
  display:none;
}
.result.show{ display:block; }
.result.ok{ border-style:solid; }
.result.bad{ border-style:solid; }

.modal{
  position:fixed;
  inset:0;
  display:none;
  align-items:center;
  justify-content:center;
  padding:18px;
  z-index:50;
}
.modal.show{ display:flex; }
.modal__backdrop{
  position:absolute;
  inset:0;
  background:rgba(0,0,0,.45);
}
.modal__panel{
  position:relative;
  width:min(820px, 100%);
  background:#fff;
  border-radius:18px;
  overflow:hidden;
  border:1px solid var(--border);
  box-shadow:var(--shadow);
  z-index:2;
}
.modal__header{
  display:flex;
  align-items:flex-start;
  justify-content:space-between;
  gap:12px;
  padding:14px 14px 10px;
  border-bottom:1px solid var(--border);
}
.modal__header h2{
  margin:0;
  font-size:18px;
}
.modal__sub{
  margin:4px 0 0;
  color:var(--muted);
  font-size:13px;
}
.iconbtn{
  width:36px;height:36px;
  border-radius:12px;
  border:1px solid var(--border);
  background:#fff;
  cursor:pointer;
}
.map{
  width:100%;
  height:420px;
}
.modal__footer{
  display:flex;
  gap:10px;
  padding:12px 14px 14px;
  border-top:1px solid var(--border);
}
.modal__footer .secondary, .modal__footer .primary{
  width:auto;
  flex:1;
}
.modal__fineprint{
  padding:0 14px 14px;
  color:var(--muted);
  font-size:12px;
}
@media (max-width:560px){
  .grid2{ grid-template-columns:1fr; }
  .hintrow{ flex-direction:column; align-items:flex-start; }
  .linkbtn{ white-space:normal; }
  .map{ height:380px; }
}


/* Alerts */
.alert{
  margin-top: 10px;
  padding: 12px 14px;
  border-radius: 12px;
  border: 1px solid var(--border);
  font-size: 14px;
  line-height: 1.35;
}
.alert--top{
  border-color: rgba(220, 38, 38, .35);
  background: rgba(220, 38, 38, .08);
}
.alert--bottom{
  margin-top: 14px;
  border-color: rgba(2, 132, 199, .25);
  background: rgba(2, 132, 199, .06);
}
.whatsapp{
  width: 100%;
  border: 0;
  border-radius: 14px;
  padding: 14px 16px;
  font-weight: 700;
  cursor: pointer;
  margin-top: 10px;
  background: #16a34a;
  color: white;
}
.whatsapp:hover{ filter: brightness(0.98); }

.small-muted{margin-top:6px;font-size:12px;opacity:.7;}
