/* Raffle Tools Dashboard — shared styles */

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --bg: #f6f8fb;
  --surface: #ffffff;
  --surface-alt: #f1f4f9;
  --border: #e2e8f0;
  --border-strong: #cbd5e1;
  --text: #0f172a;
  --text-muted: #64748b;
  --text-subtle: #94a3b8;
  --primary: #2563eb;
  --primary-dark: #1d4ed8;
  --primary-darker: #1e3a8a;
  --primary-light: #eff6ff;
  --shadow-sm: 0 1px 2px rgba(15, 23, 42, 0.06);
  --shadow-md: 0 4px 12px rgba(15, 23, 42, 0.08);
  --shadow-lg: 0 12px 32px rgba(15, 23, 42, 0.12);
  --radius-sm: 6px;
  --radius: 12px;
  --radius-lg: 18px;
}

html { -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; }

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, "Helvetica Neue", sans-serif;
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
  line-height: 1.5;
}

.page {
  max-width: 1160px;
  margin: 0 auto;
  padding: 56px 24px 96px;
}

/* -------- Header -------- */
.site-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 44px;
  padding-bottom: 24px;
  border-bottom: 1px solid var(--border);
}

.brand {
  display: flex;
  align-items: center;
  gap: 14px;
}

.brand-mark {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  background: #ffffff;
  border: 1px solid var(--border);
  display: grid;
  place-items: center;
  color: #0f172a;
  font-weight: 800;
  font-size: 16px;
  letter-spacing: -0.02em;
  box-shadow: var(--shadow-sm);
}

.brand-text h1 {
  font-size: 20px;
  font-weight: 700;
  letter-spacing: -0.01em;
  color: var(--text);
  line-height: 1.2;
}

.brand-text p {
  font-size: 13px;
  color: var(--text-muted);
  margin-top: 2px;
}

.header-nav {
  display: flex;
  gap: 8px;
}

.header-nav a {
  font-size: 13px;
  color: var(--text-muted);
  text-decoration: none;
  padding: 8px 14px;
  border-radius: var(--radius-sm);
  transition: background 0.15s, color 0.15s;
}

.header-nav a:hover {
  background: var(--surface);
  color: var(--text);
}

/* -------- Section intro -------- */
.intro {
  margin-bottom: 32px;
}

.intro-eyebrow {
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--primary);
  margin-bottom: 10px;
}

.intro h2 {
  font-size: clamp(28px, 4vw, 40px);
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.15;
  color: var(--text);
  margin-bottom: 10px;
}

.intro p {
  font-size: 15px;
  color: var(--text-muted);
  max-width: 620px;
}

/* -------- Tile grid -------- */
.tile-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 24px;
}

.tile-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  height: 100%;
}

.tile {
  width: 100%;
  flex: 1;
  position: relative;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 32px 28px;
  box-shadow: var(--shadow-sm);
  display: flex;
  flex-direction: column;
  min-height: 220px;
  transition: transform 0.15s ease, box-shadow 0.2s ease, border-color 0.15s;
  text-decoration: none;
  color: inherit;
  cursor: pointer;
}

.tile:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
  border-color: var(--primary);
}

.tile:focus-visible {
  outline: 3px solid var(--primary);
  outline-offset: 2px;
}

.tile-icon {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  background: #ffffff;
  color: #0f172a;
  border: 1px solid var(--border);
  display: grid;
  place-items: center;
  margin-bottom: 20px;
  font-weight: 800;
  font-size: 20px;
  letter-spacing: -0.02em;
  flex-shrink: 0;
}

.tile-name {
  font-size: 20px;
  font-weight: 700;
  letter-spacing: -0.01em;
  color: var(--text);
  margin-bottom: 8px;
}

.tile-tagline {
  font-size: 14px;
  color: var(--text-muted);
  flex-grow: 1;
}

.tile-instructions-link {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 13px;
  font-weight: 500;
  color: var(--text-muted);
  text-decoration: none;
  padding: 6px 10px;
  border-radius: var(--radius-sm);
  transition: color 0.15s, background 0.15s;
}

.tile-instructions-link:hover {
  color: var(--primary);
  background: var(--surface);
}

/* -------- Footer -------- */
.site-footer {
  margin-top: 72px;
  padding-top: 32px;
  border-top: 1px solid var(--border);
  text-align: center;
}

.footer-brand {
  display: inline-block;
  opacity: 0.7;
  transition: opacity 0.15s ease;
}

.footer-brand:hover { opacity: 1; }

.footer-logo {
  max-height: 56px;
  width: auto;
  display: block;
}

/* -------- Sub-dashboard (InVenue) -------- */
.subdash-back {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  color: var(--text-muted);
  text-decoration: none;
  margin-bottom: 24px;
  padding: 6px 0;
}

.subdash-back:hover { color: var(--primary); }

.lang-switch {
  display: inline-flex;
  padding: 4px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 999px;
  margin-bottom: 32px;
  box-shadow: var(--shadow-sm);
}

.lang-switch button {
  padding: 10px 24px;
  border: none;
  background: transparent;
  color: var(--text-muted);
  font-size: 14px;
  font-weight: 600;
  border-radius: 999px;
  cursor: pointer;
  font-family: inherit;
  transition: background 0.15s, color 0.15s;
}

.lang-switch button.active {
  background: var(--primary);
  color: #fff;
}

.lang-switch button:not(.active):hover {
  color: var(--text);
}

/* -------- Instructions page -------- */
.doc {
  max-width: 760px;
  margin: 0 auto;
  padding: 56px 24px 96px;
}

.doc-header {
  margin-bottom: 40px;
  padding-bottom: 24px;
  border-bottom: 1px solid var(--border);
}

.doc-header .eyebrow {
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--primary);
  margin-bottom: 10px;
}

.doc-header h1 {
  font-size: clamp(28px, 4vw, 36px);
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--text);
  margin-bottom: 8px;
}

.doc-header p {
  color: var(--text-muted);
  font-size: 15px;
}

.doc h2 {
  font-size: 20px;
  font-weight: 700;
  color: var(--text);
  margin: 36px 0 12px;
  letter-spacing: -0.01em;
}

.doc h3 {
  font-size: 16px;
  font-weight: 700;
  color: var(--text);
  margin: 24px 0 8px;
}

.doc p, .doc li {
  color: var(--text);
  font-size: 15px;
  line-height: 1.65;
}

.doc ol, .doc ul {
  padding-left: 22px;
  margin: 8px 0 16px;
}

.doc li { margin-bottom: 6px; }

.doc code {
  background: var(--surface-alt);
  padding: 2px 6px;
  border-radius: 4px;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 0.9em;
}

.doc .callout {
  background: var(--primary-light);
  border-left: 3px solid var(--primary);
  padding: 14px 18px;
  border-radius: 4px;
  margin: 18px 0;
  font-size: 14px;
  color: var(--primary-darker);
}

.doc-actions {
  margin-top: 40px;
  padding-top: 24px;
  border-top: 1px solid var(--border);
  display: flex;
  gap: 12px;
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 10px 18px;
  border-radius: var(--radius-sm);
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
  border: 1px solid transparent;
  cursor: pointer;
  font-family: inherit;
}

.btn-primary {
  background: var(--primary);
  color: #fff;
}

.btn-primary:hover { background: var(--primary-dark); }

.btn-secondary {
  background: var(--surface);
  color: var(--text);
  border-color: var(--border-strong);
}

.btn-secondary:hover { background: var(--surface-alt); }
