:root {
  --background: #f6f6f6;
  --surface: #ffffff;
  --surface-muted: #f0f0f0;
  --header: #111111;
  --text: #18181b;
  --text-muted: #626269;
  --border: #dedee2;
  --accent: #ff5a00;
  --accent-dark: #d94c00;
  --shadow: 0 14px 34px rgb(24 24 27 / 10%);
  --max-width: 1220px;
}

* {
  box-sizing: border-box;
}

html {
  background: var(--background);
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  background: var(--background);
  color: var(--text);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.5;
}

img,
iframe {
  display: block;
}

a {
  color: inherit;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  border-bottom: 3px solid var(--accent);
  background: var(--header);
  color: #ffffff;
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: min(var(--max-width), calc(100% - 32px));
  min-height: 58px;
  margin: 0 auto;
  gap: 24px;
}

.site-name,
.back-link {
  text-decoration: none;
}

.site-name {
  font-size: 1rem;
  font-weight: 900;
  letter-spacing: 0.03em;
}

.site-name span {
  color: var(--accent);
}

.back-link {
  color: #d7d7db;
  font-size: 0.88rem;
  font-weight: 700;
}

.back-link:hover,
.back-link:focus-visible {
  color: #ffffff;
}

.page-shell {
  width: min(var(--max-width), calc(100% - 32px));
  margin: 0 auto;
  padding: 40px 0 80px;
}

.brand-banner {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 190px;
  margin-bottom: 48px;
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--surface);
  box-shadow: var(--shadow);
}

.brand-banner img {
  width: min(760px, 92%);
  height: auto;
}

.page-introduction {
  max-width: 820px;
  margin-bottom: 54px;
}

.eyebrow,
.section-kicker {
  margin: 0 0 8px;
  color: var(--accent);
  font-size: 0.77rem;
  font-weight: 900;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  margin-bottom: 16px;
  font-size: clamp(2.7rem, 8vw, 5.4rem);
  line-height: 0.96;
  letter-spacing: -0.055em;
}

h2 {
  margin-bottom: 0;
  font-size: clamp(1.6rem, 4vw, 2.35rem);
  letter-spacing: -0.025em;
}

h3 {
  margin-bottom: 0;
  font-size: 1.32rem;
  line-height: 1.2;
}

.intro {
  margin-bottom: 0;
  color: var(--text-muted);
  font-size: clamp(1rem, 2vw, 1.16rem);
  line-height: 1.75;
}

.section-heading {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 28px;
  margin-bottom: 22px;
  padding-bottom: 18px;
  border-bottom: 1px solid var(--border);
}

.manual-note {
  margin-bottom: 2px;
  color: var(--text-muted);
  font-size: 0.86rem;
}

.manual-note code,
.card-heading code {
  border: 1px solid var(--border);
  border-radius: 5px;
  background: var(--surface-muted);
  font-family: "Cascadia Code", "SFMono-Regular", Consolas, monospace;
}

.manual-note code {
  padding: 2px 5px;
}

.apps-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 26px;
}

.app-card {
  min-width: 0;
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--surface);
  box-shadow: var(--shadow);
  transition: transform 170ms ease, border-color 170ms ease, box-shadow 170ms ease;
}

.app-card:hover {
  transform: translateY(-3px);
  border-color: rgb(255 90 0 / 65%);
  box-shadow: 0 18px 42px rgb(24 24 27 / 14%);
}

.preview-frame {
  position: relative;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  border-bottom: 1px solid var(--border);
  background:
    linear-gradient(135deg, rgb(255 90 0 / 10%), transparent 48%),
    #e8e8eb;
}

.preview-frame iframe {
  width: 1600px;
  height: 900px;
  border: 0;
  background: #ffffff;
  pointer-events: none;
  transform: scale(0.36);
  transform-origin: top left;
}

.preview-label {
  position: absolute;
  top: 12px;
  right: 12px;
  padding: 5px 8px;
  border-radius: 4px;
  background: rgb(17 17 17 / 88%);
  color: #ffffff;
  font-size: 0.7rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.card-content {
  padding: 22px;
}

.card-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 13px;
}

.card-heading code {
  flex: 0 0 auto;
  max-width: 48%;
  overflow: hidden;
  padding: 4px 7px;
  color: var(--text-muted);
  font-size: 0.68rem;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.card-content p {
  min-height: 52px;
  margin-bottom: 20px;
  color: var(--text-muted);
  font-size: 0.94rem;
  line-height: 1.6;
}

.open-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0 18px;
  border: 2px solid var(--accent);
  border-radius: 6px;
  background: var(--accent);
  color: #ffffff;
  font-size: 0.84rem;
  font-weight: 900;
  letter-spacing: 0.035em;
  text-decoration: none;
  text-transform: uppercase;
  transition: background 150ms ease, border-color 150ms ease, transform 150ms ease;
}

.open-button:hover,
.open-button:focus-visible {
  border-color: var(--accent-dark);
  background: var(--accent-dark);
  transform: translateY(-1px);
  outline: none;
}

.site-footer {
  border-top: 1px solid #2f2f33;
  background: var(--header);
  color: #bdbdc2;
  text-align: center;
}

.site-footer p {
  width: min(var(--max-width), calc(100% - 32px));
  margin: 0 auto;
  padding: 28px 0;
  font-size: 0.82rem;
}

@media (max-width: 850px) {
  .apps-grid {
    grid-template-columns: 1fr;
  }

  .section-heading {
    align-items: flex-start;
    flex-direction: column;
    gap: 10px;
  }

  .card-content p {
    min-height: 0;
  }
}

@media (max-width: 560px) {
  .header-inner {
    min-height: 54px;
  }

  .back-link {
    font-size: 0.78rem;
  }

  .page-shell {
    padding-top: 24px;
  }

  .brand-banner {
    min-height: 130px;
    margin-bottom: 36px;
  }

  .card-heading {
    flex-direction: column;
    gap: 8px;
  }

  .card-heading code {
    max-width: 100%;
  }

  .preview-frame iframe {
    transform: scale(0.25);
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .app-card,
  .open-button {
    transition: none;
  }
}
