/* TantoSoli — design system Lilla + sole.
   Caricare dopo Bootstrap e prima degli altri CSS del sito. */

:root {
  --ts-violet: #5A48DB;
  --ts-violet-strong: #3F2FB8;
  --ts-sun: #FFC23D;
  --ts-ink: #1B1530;
  --ts-ink-soft: #2E2748;
  --ts-muted: #5E5878;
  --ts-mist: #ECE8FF;
  --ts-bg: #F6F3FF;
  --ts-surface: #FFFFFF;
  --ts-line: #E4DEF7;
  --ts-line-input: #D8D0F3;
  --ts-dark-panel: rgba(27, 21, 48, 0.86);

  --ts-font-display: "Bricolage Grotesque", system-ui, sans-serif;
  --ts-font-body: "Figtree", system-ui, sans-serif;

  --ts-r-sm: 12px;
  --ts-r-md: 16px;
  --ts-r-lg: 20px;
  --ts-r-xl: 26px;
  --ts-r-pill: 999px;
  --ts-tap: 44px;

  --bs-body-font-family: var(--ts-font-body);
  --bs-body-color: var(--ts-ink);
  --bs-body-bg: var(--ts-bg);
  --bs-primary: #5A48DB;
  --bs-primary-rgb: 90, 72, 219;
  --bs-link-color: #5A48DB;
  --bs-link-hover-color: #3F2FB8;
  --bs-focus-ring-color: rgba(90, 72, 219, 0.35);
}

body {
  background: var(--ts-bg);
  color: var(--ts-ink);
  font-family: var(--ts-font-body);
  font-size: 16px;
  line-height: 1.5;
}

h1,
h2,
h3,
.ts-display {
  font-family: var(--ts-font-display);
  font-weight: 800;
  letter-spacing: -0.025em;
  line-height: 1.05;
}

.ts-highlight {
  box-shadow: inset 0 -0.32em 0 var(--ts-sun);
}

.ts-pin {
  align-self: flex-start;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  border-radius: 999px;
  background: var(--ts-mist);
  color: var(--ts-violet-strong);
  font-size: 13px;
  font-weight: 700;
}

:focus-visible {
  outline: 3px solid rgba(90, 72, 219, 0.35);
  outline-offset: 2px;
}

.ts-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 48px;
  padding: 0 20px;
  border: 1px solid transparent;
  font-family: var(--ts-font-body);
  font-size: 15px;
  font-weight: 700;
  line-height: 1.2;
  text-decoration: none;
  cursor: pointer;
  box-sizing: border-box;
}

.ts-btn--sun {
  background: var(--ts-sun);
  color: var(--ts-ink);
  border-radius: var(--ts-r-pill);
  font-weight: 800;
}

.ts-btn--sun:hover,
.ts-btn--sun:focus {
  background: #f0b428;
  color: var(--ts-ink);
}

.ts-btn--primary {
  background: var(--ts-violet);
  color: #fff;
  border-radius: var(--ts-r-md);
}

.ts-btn--primary:hover,
.ts-btn--primary:focus {
  background: var(--ts-violet-strong);
  color: #fff;
}

.ts-btn--outline {
  background: var(--ts-surface);
  border-color: var(--ts-ink);
  color: var(--ts-ink);
  border-radius: var(--ts-r-md);
}

.ts-btn--outline:hover,
.ts-btn--outline:focus {
  background: var(--ts-mist);
  color: var(--ts-ink);
}

.ts-icon-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  padding: 0;
  border-radius: 50%;
  border: 1px solid var(--ts-line);
  background: var(--ts-surface);
  color: var(--ts-ink);
  font-size: 20px;
  line-height: 1;
  cursor: pointer;
  box-sizing: border-box;
}

.ts-icon-btn:hover,
.ts-icon-btn:focus {
  background: var(--ts-mist);
  color: var(--ts-ink);
}

.ts-segmented {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0;
  padding: 4px;
  background: var(--ts-surface);
  border: 1px solid var(--ts-line);
  border-radius: var(--ts-r-md);
}

.ts-segmented button {
  min-height: 44px;
  border: 0;
  border-radius: var(--ts-r-sm);
  background: transparent;
  color: var(--ts-ink);
  font-family: var(--ts-font-body);
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
}

.ts-segmented button[aria-pressed="true"] {
  background: var(--ts-violet);
  color: #fff;
  font-weight: 700;
}

.ts-chip {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 40px;
  padding: 0 14px;
  border-radius: var(--ts-r-pill);
  border: 1px solid var(--ts-line);
  background: var(--ts-surface);
  color: var(--ts-ink);
  font-family: var(--ts-font-body);
  font-size: 14px;
  font-weight: 600;
  line-height: 1;
  cursor: pointer;
  box-sizing: border-box;
  white-space: nowrap;
}

.ts-chip[aria-pressed="true"],
.ts-chip.is-active {
  background: var(--ts-ink);
  border-color: var(--ts-ink);
  color: #fff;
}

.ts-chip--free {
  border-style: dashed;
  border-color: #B7AEDF;
}

.ts-chip--free[aria-pressed="true"],
.ts-chip--free.is-active {
  background: var(--ts-sun);
  border-style: solid;
  border-color: var(--ts-sun);
  color: var(--ts-ink);
}

.ts-tag {
  display: inline-flex;
  align-items: center;
  padding: 4px 9px;
  border-radius: var(--ts-r-pill);
  font-family: var(--ts-font-body);
  font-size: 12px;
  line-height: 1.2;
}

.ts-tag--category {
  background: var(--ts-bg);
  color: var(--ts-violet-strong);
  font-weight: 600;
}

.ts-tag--price {
  border: 1px solid var(--ts-line);
  background: var(--ts-surface);
  color: var(--ts-ink);
  font-weight: 700;
}

.ts-tag--free {
  background: var(--ts-sun);
  color: var(--ts-ink);
  font-weight: 800;
}

.ts-card {
  background: var(--ts-surface);
  border: 1px solid var(--ts-line);
  border-radius: var(--ts-r-lg);
}

.ts-label {
  font-family: var(--ts-font-body);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--ts-violet);
}

@media (min-width: 992px) {
  .ts-label {
    font-size: 13px;
  }
}
