:root { --accent: #c2410c; --accent-soft: color-mix(in srgb, #c2410c 12%, #fff); }

.glyph-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(46px,1fr));gap:6px;margin:12px 0}
.glyph{font-size:1.2rem;min-height:44px;border:1px solid #e5e7eb;background:#fff;border-radius:10px;cursor:pointer}
.glyph.on{outline:2px solid var(--accent)}
.stage{display:flex;gap:16px;flex-wrap:wrap;align-items:flex-start;margin:12px 0}
.stage svg,.stage canvas{width:min(320px,86vw);background:#fff;border:1px solid #e5e7eb;border-radius:16px;touch-action:none}
.tool-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(118px,1fr));gap:8px;margin:8px 0 14px}
.tool-grid button{border:1px solid #e5e7eb;background:#fff;border-radius:12px;min-height:42px;cursor:pointer}
.tool-grid button[aria-pressed=true]{background:var(--accent);color:#fff;border-color:transparent}
.opt-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(150px,1fr));gap:8px}
.opt-grid input,.card input,.card select,.card textarea,main textarea,main input,main select{width:100%;box-sizing:border-box}
.sent{font-size:1.35rem;line-height:1.75;min-height:4rem}
.cmd{font-family:ui-monospace,monospace;font-size:1.35rem}
.typed{font-family:ui-monospace,monospace;color:#0369a1}
.sheet h2{margin:0 0 8px}
.sheet table{width:100%;border-collapse:collapse}
.sheet td,.sheet th{border-bottom:1px solid #e5e7eb;padding:4px;text-align:left}
.sheet .sum{font-size:1.3rem;font-weight:700}
.sudo{border-collapse:collapse}
.sudo td{width:36px;height:36px;border:1px solid #d1d5db;text-align:center}
.sudo td input{width:32px;border:0;text-align:center;font-size:1rem}
.nono div{display:flex;gap:4px;align-items:center;margin:2px 0}
.nono button{width:28px;height:28px;border:1px solid #d1d5db}
.nono button.on{background:#111}
.mine{display:grid;grid-template-columns:repeat(9,32px);gap:2px}
.mine button{height:32px}
.grid.g15{display:grid;grid-template-columns:repeat(15,1.45rem);gap:1px;width:max-content}
.grid.g8{display:grid;grid-template-columns:repeat(8,2.1rem);gap:2px;width:max-content}
.grid button{height:1.45rem;padding:0;background:#f4efe4}
.grid.g8 button{height:2.1rem}
.grid button.on{outline:2px solid var(--accent)}
.photo-list{list-style:none;padding:0}
.photo-list li{display:flex;gap:10px;margin:8px 0}
.photo-list img{width:72px;height:72px;object-fit:cover;border-radius:8px}
#map{background:#e5e7eb;border-radius:12px}
label{display:block;margin:8px 0}
.row{display:flex;gap:8px;flex-wrap:wrap;align-items:center;margin:8px 0}
.two{display:grid;grid-template-columns:1fr 1fr;gap:16px}
@media(max-width:800px){.two{grid-template-columns:1fr}}
#rain-cv{width:100%;max-width:800px;height:auto;border-radius:12px;margin-top:8px}
.sheet-form{padding:18px;border-radius:18px}
.sheet-form .field{margin:0 0 14px}
.sheet-form .field>label{display:block;margin:0 0 6px;font-size:.82rem;font-weight:700;color:var(--muted)}
.sheet-form input,.sheet-form select,.sheet-form textarea{width:100%;border:1px solid #d5dee8;border-radius:12px;background:#f8fafc;min-height:44px;padding:10px 12px;box-shadow:inset 0 1px 0 #fff}
.sheet-form input:focus{outline:none;border-color:var(--accent);background:#fff;box-shadow:0 0 0 3px var(--accent-soft)}
.sheet-form .btn{border-radius:12px;min-height:44px}
.trip .field{margin:0 0 12px}
.trip .field>label{display:block;margin:0 0 6px;font-size:.82rem;font-weight:800;color:var(--muted)}
.trip input{width:100%;box-sizing:border-box;border:1px solid #d5dee8;border-radius:12px;background:#f8fafc;min-height:44px;padding:10px 12px}
.trip input:focus{outline:none;border-color:var(--accent);background:#fff;box-shadow:0 0 0 3px var(--accent-soft)}
.trip-grid{display:grid;grid-template-columns:minmax(0,1fr) minmax(280px,1fr);gap:16px;align-items:start}
#map{position:relative;z-index:0;height:560px;min-height:320px;border-radius:18px;border:1px solid var(--line);background:#e5e7eb;overflow:hidden}
.leaflet-container img,.leaflet-container canvas{max-width:none !important;max-height:none !important}
.preset-row{display:flex;flex-wrap:wrap;gap:12px 16px;align-items:flex-end;margin:0 0 14px}
.preset-row .field{flex:1 1 220px;margin:0}
.preset-pick{display:flex;flex-direction:column;gap:6px;margin:0;min-width:240px}
.preset-pick span{font-size:.82rem;font-weight:800;color:var(--muted)}
.preset-pick select{width:100%;min-height:44px}
.day-head{display:flex;flex-wrap:wrap;align-items:flex-end;gap:8px;margin:0 0 14px}
.day-head .day-date{display:flex;flex-direction:column;gap:6px;margin:0;width:auto}
.day-head .day-date span{font-size:.82rem;font-weight:800;color:var(--muted)}
.day-head .day-date input{width:168px}
.day-bar{display:flex;gap:8px;flex-wrap:wrap;margin:0}
.day-bar button{min-height:40px;padding:8px 14px;border-radius:999px;border:1px solid var(--line);background:#fff;font-weight:800;cursor:pointer}
.day-bar button.on{background:var(--accent);color:#fff;border-color:transparent}
.search-field{position:relative}
.hits{list-style:none;margin:6px 0 0;padding:6px;position:absolute;z-index:20;left:0;right:0;background:#fff;border:1px solid var(--line);border-radius:14px;box-shadow:var(--shadow);max-height:280px;overflow:auto}
.hits button{display:flex;flex-direction:column;align-items:flex-start;gap:2px;width:100%;text-align:left;border:0;background:transparent;border-radius:10px;padding:8px 10px;cursor:pointer}
.hits button:hover{background:var(--soft)}
.hits span{color:var(--muted);font-size:.82rem}
.stop{display:flex;gap:10px;padding:12px;border:1px solid var(--line);border-radius:14px;background:#fff;margin:8px 0}
.stop-n{flex:none;width:28px;height:28px;border-radius:50%;background:var(--accent);color:#fff;display:flex;align-items:center;justify-content:center;font-weight:800}
.stop-body{min-width:0;flex:1}
.stop-body strong{display:block}
.stop-acts{margin:8px 0 0}
.leg{margin:8px 0 8px 38px;padding:8px 12px;border-radius:12px;background:#fff7ed;border:1px solid #fed7aa}
.leg b{display:block}
.leg span{color:var(--muted);font-size:.82rem}
.mode.walk{color:#15803d}
.mode.bike{color:#0369a1}
.mode.drive{color:#c2410c}
.mode.far{color:#64748b}
.mode.ferry{color:#0e7490}
.mode.transit{color:#6d28d9}
.trip-opts{display:flex;flex-wrap:wrap;gap:10px 18px;align-items:center;margin:0 0 14px;padding:12px 14px;border:1px solid var(--line);border-radius:14px;background:#fff}
.trip-opts .check{display:inline-flex;align-items:center;gap:8px;flex:0 0 auto;width:auto;min-width:max-content;margin:0;padding:0;white-space:nowrap;font-size:.95rem;font-weight:800}
.trip-opts .check input{width:18px;height:18px;min-height:18px;margin:0;padding:0;border:0;border-radius:4px;background:transparent;box-shadow:none}
.trip-actions select{width:auto;min-width:168px;max-width:240px;min-height:40px;border:1px solid var(--line);border-radius:12px;background:#fff;padding:6px 10px}
.pin{background:var(--accent);color:#fff;border-radius:50%;width:28px;height:28px;display:flex;align-items:center;justify-content:center;font-weight:800;border:2px solid #fff;box-shadow:0 2px 6px rgba(0,0,0,.25)}
.day-head .day-date{max-width:none}
@media(max-width:900px){.trip-grid{grid-template-columns:1fr}#map{height:360px;order:-1}}
@media print{.no-print,.search-field,.day-bar,.stop-acts{display:none !important}#map{height:240px}}

select:not([size]):not([multiple]) {
  -webkit-appearance: none;
  appearance: none;
  padding-right: 42px;
  background-image: linear-gradient(45deg, transparent 50%, currentColor 50%), linear-gradient(135deg, currentColor 50%, transparent 50%);
  background-position: right 22px center, right 16px center;
  background-size: 6px 6px, 6px 6px;
  background-repeat: no-repeat;
}
