/* styles/tokens.css */
:root {
  /* Color domain */
  --ds-color-brand: var(--theme-rausch-500);
  --ds-color-brand-hover: var(--theme-rausch-600);
  --ds-color-brand-pressed: var(--theme-rausch-700);
  --ds-color-brand-subtle: var(--theme-rausch-50);
  --ds-color-interactive: var(--theme-hof-900);
  --ds-color-interactive-hover: var(--theme-hof-700);
  --ds-color-success: var(--theme-kazan-500);
  --ds-color-success-subtle: var(--theme-kazan-50);
  --ds-color-warning: var(--theme-arches-500);
  --ds-color-warning-subtle: var(--theme-arches-50);
  --ds-color-error: var(--theme-rausch-500);
  --ds-color-error-subtle: var(--theme-rausch-50);
  --ds-color-star: var(--theme-hof-900);
  --ds-color-link: var(--theme-babu-600);

  /* Text domain */
  --ds-text-primary: var(--theme-hof-900);
  --ds-text-secondary: var(--theme-hof-500);
  --ds-text-tertiary: var(--theme-hof-400);
  --ds-text-inverse: var(--theme-white);
  --ds-text-brand: var(--theme-rausch-500);
  --ds-text-error: var(--theme-rausch-600);
  --ds-text-success: var(--theme-kazan-600);
  --ds-text-link: var(--theme-babu-600);

  /* Surface domain */
  --ds-surface-page: var(--theme-white);
  --ds-surface-card: var(--theme-white);
  --ds-surface-subtle: var(--theme-hof-50);
  --ds-surface-overlay: var(--theme-white);
  --ds-surface-brand: var(--theme-rausch-500);
  --ds-surface-brand-subtle: var(--theme-rausch-50);
  --ds-surface-interactive: var(--theme-hof-900);
  --ds-surface-success: var(--theme-kazan-50);
  --ds-surface-error: var(--theme-rausch-50);
  --ds-surface-disabled: var(--theme-hof-100);

  /* Border domain */
  --ds-border-default: var(--theme-hof-200);
  --ds-border-strong: var(--theme-hof-700);
  --ds-border-subtle: var(--theme-hof-100);
  --ds-border-brand: var(--theme-rausch-500);
  --ds-border-error: var(--theme-rausch-500);
  --ds-border-focus: var(--theme-hof-900);

  /* Focus domain */
  --ds-focus-ring: var(--theme-focus-ring);

  /* Overlay domain */
  --ds-overlay-dark: var(--theme-overlay-dark);
  --ds-overlay-light: var(--theme-overlay-light);
}

/* styles/recipes/chat.css */
/* Chat Bubble â€” message conversation patterns */

.ds-chat-bubble {
  max-width: 80%;
  padding: var(--theme-spacing-md) var(--theme-spacing-lg);
  font-family: var(--theme-font-sans);
  font-size: var(--theme-font-size-base);
  line-height: var(--theme-line-height-normal);
  word-wrap: break-word;
}

.ds-chat-bubble-sent {
  background: var(--ds-surface-interactive);
  color: var(--ds-text-inverse);
  border-radius: var(--theme-radius-xl) var(--theme-radius-xl) 2px var(--theme-radius-xl);
  align-self: flex-end;
}

.ds-chat-bubble-received {
  background: var(--ds-surface-subtle);
  color: var(--ds-text-primary);
  border-radius: var(--theme-radius-xl) var(--theme-radius-xl) var(--theme-radius-xl) 2px;
  align-self: flex-start;
}

/* Received message group â€” avatar sits left of bubble at bottom */
.ds-chat-received-group {
  display: flex;
  flex-direction: column;
  align-self: flex-start;
  max-width: 80%;
  gap: var(--theme-spacing-xs);
}

.ds-chat-received-row {
  display: flex;
  align-items: flex-end;
  gap: var(--theme-spacing-sm);
}

.ds-chat-received-avatar {
  width: 32px;
  height: 32px;
  border-radius: var(--theme-radius-full);
  object-fit: cover;
  flex-shrink: 0;
}

.ds-chat-received-row .ds-chat-bubble-received {
  align-self: auto;
}

.ds-chat-timestamp {
  font-family: var(--theme-font-sans);
  font-size: var(--theme-font-size-xs);
  color: var(--ds-text-tertiary);
  padding: var(--theme-spacing-sm) 0 var(--theme-spacing-xs);
}

.ds-chat-timestamp-right {
  text-align: right;
}

.ds-chat-timestamp-center {
  text-align: center;
}

.ds-chat-sender-name {
  font-family: var(--theme-font-sans);
  font-size: var(--theme-font-size-sm);
  font-weight: var(--theme-font-weight-normal);
  color: var(--ds-text-secondary);
  padding-left: calc(32px + var(--theme-spacing-sm));
}

.ds-chat-read-receipt {
  font-family: var(--theme-font-sans);
  font-size: var(--theme-font-size-xs);
  color: var(--ds-text-tertiary);
  text-align: right;
  padding-top: var(--theme-spacing-xs);
}

.ds-chat-system {
  text-align: center;
  padding: var(--theme-spacing-lg) var(--theme-spacing-xl);
}

.ds-chat-system-text {
  font-family: var(--theme-font-sans);
  font-size: var(--theme-font-size-sm);
  color: var(--ds-text-secondary);
  line-height: var(--theme-line-height-normal);
}

.ds-chat-system-link {
  font-weight: var(--theme-font-weight-semibold);
  color: var(--ds-text-primary);
  text-decoration: underline;
  cursor: pointer;
}

/* Chat booking invitation â€” centered system-level message */
.ds-chat-booking-invite {
  text-align: center;
  padding: var(--theme-spacing-lg) var(--theme-spacing-xl);
}

.ds-chat-booking-invite-text {
  font-family: var(--theme-font-sans);
  font-size: var(--theme-font-size-base);
  color: var(--ds-text-primary);
  line-height: var(--theme-line-height-normal);
}

.ds-chat-booking-invite-link {
  display: block;
  font-family: var(--theme-font-sans);
  font-size: var(--theme-font-size-base);
  font-weight: var(--theme-font-weight-semibold);
  color: var(--ds-text-primary);
  text-decoration: underline;
  cursor: pointer;
  padding-top: var(--theme-spacing-xs);
}

/* Chat footer â€” input row + CTA, rounded top corners */
.ds-chat-footer {
  border-top: 1px solid var(--ds-border-subtle);
  border-radius: var(--theme-radius-xl) var(--theme-radius-xl) 0 0;
  background: var(--ds-surface-page);
  padding: var(--theme-spacing-xl) var(--theme-spacing-lg) var(--theme-spacing-2xl);
  display: flex;
  flex-direction: column;
  gap: var(--theme-spacing-lg);
}

.ds-chat-input-row {
  display: flex;
  align-items: center;
  gap: var(--theme-spacing-sm);
}

.ds-chat-input-field {
  flex: 1;
  font-family: var(--theme-font-sans);
  font-size: var(--theme-font-size-base);
  color: var(--ds-text-primary);
  background: transparent;
  border: none;
  outline: none;
  min-height: 24px;
  padding: 0;
}

.ds-chat-input-field::placeholder {
  color: var(--ds-text-tertiary);
}

.ds-chat-send-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border-radius: var(--theme-radius-full);
  border: 1.5px solid var(--ds-border-default);
  background: none;
  color: var(--ds-text-tertiary);
  font-size: 1rem;
  cursor: pointer;
  flex-shrink: 0;
  transition: border-color var(--theme-motion-fast), color var(--theme-motion-fast);
  -webkit-tap-highlight-color: transparent;
}

.ds-chat-send-btn:active {
  border-color: var(--ds-border-strong);
  color: var(--ds-text-primary);
}

/* Info banner â€” dismissible, within chat */
.ds-chat-info-banner {
  display: flex;
  align-items: flex-start;
  gap: var(--theme-spacing-sm);
  padding: var(--theme-spacing-md) var(--theme-spacing-lg);
  background: var(--ds-surface-subtle);
  border-radius: var(--theme-radius-lg);
  margin: 0 var(--theme-spacing-lg);
}

.ds-chat-info-banner-text {
  flex: 1;
  font-family: var(--theme-font-sans);
  font-size: var(--theme-font-size-sm);
  color: var(--ds-text-secondary);
  line-height: var(--theme-line-height-normal);
}

.ds-chat-info-banner-link {
  font-weight: var(--theme-font-weight-semibold);
  text-decoration: underline;
  cursor: pointer;
}

.ds-chat-info-banner-close {
  flex-shrink: 0;
  background: none;
  border: none;
  cursor: pointer;
  color: var(--ds-text-secondary);
  font-size: 1rem;
  padding: 0;
  line-height: 1;
}

/* Detail header for chat â€” two rows */
.ds-chat-header {
  display: flex;
  flex-direction: column;
  border-bottom: 1px solid var(--ds-border-subtle);
  padding: var(--theme-spacing-md) var(--theme-spacing-lg);
}

/* Top row: back arrow left, Details button right */
.ds-chat-header-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.ds-chat-header-back {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border-radius: var(--theme-radius-full);
  background: none;
  border: none;
  cursor: pointer;
  color: var(--ds-text-primary);
  font-size: 1.25rem;
  -webkit-tap-highlight-color: transparent;
  flex-shrink: 0;
}

.ds-chat-header-back:active {
  opacity: 0.6;
}

/* Centered identity: avatar + name + context stacked */
.ds-chat-header-identity {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--theme-spacing-xs);
  padding-top: var(--theme-spacing-sm);
}

.ds-chat-header-avatar {
  width: 32px;
  height: 32px;
  border-radius: var(--theme-radius-full);
  object-fit: cover;
}

.ds-chat-header-name {
  font-family: var(--theme-font-sans);
  font-size: var(--theme-font-size-base);
  font-weight: var(--theme-font-weight-semibold);
  color: var(--ds-text-primary);
  line-height: 1;
}

.ds-chat-header-context {
  font-family: var(--theme-font-sans);
  font-size: var(--theme-font-size-sm);
  color: var(--ds-text-secondary);
  line-height: var(--theme-line-height-normal);
}


/* styles/recipes/input-group.css */
/* Input Group â€” collapses multiple ds-input fields into one visual unit */

.ds-input-group {
  display: flex;
  flex-direction: column;
}

.ds-input-group-row {
  display: flex;
}

/* Reset all radii inside a group */
.ds-input-group ds-input,
.ds-input-group-row ds-input {
  --_ds-input-radius-tl: 0;
  --_ds-input-radius-tr: 0;
  --_ds-input-radius-br: 0;
  --_ds-input-radius-bl: 0;
  flex: 1;
  min-width: 0;
}

/* Collapse vertical borders between stacked items */
.ds-input-group > ds-input + ds-input,
.ds-input-group > .ds-input-group-row + ds-input,
.ds-input-group > ds-input + .ds-input-group-row,
.ds-input-group > .ds-input-group-row + .ds-input-group-row {
  margin-top: -1px;
}

/* Collapse horizontal borders between row items */
.ds-input-group-row > ds-input + ds-input {
  margin-left: -1px;
}

/* Top-left radius: first child, or first in first row */
.ds-input-group > ds-input:first-child {
  --_ds-input-radius-tl: var(--theme-radius-lg);
  --_ds-input-radius-tr: var(--theme-radius-lg);
}

.ds-input-group > .ds-input-group-row:first-child > ds-input:first-child {
  --_ds-input-radius-tl: var(--theme-radius-lg);
}

.ds-input-group > .ds-input-group-row:first-child > ds-input:last-child {
  --_ds-input-radius-tr: var(--theme-radius-lg);
}

/* Bottom-left radius: last child, or first in last row */
.ds-input-group > ds-input:last-child {
  --_ds-input-radius-bl: var(--theme-radius-lg);
  --_ds-input-radius-br: var(--theme-radius-lg);
}

.ds-input-group > .ds-input-group-row:last-child > ds-input:first-child {
  --_ds-input-radius-bl: var(--theme-radius-lg);
}

.ds-input-group > .ds-input-group-row:last-child > ds-input:last-child {
  --_ds-input-radius-br: var(--theme-radius-lg);
}

/* Single child gets all radii */
.ds-input-group > ds-input:only-child {
  --_ds-input-radius-tl: var(--theme-radius-lg);
  --_ds-input-radius-tr: var(--theme-radius-lg);
  --_ds-input-radius-bl: var(--theme-radius-lg);
  --_ds-input-radius-br: var(--theme-radius-lg);
}

/* Ensure focus ring shows above siblings */
.ds-input-group ds-input:focus-within {
  z-index: 2;
  position: relative;
}

/* styles/recipes/screen-header.css */
/* Screen Header â€” top-level screen title pattern (e.g. Trips, Wishlists, Messages) */
/* Action button(s) sit above title, right-aligned; heading sits below */

.ds-screen-header {
  padding: var(--theme-spacing-lg) var(--theme-spacing-xl) var(--theme-spacing-lg);
}

.ds-screen-header-nav {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: var(--theme-spacing-sm);
  padding-bottom: var(--theme-spacing-md);
}

.ds-screen-header-title {
  font-family: var(--theme-font-sans);
  font-size: var(--theme-font-size-3xl);
  font-weight: var(--theme-font-weight-bold);
  color: var(--ds-text-primary);
  line-height: var(--theme-line-height-tight);
  margin: 0;
}

.ds-screen-header-filters {
  display: flex;
  gap: var(--theme-spacing-sm);
  padding-top: var(--theme-spacing-lg);
  overflow-x: auto;
  scrollbar-width: none;
  -ms-overflow-style: none;
}

.ds-screen-header-filters::-webkit-scrollbar {
  display: none;
}


/* styles/recipes/surface.css */
.ds-surface-card {
  background: var(--ds-surface-card);
  border-radius: var(--theme-radius-xl);
  box-shadow: var(--theme-shadow-border), var(--theme-shadow-sm);
}

.ds-surface-card-elevated {
  background: var(--ds-surface-card);
  border-radius: var(--theme-radius-xl);
  box-shadow: var(--theme-shadow-lg);
}

.ds-surface-panel {
  background: var(--ds-surface-subtle);
  border-radius: var(--theme-radius-lg);
}

.ds-surface-overlay {
  background: var(--ds-surface-overlay);
  border-radius: var(--theme-radius-2xl);
  box-shadow: var(--theme-shadow-xl);
}

/* styles/recipes/type.css */
/* Type recipes â€” no color, Figma text style equivalents */

.ds-type-display {
  font-family: var(--theme-font-sans);
  font-size: var(--theme-font-size-4xl);
  font-weight: var(--theme-font-weight-extrabold);
  line-height: var(--theme-line-height-tight);
  letter-spacing: -0.02em;
}

.ds-type-heading-xl {
  font-family: var(--theme-font-sans);
  font-size: var(--theme-font-size-3xl);
  font-weight: var(--theme-font-weight-bold);
  line-height: var(--theme-line-height-tight);
  letter-spacing: -0.01em;
}

.ds-type-heading-lg {
  font-family: var(--theme-font-sans);
  font-size: var(--theme-font-size-2xl);
  font-weight: var(--theme-font-weight-bold);
  line-height: var(--theme-line-height-snug);
}

.ds-type-heading-md {
  font-family: var(--theme-font-sans);
  font-size: var(--theme-font-size-xl);
  font-weight: var(--theme-font-weight-semibold);
  line-height: var(--theme-line-height-snug);
}

.ds-type-heading-sm {
  font-family: var(--theme-font-sans);
  font-size: var(--theme-font-size-md);
  font-weight: var(--theme-font-weight-semibold);
  line-height: var(--theme-line-height-snug);
}

.ds-type-body-lg {
  font-family: var(--theme-font-sans);
  font-size: var(--theme-font-size-md);
  font-weight: var(--theme-font-weight-normal);
  line-height: var(--theme-line-height-normal);
}

.ds-type-body {
  font-family: var(--theme-font-sans);
  font-size: var(--theme-font-size-base);
  font-weight: var(--theme-font-weight-normal);
  line-height: var(--theme-line-height-normal);
}

.ds-type-body-medium {
  font-family: var(--theme-font-sans);
  font-size: var(--theme-font-size-base);
  font-weight: var(--theme-font-weight-medium);
  line-height: var(--theme-line-height-normal);
}

.ds-type-caption {
  font-family: var(--theme-font-sans);
  font-size: var(--theme-font-size-sm);
  font-weight: var(--theme-font-weight-normal);
  line-height: var(--theme-line-height-normal);
}

.ds-type-overline {
  font-family: var(--theme-font-sans);
  font-size: var(--theme-font-size-xs);
  font-weight: var(--theme-font-weight-semibold);
  line-height: var(--theme-line-height-normal);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.ds-type-label {
  font-family: var(--theme-font-sans);
  font-size: var(--theme-font-size-sm);
  font-weight: var(--theme-font-weight-semibold);
  line-height: var(--theme-line-height-snug);
}

/* styles/_internal/layout.css */
._ds-stack {
  display: flex;
  flex-direction: column;
}

._ds-row {
  display: flex;
  flex-direction: row;
  align-items: center;
}

._ds-grid-2 {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--theme-spacing-lg);
}

._ds-grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--theme-spacing-lg);
}

._ds-container {
  width: 100%;
  max-width: 1128px;
  margin: 0 auto;
  padding: 0 var(--theme-spacing-xl);
}

/* styles/_internal/reset.css */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: var(--theme-font-sans);
  font-size: var(--theme-font-size-base);
  line-height: var(--theme-line-height-normal);
  color: var(--ds-text-primary);
  background: var(--ds-surface-page);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

img, svg {
  display: block;
  max-width: 100%;
}

button {
  font: inherit;
  cursor: pointer;
  border: none;
  background: none;
}

input, textarea, select {
  font: inherit;
}

a {
  color: inherit;
  text-decoration: none;
}