:root {
  --tista-red: #E52721;
  --tista-cream: #F6DFC4;
  --tista-cream-dark: #F3DEC2;
  --tista-paper: #FFF8EF;
  --tista-ink: #4A302C;
  --tista-muted: #6B4944;
}

/* Hero */
.tista-hero {
  padding: 90px 0;
  background: var(--tista-cream);
}

.tista-hero .hero-text {
  display: flex;
  height: 100%;
  flex-direction: column;
  justify-content: center;
}

.tista-hero .hero-text h1 {
  color: var(--tista-red);
  font-size: 6em;
  text-transform: uppercase;
}

.tista-hero .hero-text p {
  margin-top: 30px;
  color: var(--tista-red);
  font-size: 1.75em;
  font-style: italic;
  font-weight: 300;
}

.tista-hero .hero-hlib {
  padding: 90px 0;
}

.tista-hero .hero-extra {
  color: var(--tista-red);
  font-size: 1.5em;
  font-style: italic;
  font-weight: 300;
}

/* Map */
#tista-map {
  --map-fill: transparent;
  --map-stroke: #E11D2E;
  --map-stroke-width: 2;
  --pin-size: 26px;
  --tooltip-offset: 16px;
  padding: 30px 0;
  background: var(--tista-cream);
}

#tista-map .tista-symbols {
  position: absolute;
  visibility: hidden;
}

#tista-map .tista-block {
  max-width: 1200px;
  margin: 24px auto;
  padding: 0 16px;
}

#tista-map .tista-wrap {
  position: relative;
  overflow: hidden;
  border-radius: 12px;
  background: #fff;
}

#tista-map .tista-stage {
  position: relative;
  width: 100%;
  aspect-ratio: 1416 / 838;
  background: var(--tista-cream);
}

#tista-map .tista-svg {
  position: absolute;
  inset: 0;
}

#tista-map .tista-svg svg {
  display: block;
  width: 100%;
  height: 100%;
}

#tista-map .tista-svg path,
#tista-map .tista-svg polygon,
#tista-map .tista-svg polyline {
  fill: var(--map-fill);
  stroke: var(--map-stroke);
  stroke-width: var(--map-stroke-width);
  stroke-linecap: round;
  stroke-linejoin: round;
  vector-effect: non-scaling-stroke;
}

#tista-map .tista-marker {
  position: absolute;
  margin: 0;
  padding: 0;
  border: 0;
  background: transparent;
  color: inherit;
  cursor: pointer;
  font: inherit;
  font-size: 0;
  line-height: 0;
  transform: translate(-50%, -100%);
  user-select: none;
  appearance: none;
}

#tista-map .tista-marker:focus-visible {
  border-radius: 50%;
  outline: 2px solid #7C312D;
  outline-offset: 4px;
}

#tista-map .tista-marker svg {
  display: block;
  width: var(--pin-size);
  height: var(--pin-size);
}

#tista-map .tista-float {
  display: inline-block;
  line-height: 0;
  transform: translate3d(0, 0, 0) rotate(0deg);
  animation: tista-cloud var(--float-dur, 6s) ease-in-out var(--float-delay, 0s) infinite alternate;
  will-change: transform;
}

@keyframes tista-cloud {
  to {
    transform: translate3d(var(--float-x, 0), var(--float-y, -6px), 0) rotate(var(--float-rot, 1deg));
  }
}

@media (prefers-reduced-motion: reduce) {
  #tista-map .tista-float {
    animation: none;
  }
}

#tista-map .tista-tooltip {
  position: absolute;
  z-index: 10;
  padding: 6px 8px;
  border: 1px solid #E5E7EB;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 2px 8px rgba(0, 0, 0, .1);
  color: #222;
  font-size: 12px;
  line-height: 1;
  opacity: 0;
  pointer-events: none;
  transform: translate(-50%, -100%);
  transition: opacity .12s ease;
  white-space: nowrap;
}

#tista-map .tista-tooltip.tista-show {
  opacity: 1;
}

/* Popover */
#tista-map .tista-popover {
  --popover-bg: var(--tista-paper);
  --popover-text: var(--tista-ink);
  --popover-title: var(--tista-red);
  --popover-meta: var(--tista-muted);
  --popover-divider: rgba(124, 49, 45, .14);
  --popover-scroll: rgba(107, 73, 68, .32);
  --popover-close-bg: rgba(124, 49, 45, .07);
  --popover-close-color: var(--tista-muted);
  --popover-shadow: 0 18px 48px rgba(78, 42, 35, .20);
  position: fixed;
  z-index: 9999;
  width: 540px;
  max-width: calc(100vw - 24px);
  overflow: hidden;
  border: 1px solid rgba(124, 49, 45, .10);
  border-radius: 15px;
  background: var(--popover-bg);
  box-shadow: var(--popover-shadow);
  color: var(--popover-text);
  contain: layout paint;
  transform: translate3d(-50%, -100%, 0);
  transition: transform .12s ease;
  will-change: transform, top, left;
}

#tista-map .tista-popover.is-region {
  --popover-bg: var(--tista-red);
  --popover-text: var(--tista-cream);
  --popover-title: var(--tista-cream);
  --popover-meta: var(--tista-cream);
  --popover-divider: rgba(246, 223, 196, .28);
  --popover-scroll: rgba(246, 223, 196, .46);
  --popover-close-bg: rgba(82, 18, 15, .22);
  --popover-close-color: var(--tista-paper);
  --popover-shadow: 0 18px 40px rgba(0, 0, 0, .28);
}

#tista-map .tista-popover-close {
  position: absolute;
  top: 8px;
  right: 8px;
  z-index: 2;
  display: grid;
  width: 36px;
  height: 36px;
  padding: 0;
  place-items: center;
  border: 0;
  border-radius: 50%;
  background: var(--popover-close-bg);
  color: var(--popover-close-color);
  cursor: pointer;
  font-size: 18px;
  line-height: 1;
}

#tista-map .tista-popover-close:focus-visible {
  outline: 2px solid currentColor;
  outline-offset: -4px;
}

#tista-map .tista-popover-content {
  padding: 18px 20px 16px;
}

#tista-map .tista-title {
  margin: 0 0 3px;
  padding-right: 44px;
  color: var(--popover-title);
  font-size: 20px;
  font-weight: 700;
  line-height: 1.25;
  text-wrap: balance;
}

#tista-map .tista-eyebrow {
  margin: 0;
  padding: 0 44px 12px 0;
  border-bottom: 1px solid var(--popover-divider);
  color: var(--popover-meta);
  font-size: 13px;
  font-style: normal;
  font-weight: 400;
  line-height: 1.45;
}

#tista-map .tista-eyebrow span {
  font-weight: 600;
}

#tista-map .tista-content {
  max-height: clamp(260px, 62vh, 620px);
  margin-top: 12px;
  padding-right: 8px;
  overflow: auto;
  color: var(--popover-text);
  font-size: 15px;
  line-height: 1.55;
  overscroll-behavior: contain;
  scrollbar-color: var(--popover-scroll) transparent;
  scrollbar-gutter: stable;
  scrollbar-width: thin;
  -webkit-overflow-scrolling: touch;
}

#tista-map .tista-content::-webkit-scrollbar {
  width: 6px;
}

#tista-map .tista-content::-webkit-scrollbar-track {
  margin: 6px;
  background: transparent;
}

#tista-map .tista-content::-webkit-scrollbar-thumb,
#tista-map .tista-content::-webkit-scrollbar-thumb:hover {
  border: 2px solid transparent;
  border-radius: 999px;
  background: var(--popover-scroll);
  background-clip: padding-box;
}

#tista-map .tista-content p {
  margin: 0;
  padding: 0;
  color: var(--popover-text);
  font-size: 15px;
  font-weight: 400;
  line-height: 1.55;
}

#tista-map .tista-popover.is-region .tista-content p + p {
  margin-top: 10px;
}

#tista-map .tista-popover-arrow {
  position: absolute;
  top: 100%;
  left: 50%;
  width: 16px;
  height: 16px;
  border-right: 1px solid rgba(0, 0, 0, .06);
  border-bottom: 1px solid rgba(0, 0, 0, .06);
  background: inherit;
  transform: translateX(-50%) rotate(45deg);
  transition: top .15s ease;
}

#tista-map .tista-actions {
  position: static;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 24px;
  margin: 0;
  padding: 12px 0 0;
  border-top: 1px solid var(--popover-divider);
  background: var(--popover-bg);
}

#tista-map .tista-chip {
  display: inline-block;
  min-height: 42px;
  padding: 11px 18px;
  border: 0;
  border-radius: 10px;
  box-shadow: none;
  cursor: pointer;
  font-size: 14px;
  font-weight: 600;
  line-height: 20px;
  text-align: center;
  text-decoration: none;
  transition: background .2s ease, transform .2s ease;
  user-select: none;
}

#tista-map .tista-popover.is-recipe .primary-recipe {
  background: var(--tista-red);
  color: #fff;
}

#tista-map .tista-popover.is-recipe .primary-recipe:hover {
  background: #C61F1C;
  transform: translateY(1px);
}

#tista-map .tista-popover.is-region .btn-white {
  background: #fff;
  color: #B3231D;
}

#tista-map .tista-popover.is-region .btn-outline {
  background: #EEDAC1;
  color: #B3231D;
}

#tista-map .tista-popover.is-region .btn-white:hover {
  background: #F3F3F3;
  transform: translateY(1px);
}

#tista-map .tista-popover.is-region .btn-outline:hover {
  background: #E6CFAE;
  transform: translateY(1px);
}

/* User recipe content */
#tista-map .tista-recipe-photo {
  aspect-ratio: 16 / 9;
  margin: 0 0 18px;
  overflow: hidden;
  border-radius: 10px;
  background: var(--tista-cream);
}

#tista-map .tista-recipe-photo img {
  display: block;
  width: 100%;
  height: 100%;
  max-height: none;
  object-fit: cover;
}

#tista-map .tista-recipe-gallery {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  margin-top: 18px;
}

#tista-map .tista-recipe-gallery.is-single {
  grid-template-columns: 1fr;
}

#tista-map .tista-recipe-gallery img {
  display: block;
  width: 100%;
  height: 150px;
  border-radius: 10px;
  object-fit: cover;
}

#tista-map .tista-recipe-story {
  margin: 0 0 4px;
  padding: 14px 15px;
  border-left: 2px solid rgba(200, 52, 46, .48);
  border-radius: 0 10px 10px 0;
  background: #FAF0E4;
  color: var(--tista-ink);
}

#tista-map .tista-recipe-story p + p {
  margin-top: 8px;
}

#tista-map .tista-recipe-section-title {
  display: block;
  margin: 18px 0 10px;
  padding-top: 14px;
  border-top: 1px solid rgba(124, 49, 45, .12);
  color: #A83A34;
  font-size: 15px;
  font-weight: 700;
  line-height: 1.4;
}

#tista-map .tista-recipe-subtitle {
  display: block;
  margin: 14px 0 5px;
  color: var(--tista-muted);
  font-size: 14px;
  font-weight: 600;
  line-height: 1.5;
}

#tista-map .tista-recipe-ingredients {
  margin: 0;
  padding-left: 20px;
}

#tista-map .tista-recipe-steps {
  margin: 0;
  padding-left: 28px;
}

#tista-map .tista-recipe-ingredients li,
#tista-map .tista-recipe-steps li {
  margin-bottom: 8px;
  color: var(--tista-ink);
  font-size: 15px;
  font-weight: 400;
  line-height: 1.5;
}

#tista-map .tista-recipe-ingredients li:last-child,
#tista-map .tista-recipe-steps li:last-child {
  margin-bottom: 0;
}

#tista-map .tista-recipe-ingredients li::marker,
#tista-map .tista-recipe-steps li::marker {
  color: #C8342E;
  font-weight: 700;
}

#tista-map .tista-recipe-note {
  margin-top: 18px;
  padding: 13px 14px;
  border: 1px solid rgba(124, 49, 45, .10);
  border-radius: 10px;
  background: var(--tista-cream);
  color: var(--tista-muted);
  font-size: 14px;
  font-weight: 400;
  line-height: 1.55;
}

/* Regional illustration */
#tista-map .tista-region-footer {
  float: right;
  margin: 10px 0 8px 16px;
  padding: 0;
}

#tista-map .tista-region-footer .region-image {
  display: flex;
  align-items: center;
  justify-content: center;
}

#tista-map .tista-region-footer img {
  display: block;
  width: auto;
  height: 72px;
}

/* Legend */
.tista-legend {
  padding: 30px 0 10px;
  background: var(--tista-cream);
  text-align: center;
}

.tista-legend-inner {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 30px;
  flex-wrap: wrap;
}

.tista-legend-item {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--tista-red);
  font-size: 1rem;
}

.tista-legend-item svg {
  display: inline-block;
  width: 20px;
  height: 20px;
}

.tista-legend-star {
  margin-left: 2px;
  font-size: .65em;
  line-height: 1;
  vertical-align: super;
}

.tista-legend-disclaimer {
  max-width: 760px;
  margin: 10px auto 0;
  color: var(--tista-red);
  font-size: .7rem;
  line-height: 1.35;
  text-align: center;
}

/* Submission form */
.tista-form-wrap {
  --tf-red: var(--tista-red);
  --tf-text: #1F2937;
  --tf-muted: #9A7F6B;
  --tf-white: #fff;
  position: relative;
  padding-top: 90px;
  padding-bottom: 222px;
  background: var(--tf-red);
}

.tista-form-wrap::after {
  position: absolute;
  bottom: 0;
  left: 25vw;
  z-index: 5;
  width: 50vw;
  height: 100%;
  background: url(../images/tisto-hlib-2.webp) center bottom / contain no-repeat;
  content: '';
}

.tista-form {
  position: relative;
  z-index: 10;
  padding: 15px 30px 30px;
  border-radius: 30px;
  background: var(--tista-cream-dark);
}

.tista-form-text {
  padding-top: 120px;
}

.tista-form-text h2 {
  color: var(--tista-cream-dark);
  font-size: 5em;
}

.tista-form-text p {
  padding-top: 20px;
  color: var(--tista-cream-dark);
  font-size: 1.5em;
  font-style: italic;
  font-weight: 300;
  line-height: 1.6;
}

.tista-form .tf-label {
  display: block;
  margin: 16px 0 6px;
  color: var(--tf-red);
  font-weight: 600;
}

.tista-form .tf-label:first-of-type {
  margin-top: 0;
}

.tista-form .tf-input {
  width: 100%;
  padding: 14px 16px;
  border: 0;
  border-radius: 15px;
  outline: none;
  background: var(--tf-white);
  box-shadow: inset 0 0 0 2px rgba(220, 39, 37, .15);
  color: var(--tf-text);
  transition: box-shadow .15s ease, background .15s ease;
}

.tista-form .tf-input::placeholder {
  color: #C6B6A5;
  font-style: italic;
}

.tista-form .tf-input:focus {
  background: #fff;
  box-shadow: inset 0 0 0 2px var(--tf-red), 0 0 0 4px rgba(220, 39, 37, .12);
}

.tista-form textarea.tf-input {
  box-sizing: border-box;
  min-height: 110px;
  overflow: hidden;
  resize: none;
}

.tista-form .tf-btn {
  padding: 16px 22px;
  border: 0;
  border-radius: 15px;
  background: var(--tf-red);
  box-shadow: 0 8px 18px rgba(220, 39, 37, .25);
  color: #fff;
  cursor: pointer;
  font-size: 1rem;
  font-weight: 600;
  transition: transform .08s ease, box-shadow .15s ease, background .15s ease;
}

.tista-form .tf-btn:hover {
  background: #C51F1E;
  box-shadow: 0 10px 22px rgba(220, 39, 37, .28);
}

.tista-form .tf-btn:active {
  transform: translateY(1px);
}

.tista-form .tf-btn[disabled] {
  opacity: .7;
  cursor: not-allowed;
  pointer-events: none;
}

.tista-form .tf-btn.is-loading::after {
  margin-left: 8px;
  content: '⏳';
}

.tista-dropzone {
  position: relative;
  padding: 15px;
  border: 2px dashed rgba(229, 39, 33, .35);
  border-radius: 15px;
  background: var(--tista-cream);
}

.tista-dropzone-inner {
  text-align: center;
}

.tista-drop-main {
  color: var(--tf-muted);
  font-size: 12px;
  font-weight: 500;
  line-height: 25px;
}

.tista-drop-btn {
  display: inline-block;
  margin: 10px;
  padding: 0 10px;
  border: 0;
  border-radius: 999px;
  background: var(--tf-red);
  color: #fff;
  cursor: pointer;
  font-size: 12px;
  font-weight: 500;
}

.tista-drop-hint {
  margin-top: 0;
  color: var(--tf-muted);
  font-size: 12px;
  font-style: italic;
}

#tf_media_files {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
}

.tista-dropzone.is-dragover {
  border-color: var(--tf-red);
  background: #F3D2AD;
}

.tista-upload-status {
  margin-top: 8px;
  color: var(--tf-muted);
  font-size: 12px;
  text-align: center;
}

.tista-upload-progress {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-left: 10px;
  color: var(--tf-muted);
  font-size: 12px;
}

.tista-upload-progress.is-loading::before {
  width: 14px;
  height: 14px;
  border: 2px solid rgba(229, 39, 33, .25);
  border-top-color: var(--tf-red);
  border-radius: 50%;
  animation: tista-spinner .7s linear infinite;
  content: '';
}

@keyframes tista-spinner {
  to {
    transform: rotate(360deg);
  }
}

.tista-file-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin: 15px 0;
}

.tista-file-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 14px;
  border-radius: 15px;
  background: #fff;
  box-shadow: 0 2px 6px rgba(0, 0, 0, .05);
}

.tista-file-main {
  display: flex;
  min-width: 0;
  flex-direction: column;
}

.tista-file-name {
  overflow: hidden;
  color: #111827;
  font-size: 14px;
  font-weight: 600;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.tista-file-size {
  color: #6B7280;
  font-size: 11px;
}

.tista-file-remove {
  padding: 0 4px;
  border: 0;
  background: transparent;
  color: var(--tf-red);
  cursor: pointer;
  font-size: 18px;
  font-weight: 500;
}

.tista-form-info {
  color: var(--tf-muted);
  font-size: 13px;
}

.tf-status {
  margin-top: 12px;
  font-size: 12px;
}

.tf-status--ok {
  color: #14532D;
}

.tf-status--error {
  color: #7F1D1D;
}

.tista-honeypot {
  position: absolute !important;
  left: -10000px !important;
  width: 1px !important;
  height: 1px !important;
  overflow: hidden !important;
  opacity: 0 !important;
  pointer-events: none !important;
}

/* Closing section */
.extra-deco {
  position: relative;
  z-index: 5;
  padding: 200px 0;
  background: var(--tista-cream-dark);
  color: var(--tista-red);
  font-size: 2rem;
  font-weight: 500;
  text-align: center;
}

.extra-deco::before {
  position: absolute;
  top: -273px;
  left: 30vw;
  width: 40vw;
  height: 100%;
  background: url(../images/tisto-decor-5-logo.svg) center / contain no-repeat;
  content: '';
}

footer {
  background: var(--tista-cream);
}

@media (max-width: 1024px) {
  .extra-deco::before {
    left: 15vw;
    width: 70vw;
  }

  .tisto-hide-hero {
    display: none;
  }
}

@media (max-width: 991px) {
  .tista-form-text {
    margin-bottom: 60px;
  }

  .tista-form-wrap::after {
    left: 5vw;
    width: 90vw;
  }
}

@media (max-width: 767.98px) {
  #tista-map .tista-popover {
    right: 0 !important;
    bottom: 0 !important;
    left: 0 !important;
    top: auto !important;
    width: 100%;
    max-width: 100vw;
    margin: 0 auto;
    border-radius: 18px 18px 0 0;
    transform: none !important;
  }

  #tista-map .tista-popover-arrow {
    display: none;
  }

  #tista-map .tista-popover-content {
    padding: 14px 16px 12px;
  }

  #tista-map .tista-popover-close {
    width: 38px;
    height: 38px;
  }

  #tista-map .tista-title {
    padding-right: 46px;
    font-size: 19px;
  }

  #tista-map .tista-eyebrow {
    padding-right: 46px;
  }

  #tista-map .tista-content {
    max-height: calc(100dvh - 210px);
    margin-top: 10px;
    padding-right: 6px;
  }

  #tista-map .tista-recipe-photo {
    margin-bottom: 16px;
  }

  #tista-map .tista-recipe-gallery img {
    height: 120px;
  }

  #tista-map .tista-actions {
    padding-top: 10px;
  }

  .extra-deco::before {
    top: -323px;
    left: 10vw;
    width: 80vw;
  }
}

@media (max-width: 575.98px) {
  .tista-hero {
    padding-bottom: 30px;
  }

  .tista-hero .hero-text {
    padding-bottom: 60px;
  }

  .tista-hero .hero-text h1 {
    font-size: 4em;
  }

  .tista-hero .hero-text p {
    font-size: 1.5em;
  }

  .tista-hero .hero-extra {
    font-size: 1.25em;
  }

  #tista-map {
    --pin-size: 18px;
  }

  #tista-map .tista-region-footer {
    margin: 8px 0 6px 12px;
  }

  #tista-map .tista-region-footer img {
    height: 64px;
  }

  #tista-map .tista-actions {
    flex-direction: column;
    gap: 14px;
  }

  #tista-map .tista-chip {
    width: 100%;
  }

  .tista-legend {
    padding: 14px 0 8px;
  }

  .tista-legend-inner {
    width: 100%;
    flex-direction: column;
    gap: 6px;
  }

  .tista-legend-item {
    justify-content: center;
    width: 100%;
    gap: 8px;
    font-size: .875rem;
    line-height: 1.3;
  }

  .tista-legend-item svg {
    width: 18px;
    height: 18px;
    flex: 0 0 18px;
  }

  .tista-legend-disclaimer {
    max-width: 100%;
    margin-top: 6px;
    padding: 0 4px;
    font-size: .625rem;
    line-height: 1.3;
  }

  .tista-form-text {
    padding-top: 0;
  }

  .tista-form-text h2 {
    font-size: 3em;
  }

  .tista-form-text p {
    font-size: 1.25em;
  }

  .tista-form {
    padding: 5px 15px;
  }

  .tista-form .tf-label,
  .tista-form .tf-input {
    font-size: 14px;
  }

  .tista-form .tf-btn {
    width: 100%;
  }
}
