/* form styling, injected site-wide on mnkitchenofkindness.com.
   the umbrella kitchen-of-kindness theme styles these forms as full-width white
   pills at 20px/24px padding. that works for a three-field signup and falls
   apart on a twelve-field registration, so this replaces it and follows the
   site's own design language instead: cream ground, coral accent, soft cards,
   bogue for display.
   #formContainer is the anchor - the theme's field rules are (0,3,0), so one id
   wins without !important. */

body.form {
  --f-cream: #fcf7dd;
  --f-white: #fffdf6;
  --f-coral: #f16457;
  --f-orange: #f9a755;
  --f-ink: #231f20;
  --f-muted: #8a8178;
  --f-hair: #e7ddc7;
  --f-col: 620px;
}

/* ---- shape of the page -------------------------------------------------- */

/* the fields read better in a narrower column than the calendar wants, so the
   rows are capped and centred and the calendar's own row opts out below. */
body.form #formContainer .form-all { width: 100%; }

body.form #formContainer li.form-line {
  max-width: var(--f-col);
  margin: 0 auto 20px;
  padding: 0;
}

body.form #formContainer li.form-line:last-child { margin-bottom: 0; }

/* the calendar runs wider than the field column so the times sit beside the
   month instead of under it. its container query keys off this width. */
body.form #formContainer li.form-line:has(#kok-booking) {
  max-width: none;
  margin-bottom: 38px;
}

/* the text block's wrapper insets its content a few pixels, which shows up as
   the calendar sitting slightly left of every field below it */
body.form #formContainer li.form-line:has(#kok-booking) .form-html { margin: 0; }
body.form #formContainer #kok-booking { max-width: none; }

/* the page hero is min-height 600 in the theme, which is most of a laptop
   screen before the form even starts. the theme's selector is (0,3,0), so this
   has to match its shape to win. */
body.form .ckk-wrapper .master-content-wrapper .article-header {
  min-height: 0;
  padding-block: 34px;
}

/* NOT ::before on the header - that is the full-bleed gradient band itself
   (100vw, margin-left -50vw). touching it insets the band and clips the title.
   the compression comes from the title and the sun mark above it, which the
   theme sets at 105px and 210x125 with a 40px gap. */
body.form .ckk-wrapper .master-content-wrapper .article-header .article-header__title {
  font-size: 62px;
}

body.form .ckk-wrapper .master-content-wrapper .article-header .article-header__title::before {
  width: 132px;
  height: 78px;
  margin-bottom: 20px;
}

/* ---- the two session fields --------------------------------------------- */

/* these carry the date and time the calendar writes, and they are the only two
   fields wired to the sheet. they are NOT hidden in the builder: that renders
   display:none and the wiring collector then skips them, so the row would
   submit with no slot on it. height 0 + visibility hidden keeps them collectable
   while taking no space and staying out of the tab order. */
body.form #formContainer form[id="7497228"] #id_4,
body.form #formContainer form[id="7497228"] #id_5 {
  height: 0;
  min-height: 0;
  margin: 0;
  padding: 0;
  overflow: hidden;
  visibility: hidden;
}

/* ---- the lead paragraph ------------------------------------------------- */

body.form #formContainer form[id="7497228"] #id_17 {
  max-width: var(--f-col);
  margin: 0 auto 34px;
}

body.form #formContainer form[id="7497228"] #id_17 .form-html p {
  margin: 0 0 14px;
  font-family: "DM Sans", sans-serif;
  font-size: 18px;
  line-height: 1.6;
  color: var(--f-ink);
}

body.form #formContainer form[id="7497228"] #id_17 .form-html p:last-child {
  margin-bottom: 0;
  color: var(--f-muted);
  font-size: 16px;
}

/* ---- the calendar sits on a card so it reads as one object --------------- */

body.form #formContainer li.form-line:has(#kok-booking) .form-html {
  padding: 26px 26px 22px;
  border: 1px solid var(--f-hair);
  border-radius: 20px;
  background: var(--f-white);
}

/* ---- labels ------------------------------------------------------------- */

/* jotform injects width:150px !important inline on the label wrapper */
body.form .form-label-left {
  width: auto !important;
  float: none !important;
  display: block;
  margin: 0 0 7px;
}

body.form #formContainer .form-label-left label {
  font-family: "DM Sans", sans-serif;
  font-size: 14px;
  font-weight: 600;
  line-height: 1.3;
  letter-spacing: .01em;
  color: var(--f-ink);
}

body.form #formContainer .form-required {
  color: var(--f-orange);
  font-weight: 400;
}

body.form #formContainer li.form-line .form-input,
body.form #formContainer li.form-line .form-input-wide {
  width: 100%;
  margin-left: 0;
}

/* ---- fields ------------------------------------------------------------- */

body.form #formContainer .form-textbox,
body.form #formContainer .form-textarea,
body.form #formContainer .form-dropdown {
  width: 100%;
  padding: 12px 15px;
  border: 1px solid var(--f-hair);
  border-radius: 12px;
  background: var(--f-white);
  font-family: "DM Sans", sans-serif;
  font-size: 16px;
  font-weight: 400;
  line-height: 1.35;
  color: var(--f-ink);
  box-shadow: none;
  transition: border-color .15s;
}

body.form #formContainer .form-textbox::placeholder,
body.form #formContainer .form-textarea::placeholder { color: var(--f-muted); }

body.form #formContainer .form-textbox:focus,
body.form #formContainer .form-textarea:focus,
body.form #formContainer .form-dropdown:focus {
  border-color: var(--f-coral);
  outline: none;
}

body.form #formContainer .form-textarea { min-height: 96px; resize: vertical; }

/* selects. the country one is .form-address-country and the expiration pair are
   .form-textbox, so none of them pick up a plain .form-dropdown rule - the tag
   is in the selector to clear whatever the platform sets on each. */
body.form #formContainer select,
body.form #formContainer select.form-dropdown,
body.form #formContainer select.form-address-country,
body.form #formContainer .form-address-table select {
  /* !important because an inline height on this element still computes to 23px,
     so something in the cross-origin theme is winning it. not worth more digging
     for one control. */
  height: 45px !important;
  min-height: 45px;
  padding: 0 12px;
  border: 1px solid var(--f-hair);
  border-radius: 12px;
  background-color: var(--f-white);
  font-family: "DM Sans", sans-serif;
  font-size: 16px;
  line-height: normal;
  color: var(--f-ink);
  appearance: none;
  -webkit-appearance: none;
  background-image: linear-gradient(45deg, transparent 50%, #8a8178 50%), linear-gradient(135deg, #8a8178 50%, transparent 50%);
  background-position: calc(100% - 18px) center, calc(100% - 13px) center;
  background-size: 5px 5px, 5px 5px;
  background-repeat: no-repeat;
  padding-right: 34px;
}

body.form #formContainer select:focus { border-color: var(--f-coral); outline: none; }

/* the phone field's sub-label is a single space and it has no hint property to
   clear, so it goes here. one input, nothing to sub-label anyway. */
body.form #formContainer #id_10 .form-sub-label { display: none; }

/* the chosen session is a fact the page is telling the visitor, so it reads as
   text rather than as an empty box waiting to be filled. it stays a real input
   because its value is what carries into the confirmation email. */
body.form #formContainer form[id="7497228"] #input_3 {
  padding: 0;
  border: 0;
  background: transparent;
  font-size: 18px;
  font-weight: 600;
  color: var(--f-ink);
  cursor: default;
}

body.form #formContainer form[id="7497228"] #input_3::placeholder {
  font-size: 16px;
  font-weight: 400;
  color: var(--f-muted);
}

body.form #formContainer form[id="7497228"] #input_3:focus { outline: none; }

/* carries an inline style="width:60px" that clips its own hint */
body.form #formContainer input.form-number-input { width: 120px !important; }

/* sub-labels read better above their field; markup order is input-then-label */
body.form #formContainer .form-sub-label-container {
  display: flex;
  flex-direction: column-reverse;
  width: 100%;
  text-align: left;
}

/* most fields carry a sub-label holding a single space, which renders a blank
   line between the label and the input. :empty cannot match whitespace, so this
   keys on the container being the only one in its field: a real sub-label (First
   / Last Name, the card fields) always has a sibling. */
body.form #formContainer div[id^="cid_"] > .form-sub-label-container:only-child .form-sub-label {
  display: none;
}

body.form #formContainer .form-sub-label {
  margin: 0 0 6px;
  padding-top: 0;
  font-size: 12px;
  font-weight: 500;
  letter-spacing: .02em;
  color: var(--f-muted);
}

/* a field with more than one sub-field (full name, phone) is a row, not a
   stack. column-reverse above put the label over each input, which also turned
   the parent into a column until this puts it back. */
body.form #formContainer div[id^="cid_"]:has(> .form-sub-label-container + .form-sub-label-container) {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: flex-start;
}

body.form #formContainer div[id^="cid_"]:has(> .form-sub-label-container + .form-sub-label-container)
  > .form-sub-label-container {
  flex: 1 1 150px;
  width: auto;
  min-width: 0;
}

/* ---- choices ------------------------------------------------------------ */

/* .form-single-column is inline-block, so option rows shrink-wrap */
body.form #formContainer .form-single-column { display: block; width: 100%; }

body.form #formContainer input[type="checkbox"],
body.form #formContainer input[type="radio"] {
  width: 17px;
  height: 17px;
  accent-color: var(--f-coral);
  vertical-align: middle;
}

body.form #formContainer .form-checkbox-item,
body.form #formContainer .form-radio-item { margin: 0; }

body.form #formContainer .form-checkbox-item label,
body.form #formContainer .form-radio-item label {
  font-family: "DM Sans", sans-serif;
  font-size: 15px;
  line-height: 1.45;
  padding-left: 7px;
  color: var(--f-ink);
}

/* ---- section headings --------------------------------------------------- */

/* the platform centres these and sizes them as body copy, which reads as an
   afterthought rather than a section break */
body.form #formContainer .form-header-group {
  /* the platform ships this shrink-wrapped inside a centred parent, so it needs
     to be a block before any alignment or width takes hold */
  display: block;
  width: 100%;
  max-width: var(--f-col);
  margin: 46px auto 18px;
  padding: 0 0 12px;
  border-bottom: 1px solid var(--f-hair);
  text-align: left;
}

body.form #formContainer li.form-line { text-align: left; }

body.form #formContainer li.form-line:first-child .form-header-group { margin-top: 0; }

body.form #formContainer .form-header-group .form-header {
  margin: 0;
  font-family: "Bogue", serif;
  font-weight: 700;
  font-style: italic;
  font-size: 27px;
  line-height: 1.1;
  text-align: left;
  color: var(--f-coral);
}

body.form #formContainer .form-header-group .form-subHeader {
  margin: 7px 0 0;
  font-family: "DM Sans", sans-serif;
  font-size: 15px;
  line-height: 1.45;
  text-align: left;
  color: var(--f-muted);
}

/* ---- total -------------------------------------------------------------- */

body.form #formContainer li.form-line:has(.form-total-amount),
body.form #formContainer li.form-line:has([id^="total_"]) {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
  margin-top: 30px;
  padding: 16px 18px;
  border-radius: 14px;
  background: var(--f-white);
  border: 1px solid var(--f-hair);
}

body.form #formContainer li.form-line:has(.form-total-amount) .form-label-left,
body.form #formContainer li.form-line:has([id^="total_"]) .form-label-left {
  margin: 0;
  flex: 0 0 auto;
}

/* the amount is pushed to the far end rather than sitting against its label */
body.form #formContainer li.form-line:has(.form-total-amount) .form-input,
body.form #formContainer li.form-line:has([id^="total_"]) .form-input {
  flex: 1 1 auto;
  width: auto;
  text-align: right;
}

body.form #formContainer .form-total-amount,
body.form #formContainer [id^="total_"] {
  font-family: "Bogue", serif;
  font-weight: 700;
  font-style: italic;
  font-size: 26px;
  color: var(--f-coral);
}

/* ---- submit ------------------------------------------------------------- */

body.form #formContainer .form-buttons-wrapper {
  max-width: var(--f-col);
  margin: 28px auto 0;
  text-align: left;
}

body.form #formContainer .form-buttons-wrapper .form-submit-button {
  width: 100%;
  padding: 15px 28px;
  border: 0;
  border-radius: 999px;
  background: var(--f-coral);
  color: #fff;
  font-family: "DM Sans", sans-serif;
  font-size: 17px;
  font-weight: 600;
  letter-spacing: .01em;
  text-transform: none;
  text-shadow: none;
  cursor: pointer;
  transition: opacity .15s;
}

body.form #formContainer .form-buttons-wrapper .form-submit-button:hover { opacity: .9; }

/* ---- errors ------------------------------------------------------------- */

body.form #formContainer .form-error-message {
  margin-top: 6px;
  padding: 0;
  border: 0;
  background: none;
  font-family: "DM Sans", sans-serif;
  font-size: 13px;
  color: #b02a37;
}

body.form #formContainer .form-error-arrow,
body.form #formContainer .form-error-arrow-inner { display: none; }

body.form #formContainer .form-textbox.form-validation-error,
body.form #formContainer .form-dropdown.form-validation-error { border-color: #b02a37; }

body.form #formContainer .form-error-js {
  max-width: var(--f-col);
  margin: 0 auto 20px;
  padding: 12px 16px;
  border-radius: 12px;
  background: #fdeacd;
  font-family: "DM Sans", sans-serif;
  font-size: 15px;
  color: var(--f-ink);
  text-align: left;
}

/* ---- payment ------------------------------------------------------------ */

body.form #formContainer .form-address-table,
body.form #formContainer .form-address-table table { width: 100%; max-width: none; }

body.form #formContainer .form-address-table table,
body.form #formContainer .form-address-table table > tbody { display: block; }

body.form #formContainer .form-address-table table > tbody > tr {
  display: flex;
  width: 100%;
  gap: 12px;
}

/* required: BuildSource toggles .hide with no inline style and it is only
   (0,1,0), so an id-scoped display would reveal card fields on a check/paypal
   form. */
body.form #formContainer .form-address-table table > tbody > tr.hide { display: none; }

body.form #formContainer .form-address-table table > tbody > tr > td {
  display: block;
  flex: 1 1 0;
  width: auto;
  padding-bottom: 14px;
  text-align: left;
}

body.form #formContainer .form-address-table table > tbody > tr > td.cc_ccv { flex: 0 0 170px; }

body.form #formContainer .credit_card th {
  font-family: "DM Sans", sans-serif;
  font-size: 14px;
  font-weight: 600;
  color: var(--f-ink);
  text-align: left;
}

/* ---- the two price options as cards, this form only --------------------
   the body never gets an aid- class on this template, so the form element's own
   id is the hook. it starts with a digit, so it has to be an attribute
   selector rather than #7497228. */

body.form #formContainer form[id="7497228"] #cid_6 .form-single-column {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 12px;
  width: 100%;
}

/* float-clearing leftovers each eat a grid cell */
body.form #formContainer form[id="7497228"] #cid_6 .form-single-column > .clearfix { display: none; }

body.form #formContainer form[id="7497228"] #cid_6 .form-radio-item {
  display: block;
  width: 100%;
  margin: 0;
}

/* the label is the card, so the whole tile is the click target and
   :checked + label drives the selected state with no :has() */
body.form #formContainer form[id="7497228"] #cid_6 .form-radio-item input[type="radio"] {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

body.form #formContainer form[id="7497228"] #cid_6 .form-radio-item label {
  display: block;
  margin: 0;
  padding: 20px 22px;
  border: 1.5px solid var(--f-hair);
  border-radius: 14px;
  background: var(--f-white);
  font-size: 15px;
  line-height: 1.4;
  cursor: pointer;
  transition: border-color .15s, background .15s;
}

body.form #formContainer form[id="7497228"] #cid_6 .form-radio-item label:hover {
  border-color: var(--f-orange);
}

body.form #formContainer form[id="7497228"] #cid_6 .form-radio-item input[type="radio"]:checked + label {
  border-color: var(--f-coral);
  background: #fdf0dc;
}

body.form #formContainer form[id="7497228"] #cid_6 .form-radio-item input[type="radio"]:focus-visible + label {
  outline: 2px solid var(--f-coral);
  outline-offset: 2px;
}

@media (max-width: 640px) {
  body.form #formContainer .form-address-table table > tbody > tr { flex-wrap: wrap; }
  body.form #formContainer .form-address-table table > tbody > tr > td.cc_ccv { flex: 1 1 0; }
  body.form #formContainer .form-header-group { margin-top: 30px; }
}
