/* YL27 component styles, copied from the design system (components/bundle.css). The site uses this markup without React.
    Values come from tokens.css; inverse context = .yl-inverse on the component or an ancestor. */
body { margin: 0; font-family: var(--font-sans); font-weight: 300; background: var(--surface-default); color: var(--text-primary); }

/* ---------- Button ---------- */
.yl-btn {
  display: inline-flex; align-items: center; gap: var(--space-16);
  height: var(--control-m); padding: 0 var(--space-20);
  border: 1px solid transparent; border-radius: var(--radius-4);
  background: transparent; color: var(--text-primary);
  font-family: var(--font-sans); font-size: 14px; line-height: 20px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase;
  cursor: pointer; white-space: nowrap;
  transition: background-color 120ms cubic-bezier(.2, 0, 0, 1), border-color 120ms cubic-bezier(.2, 0, 0, 1);
}
.yl-btn--s { height: var(--control-s); }
.yl-btn--l { height: var(--control-l); padding: 0 var(--space-28); }
.yl-btn__arrow { flex: none; transition: transform 200ms cubic-bezier(.2, 0, 0, 1); }
.yl-btn:focus-visible { outline: var(--focus-ring-width) solid var(--focus-default); outline-offset: var(--focus-ring-offset); }

.yl-btn--primary { background: var(--action-primary); color: var(--text-primary); }
.yl-btn--primary:hover { background: var(--action-hover); }
.yl-btn--primary:hover .yl-btn__arrow { transform: translateX(4px); }
.yl-btn--primary:active { background: var(--action-pressed); transition: none; }

.yl-btn--secondary { border-color: var(--charcoal-900); }
.yl-btn--secondary:hover, .yl-btn--tertiary:hover { background: var(--charcoal-100); }
.yl-btn--secondary:active, .yl-btn--tertiary:active { background: var(--charcoal-300); transition: none; }

.yl-btn:disabled { cursor: not-allowed; background: var(--charcoal-200); color: var(--charcoal-600); }
.yl-btn--secondary:disabled { border-color: var(--charcoal-400); }

/* inverse context */
.yl-inverse .yl-btn, .yl-btn.yl-inverse { color: var(--text-inverse); }
.yl-inverse .yl-btn--primary, .yl-btn--primary.yl-inverse { color: var(--text-primary); }
.yl-inverse .yl-btn--secondary, .yl-btn--secondary.yl-inverse { border-color: var(--white-50); }
.yl-inverse .yl-btn--secondary:hover, .yl-btn--secondary.yl-inverse:hover,
.yl-inverse .yl-btn--tertiary:hover, .yl-btn--tertiary.yl-inverse:hover { background: var(--charcoal-800); }
.yl-inverse .yl-btn--secondary:active, .yl-btn--secondary.yl-inverse:active,
.yl-inverse .yl-btn--tertiary:active, .yl-btn--tertiary.yl-inverse:active { background: var(--charcoal-600); }
.yl-inverse .yl-btn:focus-visible, .yl-btn.yl-inverse:focus-visible { outline-color: var(--text-inverse); }
.yl-inverse .yl-btn:disabled, .yl-btn.yl-inverse:disabled { background: var(--charcoal-700); color: var(--charcoal-400); }
.yl-inverse .yl-btn--secondary:disabled, .yl-btn--secondary.yl-inverse:disabled { border-color: var(--charcoal-400); }

/* ---------- TextField ---------- */
.yl-field { display: flex; flex-direction: column; gap: var(--space-8); max-width: 469px; font-family: var(--font-sans); }
.yl-field__label { font-size: 14px; line-height: 1.5; font-weight: 700; color: var(--text-primary); }
.yl-field__control { position: relative; display: flex; align-items: center; }
.yl-field__input {
  box-sizing: border-box; width: 100%; height: var(--input-height); padding: 0 var(--space-16); margin: 0;
  border: 1px solid var(--border-control); border-radius: var(--radius-4); background: var(--surface-default);
  font-family: var(--font-sans); font-size: 16px; line-height: 1.5; font-weight: 400; color: var(--text-primary);
}
.yl-field__input::placeholder { color: var(--text-secondary); opacity: 1; }
.yl-field__input:focus { outline: none; border: 2px solid var(--focus-default); padding: 0 calc(var(--space-16) - 1px); }
.yl-field__icon { position: absolute; right: var(--space-16); font-size: 20px; line-height: 1; font-weight: 400; color: var(--text-primary); pointer-events: none; }
.yl-field--error .yl-field__input, .yl-field--error .yl-field__input:focus { border: 2px solid var(--feedback-error); padding: 0 calc(var(--space-16) - 1px); }
.yl-field--error .yl-field__input, .yl-field--valid .yl-field__input { padding-right: 48px; }
.yl-field__icon--error { color: var(--feedback-error); font-weight: 700; }
.yl-field__hint { margin: 0; font-size: 13px; line-height: 1.5; font-weight: 400; color: var(--text-secondary); }
.yl-field--error .yl-field__hint { color: var(--feedback-error); }
.yl-field--disabled .yl-field__input { background: var(--surface-subtle); color: var(--text-disabled); cursor: not-allowed; }

/* ---------- FilterChip ---------- */
.yl-chip {
  display: inline-flex; align-items: center; gap: 10px; height: var(--control-s); padding: 0 var(--space-20);
  border: 1px solid var(--charcoal-900); border-radius: var(--radius-999); background: var(--surface-default); color: var(--text-primary);
  font-family: var(--font-sans); font-size: 14px; line-height: 20px; font-weight: 400; cursor: pointer;
  transition: background-color 120ms cubic-bezier(.2, 0, 0, 1);
}
.yl-chip:hover { background: var(--surface-subtle); }
.yl-chip--selected, .yl-chip--selected:hover { background: var(--action-primary); font-weight: 700; }
.yl-chip:focus-visible { outline: none; border-width: 2px; padding: 0 calc(var(--space-20) - 1px); }
.yl-chip:disabled { border-color: var(--charcoal-300); color: var(--text-disabled); background: var(--surface-default); cursor: not-allowed; }

/* ---------- TextLink ---------- */
.yl-link {
  font-family: var(--font-sans); font-size: 16px; line-height: 24px; font-weight: 400; color: var(--link);
  text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 3px; border-radius: var(--radius-4);
}
.yl-link--standalone { display: inline-flex; align-items: center; min-height: var(--control-s); }
.yl-link:hover { font-weight: 700; text-decoration-thickness: 2px; }
.yl-link:active { font-weight: 700; color: var(--link-pressed); }
.yl-link:focus-visible { outline: var(--focus-ring-width) solid var(--focus-default); outline-offset: var(--space-4); }
.yl-link--disabled { text-decoration: none; color: var(--text-disabled); cursor: default; }
.yl-inverse .yl-link, .yl-link.yl-inverse { color: var(--text-inverse); }
.yl-inverse .yl-link:focus-visible, .yl-link.yl-inverse:focus-visible { outline-color: var(--text-inverse); }

@media (prefers-reduced-motion: reduce) {
  .yl-btn, .yl-btn__arrow, .yl-chip { transition: none; }
  .yl-btn--primary:hover .yl-btn__arrow { transform: none; }
}
