/* ── Vendor / Booth Application — farmers-market morning ────────────
   Daylight cream, red-and-white bunting, hand-painted sign caps,
   gingham runner strips, wooden stall cards with rope holes,
   tomato-red stitched apply button. */

:root {
  --cream: #fbf5e9;
  --cream-deep: #f4ebd8;
  --tomato: #d64533;
  --tomato-deep: #b23423;
  --wood: #8a5a3b;
  --wood-light: #f9f1e2;
  --leaf: #4c7a3f;
  --ink: #3a2f26;
  --ink-soft: #8a7c6c;
  --err: #d64533;
  --sign: 'Alfa Slab One', serif;
  --sans: 'Karla', sans-serif;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

.hidden { display: none !important; }

body {
  font-family: var(--sans);
  color: var(--ink);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  background: linear-gradient(180deg, var(--cream), var(--cream-deep));
  background-attachment: fixed;
  min-height: 100vh;
}

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

.wrap { width: 100%; max-width: 660px; margin: 0 auto; padding: 0 24px; }

main { flex: 1 0 auto; padding-bottom: 60px; }

/* ── Hero ─────────────────────────────────────────────────────────── */
.hero { text-align: center; padding: 0 24px 12px; }

.bunting { display: block; width: 100%; max-width: 680px; height: 70px; margin: 0 auto; }

.call-tag {
  font-weight: 800;
  font-size: 0.74rem;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--leaf);
  margin: 22px 0 12px;
}

.hero h1 {
  font-family: var(--sign);
  font-weight: 400;
  font-size: clamp(2rem, 8vw, 3.4rem);
  line-height: 1.1;
  color: var(--tomato);
  text-shadow: 2px 3px 0 rgba(58, 47, 38, 0.16);
  transform: rotate(-1deg);
}

.dates { font-weight: 700; font-size: 1.02rem; margin-top: 14px; }

.fee-row { margin-top: 14px; }

.fee-chip {
  display: inline-block;
  font-weight: 700;
  font-size: 0.85rem;
  color: var(--wood);
  background: #fff;
  border: 2px solid var(--wood);
  border-radius: 999px;
  padding: 8px 20px;
}

.deadline { color: var(--ink-soft); font-size: 0.9rem; margin-top: 14px; font-style: italic; }

/* ── Stall card ───────────────────────────────────────────────────── */
.stall {
  position: relative;
  background: var(--wood-light);
  border: 2px solid var(--wood);
  border-radius: 10px;
  padding: 36px 32px 30px;
  margin-top: 26px;
  box-shadow: 0 12px 0 -4px rgba(138, 90, 59, 0.35), 0 20px 36px rgba(58, 47, 38, 0.14);
}

.rope-hole {
  position: absolute;
  top: 12px;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--cream);
  border: 2.5px solid var(--wood);
  box-shadow: inset 0 2px 3px rgba(58, 47, 38, 0.3);
}

.rh-l { left: 18px; }
.rh-r { right: 18px; }

.stall-title {
  font-family: var(--sign);
  font-weight: 400;
  font-size: 1.5rem;
  text-align: center;
  color: var(--ink);
  margin-bottom: 8px;
}

/* gingham runner under the title */
.gingham {
  display: block;
  height: 12px;
  max-width: 220px;
  margin: 0 auto 14px;
  background:
    repeating-linear-gradient(90deg, rgba(214, 69, 51, 0.55) 0 8px, transparent 8px 16px),
    repeating-linear-gradient(0deg, rgba(214, 69, 51, 0.35) 0 6px, transparent 6px 12px),
    #fff;
  border-radius: 2px;
}

/* ── Fields ───────────────────────────────────────────────────────── */
.field { margin-bottom: 18px; }

.field-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-bottom: 18px; }

.field-grid .field { margin-bottom: 0; }

label {
  display: block;
  font-weight: 800;
  font-size: 0.72rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  margin-bottom: 7px;
  color: var(--wood);
}

.opt { font-weight: 600; font-size: 0.68rem; text-transform: none; letter-spacing: 0.02em; color: var(--ink-soft); }

input[type="text"],
input[type="email"],
select,
textarea {
  width: 100%;
  padding: 13px 15px;
  font-family: var(--sans);
  font-size: 1rem;
  font-weight: 600;
  color: var(--ink);
  background: #fff;
  border: 2px solid #e0d2ba;
  border-radius: 8px;
  transition: border-color 0.15s ease;
}

textarea { resize: vertical; min-height: 100px; }

select {
  appearance: none;
  background-image: url("data:image/svg+xml;charset=UTF-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' fill='none' stroke='%238a5a3b' stroke-width='2'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  cursor: pointer;
}

input:focus, select:focus, textarea:focus { outline: none; border-color: var(--tomato); }
input.error, textarea.error { border-color: var(--err); }
input::placeholder, textarea::placeholder { color: #bcab92; font-weight: 500; }

/* ── Photo drop ───────────────────────────────────────────────────── */
.photo-drop {
  position: relative;
  border: 2px dashed var(--leaf);
  border-radius: 8px;
  background: rgba(76, 122, 63, 0.06);
  min-height: 96px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 20px;
  transition: background 0.15s ease;
}

.photo-drop:hover { background: rgba(76, 122, 63, 0.12); }

.photo-drop input[type="file"] {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
  z-index: 2;
}

.photo-inner { text-align: center; padding: 16px; }

.basket { font-size: 1.4rem; letter-spacing: 0.2em; display: block; margin-bottom: 4px; }

.photo-text { font-weight: 700; font-size: 0.95rem; }

.photo-chosen {
  position: absolute;
  bottom: 6px;
  left: 0;
  right: 0;
  text-align: center;
  font-weight: 700;
  font-size: 0.8rem;
  color: var(--leaf);
}

/* ── Button ───────────────────────────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-family: var(--sans);
  font-weight: 800;
  font-size: 1rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #fff;
  background: var(--tomato);
  border: none;
  border-radius: 10px;
  padding: 17px 30px;
  cursor: pointer;
  transition: transform 0.12s ease, background 0.15s ease;
  outline: 2px dashed rgba(255, 255, 255, 0.65);
  outline-offset: -7px;
  box-shadow: 0 5px 0 var(--tomato-deep);
}

.btn:hover:not(:disabled) { transform: translateY(-2px); background: #e05341; }
.btn:disabled { opacity: 0.6; cursor: not-allowed; }
.btn:focus-visible { outline: 3px solid var(--leaf); outline-offset: 3px; }

.btn-block { width: 100%; }

.form-error { color: var(--err); font-weight: 700; text-align: center; margin-top: 14px; }

.spinner {
  display: inline-block;
  width: 15px;
  height: 15px;
  border: 2.5px solid rgba(255, 255, 255, 0.4);
  border-top-color: #fff;
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
}

@keyframes spin { to { transform: rotate(360deg); } }

/* ── Confirmation ─────────────────────────────────────────────────── */
.confirmed { text-align: center; padding: 44px 32px; }

.confirm-mark { font-size: 2.4rem; display: block; margin-bottom: 12px; }

.confirmed h2 { font-family: var(--sign); font-weight: 400; font-size: 1.8rem; color: var(--leaf); }

.confirmed p { color: var(--ink-soft); margin-top: 10px; max-width: 430px; margin-left: auto; margin-right: auto; }

/* ── Footer ───────────────────────────────────────────────────────── */
.foot {
  text-align: center;
  padding: 30px 20px;
  color: var(--ink-soft);
  font-size: 0.8rem;
  font-weight: 600;
}

#wbx-powered-by-slot { margin-top: 12px; }

/* ── Responsive ───────────────────────────────────────────────────── */
@media (max-width: 560px) {
  .field-grid { grid-template-columns: 1fr; gap: 18px; }
  .stall { padding: 30px 20px 26px; }
}
