:root {
  --hddms-color-text: var(--hddms-color-semantic-text-primary);
  --hddms-color-accent: var(--hddms-color-semantic-accent);
  --hddms-color-border: var(--hddms-color-semantic-border-control);
  --hddms-color-surface: var(--hddms-color-semantic-bg-surface);
  --hddms-color-surface-alt: var(--hddms-color-semantic-bg-subtle);
}

body {
  font-optical-sizing: auto;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  overflow-wrap: break-word;
  min-width: 0;
}

a:hover {
  text-decoration-color: var(--hddms-color-semantic-accent);
}

.hddms-site-header {
  border-bottom: 1px solid var(--hddms-color-surface-alt);
  padding-block: 1rem;
}

.hddms-brand {
  display: inline-flex;
  flex: 0 0 auto;
}

.hddms-brand img {
  display: block;
  height: auto;
  width: clamp(9rem, 15vw, 12rem);
}

.hddms-site-header .wp-block-navigation-item__content {
  text-decoration: none;
}

.hddms-site-header
  .wp-block-navigation-item__content[aria-current="page"] {
  background: var(--hddms-color-accent);
  color: var(--hddms-color-text);
  padding: 0.55rem 0.9rem;
}

.hddms-hero-content > * {
  max-width: 52rem;
}

.hddms-product-collection .wc-block-product-template {
  gap: var(--wp--preset--spacing--40);
}

.hddms-product-collection .wc-block-product {
  border-top: 3px solid var(--hddms-color-accent);
  height: 100%;
  padding-top: var(--wp--preset--spacing--30);
}

.hddms-product-collection .wc-block-components-product-image {
  margin-block-start: 0;
}

.hddms-product-collection .wp-block-post-title {
  margin-block-end: 0;
}

.hddms-product-collection .wp-block-post-excerpt__more-link {
  font-weight: 650;
}

.hddms-hero-image img {
  display: block;
  width: 100%;
}

.hddms-site-footer {
  margin-block-start: 0;
  padding-block: var(--wp--preset--spacing--50);
}

@media (max-width: 48rem) {
  .hddms-site-header {
    padding-block: 0.75rem;
  }

  .hddms-hero {
    padding-block: var(--wp--preset--spacing--50) !important;
  }

  .hddms-hero,
  .hddms-product-collection,
  .hddms-call-to-action,
  .hddms-site-footer {
    box-sizing: border-box;
    padding-inline: var(--wp--preset--spacing--40) !important;
  }

  .hddms-site-header .wp-block-navigation__responsive-container.is-menu-open {
    bottom: auto;
    box-sizing: border-box;
    height: auto;
    left: 0;
    min-height: 0;
    overflow-x: hidden;
    padding: var(--wp--preset--spacing--40);
    right: 0;
    top: 0;
    width: 100%;
  }

  .hddms-site-header .wp-block-navigation__responsive-container.is-menu-open
    .wp-block-navigation__responsive-container-content {
    align-items: flex-start;
    padding-top: var(--wp--preset--spacing--50);
  }

  .hddms-site-header .wp-block-navigation__responsive-container.is-menu-open
    .wp-block-navigation__container {
    align-items: flex-start;
    gap: var(--wp--preset--spacing--30);
    margin: 0;
    max-width: 100%;
    padding: 0;
    width: 100%;
  }

  .hddms-site-header .wp-block-navigation__responsive-container.is-menu-open
    .wp-block-navigation-item {
    align-items: flex-start;
    box-sizing: border-box;
    margin: 0;
    max-width: 100%;
    padding: 0;
    width: 100%;
  }

  .hddms-site-header .wp-block-navigation__responsive-container.is-menu-open
    .wp-block-navigation-item__content {
    box-sizing: border-box;
    display: block;
    max-width: 100%;
    text-align: left;
    width: auto;
  }

  .hddms-site-chat-launcher {
    box-sizing: border-box;
    height: 3.25rem;
    padding: 0;
    width: 3.25rem;
  }

  .hddms-site-chat-launcher__label {
    display: none;
  }

  .hddms-type-specimen {
    padding-inline: var(--wp--preset--spacing--40);
  }
}

*:focus-visible {
  outline: var(--hddms-size-focus-width) solid currentColor;
  outline-offset: 2px;
}

.wp-element-button,
.wp-block-button__link {
  align-items: center;
  border-radius: var(--hddms-size-radius);
  display: inline-flex;
  min-height: var(--hddms-size-button-default);
  transition-duration: var(--hddms-motion-duration-fast);
  transition-property: background-color, border-color, color;
  transition-timing-function: var(--hddms-motion-ease-standard);
}

.wp-element-button:focus-visible,
.wp-block-button__link:focus-visible {
  --hddms-button-focus-gap: var(--hddms-color-semantic-action-primary);

  box-shadow:
    inset 0 0 0 var(--hddms-size-focus-inset) var(--hddms-button-focus-gap),
    inset 0 0 0 calc(var(--hddms-size-focus-inset) + var(--hddms-size-focus-width)) currentColor;
  outline: none;
}

.wp-block-button.is-style-outline > .wp-block-button__link {
  --hddms-button-focus-gap: var(--hddms-color-semantic-bg-surface);

  background: transparent;
  border: var(--hddms-size-border-thin) solid var(--hddms-color-semantic-text-primary);
  color: var(--hddms-color-semantic-text-primary);
}

table {
  border-collapse: collapse;
  font-variant-numeric: tabular-nums lining-nums;
  width: 100%;
}

.hddms-type-specimen {
  margin-inline: auto;
  max-width: var(--wp--style--global--wide-size);
  padding: var(--wp--preset--spacing--50) var(--wp--preset--spacing--30);
}

.hddms-type-specimen__intro {
  max-width: 52rem;
}

.hddms-type-specimen__meta {
  color: var(--hddms-color-text);
  font-size: var(--hddms-type-size-label);
  font-weight: var(--hddms-font-weight-semibold);
  line-height: var(--hddms-type-line-height-label);
  letter-spacing: var(--hddms-type-tracking-label);
  text-transform: uppercase;
}

.hddms-type-specimen__language {
  border-top: 1px solid var(--hddms-color-border);
  margin-block-start: var(--wp--preset--spacing--50);
  padding-block-start: var(--wp--preset--spacing--40);
}

.hddms-type-specimen__display {
  margin-block: var(--wp--preset--spacing--20) var(--wp--preset--spacing--30);
  max-width: 18ch;
}

.hddms-type-specimen__product {
  font-size: var(--wp--preset--font-size--h-3);
  font-weight: var(--hddms-font-weight-semibold);
  letter-spacing: var(--hddms-type-tracking-h3);
  line-height: var(--hddms-type-line-height-h3);
  max-width: 30ch;
}

.hddms-type-specimen__copy {
  max-width: 68ch;
}

.hddms-type-specimen__ui {
  align-items: center;
  display: flex;
  flex-wrap: wrap;
  gap: var(--wp--preset--spacing--20);
  margin-block: var(--wp--preset--spacing--30);
}

.hddms-type-specimen__button {
  background: var(--hddms-color-accent);
  color: var(--hddms-color-text);
  display: inline-block;
  font-weight: var(--hddms-font-weight-semibold);
  letter-spacing: var(--hddms-type-tracking-button);
  padding: 0.8em 1.25em;
  text-decoration: none;
}

.hddms-type-specimen__label {
  font-size: var(--hddms-type-size-small-max);
  font-weight: var(--hddms-font-weight-semibold);
  line-height: var(--hddms-type-line-height-small);
  letter-spacing: var(--hddms-type-tracking-body);
}

.hddms-type-specimen__table-wrap {
  overflow-x: auto;
}

.hddms-type-specimen__glyphs {
  font-size: var(--wp--preset--font-size--lead);
  overflow-wrap: anywhere;
}

th,
td {
  border-bottom: 1px solid var(--hddms-color-border);
  padding: 0.75rem;
  text-align: left;
  vertical-align: top;
}


:where(
  input:not([type="checkbox"]):not([type="radio"]):not([type="submit"]):not([type="button"]):not([type="reset"]):not([type="file"]),
  select,
  textarea
) {
  background: var(--hddms-component-field-color-bg);
  border: var(--hddms-size-border-thin) solid var(--hddms-component-field-color-border);
  border-radius: var(--hddms-size-radius);
  box-sizing: border-box;
  color: var(--hddms-color-text);
  font: inherit;
  font-size: var(--hddms-component-field-size-text);
  font-weight: var(--hddms-font-weight-regular);
  line-height: var(--hddms-type-line-height-body);
  letter-spacing: var(--hddms-type-tracking-body);
  max-width: 100%;
  min-height: var(--hddms-component-field-size-height);
  padding-block: 0;
  padding-inline: var(--hddms-component-field-size-padding-inline);
  transition-duration: var(--hddms-motion-duration-fast);
  transition-property: background-color, border-color, box-shadow, color;
  transition-timing-function: var(--hddms-motion-ease-standard);
}

:where(textarea) {
  min-height: var(--hddms-component-field-size-textarea-min-height);
  padding-block: var(--hddms-space-3);
  resize: vertical;
}

:where(
  input:not([type="checkbox"]):not([type="radio"]):not([type="submit"]):not([type="button"]):not([type="reset"]):not([type="file"]),
  textarea
)::placeholder {
  color: var(--hddms-component-field-color-placeholder);
  opacity: 1;
}

:where(
  input:not([type="checkbox"]):not([type="radio"]):not([type="submit"]):not([type="button"]):not([type="reset"]):not([type="file"]),
  select,
  textarea
):not(:disabled):not([readonly]):hover {
  border-color: var(--hddms-component-field-color-border-hover);
}

:where(
  input:not([type="checkbox"]):not([type="radio"]):not([type="submit"]):not([type="button"]):not([type="reset"]):not([type="file"]),
  select,
  textarea
):focus-visible {
  border-color: var(--hddms-component-field-color-border-focus);
  box-shadow: inset 0 0 0 var(--hddms-size-border-thin) var(--hddms-component-field-color-border-focus);
  outline: none;
}

:where(
  input:not([type="checkbox"]):not([type="radio"]):not([type="submit"]):not([type="button"]):not([type="reset"]):not([type="file"]),
  select,
  textarea
):disabled {
  background: var(--hddms-component-field-color-disabled-bg);
  border-color: var(--hddms-component-field-color-disabled-border);
  color: var(--hddms-component-field-color-disabled-text);
  cursor: not-allowed;
  opacity: 1;
}

:where(
  input:not([type="checkbox"]):not([type="radio"]):not([type="submit"]):not([type="button"]):not([type="reset"]):not([type="file"]),
  textarea
)[readonly] {
  background: var(--hddms-component-field-color-readonly-bg);
  border-color: var(--hddms-component-field-color-readonly-border);
}

:where(
  input:not([type="checkbox"]):not([type="radio"]):not([type="submit"]):not([type="button"]):not([type="reset"]):not([type="file"]),
  select,
  textarea
)[aria-invalid="true"],
.wpcf7-form :where(
  input:not([type="checkbox"]):not([type="radio"]):not([type="submit"]):not([type="button"]):not([type="reset"]):not([type="file"]),
  select,
  textarea
).wpcf7-not-valid {
  border-color: var(--hddms-component-field-color-error);
  box-shadow: inset 0 0 0 var(--hddms-size-border-thin) var(--hddms-component-field-color-error);
}

:where(
  input:not([type="checkbox"]):not([type="radio"]):not([type="submit"]):not([type="button"]):not([type="reset"]):not([type="file"]),
  select,
  textarea
).is-success,
:where(
  input:not([type="checkbox"]):not([type="radio"]):not([type="submit"]):not([type="button"]):not([type="reset"]):not([type="file"]),
  select,
  textarea
)[data-hddms-validation="success"] {
  border-color: var(--hddms-component-field-color-success);
  box-shadow: inset 0 0 0 var(--hddms-size-border-thin) var(--hddms-component-field-color-success);
}

.wpcf7-form :where(.hddms-field, .hddms-field-label) {
  display: grid;
  gap: var(--hddms-component-field-size-label-gap);
}

.wpcf7-form :where(.wpcf7-not-valid-tip, .hddms-field-supporting, .hddms-field-message, .hddms-form-privacy) {
  display: block;
  font-size: var(--hddms-component-field-size-supporting-text);
  font-weight: var(--hddms-font-weight-regular);
  line-height: var(--hddms-type-line-height-small);
  letter-spacing: var(--hddms-type-tracking-small);
  margin-block-start: var(--hddms-component-field-size-message-gap);
}

.wpcf7-form .wpcf7-not-valid-tip {
  color: var(--hddms-component-field-color-error);
}

.wpcf7-form .hddms-form-privacy {
  font-size: var(--hddms-component-field-size-privacy-text);
}

.wpcf7-form input:not([type="checkbox"]):not([type="radio"]):not([type="submit"]),
.wpcf7-form select,
.wpcf7-form textarea {
  box-sizing: border-box;
  width: 100%;
}

.wpcf7-form fieldset {
  box-sizing: border-box;
  min-width: 0;
}

.hddms-site-header .wp-block-navigation__responsive-container.is-menu-open {
  z-index: 100001;
}

/* Field labels are not the uppercase metadata Label style. */
.wpcf7-form :where(label, .hddms-field-label) {
  font-size: var(--hddms-type-size-small-max);
  font-weight: var(--hddms-font-weight-semibold);
  line-height: var(--hddms-type-line-height-small);
  letter-spacing: var(--hddms-type-tracking-body);
}

/* Editor-owned multilingual footer: existing tokens, no page-specific styling. */
.hddms-footer-columns { gap: var(--wp--preset--spacing--50); }
.hddms-footer-columns .wp-block-column { min-width: 0; }
.hddms-footer-links { list-style: none; margin: 0; padding: 0; }
.hddms-footer-links li + li { margin-block-start: var(--wp--preset--spacing--20); }
.hddms-site-footer a { color: inherit; text-decoration: underline; text-underline-offset: 0.2em; }
.hddms-site-footer a:hover { text-decoration-thickness: 2px; }
.hddms-site-footer a:focus-visible { outline: 2px solid currentColor; outline-offset: 4px; }
.hddms-site-footer .hddms-copyright { margin-block-start: var(--wp--preset--spacing--50); }
