/* Shared KUTORA platform tokens. Page-specific styles remain authoritative
   during migration so Jackson Barber Co.'s current appearance is preserved. */
:root {
  --cut-iq-primary: #111111;
  --cut-iq-accent: #c9a24b;
  --cut-iq-background: #ffffff;
  --cut-iq-text: #111111;
  --cut-iq-success: #2f855a;
  --cut-iq-warning: #b7791f;
  --cut-iq-danger: #c53030;
  --cut-iq-radius-sm: 4px;
  --cut-iq-radius-md: 8px;
  --cut-iq-radius-lg: 16px;
  --cut-iq-space-1: 4px;
  --cut-iq-space-2: 8px;
  --cut-iq-space-3: 12px;
  --cut-iq-space-4: 16px;
  --cut-iq-space-6: 24px;
  --cut-iq-space-8: 32px;
  --cut-iq-shadow: 0 12px 40px rgba(0, 0, 0, 0.18);
}

[data-cut-iq-hidden] {
  display: none !important;
}

.cut-iq-sr-only {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  padding: 0 !important;
  margin: -1px !important;
  overflow: hidden !important;
  clip: rect(0, 0, 0, 0) !important;
  white-space: nowrap !important;
  border: 0 !important;
}

.cut-iq-copilot-launcher {
  position: fixed;
  right: 20px;
  bottom: max(20px, env(safe-area-inset-bottom));
  z-index: 2147483000;
  display: flex;
  align-items: center;
  gap: 9px;
  min-height: 50px;
  padding: 12px 18px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 999px;
  background: var(--cut-iq-accent, #c9a24b);
  color: #111;
  box-shadow: 0 12px 36px rgba(0, 0, 0, 0.35);
  font: 700 14px/1.2 system-ui, sans-serif;
  cursor: pointer;
}

.cut-iq-copilot-launcher:hover,
.cut-iq-copilot-launcher:focus-visible {
  filter: brightness(1.08);
  transform: translateY(-1px);
}

.cut-iq-copilot-backdrop {
  position: fixed;
  inset: 0;
  z-index: 2147482998;
  background: rgba(0, 0, 0, 0.48);
  backdrop-filter: blur(2px);
}

.cut-iq-copilot-panel {
  position: fixed;
  right: 20px;
  bottom: 84px;
  z-index: 2147482999;
  width: min(430px, calc(100vw - 40px));
  height: min(680px, calc(100dvh - 110px));
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 18px;
  background: #090909;
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.5);
}

.cut-iq-copilot-panel-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 54px;
  padding: 0 10px 0 18px;
  background: #151515;
  color: #f2f2f2;
  font: 700 14px/1 system-ui, sans-serif;
  letter-spacing: 0.04em;
}

.cut-iq-copilot-close {
  width: 38px;
  height: 38px;
  border: 0;
  border-radius: 50%;
  background: transparent;
  color: #f2f2f2;
  font: 28px/1 system-ui, sans-serif;
  cursor: pointer;
}

.cut-iq-copilot-close:hover,
.cut-iq-copilot-close:focus-visible {
  background: rgba(255, 255, 255, 0.1);
}

.cut-iq-copilot-frame {
  display: block;
  width: 100%;
  height: calc(100% - 54px);
  border: 0;
  background: #090909;
}

@media (max-width: 640px) {
  html.cut-iq-copilot-open,
  html.cut-iq-copilot-open body {
    overflow: hidden;
  }

  .cut-iq-copilot-launcher {
    right: 12px;
    bottom: max(12px, env(safe-area-inset-bottom));
    min-height: 48px;
    padding: 11px 15px;
  }

  .cut-iq-copilot-panel {
    inset: 0;
    width: 100%;
    height: 100dvh;
    border: 0;
    border-radius: 0;
  }

  .cut-iq-copilot-panel-bar {
    height: calc(56px + env(safe-area-inset-top));
    padding-top: env(safe-area-inset-top);
  }

  .cut-iq-copilot-frame {
    height: calc(100% - 56px - env(safe-area-inset-top));
  }
}

@media (max-width: 400px) {
  .cut-iq-copilot-launcher{width:50px;padding:11px;justify-content:center}
  .cut-iq-copilot-launcher span:last-child{display:none}
}

@media (prefers-reduced-motion: reduce) {
  html:focus-within{scroll-behavior:auto}
  *,*::before,*::after{
    animation-duration:0.01ms!important;
    animation-iteration-count:1!important;
    scroll-behavior:auto!important;
    transition-duration:0.01ms!important;
  }
  .cut-iq-copilot-launcher{transition:none}
  .cut-iq-copilot-launcher:hover,.cut-iq-copilot-launcher:focus-visible{transform:none}
}

:where(a,button,input,select,textarea,[tabindex]):focus-visible {
  outline: 3px solid #f2f2f2;
  outline-offset: 3px;
}
