/* Shopa Coupon brand tokens. Semantic tokens switch with data-theme; night is the default. */
@font-face {
  font-family: 'DM Serif Display';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('/fonts/dm-serif-display-400.woff2') format('woff2');
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('/fonts/inter-400.woff2') format('woff2');
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url('/fonts/inter-500.woff2') format('woff2');
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url('/fonts/inter-600.woff2') format('woff2');
}

:root {
  /* Raw palette */
  --sc-charcoal: #292D29;
  --sc-cream: #F2EFE8;
  --sc-lime: #D6FF3F;
  --sc-ink: #151715;
  --sc-lavender: #CFC5DE;
  --sc-grey: #6B706A;
  --sc-charcoal-raised: #353A35;
  --sc-charcoal-line: #4B514B;
  --sc-cream-muted: #BDBFB6;
  --sc-cream-line: #D6D2C6;
  --sc-grey-dark: #565B55;
  --sc-white: #FFFFFF;

  --sc-font-display: 'DM Serif Display', Georgia, 'Times New Roman', serif;
  --sc-font-body: 'Inter', system-ui, -apple-system, 'Segoe UI', Roboto, Arial, sans-serif;

  /* Fixed chrome: header, home hero and footer are charcoal in both themes */
  --sc-chrome: var(--sc-charcoal);
  --sc-on-chrome: var(--sc-cream);
  --sc-chrome-accent: var(--sc-lime);
  --sc-on-chrome-accent: var(--sc-ink);
  --sc-on-chrome-muted: var(--sc-cream-muted);
  --sc-chrome-raised: var(--sc-charcoal-raised);
  --sc-chrome-line: var(--sc-charcoal-line);
  /* Search field set into the chrome */
  --sc-chrome-field: var(--sc-cream);
  --sc-on-chrome-field: var(--sc-ink);
  --sc-on-chrome-field-muted: var(--sc-grey-dark);
  /* Note boxes (coupon conditions, Show coupon note): lavender with ink text in both themes */
  --sc-note: var(--sc-lavender);
  --sc-on-note: var(--sc-ink);
  /* Dividers inside a card (cards are cream or white in both themes) */
  --sc-card-line: var(--sc-cream-line);
  /* Strong button (.sc-btn--dark): charcoal fill, cream text in both themes */
  --sc-strong: var(--sc-charcoal);
  --sc-on-strong: var(--sc-cream);
  --sc-strong-hover: var(--sc-ink);
  /* Paper: the printed coupon, white with ink text in both themes */
  --sc-paper: var(--sc-white);
  --sc-on-paper: var(--sc-ink);
  --sc-on-paper-muted: var(--sc-grey-dark);
  --sc-paper-line: var(--sc-cream-line);
}

/* Night (default): charcoal page, cream cards with ink text */
:root,
:root[data-theme="night"] {
  --sc-surface: var(--sc-charcoal);
  --sc-surface-raised: var(--sc-charcoal-raised);
  --sc-card: var(--sc-cream);
  --sc-card-text: var(--sc-ink);
  --sc-text: var(--sc-cream);
  --sc-text-muted: var(--sc-cream-muted);
  --sc-border: var(--sc-charcoal-line);
  --sc-action: var(--sc-lime);
  --sc-on-action: var(--sc-ink);
  --sc-link: var(--sc-lime);
  --sc-link-underline: var(--sc-lime);
  --sc-badge: var(--sc-lavender);
  --sc-on-badge: var(--sc-ink);
  --sc-focus: var(--sc-lime);
  /* Registration card and form fields (card is cream/white, fields white) */
  --sc-card-error: #A31515;
  --sc-card-muted: var(--sc-grey-dark);
  --sc-field: var(--sc-white);
  --sc-on-field: var(--sc-ink);
  --sc-field-border: var(--sc-grey-dark);
  /* A strong button on the charcoal page needs a light edge to be seen */
  --sc-strong-edge: var(--sc-cream-muted);
  color-scheme: dark;
}

/* Day: cream page, white cards. Lime is a fill only, never text. */
:root[data-theme="day"] {
  --sc-surface: var(--sc-cream);
  --sc-surface-raised: var(--sc-white);
  --sc-card: var(--sc-white);
  --sc-card-text: var(--sc-ink);
  --sc-text: var(--sc-ink);
  --sc-text-muted: var(--sc-grey-dark);
  --sc-border: var(--sc-cream-line);
  --sc-action: var(--sc-lime);
  --sc-on-action: var(--sc-ink);
  --sc-link: var(--sc-ink);
  --sc-link-underline: var(--sc-lime);
  --sc-badge: var(--sc-lavender);
  --sc-on-badge: var(--sc-ink);
  --sc-focus: var(--sc-ink);
  --sc-card-error: #A31515;
  --sc-card-muted: var(--sc-grey-dark);
  --sc-field: var(--sc-white);
  --sc-on-field: var(--sc-ink);
  --sc-field-border: var(--sc-grey-dark);
  --sc-strong-edge: var(--sc-charcoal);
  color-scheme: light;
}

