/* Workday Tools — High-performance, accessible, responsive stylesheet */
:root {
  --bg: #f8fafc;
  --surface: #ffffff;
  --surface-subtle: #f1f5f9;
  --surface-hover: #f8fafc;
  --text: #0f172a;
  --text-secondary: #334155;
  --muted: #475569;
  --line: #e2e8f0;
  --line-subtle: #f1f5f9;
  --accent: #0284c7;
  --accent-hover: #0369a1;
  --accent-soft: #f0f9ff;
  --accent-border: #bae6fd;
  --ok: #047857;
  --ok-soft: #ecfdf5;
  --ok-border: #a7f3d0;
  --focus: #0284c7;
  --radius-sm: 6px;
  --radius: 10px;
  --radius-lg: 14px;
  --shadow-sm: 0 1px 2px 0 rgba(15, 23, 42, 0.05);
  --shadow: 0 1px 3px 0 rgba(15, 23, 42, 0.08), 0 1px 2px -1px rgba(15, 23, 42, 0.04);
  --shadow-md: 0 4px 6px -1px rgba(15, 23, 42, 0.08), 0 2px 4px -2px rgba(15, 23, 42, 0.05);
  --max: 940px;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0b0f17;
    --surface: #131b26;
    --surface-subtle: #182232;
    --surface-hover: #1c2738;
    --text: #f8fafc;
    --text-secondary: #cbd5e1;
    --muted: #94a3b8;
    --line: #233247;
    --line-subtle: #1a2636;
    --accent: #38bdf8;
    --accent-hover: #7dd3fc;
    --accent-soft: #0c2642;
    --accent-border: #194a73;
    --ok: #34d399;
    --ok-soft: #09281e;
    --ok-border: #134e38;
    --focus: #38bdf8;
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.4);
    --shadow: 0 2px 4px 0 rgba(0, 0, 0, 0.45);
    --shadow-md: 0 4px 8px -1px rgba(0, 0, 0, 0.55);
  }
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; color-scheme: light dark; scroll-behavior: smooth; }
body {
  margin: 0;
  font: 16px/1.6 system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

main.wrap { flex: 1 0 auto; }
.wrap { max-width: var(--max); margin: 0 auto; padding: 0 18px; width: 100%; }

a { color: var(--accent); text-decoration-thickness: 1px; text-underline-offset: 2px; }
a:hover { color: var(--accent-hover); }

/* Typography */
h1, h2, h3 { color: var(--text); font-weight: 700; letter-spacing: -0.02em; }
h1 { font-size: clamp(1.65rem, 3.5vw, 2.15rem); line-height: 1.25; margin: 12px 0 12px; }
h2 { font-size: clamp(1.2rem, 2.5vw, 1.45rem); margin: 36px 0 12px; padding-bottom: 6px; border-bottom: 1px solid var(--line-subtle); }
h3 { font-size: 1.05rem; margin: 0 0 10px; }
.lead { color: var(--muted); font-size: 1.1rem; line-height: 1.55; margin-top: 0; margin-bottom: 20px; }
p { margin: 0 0 14px; }
b, strong { font-weight: 700; }

/* Focus Visibility & Accessibility */
:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }

/* Header & Navigation */
header.site {
  background: var(--surface);
  border-bottom: 1px solid var(--line);
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: var(--shadow-sm);
}
header.site .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 60px;
  gap: 14px;
  flex-wrap: wrap;
  padding: 8px 18px;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  font-size: 1.15rem;
  text-decoration: none;
  color: var(--text);
  letter-spacing: -0.02em;
}
.brand-icon { flex-shrink: 0; border-radius: 7px; display: block; }
.brand-text { display: inline-flex; align-items: baseline; }
.brand-accent { color: var(--accent); font-weight: 700; }
nav.top {
  display: flex;
  align-items: center;
  gap: 4px;
  flex-wrap: wrap;
}
nav.top a {
  font-size: 0.88rem;
  font-weight: 500;
  color: var(--muted);
  text-decoration: none;
  padding: 6px 11px;
  border-radius: var(--radius-sm);
  transition: color 0.15s ease, background-color 0.15s ease;
}
nav.top a:hover {
  color: var(--text);
  background: var(--surface-subtle);
}

/* Breadcrumbs */
.crumbs {
  font-size: 0.85rem;
  color: var(--muted);
  margin: 18px 0 6px;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
}
.crumbs a {
  color: var(--muted);
  text-decoration: none;
  transition: color 0.15s ease;
}
.crumbs a:hover { color: var(--accent); text-decoration: underline; }

/* Hero Section */
.hero { padding: 32px 0 20px; }
.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 12px;
  background: var(--accent-soft);
  border: 1px solid var(--accent-border);
  color: var(--accent);
  font-size: 0.82rem;
  font-weight: 600;
  border-radius: 999px;
  margin-bottom: 14px;
}
.hero-title {
  font-size: clamp(2rem, 4.5vw, 2.5rem);
  line-height: 1.18;
  font-weight: 800;
  letter-spacing: -0.03em;
  margin: 0 0 14px;
  color: var(--text);
}
.hero-lead {
  font-size: 1.15rem;
  line-height: 1.6;
  color: var(--muted);
  max-width: 720px;
  margin: 0 0 24px;
}
.hero-actions { display: flex; gap: 12px; flex-wrap: wrap; margin-bottom: 8px; }

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font: inherit;
  font-size: 0.95rem;
  font-weight: 600;
  padding: 10px 18px;
  border-radius: 8px;
  text-decoration: none;
  cursor: pointer;
  min-height: 44px;
  transition: background-color 0.15s ease, border-color 0.15s ease, transform 0.1s ease;
}
.btn:active { transform: scale(0.98); }
.btn-primary {
  background: var(--accent);
  color: #ffffff !important;
  border: 1px solid transparent;
  box-shadow: 0 2px 4px rgba(2, 132, 199, 0.2);
}
.btn-primary:hover { background: var(--accent-hover); }
.btn-secondary {
  background: var(--surface);
  color: var(--text) !important;
  border: 1px solid var(--line);
  box-shadow: var(--shadow-sm);
}
.btn-secondary:hover { border-color: var(--accent); color: var(--accent) !important; }

button {
  font: inherit;
  font-weight: 600;
  background: var(--accent);
  color: #ffffff;
  border: 1px solid transparent;
  border-radius: 8px;
  padding: 9px 16px;
  cursor: pointer;
  min-height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  transition: background-color 0.15s ease, transform 0.1s ease;
}
button:hover { background: var(--accent-hover); }
button:active { transform: scale(0.98); }
button.ghost {
  background: transparent;
  color: var(--text);
  border: 1px solid var(--line);
}
button.ghost:hover { border-color: var(--accent); color: var(--accent); }

/* Tool Cards / Tiles */
.tiles {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(270px, 1fr));
  gap: 16px;
  margin: 20px 0 36px;
}
.tile {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 18px;
  text-decoration: none;
  color: var(--text);
  box-shadow: var(--shadow-sm);
  transition: border-color 0.2s ease, box-shadow 0.2s ease, transform 0.15s ease;
  position: relative;
}
.tile:hover {
  border-color: var(--accent);
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}
.tile-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  border-radius: 9px;
  background: var(--accent-soft);
  color: var(--accent);
  flex-shrink: 0;
}
.tile-body { flex: 1; min-width: 0; }
.tile-body b {
  display: block;
  font-size: 1.02rem;
  font-weight: 700;
  margin-bottom: 4px;
  color: var(--text);
}
.tile-body span {
  display: block;
  color: var(--muted);
  font-size: 0.88rem;
  line-height: 1.45;
}
.tile-arrow {
  color: var(--muted);
  font-size: 1.15rem;
  margin-left: auto;
  align-self: center;
  transition: transform 0.2s ease, color 0.2s ease;
}
.tile:hover .tile-arrow { color: var(--accent); transform: translateX(3px); }

/* Forms, Cards & Inputs */
.card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 24px;
  margin: 20px 0 28px;
  box-shadow: var(--shadow);
}
label {
  display: block;
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--text-secondary);
  margin-bottom: 6px;
}
input, select {
  font: inherit;
  font-size: 1rem;
  padding: 9px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface-subtle);
  color: var(--text);
  width: 100%;
  min-height: 44px;
  transition: border-color 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
}
input:hover, select:hover { border-color: var(--muted); }
input:focus, select:focus {
  outline: none;
  border-color: var(--accent);
  background: var(--surface);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 20%, transparent);
}
.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 14px;
}
.row-actions { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 16px; }

/* Direct Answer Box */
.answer {
  position: relative;
  background: var(--accent-soft);
  border: 1px solid var(--accent-border);
  border-left: 5px solid var(--accent);
  border-radius: var(--radius);
  padding: 16px 20px;
  margin: 18px 0 24px;
  font-size: 1.08rem;
  line-height: 1.6;
  color: var(--text);
  box-shadow: var(--shadow-sm);
}
.answer strong {
  display: inline-block;
  font-size: 1.45rem;
  font-weight: 800;
  color: var(--accent);
  letter-spacing: -0.02em;
}

/* Prominent Result Box */
.result {
  margin-top: 20px;
  padding: 18px 22px;
  background: var(--ok-soft);
  border: 1.5px solid var(--ok-border);
  border-left: 5px solid var(--ok);
  border-radius: 8px;
  font-size: 1.1rem;
  line-height: 1.6;
  color: var(--text);
  box-shadow: var(--shadow-sm);
}
.result:empty { display: none; }
.result b {
  color: var(--ok);
  font-weight: 800;
  font-size: 1.14em;
  letter-spacing: -0.01em;
}

/* Tables */
.scroll {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  margin: 16px 0 24px;
  border-radius: var(--radius);
  border: 1px solid var(--line);
  background: var(--surface);
}
table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.94rem;
  text-align: left;
}
th, td {
  padding: 10px 14px;
  border-bottom: 1px solid var(--line);
  font-variant-numeric: tabular-nums;
}
th {
  background: var(--surface-subtle);
  font-weight: 700;
  color: var(--text-secondary);
  font-size: 0.85rem;
  letter-spacing: 0.03em;
  white-space: nowrap;
}
tr:last-child td { border-bottom: 0; }
tbody tr:hover td { background: var(--surface-hover); }

/* Specific Time Card table */
#timecard table { min-width: 480px; }
#timecard tr[data-day] td:first-child {
  font-weight: 700;
  color: var(--text);
  width: 52px;
}
#timecard td.day-total {
  font-weight: 700;
  color: var(--ok);
  white-space: nowrap;
}
#timecard input {
  min-height: 38px;
  padding: 6px 8px;
  font-size: 0.94rem;
}
#timecard input[type=number] { width: 80px; }

/* Conversions Block */
.conversions-block { margin: 40px 0; }
.conversions-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 18px;
  margin-top: 16px;
}
.conversions-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 20px;
  box-shadow: var(--shadow-sm);
}
.conversions-card h3 {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--text);
  font-weight: 700;
  margin: 0 0 12px;
}
.pills {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 10px 0 16px;
}
.pills a {
  display: inline-flex;
  align-items: center;
  padding: 5px 12px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 999px;
  text-decoration: none;
  font-size: 0.88rem;
  font-weight: 500;
  color: var(--text);
  transition: all 0.15s ease;
  box-shadow: var(--shadow-sm);
}
.pills a:hover {
  border-color: var(--accent);
  background: var(--accent-soft);
  color: var(--accent);
  transform: translateY(-1px);
}

/* Trust Block */
.trust-block {
  background: var(--surface);
  border: 1px solid var(--line);
  border-left: 5px solid var(--ok);
  border-radius: var(--radius);
  padding: 24px;
  margin: 40px 0;
  display: flex;
  gap: 20px;
  align-items: flex-start;
  box-shadow: var(--shadow-sm);
}
.trust-icon {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  background: var(--ok-soft);
  color: var(--ok);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.trust-content { flex: 1; }
.trust-content h2 { margin: 0 0 8px; font-size: 1.25rem; border: 0; padding: 0; }
.trust-content p { margin: 0 0 14px; color: var(--muted); font-size: 0.95rem; line-height: 1.55; }
.trust-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  font-size: 0.85rem;
  color: var(--muted);
  align-items: center;
}
.trust-link { color: var(--accent); font-weight: 600; text-decoration: none; margin-left: auto; }
.trust-link:hover { text-decoration: underline; }

/* Ad slot & Notes */
.ad-slot {
  min-height: 250px;
  margin: 40px 0;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px dashed var(--line);
  border-radius: var(--radius);
  color: var(--muted);
  font-size: 13px;
}
.note { font-size: 0.88rem; color: var(--muted); line-height: 1.5; }

/* Footer */
footer.site {
  margin-top: 60px;
  background: var(--surface);
  border-top: 1px solid var(--line);
  padding: 48px 0 36px;
  color: var(--muted);
  font-size: 0.9rem;
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: 36px;
  margin-bottom: 36px;
}
.footer-brand {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 1.1rem;
  color: var(--text);
  margin-bottom: 12px;
}
.footer-col p { margin: 0 0 10px; line-height: 1.5; font-size: 0.88rem; }
.footer-updated { font-size: 0.8rem; color: var(--muted); }
.footer-title {
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--text);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 14px;
}
.footer-links { list-style: none; padding: 0; margin: 0; }
.footer-links li { margin-bottom: 8px; }
.footer-links a {
  color: var(--muted);
  text-decoration: none;
  font-size: 0.88rem;
  transition: color 0.15s ease;
}
.footer-links a:hover { color: var(--accent); text-decoration: underline; }
.footer-bottom {
  border-top: 1px solid var(--line);
  padding-top: 24px;
  font-size: 0.82rem;
  line-height: 1.55;
  color: var(--muted);
}

/* Responsive Breakpoints */
@media (max-width: 768px) {
  .footer-grid {
    grid-template-columns: 1fr 1fr;
    gap: 28px;
  }
}

@media (max-width: 600px) {
  .wrap { padding: 0 14px; }
  header.site .wrap { min-height: auto; padding: 10px 14px; }
  nav.top { gap: 2px; }
  nav.top a { font-size: 0.82rem; padding: 5px 8px; }
  .hero { padding: 20px 0 16px; }
  .hero-actions { flex-direction: column; }
  .hero-actions .btn { width: 100%; }
  .card { padding: 18px 14px; border-radius: var(--radius); }
  .grid { grid-template-columns: 1fr; gap: 12px; }
  #timecard table { min-width: 420px; }
  #timecard th, #timecard td { padding: 8px 6px; font-size: 0.88rem; }
  #timecard input { padding: 6px 4px; font-size: 0.88rem; }
  #timecard input[type=number] { width: 60px; }
  .trust-block { flex-direction: column; padding: 18px 16px; }
  .trust-link { margin-left: 0; margin-top: 4px; }
  .footer-grid { grid-template-columns: 1fr; gap: 24px; }
}

@media (max-width: 390px) {
  .wrap { padding: 0 10px; }
  .card { padding: 14px 10px; }
  #timecard input[type=number] { width: 52px; }
  h1 { font-size: 1.55rem; }
}

/* Print Stylesheet */
@media print {
  header.site, footer.site, .ad-slot, .no-print, .crumbs, .hero-actions, .tile-arrow {
    display: none !important;
  }
  body {
    background: #ffffff !important;
    color: #000000 !important;
    font-size: 11pt;
  }
  .card {
    border: 1px solid #000000 !important;
    box-shadow: none !important;
    padding: 10px !important;
    margin: 10px 0 !important;
  }
  .wrap { max-width: 100% !important; padding: 0 !important; }
  table { border: 1px solid #000000 !important; }
  th, td { border-bottom: 1px solid #666666 !important; color: #000000 !important; }
  input { border: 1px solid #999999 !important; background: #ffffff !important; color: #000000 !important; }
  .result {
    background: #ffffff !important;
    border: 2px solid #000000 !important;
    color: #000000 !important;
  }
  .result b { color: #000000 !important; }
}
