/* affiche: forms and tables on /notices pages, loaded after the host site's
   own style.css. Kept in the 90s idiom of naplesrentals' advertiser form:
   grooved fieldsets, bold Arial labels, inset inputs, plain gray-ruled tables.
   Class names start with af- and never contain the tokens the site repos keep
   out of class names for EasyList (see docs/DESIGN.md). */

.af-form fieldset {
  max-width: 420px;
  margin: 10px 0;
  padding: 8px 12px 12px;
  border: 2px groove #999999;
}

.af-form legend {
  font-family: Arial, Helvetica, sans-serif;
  font-size: 12px;
  font-weight: bold;
  color: #003366;
}

.af-form label {
  display: block;
  margin: 8px 0 2px;
  font-family: Arial, Helvetica, sans-serif;
  font-size: 12px;
  font-weight: bold;
}

.af-form input[type="email"],
.af-form input[type="text"],
.af-form input[type="number"],
.af-form input[type="url"],
.af-form select,
.af-form textarea {
  width: 100%;
  max-width: 300px;
  box-sizing: border-box;
  padding: 3px;
  border: 2px inset #999999;
  font-family: "Times New Roman", Times, serif;
  font-size: 15px;
}

.af-form button {
  display: block;
  margin-top: 12px;
  font-family: Arial, Helvetica, sans-serif;
  font-size: 13px;
}

.af-note {
  font-family: Arial, Helvetica, sans-serif;
  font-size: 12px;
  color: #666666;
}

.af-error {
  max-width: 420px;
  padding: 4px 8px;
  border: 1px solid #cc0000;
  background: #fff0f0;
  font-family: Arial, Helvetica, sans-serif;
  font-size: 12px;
  font-weight: bold;
  color: #cc0000;
}

.af-table {
  border-collapse: collapse;
  margin: 10px 0;
  font-family: Arial, Helvetica, sans-serif;
  font-size: 12px;
}

.af-table th,
.af-table td {
  padding: 3px 8px;
  border: 1px solid #999999;
  text-align: left;
  vertical-align: top;
}

.af-table th {
  background: #e8eef6;
  color: #003366;
  font-size: 10px;
  letter-spacing: 1px;
  text-transform: uppercase;
}

/* One-line notice after an action (?done=...). */
.af-flash {
  max-width: 420px;
  padding: 4px 8px;
  border: 1px solid #336633;
  background: #f0fff0;
  font-family: Arial, Helvetica, sans-serif;
  font-size: 12px;
  font-weight: bold;
  color: #225522;
}

.af-button {
  display: inline-block;
  padding: 3px 10px;
  border: 2px outset #999999;
  background: #e8eef6;
  font-family: Arial, Helvetica, sans-serif;
  font-size: 13px;
  font-weight: bold;
  color: #003366;
  text-decoration: none;
}

.af-inline {
  display: inline;
  margin: 0;
}

.af-actions {
  white-space: nowrap;
}

/* The editor. */
.af-editor fieldset.af-preview {
  max-width: none;
}

.af-count {
  font-family: Arial, Helvetica, sans-serif;
  font-size: 11px;
  color: #666666;
}

.af-count.af-over {
  font-weight: bold;
  color: #cc0000;
}

.af-editor .af-choice {
  display: inline-block;
  margin: 4px 12px 4px 0;
}

.af-editor .af-choice label {
  display: inline;
  margin: 0 0 0 3px;
  font-size: 15px;
  font-weight: normal;
}

/* Swatch chips: real radio buttons (so arrow keys and Tab work), visually
   replaced by the chip; the checked chip is outlined, the focused one ringed. */
.af-chips {
  position: relative;
}

.af-chip {
  display: inline-block;
  margin: 4px 6px 4px 0;
}

.af-chip input {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: 0;
  opacity: 0;
}

.af-editor .af-chip label {
  display: inline-block;
  margin: 0;
  padding: 2px 6px 2px 2px;
  border: 1px solid #999999;
  background: #ffffff;
  font-size: 11px;
  font-weight: normal;
  cursor: pointer;
}

.af-chip-color {
  display: inline-block;
  width: 16px;
  height: 16px;
  margin-right: 4px;
  border: 1px solid #666666;
  vertical-align: middle;
}

.af-chip input:checked + label {
  outline: 3px solid #003366;
  outline-offset: 1px;
  font-weight: bold;
}

.af-chip input:focus-visible + label {
  box-shadow: 0 0 0 5px #ffcc00;
}

.af-chip input:disabled + label {
  opacity: 0.35;
  cursor: not-allowed;
  text-decoration: line-through;
}

.af-frames {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  gap: 12px;
}

.af-frame {
  margin: 0;
}

.af-frame-box {
  display: block;
  border: 0;
}

.af-editor .af-buttons button {
  display: inline-block;
  margin-right: 8px;
}

/* Add funds and the history. */
.af-funds .af-choice {
  margin: 4px 0;
}

.af-funds .af-choice label {
  display: inline;
  margin: 0 0 0 3px;
  font-size: 15px;
  font-weight: normal;
}

.af-form input.af-custom {
  max-width: 6em;
}

.af-table td.af-num {
  text-align: right;
  white-space: nowrap;
}

/* Stripe test mode (STRIPE_MODE = "test"): on every advertiser page. */
.af-test-mode {
  margin: 0 0 8px;
  padding: 6px 10px;
  border: 2px solid #b38f00;
  background: #ffe14d;
  color: #000000;
  font-family: Arial, Helvetica, sans-serif;
  font-size: 13px;
  font-weight: bold;
  text-align: center;
}

/* The landing page's three steps. */
.af-steps {
  margin: 8px 0 10px;
  padding-left: 22px;
}

.af-steps li {
  margin: 3px 0;
}

.af-check {
  max-width: 420px;
  margin-top: 12px;
}

.af-address {
  margin-left: 16px;
}

/* The wordmark is a link on /notices pages (the Courant's own style.css only
   has it as plain text there). naplesrentals' style.css has this same rule. */
.wordmark a,
.wordmark a:visited {
  color: var(--ink);
  text-decoration: none;
}

.wordmark a:hover {
  text-decoration: none;
}
