.timy-cookie-consent,
.timy-cookie-manage,
.timy-cookie-noscript {
  font-family: Inter, "Noto Sans SC", "Noto Sans TC", system-ui, sans-serif;
  box-sizing: border-box;
}

.timy-cookie-consent *,
.timy-cookie-consent *::before,
.timy-cookie-consent *::after {
  box-sizing: border-box;
}

.timy-cookie-consent {
  position: fixed;
  z-index: 100000;
  left: 50%;
  bottom: max(18px, env(safe-area-inset-bottom));
  width: min(1120px, calc(100vw - 36px));
  padding: 20px;
  transform: translateX(-50%);
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 18px 28px;
  align-items: center;
  border: 1px solid rgba(255, 255, 255, .16);
  background: #2b201a;
  color: #fffaf4;
  box-shadow: 0 24px 72px rgba(32, 22, 17, .3);
}

.timy-cookie-consent[hidden],
.timy-cookie-manage[hidden],
.timy-cookie-consent [hidden] {
  display: none !important;
}

.timy-cookie-consent__eyebrow {
  margin: 0 0 6px;
  color: #f1a39a;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: .14em;
  text-transform: uppercase;
}

.timy-cookie-consent__summary > strong {
  display: block;
  font-family: "Noto Serif SC", "Noto Serif TC", Georgia, serif;
  font-size: clamp(19px, 2vw, 25px);
  line-height: 1.25;
}

.timy-cookie-consent__summary > p:last-child {
  max-width: 760px;
  margin: 8px 0 0;
  color: rgba(255, 250, 244, .75);
  font-size: 13px;
  line-height: 1.65;
}

.timy-cookie-consent a {
  color: inherit;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.timy-cookie-consent__actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(148px, 1fr));
  grid-template-areas:
    "reject accept"
    "custom custom";
  gap: 8px;
}

.timy-cookie-consent__actions [data-cookie-reject] { grid-area: reject; }
.timy-cookie-consent__actions [data-cookie-accept] { grid-area: accept; }
.timy-cookie-consent__actions [data-cookie-customize] { grid-area: custom; }

.timy-cookie-consent button,
.timy-cookie-manage {
  min-height: 44px;
  border: 1px solid rgba(255, 255, 255, .5);
  border-radius: 0;
  padding: 0 16px;
  background: transparent;
  color: #fffaf4;
  font: inherit;
  font-size: 12px;
  font-weight: 750;
  cursor: pointer;
}

.timy-cookie-consent__actions [data-cookie-customize] {
  min-height: 38px;
}

.timy-cookie-consent__choice {
  border-color: #fffaf4 !important;
  background: #fffaf4 !important;
  color: #2b201a !important;
}

.timy-cookie-consent button:hover,
.timy-cookie-consent button:focus-visible,
.timy-cookie-manage:hover,
.timy-cookie-manage:focus-visible {
  outline: 3px solid #f1a39a;
  outline-offset: 2px;
}

.timy-cookie-consent__preferences {
  grid-column: 1 / -1;
  padding-top: 18px;
  border-top: 1px solid rgba(255, 255, 255, .18);
}

.timy-cookie-consent__preferences h2 {
  margin: 0 0 12px;
  color: #fffaf4;
  font-family: "Noto Serif SC", "Noto Serif TC", Georgia, serif;
  font-size: 20px;
}

.timy-cookie-consent__preferences label {
  min-height: 66px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 20px;
  align-items: center;
  padding: 12px 0;
  border-top: 1px solid rgba(255, 255, 255, .12);
}

.timy-cookie-consent__preferences label strong,
.timy-cookie-consent__preferences label small {
  display: block;
}

.timy-cookie-consent__preferences label strong {
  font-size: 13px;
}

.timy-cookie-consent__preferences label small {
  margin-top: 4px;
  color: rgba(255, 250, 244, .66);
  font-size: 11px;
  line-height: 1.55;
}

.timy-cookie-consent__preferences input {
  width: 22px;
  height: 22px;
  accent-color: #ec5a57;
}

.timy-cookie-consent__save {
  margin-top: 14px;
  background: #fffaf4 !important;
  color: #2b201a !important;
}

.timy-cookie-consent__status {
  grid-column: 1 / -1;
  min-height: 1px;
  margin: 0;
  color: #efc78c;
  font-size: 11px;
}

.timy-cookie-manage {
  position: fixed;
  z-index: 99990;
  left: 14px;
  bottom: max(14px, env(safe-area-inset-bottom));
  min-height: 36px;
  border-color: rgba(48, 36, 30, .28);
  padding-inline: 12px;
  background: #fffdf9;
  color: #30241e;
  box-shadow: 0 10px 30px rgba(48, 36, 30, .14);
}

.timy-cookie-noscript {
  position: fixed;
  z-index: 100000;
  right: 16px;
  bottom: 16px;
  max-width: 460px;
  padding: 14px 16px;
  background: #2b201a;
  color: #fffaf4;
  font-size: 12px;
  line-height: 1.6;
}

.timy-cookie-noscript a {
  color: inherit;
}

.timy-cookie-inventory {
  margin-top: 28px;
  padding: 22px;
  border: 1px solid #d8cdc2;
  background: #fffdf9;
}

.timy-cookie-inventory h3 {
  margin: 0;
  font-family: "Noto Serif SC", "Noto Serif TC", Georgia, serif;
  font-size: 21px;
}

.timy-cookie-inventory dl {
  margin: 16px 0 0;
}

.timy-cookie-inventory dl > div {
  display: grid;
  grid-template-columns: minmax(160px, .45fr) minmax(0, 1fr);
  gap: 20px;
  padding: 13px 0;
  border-top: 1px solid #d8cdc2;
}

.timy-cookie-inventory dt,
.timy-cookie-inventory dd {
  margin: 0;
}

.timy-cookie-inventory code {
  font-size: 12px;
  overflow-wrap: anywhere;
}

.timy-cookie-inventory dd,
.timy-cookie-inventory > p {
  color: #756a62;
  font-size: 13px;
  line-height: 1.75;
}

.timy-cookie-inventory > p {
  margin: 14px 0 0;
}

@media (max-width: 760px) {
  .timy-cookie-consent {
    left: 12px;
    right: 12px;
    bottom: calc(82px + env(safe-area-inset-bottom));
    width: auto;
    max-height: calc(100dvh - 104px - env(safe-area-inset-bottom));
    overflow-y: auto;
    padding: 18px;
    transform: none;
    grid-template-columns: 1fr;
    gap: 16px;
  }

  .timy-cookie-consent__summary > strong {
    font-size: 20px;
  }

  .timy-cookie-consent__summary > p:last-child {
    font-size: 12px;
  }

  .timy-cookie-consent__actions {
    grid-template-columns: 1fr 1fr;
  }

  .timy-cookie-consent button {
    padding-inline: 10px;
    font-size: 11px;
  }

  .timy-cookie-manage {
    bottom: calc(82px + env(safe-area-inset-bottom));
  }

  .timy-cookie-inventory dl > div {
    grid-template-columns: 1fr;
    gap: 7px;
  }
}

@media (max-width: 380px) {
  .timy-cookie-consent__actions {
    grid-template-columns: 1fr;
    grid-template-areas:
      "reject"
      "accept"
      "custom";
  }

  .timy-cookie-consent__actions [data-cookie-customize] {
    min-height: 42px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .timy-cookie-consent *,
  .timy-cookie-manage {
    scroll-behavior: auto !important;
    transition: none !important;
  }
}
