* { margin: 0; padding: 0; outline: none; box-sizing: inherit; } *::before, *::after { box-sizing: inherit; } html { font-size: 100%; box-sizing: border-box; scroll-behavior: smooth; } html::after { display: none; content: "small:25em,medium:43.75em,large:64em,xlarge:80em,xxlarge:90em"; } img { display: inline-block; max-width: 100%; } iframe { display: block; border: none; } ul { list-style-type: none; } button { font-family: inherit; font-size: inherit; line-height: inherit; border-radius: unset; cursor: pointer; } @media (prefers-reduced-motion: reduce) { /* stylelint-disable declaration-no-important */ * { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; scroll-behavior: auto !important; } /* stylelint-enable declaration-no-important */ } body { font-family: system-ui, sans-serif; display: flex; align-items: center; justify-content: center; min-height: 100vh; } .wrapper { width: 60vh; max-width: 100%; padding-inline: 1rem; } label { display: block; font-weight: bold; margin-block-end: 0.5em; } :is(select, .select-replace) { display: block; width: 100%; border-width: 2px; border-style: solid; border-color: lightgray; border-radius: 10px; padding-inline: 1em; padding-block: 0.5em; } select.visually-hidden { clip: rect(0 0 0 0); clip-path: inset(50%); height: 1px; overflow: hidden; position: absolute; white-space: nowrap; width: 1px; } select:user-invalid + .select-replace { border-color: red; } .select-replace { cursor: pointer; background-image: url("data:image/svg+xml;utf8,"); background-origin: content-box; background-size: 0.5625rem 0.375rem; background-repeat: no-repeat; background-position: right -1.53125rem center; padding-inline-end: 2.5rem; } .select-replace.has-focus { outline-width: 2px; outline-style: solid; outline-color: lightcoral; outline-offset: 2px; } .select-replace.disabled { opacity: 0.5; cursor: not-allowed; } .option-list { display: none; position: absolute; overflow-x: hidden; overflow-y: auto; background-color: white; border-width: 2px; border-style: solid; border-color: lightgray; border-radius: 10px; margin-block-start: 0.5rem; padding: 0.2em; } .option-list .option-list-search { position: sticky; top: 0; z-index: 1; background-color: white; width: 100%; border-width: 1px; border-style: solid; border-color: lightgray; border-radius: 0.5rem; margin-block-end: 0.4rem; padding-inline: 0.6rem; padding-block: 0.3rem; } .option-list .option-list-empty { color: lightgray; padding-inline: 0.8em; padding-block: 0.5em; } .option-list .option-list-group:not(:first-child) { margin-block-start: 0.5em; } .option-list .option-list-group .label { font-weight: bold; font-size: 0.85em; color: lightgray; text-transform: uppercase; padding-inline: 0.8em; padding-block: 0.4em 0.2em; cursor: default; } .option-list .option-list-group.disabled .option-list-group-label { opacity: 0.5; } .option-list [role=option] { cursor: pointer; padding-inline: 0.8em; padding-block: 0.3em; } .option-list [role=option]:nth-child(even) { background-color: #fafafa; } .option-list [aria-selected=true] { font-weight: bold; } .option-list .disabled { opacity: 0.5; cursor: not-allowed; } #custom-container { position: relative; background-color: #fafafa; padding: 2rem; border-color: lightgray; border-width: 1px; border-style: solid; border-radius: 1rem; } .button-bar { grid-column: span 2; display: flex; justify-content: center; gap: 0.5rem; margin-block-start: 2rem; } .button-bar button { font-family: inherit; border-width: 2px; border-style: solid; border-radius: 1000px; padding-block: 0.5rem; padding-inline: 1.5rem; } .form-grid { display: grid; gap: 1rem; grid-template-columns: repeat(auto-fit, minmax(8rem, 1fr)); }