/* BlockView — sign-in screen and account menu (uses the tokens in base.css) */
input[type=email] { font: inherit; width: 100%; height: 32px; padding: 0 9px; border-radius: var(--radius-sm);
  border: 1px solid var(--line-2); background: var(--raised); color: var(--ink); }
html.signed-out #app { display: none; }
#auth { min-height: 100vh; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 18px;
  padding: 24px 16px; background: var(--page); }
.auth-card { width: min(380px, 100%); padding: 28px 28px 22px; background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--radius); box-shadow: var(--shadow); }
.auth-brand { margin-bottom: 22px; }
.auth-brand .brand { display: flex; align-items: center; justify-content: center; gap: 10px; width: auto; text-align: center; }
.auth-brand .logo { display: none; }   /* the whole drawing is shown above it */
.auth-card h1 { font-family: var(--font-head); font-size: 24px; font-weight: 600; margin: 0 0 4px; letter-spacing: -.01em; }
.auth-mammoth { display: block; width: 92px; margin: 0 auto 18px; padding: 10px; background: var(--paper); border-radius: var(--radius); border: 1px solid var(--line); }
.auth-sub { margin: 0 0 6px; color: var(--ink-2); }
.auth-card input { height: 38px; font-size: 14px; }
.auth-card .note.fine { margin: 5px 0 0; }
.auth-card button.primary { height: 38px; margin-top: 18px; font-size: 14px; }
.auth-card button:disabled { opacity: .6; cursor: default; }
.auth-err { margin: 14px 0 0; padding: 8px 10px; border-radius: var(--radius-sm); font-size: 12.5px;
  color: var(--critical); background: color-mix(in srgb, var(--critical) 9%, transparent);
  border: 1px solid color-mix(in srgb, var(--critical) 35%, transparent); }
.auth-swap { margin: 16px 0 0; text-align: center; }
.auth-swap button.link { font-size: 12px; }
.auth-foot { max-width: 380px; text-align: center; margin: 0; }
.auth-site { color: var(--ink-2); font-size: 12px; }
#btnAcct { border-radius: 50%; font-weight: 650; background: var(--accent-wash); border-color: transparent; }
#acctMenu { width: 250px; }
.acct-who { display: flex; flex-direction: column; gap: 1px; padding: 6px 8px 4px; }
.acct-who b { font-weight: 600; overflow: hidden; text-overflow: ellipsis; }
@media print { #auth { display: none; } }
.auth-ok { margin: 14px 0 0; padding: 8px 10px; border-radius: var(--radius-sm); font-size: 12.5px; color: var(--good-ink);
  background: color-mix(in srgb, var(--good) 10%, transparent); border: 1px solid color-mix(in srgb, var(--good) 35%, transparent); }
.auth-forgot { display: block; margin: 8px 0 0 auto; font-size: 12px; }
#btnAcct.attn { box-shadow: 0 0 0 2px var(--surface), 0 0 0 4px var(--warning); }

/* Organization ------------------------------------------------------------- */
#pOrg h4, #pFields h4, #pData h4 { font-size: 12px; font-weight: 600; color: var(--ink-2); margin: 16px 0 6px; }
.org-name { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; margin-top: 8px; }
.org-name b { font-size: 15px; font-weight: 650; overflow: hidden; text-overflow: ellipsis; }
.org-bill { margin: 4px 0 0; line-height: 1.6; }
.org-bill .badge { margin: 0; vertical-align: 1px; }
.org-list { list-style: none; margin: 0 0 8px; padding: 0; border: 1px solid var(--line); border-radius: var(--radius-sm); }
.org-list li { display: flex; align-items: center; gap: 10px; padding: 7px 10px; border-top: 1px solid var(--line); font-size: 12.5px; }
.org-list li:first-child { border-top: none; }
.org-list .nm { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 550; }
.org-list .note { white-space: nowrap; }
.org-list select { width: auto; height: 26px; font-size: 12px; padding: 0 6px; }
.role { color: var(--muted); font-size: 12px; }
button.link.danger { color: var(--critical); }
.org-invite { display: flex; gap: 6px; margin-top: 4px; }
.org-invite input { flex: 1; min-width: 0; }
.org-invite select { width: auto; }
#inviteLink { margin-top: 8px; }
#inviteLink p { margin: 0 0 4px; }
/* a viewer can look but not change */
html.read-only #btnDraw, html.read-only label.btn:has(#fileIn), html.read-only #pBlockSet { display: none !important; }

/* Place search and welcome ---------------------------------------------------- */
.place { position: relative; margin-bottom: 8px; }
.place input[type=search], .welcome input[type=search] { font: inherit; width: 100%; height: 32px; padding: 0 9px; border-radius: var(--radius-sm);
  border: 1px solid var(--line-2); background: var(--raised); color: var(--ink); }
.place-res { position: absolute; left: 0; right: 0; top: calc(100% + 4px); z-index: 1200; list-style: none; margin: 0; padding: 4px;
  background: var(--raised); border: 1px solid var(--line); border-radius: var(--radius-sm); box-shadow: var(--shadow); }
.place-res button { width: 100%; height: auto; padding: 7px 8px; border: none; background: none; justify-content: flex-start; text-align: left;
  white-space: normal; font-weight: 500; line-height: 1.35; }
.place-res button:hover { background: var(--surface-2); }
.place-res .note { padding: 4px 8px 2px; font-size: 10.5px; }
.map-empty > .welcome { pointer-events: auto; text-align: left; max-width: 430px; gap: 0; padding: 22px 24px 18px; }
.welcome h2 { font-size: 18px; font-weight: 650; text-transform: none; letter-spacing: -.01em; color: var(--ink); }
.welcome .lead { margin: 4px 0 12px; color: var(--ink-2); }
.welcome ol { margin: 0 0 12px; padding-left: 20px; display: flex; flex-direction: column; gap: 12px; }
.welcome li b { font-weight: 600; }
.welcome-row { display: flex; gap: 8px; margin-top: 6px; flex-wrap: wrap; }
.welcome-row input { flex: 1; min-width: 150px; }
.welcome .note { margin: 6px 0 0; line-height: 1.45; }
.welcome .note .link { font-size: 12px; }
html.read-only #placeForm { display: block; }

/* Outline editing and block facts ---------------------------------------------- */
.edit-bar { top: 10px; left: 50%; transform: translateX(-50%); display: flex; align-items: center; gap: 10px; padding: 8px 10px 8px 14px;
  max-width: calc(100% - 20px); font-size: 12.5px; color: var(--ink-2); }
.edit-bar span { flex: 1; min-width: 0; }
.edit-bar b { color: var(--ink); font-weight: 600; }
.setf select, .setf input[type=text], .setf textarea { font: inherit; width: 100%; padding: 0 8px; border-radius: var(--radius-sm);
  border: 1px solid var(--line-2); background: var(--raised); color: var(--ink); font-weight: 400; }
.setf select, .setf input[type=text] { height: 30px; }
#factGrid input[type=number] { padding-right: 8px; }
.setf textarea { padding: 6px 8px; resize: vertical; line-height: 1.4; }
.setf.notes { margin-top: 8px; }
.kv .pre { white-space: pre-wrap; }
html.print-layout #editBar { display: none !important; }

/* Field log ------------------------------------------------------------------- */
.log-form { display: flex; flex-direction: column; gap: 6px; }
.log-row { display: flex; gap: 6px; }
.log-row input, .log-row select { flex: 1; min-width: 0; height: 30px; }
.log-form textarea { font: inherit; width: 100%; padding: 6px 9px; border-radius: var(--radius-sm); border: 1px solid var(--line-2);
  background: var(--raised); color: var(--ink); resize: vertical; line-height: 1.4; }
.log-form button { align-self: flex-end; }
.log-list { list-style: none; margin: 12px 0 0; padding: 0; display: flex; flex-direction: column; gap: 10px; max-height: 320px; overflow-y: auto; scrollbar-width: thin; }
.log-list li { padding-top: 10px; border-top: 1px solid var(--line); }
.log-list li:first-child, .log-list li.none { border-top: none; padding-top: 0; }
.log-meta { display: flex; align-items: center; gap: 8px; font-size: 12px; }
.log-meta .badge { margin: 0; padding: 1px 7px; }
.log-meta b { font-weight: 600; }
.log-meta .who { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.log-list p { margin: 4px 0 0; white-space: pre-wrap; overflow-wrap: anywhere; line-height: 1.45; }
html.print-layout #pLog { display: none !important; }

/* Organization settings --------------------------------------------------------- */
.org-list .badge { margin: 0; }
.check:has(input:disabled), select:disabled { opacity: .65; cursor: default; }
html.read-only #btnFull { display: none; }

/* Official alerts, surroundings, soil ------------------------------------------- */
.official { list-style: none; margin: 7px 0 0; padding: 0; display: flex; flex-direction: column; gap: 4px; }
.official li { border-radius: 6px; background: var(--surface-2); font-size: 12px; }
.official li.warn { background: color-mix(in srgb, var(--warning) 18%, var(--surface-2)); }
.official summary { display: flex; align-items: baseline; gap: 8px; padding: 6px 8px; cursor: pointer; list-style: none; }
.official summary::-webkit-details-marker { display: none; }
.official summary b { flex: 1; min-width: 0; font-weight: 600; }
.official summary .d { color: var(--muted); font-size: 11px; white-space: nowrap; }
.official p { margin: 0; padding: 0 8px 7px; color: var(--ink-2); line-height: 1.45; white-space: pre-line; }
.official p:empty { display: none; }
.kv.around { margin-top: 8px; font-size: 12px; gap: 6px 12px; line-height: 1.45; }
.kv.around .m { color: var(--muted); }
.kv.around .badge { margin: 0; vertical-align: 1px; }
.kv.around > span:nth-child(even) { font-variant-numeric: tabular-nums; }
.soil-list { list-style: none; margin: 8px 0 10px; padding: 0; display: flex; flex-direction: column; gap: 9px; }
.soil-list li { display: flex; gap: 9px; align-items: flex-start; }
.soil-list .dot { width: 10px; height: 10px; border-radius: 3px; flex: none; margin-top: 4px; }
.soil-list li > div { flex: 1; min-width: 0; }
.soil-h { display: flex; justify-content: space-between; gap: 8px; align-items: baseline; font-size: 12.5px; }
.soil-h b { font-weight: 600; }
.soil-h .note { white-space: nowrap; }
#pSoil .op-main { margin-top: 0; }
#pSoil .note { line-height: 1.4; }
#pSoil > #soilBody > .note:last-child { margin-top: 8px; font-size: 11px; }
html.print-layout #pSoil, html.print-layout #opsAround .note { display: none !important; }

/* Season models ----------------------------------------------------------------- */
.dd-row { display: grid; grid-template-columns: 1.5fr 1fr 1fr; gap: 8px; margin-top: 6px; }
.dd-row label { display: flex; flex-direction: column; gap: 3px; font-size: 11px; font-weight: 550; color: var(--ink-2); }
.dd-row input { font: inherit; width: 100%; height: 28px; padding: 0 6px; border-radius: var(--radius-sm); border: 1px solid var(--line-2);
  background: var(--raised); color: var(--ink); font-size: 12px; font-variant-numeric: tabular-nums; }
html.print-layout #opsModels { display: none !important; }

/* Water boundaries --------------------------------------------------------------- */
#pWater .kv.around { margin-top: 0; }
#pWater .check { margin-top: 10px; }
#pWater .note { margin-top: 8px; font-size: 11px; line-height: 1.4; }
html.print-layout #pWater { display: none !important; }
/* Account section of the settings page (account.js) */
.acct-row > span:first-child { display: flex; flex-direction: column; gap: 1px; min-width: 0; }
.acct-row b { font-weight: 600; color: var(--ink); }
.acct-row .note { font-weight: 400; overflow-wrap: anywhere; }
.acct-row button { flex: none; }
.acct-row button[aria-pressed="true"] { background: var(--sel); color: var(--ink); }
