:root {
  --accw-bg: #fbfaf7;
  --accw-surface: #ffffff;
  --accw-text: #161616;
  --accw-muted: #65615a;
  --accw-border: rgba(22, 22, 22, 0.14);
  --accw-accent: #9b7b42;
  --accw-accent-dark: #73572c;
  --accw-shadow: 0 24px 60px rgba(0, 0, 0, 0.18);
  --accw-radius: 8px;
  --accw-font-scale: 1;
  --accw-line-height: initial;
}

html.accw-font-readable,
html.accw-font-readable body,
html.accw-font-readable button,
html.accw-font-readable input,
html.accw-font-readable select,
html.accw-font-readable textarea {
  font-family: Arial, Helvetica, sans-serif !important;
}

html.accw-underline-links a {
  text-decoration: underline !important;
  text-decoration-thickness: 0.12em !important;
  text-underline-offset: 0.18em !important;
}

html.accw-grayscale {
  filter: grayscale(1) !important;
}

html.accw-reduce-motion *,
html.accw-reduce-motion *::before,
html.accw-reduce-motion *::after {
  animation-duration: 0.001ms !important;
  animation-iteration-count: 1 !important;
  scroll-behavior: auto !important;
  transition-duration: 0.001ms !important;
}

html.accw-high-contrast {
  background: #000 !important;
}

html.accw-high-contrast body,
html.accw-high-contrast main,
html.accw-high-contrast section,
html.accw-high-contrast article,
html.accw-high-contrast header,
html.accw-high-contrast footer,
html.accw-high-contrast nav {
  background: #000 !important;
  color: #fff !important;
}

html.accw-high-contrast a,
html.accw-high-contrast button,
html.accw-high-contrast input,
html.accw-high-contrast textarea,
html.accw-high-contrast select {
  border-color: #fff !important;
  color: #fff !important;
}

html.accw-high-contrast a {
  color: #ffe16a !important;
}

html.accw-dark-contrast {
  background: #111 !important;
}

html.accw-dark-contrast body {
  background: #111 !important;
  color: #f7f2e8 !important;
}

html.accw-light-contrast body {
  background: #fffdf7 !important;
  color: #17130d !important;
}

html.accw-large-cursor,
html.accw-large-cursor * {
  cursor: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='42' height='42' viewBox='0 0 42 42'%3E%3Cpath d='M5 3l25 25h-13l-6 11-5-3 6-10H5z' fill='%23000' stroke='%23fff' stroke-width='2'/%3E%3C/svg%3E") 3 3, auto !important;
}

html.accw-line-height body {
  line-height: 1.8 !important;
}

html.accw-line-height p,
html.accw-line-height li,
html.accw-line-height span,
html.accw-line-height a {
  line-height: 1.8 !important;
}

html.accw-focus-mode :focus-visible {
  outline: 3px solid #c99a37 !important;
  outline-offset: 4px !important;
  box-shadow: 0 0 0 7px rgba(201, 154, 55, 0.25) !important;
}

body {
  font-size: calc(100% * var(--accw-font-scale));
}

.accw-skip-link {
  position: fixed;
  inset-block-start: 12px;
  inset-inline-start: 12px;
  z-index: 2147483647;
  transform: translateY(-160%);
  border: 1px solid var(--accw-border);
  border-radius: 6px;
  background: #111;
  color: #fff;
  padding: 10px 14px;
  font: 600 14px/1.2 Arial, sans-serif;
  text-decoration: none;
}

.accw-skip-link:focus {
  transform: translateY(0);
}

.accw-root {
  position: fixed;
  inset-block-end: 22px;
  inset-inline-start: 22px;
  z-index: 2147483646;
  color: var(--accw-text);
  font-family: Arial, Helvetica, sans-serif;
  direction: rtl;
}

.accw-root[data-position="right"] {
  inset-inline-start: auto;
  inset-inline-end: 22px;
}

.accw-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 54px;
  height: 54px;
  border: 1px solid rgba(255, 255, 255, 0.44);
  border-radius: 50%;
  background: linear-gradient(145deg, #1f1b16, #7b5c2d);
  color: #fff;
  box-shadow: 0 16px 36px rgba(0, 0, 0, 0.22);
  cursor: pointer;
}

.accw-toggle:hover {
  transform: translateY(-1px);
}

.accw-toggle:focus-visible,
.accw-panel button:focus-visible {
  outline: 3px solid rgba(155, 123, 66, 0.45);
  outline-offset: 3px;
}

.accw-toggle svg {
  width: 26px;
  height: 26px;
}

.accw-panel {
  position: absolute;
  inset-block-end: 68px;
  inset-inline-start: 0;
  display: none;
  width: min(360px, calc(100vw - 28px));
  max-height: min(680px, calc(100vh - 110px));
  overflow: auto;
  border: 1px solid var(--accw-border);
  border-radius: var(--accw-radius);
  background: var(--accw-bg);
  box-shadow: var(--accw-shadow);
}

.accw-root[data-position="right"] .accw-panel {
  inset-inline-start: auto;
  inset-inline-end: 0;
}

.accw-root.is-open .accw-panel {
  display: block;
}

.accw-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 18px 18px 14px;
  border-bottom: 1px solid var(--accw-border);
}

.accw-title {
  margin: 0;
  font-size: 18px;
  line-height: 1.2;
}

.accw-subtitle {
  margin: 4px 0 0;
  color: var(--accw-muted);
  font-size: 13px;
  line-height: 1.45;
}

.accw-close {
  width: 34px;
  height: 34px;
  border: 1px solid var(--accw-border);
  border-radius: 50%;
  background: var(--accw-surface);
  color: var(--accw-text);
  cursor: pointer;
  font-size: 21px;
  line-height: 1;
}

.accw-body {
  padding: 16px 18px 18px;
}

.accw-section {
  margin-bottom: 18px;
}

.accw-section-title {
  margin: 0 0 10px;
  color: var(--accw-muted);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0;
  text-transform: uppercase;
}

.accw-size-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
}

.accw-button,
.accw-action {
  min-height: 42px;
  border: 1px solid var(--accw-border);
  border-radius: 7px;
  background: var(--accw-surface);
  color: var(--accw-text);
  cursor: pointer;
  font: 700 14px/1.2 Arial, sans-serif;
}

.accw-button[aria-pressed="true"],
.accw-action.is-primary {
  border-color: rgba(155, 123, 66, 0.9);
  background: #1f1b16;
  color: #fff;
}

.accw-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.accw-feature {
  display: flex;
  min-height: 74px;
  flex-direction: column;
  align-items: flex-start;
  justify-content: center;
  gap: 6px;
  border: 1px solid var(--accw-border);
  border-radius: 7px;
  background: var(--accw-surface);
  color: var(--accw-text);
  cursor: pointer;
  padding: 11px 12px;
  text-align: start;
}

.accw-feature strong {
  font-size: 14px;
  line-height: 1.2;
}

.accw-feature span {
  color: var(--accw-muted);
  font-size: 12px;
  line-height: 1.35;
}

.accw-feature[aria-pressed="true"] {
  border-color: rgba(155, 123, 66, 0.9);
  background: #fff8e8;
}

.accw-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.accw-note {
  margin: 12px 0 0;
  color: var(--accw-muted);
  font-size: 12px;
  line-height: 1.45;
}

@media (max-width: 520px) {
  .accw-root,
  .accw-root[data-position="right"] {
    inset-inline: 14px auto;
    inset-block-end: 14px;
  }

  .accw-panel,
  .accw-root[data-position="right"] .accw-panel {
    inset-inline: 0 auto;
    width: calc(100vw - 28px);
  }
}
