.gate-app { background: #f5f6f3; }
[hidden] { display: none !important; }
.gate-header { background: #12392f; color: white; padding: 1rem max(1.5rem, calc((100vw - 1200px)/2)); display: flex; align-items: center; justify-content: space-between; gap: 1rem; }
.brand { display: flex; gap: .7rem; align-items: center; color: white; text-decoration: none; font-weight: 750; }
.brand img { width: 42px; height: 42px; }
.brand small { display: block; color: #bcd9cf; font-size: .6rem; letter-spacing: .18em; margin-top: .25rem; }
.gate-shell { max-width: 1248px; margin: auto; padding: 1.25rem 1.5rem 2rem; }
.gate-facility { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: .7rem 0 1.4rem; }
.gate-facility h1 { margin: .3rem 0 0; font-size: 2.25rem; letter-spacing: -.04em; }
.facility-controls { display: flex; align-items: center; gap: 1rem; }
.facility-controls select { min-width: 230px; }
.facility-controls label { font-size: .75rem; color: var(--muted); }
.connection { font-size: .75rem; }
.gate-nav { display: flex; gap: 1.5rem; border-bottom: 1px solid var(--line); margin-bottom: 1.75rem; }
.gate-nav button { min-height: 48px; color: var(--muted); background: none; border: 0; border-bottom: 3px solid transparent; padding: .6rem .1rem; font-weight: 750; }
.gate-nav button.is-active { color: var(--brand); border-bottom-color: var(--brand); }
.gate-nav a { margin-left: auto; align-self: center; color: var(--muted); font-size: .85rem; }
.section-intro { display: flex; justify-content: space-between; align-items: center; margin-bottom: 1rem; }
.section-intro h2 { margin: 0 0 .4rem; font-size: 1.35rem; }
.section-intro p { color: var(--muted); margin: 0; font-size: .9rem; }
.today-label { color: var(--muted); font-size: .8rem; }
.arrival-cards { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.arrival-card { display: grid; text-align: left; position: relative; padding: 1.5rem 1.75rem; border: 1px solid #bdccc3; background: #fff; border-radius: 1rem; color: var(--ink); transition: border-color .15s, box-shadow .15s; }
.arrival-card:hover { border-color: var(--brand); box-shadow: 0 6px 22px #12392f10; }
.arrival-card--truck { background: #ebf1eb; }
.arrival-card .card-number { font-size: .7rem; font-weight: 800; letter-spacing: .1em; color: var(--muted); margin-bottom: 1rem; }
.card-icon { position: absolute; right: 1.5rem; top: 1.3rem; background: #e3eee7; color: var(--brand); border-radius: 50%; width: 34px; height: 34px; display: grid; place-items: center; font-size: 1.4rem; }
.arrival-card strong { font-size: clamp(1.2rem, 2.4vw, 1.6rem); letter-spacing: -.03em; margin-bottom: .5rem; }
.arrival-card > span:not(.card-number):not(.card-icon):not(.card-action) { color: var(--muted); font-size: .9rem; }
.arrival-card .card-action { margin-top: 1.5rem; padding-top: 1rem; border-top: 1px solid var(--line); color: var(--brand); font-weight: 750; font-size: .85rem; display: flex; justify-content: space-between; }
.metrics { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1rem; margin: 1.5rem 0; }
.metrics > div { border-left: 2px solid #d0ddd5; padding-left: 1rem; display: flex; flex-direction: column; gap: .4rem; }
.metrics span { color: var(--muted); font-size: .8rem; }
.metrics strong { font-size: 1.7rem; font-weight: 650; }
.active-panel { padding: 1.5rem; box-shadow: none; }
.active-panel h2 { font-size: 1.3rem; }
.operations-metrics { margin: 1rem 0; }
.operations-equipment-list { max-height: 360px; overflow: auto; }
#operations-panel > .active-panel { margin-top: 1rem; }
.hint { color: var(--muted); font-size: .82rem; line-height: 1.5; }
.list-toolbar { display: grid; grid-template-columns: minmax(0,1fr) 215px; gap: 1rem; margin-bottom: 1rem; }
.list-toolbar label { font-size: .8rem; }
.person-cell strong, .person-cell small { display: block; }
.table-wrap { position: relative; }
.person-cell small { color: var(--muted); font-size: .8rem; margin-top: .3rem; }
.visit-chip { display: inline-block; font-size: .72rem; font-weight: 750; color: #365845; background: #edf3ed; padding: .35rem .6rem; border-radius: .4rem; }
.visit-chip--truck { background: #eaf0f6; color: #334e70; }
.visit-actions { display: flex; flex-wrap: wrap; gap: .4rem; }
.entry-panel { max-width: 900px; margin: auto; }
.entry-panel h2 { margin: .4rem 0; font-size: 1.8rem; }
.entry-panel form { margin-top: 1.5rem; }
.back-button { background: none; border: 0; color: var(--muted); padding: .3rem 0; margin-bottom: 1.5rem; min-height: 44px; }
.form-fields { padding: 0; margin: 0; border: 0; min-width: 0; }
.field label span { color: var(--muted); font-weight: normal; }
.equipment-choice { border: 0; padding: 0; margin: 1.5rem 0 1rem; }
.equipment-choice legend { font-weight: 750; margin-bottom: .7rem; }
.equipment-options { display: grid; grid-template-columns: repeat(4, 1fr); gap: .5rem; }
.equipment-options label { display: flex; align-items: center; gap: .45rem; padding: .8rem .6rem; border: 1px solid #bdccc3; border-radius: .6rem; font-size: .8rem; cursor: pointer; }
.equipment-options label:has(input:checked) { border-color: var(--brand); background: #edf5f1; font-weight: 750; }
.equipment-options input { accent-color: var(--brand); }
.equipment-section { background: #f5f7f4; padding: 1rem; border-radius: .8rem; margin-bottom: 1rem; }
.optional-details { border-top: 1px solid var(--line); margin: 1.5rem 0; padding-top: 1rem; }
.optional-details summary { cursor: pointer; min-height: 44px; color: var(--muted); font-size: .9rem; }
.optional-details[open] summary { margin-bottom: .7rem; }
.preview-banner { display: flex; align-items: center; justify-content: space-between; gap: 1rem; background: #fff3d8; color: #694815; border: 1px solid #e7d09f; border-radius: .65rem; padding: .8rem 1rem; font-size: .8rem; margin-bottom: 1rem; }
.preview-banner a { color: inherit; white-space: nowrap; }
.preview-link { display: block; margin-top: 1.25rem; color: var(--brand); }
.service-notice { padding: .8rem 1rem; margin-bottom: 1rem; background: #fff4e1; border: 1px solid #e0cda9; border-radius: .6rem; color: #694815; font-size: .85rem; }
.gate-footer { display: flex; justify-content: space-between; gap: 1rem; color: var(--muted); font-size: .7rem; margin-top: 1.5rem; padding-top: 1rem; }
dialog { width: min(650px, calc(100vw - 2rem)); max-height: calc(100vh - 2rem); overflow-y: auto; border: 1px solid var(--line); border-radius: 1rem; padding: 1.5rem; color: var(--ink); }
dialog::backdrop { background: #0b211cb3; }
.dialog-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 1rem; }
.dialog-heading h2 { margin: .3rem 0 0; }
.checkout-summary { padding: .8rem; background: #f0f4f0; border-radius: .5rem; }
.departure-grid { margin-top: 1rem; }
@media (max-width: 760px) {
  .active-panel table, .active-panel tbody { display: block; width: 100%; }
  .active-panel thead { position: absolute; left: 0; top: 0; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
  .active-panel tr { display: grid; grid-template-columns: minmax(0, 1fr) auto; border-bottom: 1px solid var(--line); padding: .75rem 0; }
  .active-panel td { white-space: normal; border: 0; padding: .35rem; overflow-wrap: anywhere; }
  .active-panel td:nth-child(3) { grid-column: 1 / -1; color: var(--muted); font-size: .8rem; }
  .active-panel td:nth-child(4) { align-self: center; color: var(--muted); font-size: .8rem; }
  .active-panel td:last-child { justify-self: end; }
  .active-panel .empty-row { grid-column: 1 / -1; }
}
@media (max-width: 760px) { .gate-shell { padding: 1rem; } .gate-header { padding: .8rem 1rem; } .gate-header .account { font-size: .75rem; } .gate-facility { align-items: flex-start; flex-direction: column; } .facility-controls { width: 100%; justify-content: space-between; } .facility-controls .field { flex: 1; } .facility-controls select { min-width: 0; } .arrival-cards { grid-template-columns: 1fr; } .arrival-card { padding: 1.2rem; } .metrics { grid-template-columns: 1fr 1fr; } .equipment-options { grid-template-columns: 1fr 1fr; } .list-toolbar { grid-template-columns: 1fr; } .gate-nav { gap: 1rem; } .gate-nav a { font-size: .7rem; } .today-label { display: none; } .gate-footer { flex-wrap: wrap; } .preview-banner { align-items: flex-start; } }
