/* Theme controls work in both themes. The original dark stylesheet is unchanged. */
.admin-theme-toggle { position: fixed; right: max(14px, env(safe-area-inset-right)); bottom: max(14px, env(safe-area-inset-bottom)); z-index: 90; border: 1px solid var(--admin-line); border-radius: 999px; background: var(--admin-panel); color: var(--admin-text); padding: 10px 16px; font: 750 .78rem/1.2 Inter, system-ui, sans-serif; box-shadow: 0 6px 25px rgba(0,0,0,.2); cursor: pointer; }
.admin-theme-toggle:hover, .admin-theme-toggle:focus-visible { border-color: var(--admin-accent); outline-offset: 2px; }
.password-entry { position: relative; display: block; }
.admin-form .password-entry input { padding-right: 76px; }
.password-toggle { position: absolute; top: 50%; right: 7px; transform: translateY(-50%); border: 0; border-radius: 7px; background: transparent; color: var(--admin-text); padding: 9px; font-size: .8rem; font-weight: 750; cursor: pointer; }
.password-toggle:hover, .password-toggle:focus-visible { background: rgba(232,117,45,.13); }
.admin-form .remember-choice { display: flex; align-items: flex-start; gap: 10px; line-height: 1.4; cursor: pointer; }
.admin-form .remember-choice input { flex: 0 0 auto; width: 18px; min-height: 18px; margin: 1px 0 0; padding: 0; accent-color: var(--admin-accent); }
.admin-form .remember-choice span { color: var(--admin-text); font-size: .82rem; font-weight: 600; }

html[data-admin-theme="light"] { color-scheme: light; --admin-bg: #f6f5f2; --admin-panel: #fff; --admin-panel-soft: #f1f0ed; --admin-line: #d8d8d5; --admin-text: #25272b; --admin-muted: #5d626b; --admin-accent: #ae4c13; --admin-danger: #a12720; }
html[data-admin-theme="light"] .admin-auth-body { background: radial-gradient(circle at 18% 15%, rgba(232,117,45,.14), transparent 36%), var(--admin-bg); }
html[data-admin-theme="light"] .auth-shell { box-shadow: 0 25px 65px rgba(30,30,30,.12); }
html[data-admin-theme="light"] .admin-header { background: rgba(250,249,247,.94); }
html[data-admin-theme="light"] .admin-wordmark,
html[data-admin-theme="light"] .admin-header nav > a,
html[data-admin-theme="light"] .summary-note strong,
html[data-admin-theme="light"] .trip-admin-card__facts strong,
html[data-admin-theme="light"] .trip-admin-card__actions a,
html[data-admin-theme="light"] .editor-breadcrumb a,
html[data-admin-theme="light"] .trip-counts strong,
html[data-admin-theme="light"] .secondary-button,
html[data-admin-theme="light"] .dialog-close,
html[data-admin-theme="light"] .admin-form label,
html[data-admin-theme="light"] .trip-editor-form label,
html[data-admin-theme="light"] .site-choice-fieldset legend,
html[data-admin-theme="light"] .date-label-fieldset legend,
html[data-admin-theme="light"] .date-label-preview output,
html[data-admin-theme="light"] .preference-fieldset legend,
html[data-admin-theme="light"] .reference-form > label,
html[data-admin-theme="light"] .reference-type-options legend,
html[data-admin-theme="light"] .reference-photo-field > span,
html[data-admin-theme="light"] .reference-photo-choice strong,
html[data-admin-theme="light"] .reference-sync-panel strong,
html[data-admin-theme="light"] .reference-assign-form label,
html[data-admin-theme="light"] .reference-card__location a,
html[data-admin-theme="light"] .reference-card__location span,
html[data-admin-theme="light"] .media-card-manage,
html[data-admin-theme="light"] .media-manage-choices button,
html[data-admin-theme="light"] .media-manage-result,
html[data-admin-theme="light"] .visit-story-actions button,
html[data-admin-theme="light"] .visit-story-photo-order button { color: var(--admin-text); }
html[data-admin-theme="light"] .admin-form input:not([type="checkbox"]):not([type="radio"]):not([type="color"]),
html[data-admin-theme="light"] .admin-form textarea,
html[data-admin-theme="light"] .admin-form select,
html[data-admin-theme="light"] .trip-editor-form input:not([type="checkbox"]):not([type="radio"]):not([type="color"]),
html[data-admin-theme="light"] .trip-editor-form textarea,
html[data-admin-theme="light"] .trip-editor-form select,
html[data-admin-theme="light"] .slug-input,
html[data-admin-theme="light"] .reference-form input[type="text"],
html[data-admin-theme="light"] .reference-form textarea,
html[data-admin-theme="light"] .reference-form select,
html[data-admin-theme="light"] .reference-assign-form select,
html[data-admin-theme="light"] .visit-story-text-edit textarea,
html[data-admin-theme="light"] .visit-story-field textarea,
html[data-admin-theme="light"] .visit-story-field select,
html[data-admin-theme="light"] .visit-story-field input[type="text"],
html[data-admin-theme="light"] .media-day-control select { background: #fff; color: var(--admin-text); }
html[data-admin-theme="light"] .form-alert { background: #fff0ef; color: #a12720; border-color: #e1b3af; }
html[data-admin-theme="light"] .form-notice,
html[data-admin-theme="light"] .admin-banner { background: #e8f6ec; color: #215c3d; border-color: #b8dbc5; }
html[data-admin-theme="light"] .admin-sync-indicator { color: var(--admin-text); }
html[data-admin-theme="light"] .text-button:hover { color: var(--admin-text); }
html[data-admin-theme="light"] .state-pill--draft { background: #ecebe8; color: #454a52; }
html[data-admin-theme="light"] .state-pill--published { background: #dff5e7; color: #205e3c; }
html[data-admin-theme="light"] .publication-row strong { color: #83400f; }
html[data-admin-theme="light"] .publication-row em { color: #765627; }
html[data-admin-theme="light"] .trip-admin-card__media--empty { background: linear-gradient(135deg, #edc8b0, #deddd9); }
html[data-admin-theme="light"] .admin-button { color: #fff; background: #a9440e; }
html[data-admin-theme="light"] .admin-button--muted { background: #d9d9d8; color: #505158; }
html[data-admin-theme="light"] .secondary-button:hover { background: #f1f0ed; border-color: #9fa1a3; }
html[data-admin-theme="light"] .admin-dialog__backdrop { background: rgba(32,35,39,.4); }
html[data-admin-theme="light"] .admin-dialog__panel,
html[data-admin-theme="light"] .placement-dialog { box-shadow: 0 25px 70px rgba(25,25,25,.18); }
html[data-admin-theme="light"] .field-info::after { background: #fff; color: var(--admin-text); }
html[data-admin-theme="light"] .readiness-card li.is-ready span { background: #ddf4e5; color: #21633c; }
html[data-admin-theme="light"] .readiness-card li.is-missing span { background: #fff0e4; color: #9e4b13; }
html[data-admin-theme="light"] .readiness-card > p { color: #8a4018; }
html[data-admin-theme="light"] .visit-story-block,
html[data-admin-theme="light"] .reference-card,
html[data-admin-theme="light"] .reference-location-status,
html[data-admin-theme="light"] .reference-sync-panel,
html[data-admin-theme="light"] .check-row,
html[data-admin-theme="light"] .site-choice,
html[data-admin-theme="light"] .preference-options label,
html[data-admin-theme="light"] .media-manage-choices button { background: #f8f8f6; }
html[data-admin-theme="light"] .visit-story-actions button,
html[data-admin-theme="light"] .visit-story-photo-order button { background: #f3f2f0; }
html[data-admin-theme="light"] .story-drag-handle { background: #fff; color: #333943; border-color: #b5b9be; }
html[data-admin-theme="light"] .order-controls button,
html[data-admin-theme="light"] .day-drag-handle,
html[data-admin-theme="light"] .visit-story-photo-order button {
    border-radius: 7px;
    border-color: #b5b9be;
    background: #fff;
    color: #333943;
}
html[data-admin-theme="light"] .order-controls button:hover:not(:disabled),
html[data-admin-theme="light"] .day-drag-handle:hover,
html[data-admin-theme="light"] .visit-story-photo-order button:hover:not(:disabled) { border-color: #a9440e; background: #fff3e8; color: #84330e; }
html[data-admin-theme="light"] .visit-story-coordinate-grid input { background: #fff; color: var(--admin-text); }
html[data-admin-theme="light"] .reference-card p { color: var(--admin-text); }
html[data-admin-theme="light"] .offline-home p { color: var(--admin-muted); }
html[data-admin-theme="light"] .visit-story-live-preview iframe { background: #fff; }
/* Image viewers and the miniature story preview retain their photographic treatment. */
/* Day editor and media workspace */
html[data-admin-theme="light"] .day-drag-handle:hover,
html[data-admin-theme="light"] .order-controls button,
html[data-admin-theme="light"] .visit-outline-item > a > span,
html[data-admin-theme="light"] .content-stage-note strong,
html[data-admin-theme="light"] .media-upload-form label,
html[data-admin-theme="light"] .media-upload-summary a,
html[data-admin-theme="light"] .media-foundation-note ul,
html[data-admin-theme="light"] .media-review-summary strong,
html[data-admin-theme="light"] .media-bulk-review button,
html[data-admin-theme="light"] .media-bulk-day button,
html[data-admin-theme="light"] .media-day-group__actions button,
html[data-admin-theme="light"] .media-visit-plan strong,
html[data-admin-theme="light"] .media-visit-start span,
html[data-admin-theme="light"] .media-visit-dialog-field,
html[data-admin-theme="light"] .reference-online-note strong { color: var(--admin-text); }
html[data-admin-theme="light"] .new-place-fields summary,
html[data-admin-theme="light"] .visit-location-override summary,
html[data-admin-theme="light"] .place-edit-link,
html[data-admin-theme="light"] .add-visit-link,
html[data-admin-theme="light"] .visit-arrange-link,
html[data-admin-theme="light"] .visit-story-edit-details summary,
html[data-admin-theme="light"] .media-reference-timeline time { color: #93400f; }
html[data-admin-theme="light"] .visit-date-context { color: #245b3e; }
html[data-admin-theme="light"] .visit-date-context.is-undated { color: #924518; }
html[data-admin-theme="light"] .visit-location-override,
html[data-admin-theme="light"] .media-clock-confirm,
html[data-admin-theme="light"] .media-review-summary span { background: #f8f8f6; }
html[data-admin-theme="light"] .media-upload-form input:not([type="checkbox"]):not([type="radio"]),
html[data-admin-theme="light"] .media-upload-form select,
html[data-admin-theme="light"] .media-visit-start select,
html[data-admin-theme="light"] .media-visit-dialog-field select,
html[data-admin-theme="light"] .media-visit-dialog-field input,
html[data-admin-theme="light"] .media-bulk-day select { background: #fff; color: var(--admin-text); }
html[data-admin-theme="light"] .media-bulk-review,
html[data-admin-theme="light"] .media-bulk-day { background: #fff; }
html[data-admin-theme="light"] .media-upload-summary { color: #87451c; }
html[data-admin-theme="light"] .media-file-picker input[type="file"]::file-selector-button,
html[data-admin-theme="light"] .media-day-control button { background: #eae9e6; color: var(--admin-text); }
html[data-admin-theme="light"] .media-upload-item > span { background: #ebeae7; color: var(--admin-text); }
html[data-admin-theme="light"] .media-visit-preview { color: #87400f; }
html[data-admin-theme="light"] .media-visit-dialog [data-visit-create-error] { color: #a12720; }
html[data-admin-theme="light"] .media-review-buttons button:hover { color: var(--admin-text); }
html[data-admin-theme="light"] .media-review-buttons button[data-media-review="unsure"][aria-pressed="true"] { color: #735019; }
html[data-admin-theme="light"] .media-review-buttons button[data-media-review="exclude"][aria-pressed="true"] { color: #a12720; }
html[data-admin-theme="light"] .media-manage-choices button:hover { background: #fff3eb; }
html[data-admin-theme="light"] .media-manage-result { background: #f8f8f6; }
html[data-admin-theme="light"] .reference-delete { color: #a12720; }
html[data-admin-theme="light"] .reference-photo-field > input[type="file"] { color: var(--admin-text); }
html[data-admin-theme="light"] .media-reference-suggestion { color: var(--admin-text); }
html[data-admin-theme="light"] .visit-story-live-preview [data-story-preview-unsaved] { color: #91420e; }
html[data-admin-theme="light"] .placement-dialog { color: var(--admin-text); }
html[data-admin-theme="light"] .placement-screen { color: #fff; }
