/* Work-area map (quote form + area.html) */
.am { display: grid; gap: 12px; margin-top: 4px; }
.am-search { display: flex; flex-wrap: wrap; gap: 8px; }
.am-search .am-q { flex: 1 1 220px; min-width: 0; }
.am-search .btn { min-height: 50px; padding: 10px 16px; border-radius: var(--radius-sm); }
.am-msg { margin: 0; color: var(--forest-700); font-weight: 600; font-size: .95rem; }
.am-msg:empty { display: none; }
.am-mapwrap { position: relative; border-radius: var(--radius); overflow: hidden; border: 1.5px solid var(--ash-200); background: var(--forest-900); }
.am-map { height: min(62vh, 470px); min-height: 320px; width: 100%; }
.am-map.is-drawing { cursor: crosshair; }
.am-map.is-drawing .leaflet-interactive { cursor: crosshair; }
.am-ctrls { position: absolute; top: 10px; right: 10px; z-index: 500; display: flex; flex-direction: column; gap: 6px; align-items: flex-end; }
.am-chip { display: inline-flex; align-items: center; gap: 6px; min-height: 38px; padding: 6px 12px; border: 0; border-radius: 999px; background: rgba(255,255,255,.95); color: var(--forest-900); font: 700 .9rem var(--font-body); cursor: pointer; box-shadow: 0 2px 8px rgba(0,0,0,.25); }
.am-chip[aria-pressed="true"] { background: var(--forest-700); color: #fff; }
.am-slope.is-loading::after { content: ""; width: 12px; height: 12px; border-radius: 50%; border: 2px solid currentColor; border-right-color: transparent; animation: am-spin .8s linear infinite; }
@keyframes am-spin { to { transform: rotate(360deg); } }
.am-legend { position: absolute; left: 10px; bottom: 34px; z-index: 500; background: rgba(255,255,255,.95); border-radius: 10px; padding: 10px 12px; display: grid; gap: 3px; font-size: .8rem; color: var(--ink); box-shadow: 0 2px 8px rgba(0,0,0,.25); max-width: 190px; }
.am-legend[hidden] { display: none; }
.am-legend strong { font-family: var(--font-display); font-size: .85rem; }
.am-legend span { display: flex; align-items: center; gap: 6px; white-space: nowrap; }
.am-legend i { width: 22px; height: 14px; flex: none; border-radius: 3px; background-color: #2f4a35; }
.am-legend-close { background-image: repeating-linear-gradient(0deg, #fff 0 1px, transparent 1px 3px); }
.am-legend-far { background-image: repeating-linear-gradient(0deg, #fff 0 1px, transparent 1px 7px); }
.am-topo img { filter: invert(1) drop-shadow(0 0 1.2px rgba(0,0,0,.9)); }
.am-legend em { color: var(--ink-soft); font-style: normal; }
.am-legend small { color: var(--ink-soft); white-space: normal; margin-top: 2px; }
.am-hint { position: absolute; left: 54px; right: 104px; top: 10px; z-index: 500; background: rgba(20,35,27,.92); color: #fff; padding: 8px 14px; border-radius: 14px; font-size: .9rem; font-weight: 600; text-align: center; }
.am-hint[hidden] { display: none; }
.am-v { background: #fff; border: 3px solid var(--ember-500); border-radius: 50%; box-shadow: 0 1px 4px rgba(0,0,0,.4); }
.am-v-first { background: var(--ember-500); border-color: #fff; }
.am-v-edit { cursor: grab; }
.am-tools { display: flex; flex-wrap: wrap; gap: 8px; }
.am-tools .btn { min-height: 46px; padding: 10px 16px; }
.am-tools .btn[hidden] { display: none; }
.am-tools .btn[disabled] { opacity: .5; cursor: not-allowed; }
.am-empty { margin: 0; color: var(--ink-soft); font-size: .95rem; }
.am-total { font-size: 1.1rem; color: var(--forest-900); }
.am-total strong { font-family: var(--font-display); font-size: 1.35rem; color: var(--ember-600); }
.am-list { list-style: none; margin: 8px 0 0; padding: 0; display: grid; gap: 8px; }
.am-list li { display: grid; grid-template-columns: 1fr auto; gap: 2px 12px; align-items: center; padding: 10px 12px; border: 1px solid var(--ash-200); border-radius: var(--radius-sm); background: var(--ash-50); }
.am-name { grid-column: 1; justify-self: start; background: none; border: 0; padding: 0; font: 700 1rem var(--font-body); color: var(--forest-900); cursor: pointer; text-align: left; }
.am-name:hover { color: var(--ember-600); }
.am-stats { grid-column: 1; color: var(--ink-soft); font-size: .92rem; }
.am-stats.is-pending { font-style: italic; }
.am-del { grid-column: 2; grid-row: 1 / span 2; background: none; border: 1px solid var(--ash-200); border-radius: 999px; padding: 6px 12px; font: 600 .85rem var(--font-body); color: var(--danger); cursor: pointer; }
.am-del:hover { background: #fdecea; }
.leaflet-container { font-family: var(--font-body); }
.leaflet-control-attribution { font-size: 10px; }
@media (max-width: 560px) {
  .am-search .btn span { display: none; }
  .am-search .btn { padding: 10px 14px; }
  .am-search .am-addr span, .am-search .am-addr { font-size: .9rem; }
  .am-tools .btn { flex: 1 1 auto; }
}
