:root {
  color-scheme: light dark;

  --bg: #faf9f8;
  --surface: #ffffff;
  --surface-alt: #f3f2f1;
  --hero-bg: #eeebe3;
  --text: #201f1e;
  --text-muted: #5d5b57;
  --border: #e3e1dc;
  --link: #0f6cbd;
  --link-dark: #0a4d8c;
  --accent-a: #7c5cff;
  --accent-b: #ff8a5c;
  --accent-c: #00b7c3;
  --accent-d: #ffb900;
  --success: #107c10;
  --error: #a4262c;
  --radius: 14px;
  --radius-sm: 8px;
  --shadow-sm: 0 1px 3px rgba(20, 20, 20, 0.07);
  --shadow-md: 0 8px 24px rgba(20, 20, 20, 0.09);
  --shadow-lg: 0 20px 48px rgba(20, 20, 20, 0.12);
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #17171b;
    --surface: #212026;
    --surface-alt: #29282e;
    --hero-bg: #232229;
    --text: #f1f0ee;
    --text-muted: #b2afc4;
    --border: #35343c;
    --link: #6cb6f2;
    --link-dark: #9ecdf5;
    --accent-a: #9b82ff;
    --accent-b: #ff9e73;
    --accent-c: #3fd6e0;
    --accent-d: #ffcc4d;
    --success: #6bcf6b;
    --error: #ff8a8a;
    --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.35);
    --shadow-md: 0 8px 24px rgba(0, 0, 0, 0.45);
    --shadow-lg: 0 20px 48px rgba(0, 0, 0, 0.55);
  }
}

* { box-sizing: border-box; }

html, body { background: var(--bg); }

body {
  margin: 0;
  font-family: "Poppins", "Segoe UI", -apple-system, BlinkMacSystemFont, sans-serif;
  color: var(--text);
  -webkit-font-smoothing: antialiased;
}

a { color: var(--link); }

/* Header + sub nav, Microsoft Learn style: flat, minimal, bordered */
header.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: var(--surface);
  border-bottom: 1px solid var(--border);
}

.header-inner {
  max-width: 1180px;
  margin: 0 auto;
  padding: 14px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.brand {
  font-size: 1.02rem;
  font-weight: 700;
  text-decoration: none;
  color: var(--text);
  display: flex;
  align-items: center;
  gap: 8px;
  white-space: nowrap;
}

nav.main-nav {
  background: var(--surface-alt);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

nav.main-nav ul {
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 24px;
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 2px;
  overflow-x: auto;
}

nav.main-nav a {
  display: block;
  padding: 12px 14px;
  color: var(--text-muted);
  text-decoration: none;
  font-size: 0.85rem;
  font-weight: 600;
  white-space: nowrap;
  border-bottom: 2px solid transparent;
  transition: color 0.15s ease, border-color 0.15s ease;
}

nav.main-nav a:hover {
  color: var(--text);
}

nav.main-nav a.active {
  color: var(--link);
  border-bottom-color: var(--link);
}

main {
  max-width: 1180px;
  margin: 0 auto;
  padding: 32px 24px 90px;
}

/* Hero — Microsoft Learn hub style: neutral card, eyebrow label, decorative blob */
.hero {
  position: relative;
  overflow: hidden;
  background: var(--hero-bg);
  color: var(--text);
  border-radius: var(--radius);
  padding: 44px 40px;
  margin-bottom: 32px;
  border: 1px solid var(--border);
}

.hero::before {
  content: "";
  position: absolute;
  right: -60px;
  top: -60px;
  width: 320px;
  height: 320px;
  background:
    radial-gradient(circle at 30% 30%, var(--accent-a) 0%, transparent 55%),
    radial-gradient(circle at 70% 60%, var(--accent-b) 0%, transparent 55%),
    radial-gradient(circle at 50% 90%, var(--accent-c) 0%, transparent 50%);
  opacity: 0.35;
  filter: blur(6px);
  border-radius: 40% 60% 55% 45% / 50% 40% 60% 50%;
}

.hero::after {
  content: "";
  position: absolute;
  right: 40px;
  bottom: -80px;
  width: 160px;
  height: 160px;
  background: linear-gradient(135deg, var(--accent-d), var(--accent-b));
  opacity: 0.25;
  border-radius: 30% 70% 60% 40% / 50% 60% 40% 50%;
}

.hero-eyebrow {
  position: relative;
  display: inline-block;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--link);
  margin-bottom: 10px;
}

.hero h1 {
  position: relative;
  margin: 0 0 12px;
  font-size: 2rem;
  font-weight: 800;
  letter-spacing: -0.01em;
}

.hero p {
  position: relative;
  margin: 0;
  color: var(--text-muted);
  max-width: 640px;
  font-size: 1.02rem;
  line-height: 1.55;
}

.hero-inner {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.hero-text { flex: 1; min-width: 0; }

.hero-illustration {
  position: relative;
  flex-shrink: 0;
  width: 260px;
  height: auto;
  filter: drop-shadow(0 12px 24px rgba(20, 20, 20, 0.12));
}

.hero-icon {
  display: inline-block;
  width: 40px;
  height: 40px;
  vertical-align: middle;
  margin-right: 10px;
  border-radius: 9px;
}

@media (max-width: 780px) {
  .hero-inner { flex-direction: column; align-items: flex-start; }
  .hero-illustration { width: 180px; margin: 0 auto; align-self: center; }
}

/* Card grid — "Step" style cards inspired by Learn hub */
.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 18px;
  margin: 24px 0;
}

.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  text-decoration: none;
  color: var(--text);
  display: flex;
  flex-direction: column;
  box-shadow: var(--shadow-sm);
  transition: box-shadow 0.2s ease, transform 0.2s ease, border-color 0.2s ease;
}

.card:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-3px);
  border-color: var(--link);
}

.card-thumb {
  height: 92px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.card-thumb img {
  width: 44px;
  height: 44px;
  border-radius: 10px;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.15);
}

.thumb-1 { background: linear-gradient(135deg, var(--accent-a), var(--accent-c)); }
.thumb-2 { background: linear-gradient(135deg, var(--accent-c), var(--accent-d)); }
.thumb-3 { background: linear-gradient(135deg, var(--accent-b), var(--accent-a)); }
.thumb-4 { background: linear-gradient(135deg, var(--accent-d), var(--accent-b)); }
.thumb-5 { background: linear-gradient(135deg, var(--accent-a), var(--accent-b)); }
.thumb-6 { background: linear-gradient(135deg, var(--accent-c), var(--accent-a)); }
.thumb-7 { background: linear-gradient(135deg, var(--accent-b), var(--accent-c)); }
.thumb-8 { background: linear-gradient(135deg, var(--accent-d), var(--accent-a)); }

.card-body { padding: 16px 18px 18px; display: flex; flex-direction: column; gap: 6px; flex: 1; }

.card-eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.06em;
  font-size: 0.68rem;
  font-weight: 700;
  color: var(--link);
}

.card h3 { margin: 2px 0 0; font-size: 1.02rem; font-weight: 700; }
.card p { margin: 0; color: var(--text-muted); font-size: 0.87rem; line-height: 1.4; flex: 1; }

.card-link {
  margin-top: 8px;
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--link);
}

/* Video embed */
.video-embed-wrap {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-md);
  margin: 16px 0;
  background: var(--surface-alt);
}

.video-embed-wrap iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
}

.video-meta {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 10px;
  font-size: 0.85rem;
  color: var(--text-muted);
}

.video-meta a { color: var(--link); font-weight: 600; text-decoration: none; }
.video-meta a:hover { text-decoration: underline; }

.video-placeholder {
  border: 2px dashed var(--border);
  border-radius: var(--radius);
  background: var(--surface-alt);
  aspect-ratio: 16 / 9;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  color: var(--text-muted);
  padding: 24px;
  margin: 16px 0;
}

.video-placeholder .vp-inner { max-width: 420px; }
.video-placeholder .vp-icon { font-size: 2.4rem; display: block; margin-bottom: 8px; }

.resource-link-card {
  display: flex;
  align-items: center;
  gap: 16px;
  background: var(--surface-alt);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
  margin: 16px 0;
}

.resource-link-card .icon-lg { font-size: 2rem; }
.resource-link-card a.btn {
  display: inline-block;
  margin-top: 6px;
  background: var(--link);
  color: white;
  text-decoration: none;
  padding: 9px 16px;
  border-radius: 999px;
  font-size: 0.85rem;
  font-weight: 600;
}
.resource-link-card a.btn:hover { background: var(--link-dark); }

section.block {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 26px;
  margin-bottom: 22px;
  box-shadow: var(--shadow-sm);
}

section.block h2 {
  margin-top: 0;
  font-size: 1.25rem;
  font-weight: 700;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--border);
}

.try-list {
  display: grid;
  gap: 12px;
}

.try-item {
  background: var(--surface-alt);
  border-left: 3px solid var(--link);
  padding: 14px 16px;
  border-radius: var(--radius-sm);
  font-size: 0.95rem;
}

.quiz-q {
  margin-bottom: 20px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--border);
}

.quiz-q:last-child { border-bottom: none; }

.quiz-q p.question { font-weight: 700; margin-bottom: 10px; }

.quiz-q label {
  display: block;
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  cursor: pointer;
  margin-bottom: 6px;
  border: 1px solid var(--border);
  transition: background 0.15s ease, border-color 0.15s ease;
}

.quiz-q label:hover { background: var(--surface-alt); border-color: var(--link); }

.quiz-feedback {
  margin-top: 8px;
  font-size: 0.88rem;
  font-weight: 700;
  display: none;
}

.quiz-feedback.correct { color: var(--success); }
.quiz-feedback.incorrect { color: var(--error); }

button.check-btn, button.check-quiz-btn {
  background: linear-gradient(135deg, var(--accent-a) 0%, var(--link) 100%);
  color: white;
  border: none;
  padding: 11px 20px;
  border-radius: 999px;
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  margin-top: 8px;
  box-shadow: var(--shadow-sm);
  transition: box-shadow 0.15s ease, transform 0.15s ease;
}

button.check-btn:hover, button.check-quiz-btn:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-1px);
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--surface-alt);
  color: var(--link);
  border: 1px solid var(--border);
  padding: 5px 12px;
  border-radius: 999px;
  font-size: 0.78rem;
  font-weight: 700;
  margin-bottom: 12px;
}

.footer-note {
  text-align: center;
  color: var(--text-muted);
  font-size: 0.82rem;
  margin-top: 40px;
}

.build-note {
  background: var(--surface-alt);
  border: 1px solid var(--accent-d);
  border-radius: var(--radius);
  padding: 14px 18px;
  font-size: 0.85rem;
  margin-bottom: 24px;
  color: var(--text);
}

.new-feature-note {
  background: var(--surface-alt);
  border: 1px solid var(--accent-c);
  border-radius: var(--radius);
  padding: 14px 18px;
  font-size: 0.85rem;
  margin-top: 4px;
  color: var(--text);
}

.new-feature-note strong {
  color: var(--accent-c);
}

/* Prompt of the day + prompt library */
.prompt-card {
  background: linear-gradient(135deg, var(--surface-alt), var(--surface));
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 22px 24px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.app-tag {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  background: var(--surface-alt);
  color: var(--link);
  border: 1px solid var(--border);
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.prompt-text { font-size: 1.05rem; line-height: 1.5; margin: 0; }

.prompt-actions { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }

.btn-secondary {
  background: var(--surface);
  color: var(--link);
  border: 1px solid var(--border);
  padding: 9px 16px;
  border-radius: 999px;
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
}
.btn-secondary:hover { border-color: var(--link); }

.prompt-list {
  display: grid;
  gap: 10px;
  max-height: 420px;
  overflow-y: auto;
  padding-right: 4px;
  margin-top: 12px;
}

.prompt-list-item {
  background: var(--surface-alt);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 12px 14px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.prompt-list-item .prompt-row { display: flex; justify-content: space-between; align-items: flex-start; gap: 10px; }
.prompt-list-item .prompt-text { font-size: 0.92rem; }

.prompt-form { display: grid; gap: 12px; max-width: 560px; margin-top: 12px; }

.prompt-form select, .prompt-form textarea {
  width: 100%;
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text);
  font-family: inherit;
  font-size: 0.92rem;
}

.prompt-form textarea { min-height: 80px; resize: vertical; }

.icon-btn {
  background: transparent;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  font-size: 1rem;
  line-height: 1;
  padding: 2px 6px;
  flex-shrink: 0;
}
.icon-btn:hover { color: var(--error); }

.empty-state { color: var(--text-muted); font-size: 0.9rem; font-style: italic; }

.step-list { display: grid; gap: 12px; counter-reset: step; }

.step-list li {
  list-style: none;
  background: var(--surface-alt);
  border-left: 3px solid var(--accent-a);
  padding: 14px 16px;
  border-radius: var(--radius-sm);
  font-size: 0.95rem;
}

/* Copilot-location mockups (where the Copilot button lives per app) */
.mockup-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 28px;
  margin: 24px 0 4px;
}

.app-mockup {
  display: flex;
  flex-direction: column;
  gap: 12px;
  text-align: center;
}

.app-mockup-window {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
}

.app-mockup-ribbon {
  height: 52px;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 0 16px;
}

.ribbon-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.55);
}

.ribbon-spacer { flex: 1; }

.copilot-highlight {
  width: 34px;
  height: 34px;
  border-radius: 10px;
  background: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 0 0 6px rgba(124, 92, 255, 0.55);
  animation: copilot-pulse 2.2s ease-in-out infinite;
}

.copilot-highlight img { width: 22px; height: 22px; }

@keyframes copilot-pulse {
  0%, 100% { box-shadow: 0 0 0 6px rgba(124, 92, 255, 0.55); }
  50% { box-shadow: 0 0 0 12px rgba(124, 92, 255, 0.25); }
}

.app-mockup-body {
  padding: 20px 20px 24px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.app-mockup-line {
  height: 10px;
  border-radius: 5px;
  background: var(--surface-alt);
  border: 1px solid var(--border);
}

.app-mockup-label {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  font-weight: 700;
  font-size: 1.05rem;
}

.app-mockup-label img { width: 36px; height: 36px; border-radius: 9px; }

.app-mockup-caption {
  font-size: 0.9rem;
  color: var(--text-muted);
  margin: 0;
  line-height: 1.4;
}

@media (max-width: 640px) {
  .hero { padding: 32px 22px; }
  .hero h1 { font-size: 1.5rem; }
  section.block { padding: 18px; }
}
