/* strip-extras.css — Settings → Strip → Pattern / Text on the strip,
   Booth → Guest messages (app.js renderStripExtrasSettings), and the guest
   message step (guest-message.js, .gm-*). Same palette as settings.css /
   ui-kit.css. Loaded after settings.css. */

/* ---------- Settings: pattern tiles ---------- */
#settings-panel #pattern-options { grid-template-columns: repeat(auto-fill, minmax(min(100%, 150px), 1fr)); }
#settings-panel .pattern-option { display: flex; align-items: center; gap: 10px; cursor: pointer; }
#settings-panel .pattern-swatch {
  flex: 0 0 auto; width: 40px; height: 40px; border-radius: 9px; border: 1px solid rgba(255, 255, 255, .25);
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, .25);
}
#settings-panel .pattern-option span { font-size: 15px; }

/* ---------- Settings: text on the strip ---------- */
#settings-panel #strip-text-fields { margin-top: 2px; }
#settings-panel .st-field { display: block; margin: 0 0 12px; }
#settings-panel .st-field > span {
  display: block; font-size: 13px; font-weight: 700; color: var(--st-muted, #a596c4); margin: 0 0 6px; letter-spacing: .02em;
}
#settings-panel .st-input {
  box-sizing: border-box; width: 100%; min-height: 48px; padding: 10px 14px; border-radius: 12px;
  border: 1px solid var(--st-border-2, #45306f); background: #120a22; color: var(--st-text, #efe9fb);
  font: 600 17px/1.2 -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
  -webkit-appearance: none; appearance: none;
}
#settings-panel .st-input::placeholder { color: var(--st-faint, #6f6290); }
#settings-panel .st-input:focus { outline: none; border-color: var(--st-accent, #b14dff); box-shadow: 0 0 0 3px rgba(177, 77, 255, .35); }
#settings-panel .st-input.focused {
  outline: 3px solid #ffe14d !important; outline-offset: 2px; border-color: #ffe14d !important;
  box-shadow: 0 0 22px rgba(255, 225, 77, .55) !important;
}
#settings-panel .st-chips { grid-template-columns: repeat(auto-fill, minmax(min(100%, 130px), 1fr)); }
#settings-panel .st-chips .logo-option { cursor: pointer; justify-content: center; text-align: center; }
#settings-panel .st-font-galter { font-family: 'Galter', serif !important; font-size: 19px !important; }
#settings-panel .st-font-booth { font-family: 'PhotoboothFont', sans-serif !important; font-size: 19px !important; }
#settings-panel .st-font-galter_caps { font-family: 'Galter', serif !important; letter-spacing: .14em; font-size: 16px !important; }
#settings-panel #guest-message-options .logo-option,
#settings-panel #strip-text-toggle .logo-option { cursor: pointer; }
html.is-mobile #settings-panel .st-input { font-size: 16px; }    /* no iOS zoom on focus */
html.is-mobile #settings-panel #pattern-options { grid-template-columns: repeat(2, minmax(0, 1fr)); }
/* mobile.css gives every option row width calc(100% - 32px) + auto margins
   (made for one-column lists): in these grids the cells must fill their track */
html.is-mobile #settings-panel #pattern-options > div,
html.is-mobile #settings-panel #strip-text-card .option-list > div,
html.is-mobile #settings-panel #guest-message-options > div {
  width: auto !important; max-width: none !important; margin: 0 !important;
}
html.is-mobile #settings-panel .pattern-option { padding: 10px !important; }
html.is-mobile #settings-panel .pattern-option span { font-size: 16px !important; }
html.is-mobile #settings-panel .st-chips { grid-template-columns: repeat(3, minmax(0, 1fr)); }
html.is-mobile #settings-panel .st-chips .logo-option { padding: 10px 6px !important; }

/* ---------- Guest message step ---------- */
.gm-overlay {
  position: fixed; inset: 0; z-index: 2147483000; display: flex; align-items: center; justify-content: center;
  padding: max(12px, env(safe-area-inset-top)) max(12px, env(safe-area-inset-right)) max(12px, env(safe-area-inset-bottom)) max(12px, env(safe-area-inset-left));
  box-sizing: border-box; overflow-y: auto; -webkit-overflow-scrolling: touch;
  background: radial-gradient(1000px 600px at 0% 0%, rgba(177, 77, 255, .28), transparent 60%),
              radial-gradient(900px 600px at 100% 100%, rgba(255, 63, 164, .2), transparent 60%), rgba(11, 6, 22, .94);
  color: #efe9fb; font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
  animation: gm-in .25s ease-out;
  /* sizes follow the screen: finger-sized on a phone, readable from afar on a TV */
  --gm-fs: clamp(16px, 1.25vw + 8px, 30px);
}
@keyframes gm-in { from { opacity: 0; } to { opacity: 1; } }
.gm-card {
  width: min(1100px, 100%); margin: auto; box-sizing: border-box; display: flex; flex-direction: column; gap: calc(var(--gm-fs) * .7);
  padding: calc(var(--gm-fs) * 1.1); border-radius: 22px; border: 1px solid #45306f;
  background: linear-gradient(180deg, #1f1338, #170d2b); box-shadow: 0 20px 60px rgba(0, 0, 0, .55);
}
.gm-head { text-align: center; }
.gm-title { margin: 0; font-size: calc(var(--gm-fs) * 1.6); font-weight: 800; line-height: 1.15; }
.gm-sub { margin: 6px 0 0; font-size: calc(var(--gm-fs) * .8); color: #a596c4; }
.gm-timer { height: 6px; border-radius: 3px; background: rgba(255, 255, 255, .1); overflow: hidden; }
.gm-timer > span {
  display: block; height: 100%; background: linear-gradient(90deg, #b14dff, #ff3fa4); transform-origin: left center;
  transition: transform .2s linear;
}
.gm-left { margin: 0; min-height: 1.2em; text-align: center; font-size: calc(var(--gm-fs) * .8); color: #ffb547; }
.gm-field { position: relative; display: block; }
.gm-input {
  box-sizing: border-box; width: 100%; min-height: calc(var(--gm-fs) * 2.6); padding: 0 calc(var(--gm-fs) * 3.6) 0 calc(var(--gm-fs) * .8);
  border-radius: 14px; border: 2px solid #45306f; background: #0b0616; color: #fff;
  font: 600 max(16px, calc(var(--gm-fs) * 1.1)) / 1.2 'Galter', Georgia, serif; -webkit-appearance: none; appearance: none;
}
.gm-input::placeholder { color: #6f6290; }
.gm-input:focus { outline: none; border-color: #b14dff; box-shadow: 0 0 0 4px rgba(177, 77, 255, .35); }
.gm-count { position: absolute; right: calc(var(--gm-fs) * .8); top: 50%; transform: translateY(-50%); font-size: calc(var(--gm-fs) * .7); color: #a596c4; pointer-events: none; }
.gm-or { text-align: center; font-size: calc(var(--gm-fs) * .75); color: #a596c4; text-transform: uppercase; letter-spacing: .14em; }
.gm-pad-wrap {
  position: relative; height: clamp(160px, 38vh, 440px); border-radius: 16px; border: 2px dashed #45306f;
  background: #0b0616;
}
.gm-pad-wrap::after {        /* the "sign on the line" baseline */
  content: ''; position: absolute; left: 8%; right: 8%; bottom: 26%; border-bottom: 2px solid rgba(165, 150, 196, .35); pointer-events: none;
}
.gm-pad { position: absolute; inset: 0; width: 100%; height: 100%; touch-action: none; cursor: crosshair; border-radius: 14px; z-index: 1; }
.gm-pad-hint {
  position: absolute; left: 0; right: 0; top: 38%; text-align: center; font-size: calc(var(--gm-fs) * .95); color: #6f6290; pointer-events: none;
}
.gm-pad-wrap.has-ink .gm-pad-hint { display: none; }
.gm-pad-wrap .gm-clear { position: absolute; right: 10px; top: 10px; z-index: 2; min-height: 44px; font-size: calc(var(--gm-fs) * .75); }
.gm-actions { display: flex; gap: calc(var(--gm-fs) * .6); }
.gm-btn {
  min-height: max(52px, calc(var(--gm-fs) * 2.4)); padding: 0 calc(var(--gm-fs) * 1); border-radius: 14px; border: 1px solid #45306f;
  background: #1f1338; color: #efe9fb; font: 800 calc(var(--gm-fs) * .95) / 1 -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
  cursor: pointer; display: inline-flex; align-items: center; justify-content: center; gap: 10px; -webkit-tap-highlight-color: transparent;
}
.gm-btn:hover { border-color: #b14dff; }
.gm-btn:focus { outline: none; }
.gm-btn:focus-visible { outline: 4px solid #ffe14d; outline-offset: 3px; box-shadow: 0 0 24px rgba(255, 225, 77, .5); }
.gm-skip { flex: 1; }
.gm-done { flex: 2; border-color: transparent; background: linear-gradient(135deg, #b14dff, #ff3fa4); color: #fff; }
.gm-btn kbd {
  font: 700 calc(var(--gm-fs) * .55) / 1 ui-monospace, Menlo, Consolas, monospace; padding: 4px 6px; border-radius: 6px;
  background: rgba(255, 255, 255, .14); color: inherit; opacity: .85;
}
html.is-mobile .gm-btn kbd { display: none; }      /* no keyboard keys on phones */
@media (max-width: 600px) {
  .gm-card { padding: 16px; border-radius: 18px; }
  .gm-title { font-size: 24px; }
  .gm-pad-wrap { height: clamp(150px, 34vh, 320px); }
}
@media (max-height: 520px) {                         /* phone in landscape / keyboard open */
  .gm-overlay { align-items: flex-start; }
  .gm-pad-wrap { height: 150px; }
}
@media (prefers-reduced-motion: reduce) { .gm-overlay { animation: none; } .gm-timer > span { transition: none; } }

/* Background (plain / gradient + 2nd colour + direction) and Photo frame:
   option rows with a swatch; .st-sub = a small label row (not a stop). */
#settings-panel #strip-bg-options, #settings-panel #frame-options { grid-template-columns: repeat(auto-fill, minmax(min(100%, 150px), 1fr)); }
#settings-panel #strip-bg-options .logo-option, #settings-panel #frame-options .logo-option { display: flex; align-items: center; gap: 10px; cursor: pointer; }
#settings-panel .st-sub { grid-column: 1 / -1; margin: 6px 0 -2px; font-size: 12px; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; color: var(--st-muted); }
#settings-panel .color2-option { min-height: 44px; padding: 6px 10px; }
#settings-panel .color2-option span { font-size: 13px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; text-transform: capitalize; }
#settings-panel .color2-option .pattern-swatch { border-radius: 50%; }
html.is-mobile #settings-panel #strip-bg-options, html.is-mobile #settings-panel #frame-options { grid-template-columns: repeat(2, minmax(0, 1fr)); }

/* Gradient balance slider: strip colour ◂ slider ▸ 2nd colour */
#settings-panel .st-range { grid-column: 1 / -1; display: flex; align-items: center; gap: 12px; padding: 4px 2px 10px; }
#settings-panel .st-range .pattern-swatch { width: 30px; height: 30px; border-radius: 50%; }
#settings-panel .st-range input[type=range] {
  flex: 1; height: 14px; border-radius: 999px; appearance: none; -webkit-appearance: none; cursor: pointer;
  background: linear-gradient(90deg, var(--a), var(--b)); border: 1px solid rgba(255, 255, 255, .25);
}
#settings-panel .st-range input[type=range]::-webkit-slider-thumb {
  -webkit-appearance: none; width: 30px; height: 30px; border-radius: 50%; background: #fff; border: 3px solid var(--g, #ff7ac8);
  box-shadow: 0 3px 10px rgba(0, 0, 0, .45);
}
#settings-panel .st-range input[type=range]::-moz-range-thumb {
  width: 26px; height: 26px; border-radius: 50%; background: #fff; border: 3px solid var(--g, #ff7ac8);
}
#settings-panel .st-range input.focused { outline: 3px solid #ffe14d; outline-offset: 6px; }
