.koduva-announcement--market,
.koduva-announcement--market *,
.koduva-market-dialog,
.koduva-market-dialog * {
  box-sizing: border-box;
}

.koduva-announcement--market {
  position: relative;
  z-index: 100;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
  gap: clamp(0.5rem, 2vw, 1.25rem);
  min-height: 42px;
  align-items: center;
  padding: 0.25rem max(1rem, calc((100vw - var(--koduva-wide, 1420px)) / 2));
  overflow: visible;
  text-align: left;
}

.koduva-announcement--market > p:empty {
  display: none;
}

.koduva-announcement--market .koduva-product-count {
  grid-area: 1 / 1;
  justify-self: start;
  display: inline-flex;
  min-width: 0;
  align-items: center;
  gap: 0.4rem;
  padding: 0.32rem 0.58rem;
  color: #f5f0e6;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(245, 240, 230, 0.28);
  border-radius: 999px;
  font-size: 0.76rem;
  font-weight: 800;
  line-height: 1;
  white-space: nowrap;
}

.koduva-announcement--market .koduva-product-count > span {
  opacity: 0.8;
}

.koduva-announcement--market .koduva-product-count > strong {
  color: #f5f0e6;
  font-size: 0.88rem;
  font-weight: 900;
  line-height: 1;
}

.koduva-announcement--market .koduva-announcement-message {
  grid-column: 2;
  min-width: 0;
  padding: 0.42rem clamp(0.85rem, 2vw, 1.15rem);
  color: var(--koduva-forest-dark, #102d22);
  background: var(--koduva-coral, #f15a37);
  border: 1px solid rgba(255, 253, 248, 0.35);
  border-radius: 999px;
  box-shadow: 0 3px 12px rgba(8, 28, 21, 0.22);
  font-size: clamp(0.88rem, 1.15vw, 0.98rem);
  font-weight: 900;
  line-height: 1.15;
  text-align: center;
  text-wrap: balance;
  white-space: nowrap;
}

.koduva-market-selector--announcement {
  position: relative;
  z-index: 110;
  grid-area: 1 / 3;
  justify-self: end;
  min-width: 0;
}

.koduva-market-selector-trigger {
  display: inline-flex;
  min-height: 34px;
  max-width: 100%;
  align-items: center;
  justify-content: center;
  gap: 0.3rem;
  padding: 0.42rem 0.62rem;
  color: #f5f0e6;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(245, 240, 230, 0.48);
  border-radius: 7px;
  cursor: pointer;
  font: inherit;
  font-size: 0.78rem;
  font-weight: 850;
  line-height: 1;
  white-space: nowrap;
}

.koduva-market-selector-trigger:hover {
  background: rgba(255, 255, 255, 0.16);
  border-color: #f5f0e6;
}

.koduva-market-selector-trigger b {
  opacity: 0.7;
}

.koduva-market-selector-trigger i {
  width: 0.45rem;
  height: 0.45rem;
  margin: -0.2rem 0 0 0.12rem;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: rotate(45deg);
}

.koduva-market-selector-trigger:focus-visible,
.koduva-market-dialog button:focus-visible {
  outline: 3px solid #173c2e;
  outline-offset: 2px;
  box-shadow: 0 0 0 5px #f0a14a;
}

.koduva-market-dialog-heading h2:focus {
  outline: none;
  box-shadow: none;
}

.koduva-market-dialog {
  width: min(580px, calc(100vw - 2rem));
  max-width: none;
  max-height: min(88dvh, 780px);
  margin: auto;
  padding: 0;
  overflow: hidden;
  color: #1c2922;
  background: #fffdf8;
  border: 1px solid #ded8cc;
  border-radius: 16px;
  box-shadow: 0 24px 80px rgba(8, 28, 20, 0.34);
}

.koduva-market-dialog::backdrop {
  background: rgba(8, 28, 20, 0.66);
  backdrop-filter: blur(2px);
}

.koduva-market-dialog.is-fallback[open] {
  position: fixed;
  z-index: 1000;
  inset: 50% auto auto 50%;
  box-shadow: 0 0 0 100vmax rgba(8, 28, 20, 0.66), 0 24px 80px rgba(8, 28, 20, 0.34);
  transform: translate(-50%, -50%);
}

.koduva-market-dialog-form {
  position: relative;
  display: grid;
  max-height: inherit;
  gap: 1rem;
  padding: clamp(1.15rem, 3vw, 1.65rem);
  overflow-y: auto;
  overscroll-behavior: contain;
  text-align: left;
}

.koduva-market-dialog-close {
  position: absolute;
  z-index: 2;
  top: 0.7rem;
  right: 0.7rem;
  display: grid;
  width: 2.5rem;
  height: 2.5rem;
  place-items: center;
  padding: 0;
  color: #193d2e;
  background: #f5f0e6;
  border: 1px solid #ded8cc;
  border-radius: 999px;
  cursor: pointer;
  font: inherit;
  font-size: 1.4rem;
  line-height: 1;
}

.koduva-market-dialog-brand {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.62rem;
  min-height: 2.5rem;
  padding-inline: 3rem;
}

.koduva-market-dialog-brand .koduva-wordmark {
  color: #193d2e;
  font-family: Manrope, Arial, sans-serif;
  font-size: 1.15rem;
  font-weight: 950;
  letter-spacing: 0;
  line-height: 0.95;
}

.koduva-market-dialog-globe,
.koduva-market-dialog-section-icon {
  display: inline-grid;
  flex: 0 0 auto;
  place-items: center;
  color: #2f7a56;
}

.koduva-market-dialog :is(.koduva-market-dialog-globe, .koduva-market-dialog-section-icon) svg {
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.7;
}

.koduva-market-dialog-heading {
  display: grid;
  gap: 0.28rem;
  text-align: center;
}

.koduva-market-dialog h2 {
  margin: 0;
  color: #193d2e;
  font-size: clamp(1.35rem, 3.4vw, 1.8rem);
  line-height: 1.15;
  text-wrap: balance;
}

.koduva-market-dialog-helper {
  margin: 0;
  color: #68736c;
  font-size: 0.82rem;
  line-height: 1.35;
}

.koduva-market-dialog [hidden] {
  display: none !important;
}

.koduva-market-dialog-section {
  min-width: 0;
  margin: 0;
  padding: 0;
  border: 0;
}

.koduva-market-dialog-section legend {
  display: flex;
  width: 100%;
  align-items: center;
  gap: 0.58rem;
  margin: 0 0 0.55rem;
  padding: 0;
  color: #193d2e;
}

.koduva-market-dialog-section legend > span:last-child {
  display: grid;
  gap: 0.08rem;
}

.koduva-market-dialog-section legend strong {
  font-size: 0.9rem;
  font-weight: 850;
  line-height: 1.2;
}

.koduva-market-dialog-section legend small {
  color: #68736c;
  font-size: 0.7rem;
  font-weight: 650;
  line-height: 1.2;
}

.koduva-market-choice-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.55rem;
}

.koduva-market-choice {
  position: relative;
  min-width: 0;
}

.koduva-market-choice-input {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: 0;
  opacity: 0;
  pointer-events: none;
}

.koduva-market-choice-card {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 1.4rem;
  gap: 0.5rem;
  min-height: 62px;
  align-items: center;
  padding: 0.68rem 0.72rem;
  color: #1c2922;
  background: #fff;
  border: 1px solid #cfc9bd;
  border-radius: 10px;
  cursor: pointer;
  transition: background-color 150ms ease, border-color 150ms ease, box-shadow 150ms ease;
}

.koduva-market-choice-card--country {
  grid-template-columns: auto minmax(0, 1fr) 1.4rem;
}

.koduva-market-choice-card:hover {
  border-color: #2f7a56;
}

.koduva-market-choice-input:checked + .koduva-market-choice-card {
  background: #edf6f0;
  border-color: #193d2e;
  box-shadow: inset 0 0 0 1px #193d2e;
}

.koduva-market-choice-input:focus-visible + .koduva-market-choice-card {
  outline: 3px solid #193d2e;
  outline-offset: 2px;
  box-shadow: 0 0 0 5px #f0a14a;
}

.koduva-market-choice-copy {
  display: grid;
  min-width: 0;
  gap: 0.12rem;
}

.koduva-market-choice-copy strong {
  overflow-wrap: anywhere;
  font-size: 0.9rem;
  font-weight: 850;
  line-height: 1.2;
}

.koduva-market-choice-copy small {
  color: #68736c;
  font-size: 0.7rem;
  font-weight: 650;
  line-height: 1.2;
}

.koduva-market-choice-flag {
  font-size: 1.35rem;
  line-height: 1;
}

.koduva-market-choice-check {
  display: grid;
  width: 1.35rem;
  height: 1.35rem;
  place-items: center;
  color: #fff;
  background: #2f7a56;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 900;
  opacity: 0;
}

.koduva-market-choice-input:checked + .koduva-market-choice-card .koduva-market-choice-check {
  opacity: 1;
}

.koduva-market-delivery-confirmation {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  padding: 0.78rem 0.86rem;
  color: #193d2e;
  background: #edf6f0;
  border: 1px solid #bfd5c6;
  border-radius: 10px;
}

.koduva-market-delivery-confirmation > span:last-child {
  display: grid;
  gap: 0.12rem;
}

.koduva-market-delivery-confirmation strong {
  font-size: 0.88rem;
  font-weight: 850;
  line-height: 1.25;
}

.koduva-market-delivery-confirmation small {
  color: #52655b;
  font-size: 0.7rem;
  font-weight: 650;
  line-height: 1.25;
}

.koduva-market-delivery-icon {
  display: grid;
  width: 1.6rem;
  height: 1.6rem;
  flex: 0 0 auto;
  place-items: center;
  color: #fff;
  background: #2f7a56;
  border-radius: 999px;
  font-size: 0.85rem;
  font-weight: 900;
}

.koduva-market-dialog-actions {
  display: grid;
  gap: 0.35rem;
}

.koduva-market-dialog-primary,
.koduva-market-dialog-secondary {
  min-height: 48px;
  padding: 0.72rem 1rem;
  border-radius: 9px;
  cursor: pointer;
  font: inherit;
  font-weight: 850;
  line-height: 1.25;
  overflow-wrap: anywhere;
  white-space: normal;
}

.koduva-market-dialog-primary {
  color: #fff;
  background: #2f7a56;
  border: 1px solid #2f7a56;
}

.koduva-market-dialog-primary:hover:not(:disabled) {
  background: #245f44;
  border-color: #245f44;
}

.koduva-market-dialog-primary:disabled {
  cursor: not-allowed;
  opacity: 0.52;
}

.koduva-market-dialog-secondary {
  display: grid;
  min-height: 46px;
  place-items: center;
  gap: 0.08rem;
  color: #2f7a56;
  background: transparent;
  border: 0;
  text-decoration: underline;
  text-underline-offset: 0.2em;
}

.koduva-market-dialog-secondary small {
  color: #68736c;
  font-size: 0.68rem;
  font-weight: 650;
  text-decoration: none;
}

html.koduva-market-dialog-open {
  overflow: hidden;
}

@media (max-width: 600px) {
  .koduva-announcement--market {
    grid-template-columns: auto minmax(0, 1fr) auto;
    gap: 0.32rem;
    min-height: 48px;
    padding: 0.28rem 0.5rem;
  }

  .koduva-announcement--market .koduva-product-count {
    grid-area: 1 / 1;
    padding: 0.3rem 0.42rem;
  }

  .koduva-announcement--market .koduva-product-count > span {
    display: none;
  }

  .koduva-announcement--market .koduva-announcement-message {
    grid-column: 2;
    padding: 0.38rem 0.48rem;
    font-size: 0.78rem;
    line-height: 1.18;
    text-align: center;
    white-space: normal;
  }

  .koduva-market-selector--announcement {
    grid-area: 1 / 3;
  }

  .koduva-market-selector-trigger {
    gap: 0.2rem;
    padding: 0.42rem 0.48rem;
    font-size: 0.7rem;
  }

  .koduva-market-dialog {
    width: calc(100vw - 1rem);
    max-height: min(88dvh, 760px);
    margin: auto auto 0.5rem;
    border-radius: 16px;
  }

  .koduva-market-dialog.is-fallback[open] {
    inset: auto 0.5rem 0.5rem;
    transform: none;
  }

  .koduva-market-dialog-form {
    gap: 0.82rem;
    padding: 1rem 0.9rem max(1rem, env(safe-area-inset-bottom));
  }

  .koduva-market-dialog-brand {
    min-height: 2.25rem;
  }

  .koduva-market-choice-card {
    min-height: 58px;
    padding: 0.6rem;
  }
}

@media (max-width: 340px) {
  .koduva-market-choice-grid {
    grid-template-columns: 1fr;
  }
}

@media (forced-colors: active) {
  .koduva-market-choice-input:checked + .koduva-market-choice-card {
    outline: 2px solid CanvasText;
  }

  .koduva-market-choice-check,
  .koduva-market-delivery-icon {
    border: 1px solid CanvasText;
  }
}

@media (prefers-reduced-motion: reduce) {
  .koduva-market-choice-card {
    transition: none;
  }
}
