/* Torii infomøde-tilmelding. Al styling er afgrænset under .tim og skærmet mod Elementor-kittets globale knap-/link-styling. */

.tim {
  --tim-orange: #DE601E;
  --tim-orange-hover: #CA571A;
  --tim-orange-light: #FA792B;
  --tim-brown: #A35917;
  --tim-text: #656565;
  --tim-ink: #4a3b31;
  --tim-panel: #FFE7DA;
  --tim-line: #F1D9CB;
  --tim-white: #fff;
  --tim-err: #B83E2B;
  --tim-head: 'Fugaz One', 'Montserrat', sans-serif;
  --tim-font: 'Montserrat', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --tim-marker: 'Permanent Marker', 'Montserrat', cursive;

  font-family: var(--tim-font);
  font-size: 16px;
  line-height: 1.55;
  color: var(--tim-text);
  width: 100%;
  max-width: 560px;
  margin: 0 auto;
}

.tim *,
.tim *::before,
.tim *::after {
  box-sizing: border-box;
}

.tim [hidden] {
  display: none !important;
}

.tim :focus-visible {
  outline: 3px solid var(--tim-orange-light);
  outline-offset: 2px;
}

.tim p {
  margin: 0;
}

.tim.tim a,
.tim.tim a:hover,
.tim.tim a:visited {
  color: var(--tim-brown);
}

.tim__card {
  background: var(--tim-panel);
  border-radius: 22px;
  padding: 26px 24px 22px;
  box-shadow: 0 10px 30px rgba(101, 101, 101, .10);
}

.tim__title {
  font-family: var(--tim-head);
  font-weight: 400;
  font-size: 26px;
  line-height: 1.15;
  color: var(--tim-orange);
  margin: 0 0 16px !important;
}

.tim__lede {
  color: var(--tim-ink);
  font-size: 15px;
  margin: -6px 0 14px !important;
}

/* ---------- Datoer ---------- */

.tim__dates {
  display: grid;
  gap: 10px;
  margin-bottom: 16px;
}

.tim .tim-date,
.tim .tim-date:hover,
.tim .tim-date:focus {
  all: unset;
  box-sizing: border-box;
  display: grid;
  grid-template-columns: 22px 1fr;
  column-gap: 12px;
  align-items: center;
  width: 100%;
  padding: 12px 16px;
  border-radius: 14px;
  background: var(--tim-white);
  border: 2px solid transparent;
  cursor: pointer;
  font-family: var(--tim-font);
  text-transform: none;
  letter-spacing: normal;
  transition: border-color .15s ease;
}

.tim .tim-date::before {
  content: '';
  grid-row: 1 / span 2;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  border: 2px solid #D8C3B5;
  background: var(--tim-white);
  transition: border-color .15s ease, box-shadow .15s ease;
}

.tim .tim-date:hover {
  border-color: var(--tim-line);
}

.tim .tim-date.is-selected {
  border-color: var(--tim-orange);
}

.tim .tim-date.is-selected::before {
  border-color: var(--tim-orange);
  box-shadow: inset 0 0 0 4px var(--tim-white), inset 0 0 0 10px var(--tim-orange);
}

.tim .tim-date:focus-visible {
  outline: 3px solid var(--tim-orange-light);
  outline-offset: 2px;
}

.tim .tim-date[disabled] {
  cursor: default;
  opacity: .55;
}

.tim-date__day {
  font-weight: 700;
  color: var(--tim-ink);
  font-size: 16px;
  line-height: 1.3;
}

.tim-date__time {
  font-size: 14px;
  color: var(--tim-text);
  line-height: 1.3;
}

/* Kun én dato: ingen radioknap, bare et datokort */
.tim__dates.is-single .tim-date {
  grid-template-columns: 1fr;
  cursor: default;
  border-color: transparent;
}

.tim__dates.is-single .tim-date::before {
  display: none;
}

/* ---------- Fakta ---------- */

.tim__facts {
  list-style: none;
  margin: 0 0 18px !important;
  padding: 0 !important;
  display: grid;
  gap: 6px;
}

.tim__facts li {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0;
  padding: 0;
  font-size: 15px;
  color: var(--tim-ink);
}

.tim__facts li::before {
  content: none !important;
}

.tim-ico {
  flex: 0 0 auto;
  width: 20px;
  height: 20px;
  color: var(--tim-orange);
}

/* ---------- Formular ---------- */

.tim__form {
  margin: 0;
}

.tim__fields {
  display: grid;
  gap: 10px;
  margin-bottom: 14px;
}

.tim-field {
  display: block;
  margin: 0;
}

.tim-field__label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: var(--tim-ink);
  margin: 0 0 4px 4px;
}

.tim-field__label em {
  font-style: normal;
  font-weight: 400;
  color: var(--tim-text);
}

.tim .tim-field input {
  display: block;
  width: 100%;
  height: 48px;
  margin: 0;
  padding: 0 16px;
  border: 2px solid transparent;
  border-radius: 12px;
  background: var(--tim-white);
  font-family: var(--tim-font);
  font-size: 16px;
  color: var(--tim-ink);
  box-shadow: none;
  outline: none;
  transition: border-color .15s ease;
}

.tim .tim-field input:focus {
  border-color: var(--tim-orange);
}

.tim .tim-field.is-invalid input {
  border-color: var(--tim-err);
}

.tim-hp {
  position: absolute !important;
  left: -9999px !important;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.tim .tim-btn,
.tim .tim-btn:hover,
.tim .tim-btn:focus,
.tim .tim-btn:visited {
  all: unset;
  box-sizing: border-box;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 52px;
  padding: 0 28px;
  border-radius: 30px;
  background: var(--tim-orange);
  color: var(--tim-white);
  font-family: var(--tim-font);
  font-weight: 700;
  font-size: 16px;
  line-height: 1.2;
  text-align: center;
  text-transform: none;
  letter-spacing: normal;
  cursor: pointer;
  transition: background-color .15s ease, transform .15s ease;
}

.tim .tim-btn:hover {
  background: var(--tim-orange-hover);
}

.tim .tim-btn:active {
  transform: translateY(1px);
}

.tim .tim-btn:focus-visible {
  outline: 3px solid var(--tim-orange-light);
  outline-offset: 2px;
}

.tim .tim-btn[disabled] {
  cursor: progress;
  opacity: .75;
}

.tim .tim-btn[data-tim-submit] {
  width: 100%;
}

.tim.tim .tim-btn--ghost,
.tim.tim .tim-btn--ghost:hover,
.tim.tim .tim-btn--ghost:visited {
  background: var(--tim-white);
  color: var(--tim-brown);
  min-height: 44px;
  padding: 0 20px;
  font-size: 15px;
  font-weight: 600;
}

.tim.tim .tim-btn--ghost:hover {
  background: #FFF6F1;
}

.tim__consent {
  font-size: 12.5px;
  line-height: 1.5;
  color: var(--tim-text);
  margin-top: 10px !important;
}

.tim__consent a {
  text-decoration: underline;
}

.tim__error {
  margin-top: 10px !important;
  font-size: 14px;
  font-weight: 600;
  color: var(--tim-err);
}

/* ---------- Tilmeldt ---------- */

.tim__done {
  outline: none;
}

.tim__done-title {
  font-family: var(--tim-marker);
  font-size: 28px;
  line-height: 1.2;
  color: var(--tim-orange);
  margin-bottom: 6px !important;
}

.tim__done-date {
  font-weight: 700;
  font-size: 17px;
  color: var(--tim-ink);
  margin-bottom: 8px !important;
}

.tim__done-text {
  color: var(--tim-ink);
  margin-bottom: 16px !important;
}

.tim__cal {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.tim__empty p {
  color: var(--tim-ink);
}

/* ---------- Kompakt variant (produktsider) ---------- */

.tim--compact {
  max-width: 460px;
}

.tim--compact .tim__card {
  padding: 20px 18px 18px;
  border-radius: 18px;
}

.tim--compact .tim__title {
  font-size: 21px;
  margin-bottom: 12px !important;
}

.tim--compact .tim__dates {
  gap: 8px;
  margin-bottom: 12px;
}

.tim--compact .tim-date {
  padding: 10px 14px;
}

@media (min-width: 520px) {
  .tim--full .tim__fields {
    grid-template-columns: 1fr 1fr;
  }

  .tim--full .tim__fields .tim-field:nth-child(3) {
    grid-column: 1 / -1;
  }

  .tim__card {
    padding: 32px 32px 26px;
  }

  .tim--compact .tim__card {
    padding: 22px 22px 20px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .tim *,
  .tim *::before {
    transition: none !important;
  }
}
