/*
 * This is a manifest file that'll be compiled into application.css.
 *
 * With Propshaft, assets are served efficiently without preprocessing steps. You can still include
 * application-wide styles in this file, but keep in mind that CSS precedence will follow the standard
 * cascading order, meaning styles declared later in the document or manifest will override earlier ones,
 * depending on specificity.
 *
 * Consider organizing styles into separate files for maintainability.
 */

:root {
  --ndt-bg: #FBF7EE;
  --ndt-ink: #2C211A;
  --ndt-line: #E3D9C6;
  --ndt-accent: #6E7C4C;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html, body { height: 100%; margin: 0; }
body {
  font-family: ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  color: var(--ndt-ink);
  background: var(--ndt-bg);
}

.ndt { display: flex; flex-direction: column; height: 100vh; }

.ndt-header {
  display: flex; align-items: baseline; gap: 1rem;
  padding: 0.75rem 1.25rem;
  border-bottom: 1px solid var(--ndt-line);
  background: #fff;
}
.ndt-brand { display: flex; align-items: center; gap: 0.5rem; font-weight: 700; font-size: 1.05rem; }
.ndt-mark {
  display: inline-grid; place-items: center;
  width: 1.6rem; height: 1.6rem; border-radius: 0.4rem;
  background: var(--ndt-accent); color: #fff; font-weight: 800;
}
.ndt-sub { color: #8a7d6a; font-size: 0.85rem; }

.ndt-hamburger {
  display: inline-grid; place-items: center; cursor: pointer; background: none;
  border: none; padding: 0.4rem; margin-right: 0.25rem; color: var(--ndt-ink); border-radius: 0.4rem;
}
.ndt-hamburger:hover { background: #f0ece1; }
.ndt-hamburger svg { width: 1.4rem; height: 1.4rem; }

.ndt-menu-backdrop { position: fixed; inset: 0; background: rgba(0,0,0,0.3); z-index: 40; }
.ndt-menu {
  position: fixed; top: 0; left: 0; bottom: 0; width: 260px; background: #fff; z-index: 50;
  box-shadow: 2px 0 12px rgba(0,0,0,0.15); transform: translateX(-100%);
  transition: transform 0.2s ease; display: flex; flex-direction: column;
}
.ndt-menu.is-open { transform: translateX(0); }
.ndt-menu-head {
  display: flex; align-items: center; justify-content: space-between;
  padding: 0.85rem 1rem; border-bottom: 1px solid var(--ndt-line); font-weight: 600;
}
.ndt-menu-close { background: none; border: none; font-size: 1.3rem; line-height: 1; cursor: pointer; color: #8a7d6a; }
.ndt-menu-section { padding: 1rem; display: flex; flex-direction: column; gap: 0.4rem; }
.ndt-menu-label { font-size: 0.7rem; text-transform: uppercase; letter-spacing: 0.06em; color: #8a7d6a; }
.ndt-menu-email { font-size: 0.85rem; color: #8a7d6a; margin-bottom: 0.3rem; word-break: break-all; }
.ndt-menu-item {
  display: block; width: 100%; text-align: left; padding: 0.5rem 0.6rem; font: inherit;
  border: 1px solid var(--ndt-line); border-radius: 0.5rem; background: #fff; color: inherit;
  text-decoration: none; cursor: pointer;
}
.ndt-menu-item:hover { border-color: var(--ndt-accent); }
.ndt-menu-signout { color: #b3402f; }
.ndt-settings-section { margin: 1rem 0; }

.ndt-body { display: flex; flex: 1; min-height: 0; }

.ndt-pane {
  width: 260px; flex-shrink: 0;
  border-right: 1px solid var(--ndt-line);
  background: #fff;
  padding: 1rem; overflow-y: auto;
  display: flex; flex-direction: column;
}
.ndt-pane-title {
  font-size: 0.75rem; text-transform: uppercase; letter-spacing: 0.06em;
  color: #8a7d6a; margin: 0 0 0.5rem;
}
.ndt-field-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 0.35rem; }
.ndt-field-btn {
  width: 100%; text-align: left; cursor: pointer;
  display: flex; justify-content: space-between; align-items: baseline; gap: 0.5rem;
  padding: 0.55rem 0.7rem; border: 1px solid var(--ndt-line); border-radius: 0.5rem;
  background: #fff; color: inherit; font: inherit;
}
.ndt-field-btn:hover { border-color: var(--ndt-accent); }
.ndt-field-btn.is-active { border-color: var(--ndt-accent); background: #F2F0E4; font-weight: 600; }
.ndt-field-name { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ndt-field-zones { color: #8a7d6a; font-size: 0.8rem; flex-shrink: 0; }

.ndt-method { margin-top: 1rem; }
.ndt-method-toggle { display: flex; gap: 0.25rem; }
.ndt-method-btn {
  flex: 1; cursor: pointer; font: inherit; font-size: 0.8rem;
  padding: 0.4rem 0.5rem; border: 1px solid var(--ndt-line); border-radius: 0.4rem;
  background: #fff; color: inherit;
}
.ndt-method-btn:hover { border-color: var(--ndt-accent); }
.ndt-method-btn.is-active { background: var(--ndt-accent); color: #fff; border-color: var(--ndt-accent); }

.ndt-layers { margin-top: 1rem; }
.ndt-tier { display: flex; flex-wrap: wrap; gap: 0.25rem; margin-bottom: 0.6rem; }
.ndt-chip {
  cursor: pointer; font: inherit; font-size: 0.78rem;
  padding: 0.3rem 0.55rem; border: 1px solid var(--ndt-line); border-radius: 1rem;
  background: #fff; color: inherit;
}
.ndt-chip:hover { border-color: var(--ndt-accent); }
.ndt-chip.is-active { background: var(--ndt-accent); color: #fff; border-color: var(--ndt-accent); }
.ndt-tier:empty::before { content: "—"; color: #c4b89f; font-size: 0.8rem; }

.ndt-check { display: flex; align-items: center; gap: 0.4rem; font-size: 0.82rem; margin: 0.3rem 0 0.6rem; cursor: pointer; }

.ndt-legend { margin-top: 0.3rem; }
.ndt-legend-bar { height: 0.6rem; border-radius: 0.3rem; border: 1px solid rgba(0,0,0,0.1); }
.ndt-legend-row { display: flex; justify-content: space-between; gap: 0.5rem; font-size: 0.72rem; color: #8a7d6a; margin-top: 0.2rem; }
.ndt-legend-row span:nth-child(2) { text-align: center; flex: 1; }

.ndt-info {
  margin-top: 1rem; display: flex; gap: 0.6rem; align-items: center;
  padding: 0.7rem; border: 1px solid var(--ndt-line); border-radius: 0.5rem; background: #F7F3E8;
}
.ndt-info-swatch { width: 1.4rem; height: 1.4rem; border-radius: 0.3rem; flex-shrink: 0; border: 1px solid rgba(0,0,0,0.1); }
.ndt-info-label { font-weight: 600; }
.ndt-info-meta { color: #8a7d6a; font-size: 0.85rem; }

.ndt-signout {
  margin-left: auto; cursor: pointer; font: inherit; font-size: 0.8rem;
  padding: 0.35rem 0.7rem; border: 1px solid var(--ndt-line); border-radius: 0.4rem;
  background: #fff; color: inherit;
}
.ndt-signout:hover { border-color: var(--ndt-accent); }

.ndt-auth { max-width: 22rem; margin: 4rem auto; padding: 1.5rem; }
.ndt-auth h1 { font-size: 1.2rem; margin: 0 0 1rem; }
.ndt-auth-form { display: flex; flex-direction: column; gap: 0.75rem; }
.ndt-auth-form label { display: flex; flex-direction: column; gap: 0.25rem; font-size: 0.85rem; }
.ndt-auth-form input { padding: 0.5rem; border: 1px solid var(--ndt-line); border-radius: 0.4rem; font: inherit; }
.ndt-auth-btn {
  margin-top: 0.5rem; cursor: pointer; font: inherit; font-weight: 600;
  padding: 0.55rem; border: none; border-radius: 0.4rem; background: var(--ndt-accent); color: #fff;
}
.ndt-auth-link { font-size: 0.85rem; margin-top: 1rem; color: #8a7d6a; }
.ndt-auth-alert { color: #b3402f; font-size: 0.85rem; }
.ndt-auth-notice { color: var(--ndt-accent); font-size: 0.85rem; }

.ndt-map-area { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.ndt-topbar {
  background: #fff; border-bottom: 1px solid var(--ndt-line);
  padding: 0.5rem 0.75rem; display: flex; flex-direction: column; gap: 0.35rem;
}
.ndt-topbar-row { display: flex; align-items: center; gap: 0.5rem; min-width: 0; }
.ndt-topbar-label {
  flex-shrink: 0; width: 3rem; font-size: 0.7rem; text-transform: uppercase;
  letter-spacing: 0.05em; color: #8a7d6a;
}
.ndt-topbar-row .ndt-tier { flex-wrap: nowrap; overflow-x: auto; margin: 0; padding-bottom: 2px; }
.ndt-map { flex: 1; min-height: 0; min-width: 0; }

