/* ofispro.com V1 site templates (comms 0013, D1 and D2). Layout only: colours, type, space and radius come from
   tokens.css. Breakpoints: medium 600px, expanded 840px (tokens). No script; menus use <details>. */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--surface-page); color: var(--text-primary);
  font-family: var(--font-ui); font-size: var(--type-body-l-size); line-height: var(--type-body-l-line);
}
img, svg { display: block; max-width: 100%; }
a { color: var(--text-link); text-underline-offset: 0.18em; }
a:focus-visible, button:focus-visible, summary:focus-visible, .is-focus {
  outline: var(--focus-ring-width) solid var(--focus-ring); outline-offset: var(--focus-offset); border-radius: 4px;
}
h1, h2, h3 { margin: 0; text-wrap: balance; }
p { margin: 0; }
.wrap { max-width: 1152px; margin-inline: auto; padding-inline: 16px; }
@media (min-width: 600px) { .wrap { padding-inline: 24px; } }
@media (min-width: 840px) { .wrap { padding-inline: 32px; } }
.vh { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.dk { display: none; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .lt { display: none; } :root:not([data-theme="light"]) .dk { display: block; } }
:root[data-theme="dark"] .lt { display: none; }
:root[data-theme="dark"] .dk { display: block; }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 48px; padding: 0 24px;
  border-radius: var(--radius-pill); border: 1px solid transparent; font: inherit; font-weight: 600;
  font-size: var(--type-label-l-size); text-decoration: none; cursor: pointer;
}
.btn-primary { background: var(--accent-default); color: var(--text-on-accent); }
.btn-primary:hover { background: var(--accent-hover); }
.btn-secondary { background: transparent; color: var(--text-link); border-color: var(--border-control); }
.btn-secondary:hover { background: var(--surface-hover); }
.btn svg { width: 20px; height: 20px; }
.link-more { display: inline-flex; align-items: center; gap: 4px; min-height: 48px; font-weight: 600; text-decoration: none; }
.link-more:hover { text-decoration: underline; }
.link-more svg { width: 18px; height: 18px; }

/* Header */
.s-top { background: var(--surface-raised); border-bottom: 1px solid var(--border-subtle); position: relative; z-index: 2; }
.s-top .wrap { display: flex; align-items: center; gap: 16px; min-height: 64px; }
.s-brand { display: flex; align-items: center; min-height: 48px; margin-inline-end: auto; }
.s-brand img { height: 24px; width: auto; }
.s-nav { display: none; }
.s-nav ul { display: flex; gap: 4px; list-style: none; margin: 0; padding: 0; }
.s-nav a { display: flex; align-items: center; min-height: 48px; padding: 0 12px; border-radius: var(--radius-control);
  color: var(--text-primary); text-decoration: none; font-size: var(--type-label-l-size); font-weight: 500; }
.s-nav a:hover { background: var(--surface-hover); }
.s-nav a[aria-current="page"] { color: var(--text-link); box-shadow: inset 0 -2px 0 var(--accent-default); border-radius: 0; }
.s-lang { display: flex; align-items: center; gap: 6px; min-height: 48px; padding: 0 8px; font-size: var(--type-label-l-size); font-weight: 500; }
.s-lang svg { width: 20px; height: 20px; }
.s-menu { position: static; }
.s-menu > summary { list-style: none; display: flex; align-items: center; justify-content: center; width: 48px; height: 48px;
  border-radius: var(--radius-control); cursor: pointer; color: var(--text-primary); }
.s-menu > summary::-webkit-details-marker { display: none; }
.s-menu > summary:hover { background: var(--surface-hover); }
.s-menu > summary svg { width: 24px; height: 24px; }
.s-menu .i-close { display: none; }
.s-menu[open] .i-open { display: none; }
.s-menu[open] .i-close { display: block; }
.s-menu-panel { position: absolute; inset-inline: 0; top: 100%; background: var(--surface-raised);
  border-bottom: 1px solid var(--border-subtle); box-shadow: 0 8px 16px rgb(0 0 0 / 0.08); padding: 8px 16px 16px; }
.s-menu-panel ul { list-style: none; margin: 0; padding: 0; }
.s-menu-panel a { display: flex; align-items: center; gap: 12px; min-height: 56px; color: var(--text-primary); text-decoration: none;
  font-size: var(--type-title-s-size); font-weight: 500; border-bottom: 1px solid var(--border-subtle); }
.s-menu-panel a img { width: 32px; height: 32px; }
@media (min-width: 840px) {
  .s-nav { display: block; }
  .s-menu { display: none; }
}

/* Sections */
.sec { padding-block: 48px; }
@media (min-width: 840px) { .sec { padding-block: 72px; } }
.sec-alt { background: var(--surface-raised); border-block: 1px solid var(--border-subtle); }
.sec-head { max-width: 680px; margin-bottom: 32px; }
.sec-head h2 { font-size: var(--type-title-l-size); line-height: var(--type-title-l-line); font-weight: var(--type-title-l-weight); }
.sec-head p { margin-top: 8px; color: var(--text-secondary); }
.eyebrow { font-size: var(--type-label-m-size); font-weight: 600; color: var(--accent-default); margin-bottom: 8px; }

/* Hero with file box (home and format pages) */
.hero { padding-block: 32px 48px; }
.hero-grid { display: grid; gap: 24px; }
.hero h1 { font-size: 2rem; line-height: 1.2; font-weight: var(--type-display-weight); }
.hero .lead { margin-top: 12px; color: var(--text-secondary); font-size: var(--type-body-l-size); max-width: 560px; }
.hero .facts { display: flex; flex-wrap: wrap; gap: 8px 16px; margin: 16px 0 0; padding: 0; list-style: none; color: var(--text-secondary); font-size: var(--type-body-m-size); }
.hero .facts li { display: flex; align-items: center; gap: 6px; }
.hero .facts svg { width: 18px; height: 18px; color: var(--accent-default); }
.crumb { font-size: var(--type-body-m-size); margin-bottom: 12px; color: var(--text-secondary); }
.crumb a { color: var(--text-secondary); }
@media (min-width: 840px) {
  .hero { padding-block: 64px 72px; }
  .hero-grid { grid-template-columns: 5fr 6fr; gap: 48px; align-items: center; }
  .hero h1 { font-size: 2.75rem; }
}

/* File box */
.fbox { background: var(--surface-raised); border: 2px dashed var(--border-control); border-radius: var(--radius-card);
  padding: 32px 20px; text-align: center; display: grid; justify-items: center; gap: 12px; }
.fb-icon { flex: none; width: 56px; height: 56px; border-radius: 16px; background: var(--surface-selected); color: var(--text-on-selected);
  display: grid; place-items: center; }
.fb-icon svg { width: 28px; height: 28px; }
.fbox .fb-or { font-weight: 600; }
.fbox .fb-types { color: var(--text-secondary); font-size: var(--type-body-m-size); }
.fbox .fb-sample { font-size: var(--type-body-m-size); }
.fbox-privacy { display: flex; align-items: center; justify-content: center; gap: 8px; margin-top: 12px; padding: 10px 16px;
  border-radius: var(--radius-control); background: var(--privacy-surface); color: var(--privacy-text); font-size: var(--type-body-m-size); }
.fbox-privacy svg { width: 18px; height: 18px; flex: none; }
.fbox.is-drag { border-style: solid; border-color: var(--accent-default); background: var(--surface-selected); }
.fbox.is-error { border-style: solid; border-color: var(--status-error-text); }
.fbox.is-warn { border-style: solid; border-color: var(--status-warning-text); }
.fb-msg { display: flex; gap: 10px; text-align: start; padding: 12px 16px; border-radius: var(--radius-control); max-width: 440px; font-size: var(--type-body-m-size); }
.fb-msg svg { width: 20px; height: 20px; flex: none; margin-top: 2px; }
.fb-msg strong { display: block; }
.fb-msg.err { background: var(--status-error-surface); color: var(--status-error-text); }
.fb-msg.warn { background: var(--status-warning-surface); color: var(--status-warning-text); }
@media (min-width: 840px) { .fbox { padding: 48px 32px; } }

/* Product cards */
.pcards { display: grid; gap: 16px; }
@media (min-width: 840px) { .pcards { grid-template-columns: 1fr 1fr; gap: 24px; } }
.pcard { background: var(--surface-raised); border: 1px solid var(--border-subtle); border-radius: var(--radius-card);
  overflow: hidden; display: grid; grid-template-rows: auto 1fr; }
.pcard-body { padding: 24px; display: grid; gap: 12px; align-content: start; }
.pcard-id { display: flex; align-items: center; gap: 12px; }
.pcard-id img { width: 48px; height: 48px; }
.pcard h3 { font-size: var(--type-title-m-size); line-height: var(--type-title-m-line); font-weight: var(--type-title-m-weight); }
.pcard .sub { font-size: var(--type-body-m-size); color: var(--text-secondary); }
.pcard ul { margin: 0; padding-inline-start: 20px; color: var(--text-secondary); font-size: var(--type-body-m-size); }
.pcard-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 16px; margin-top: 4px; }
.pcard-shot { background: var(--surface-canvas); height: 220px; overflow: hidden; display: flex; justify-content: center; gap: 16px; padding-top: 24px; }
@media (min-width: 840px) { .pcard-shot { height: 280px; } }

/* Phone frame (screens from the store captures) */
.phone { width: 180px; flex: none; border-radius: 28px; padding: 8px; background: #1f1c19; box-shadow: 0 12px 32px rgb(0 0 0 / 0.18); align-self: flex-start; }
.phone img { border-radius: 20px; width: 100%; height: auto; }
.phone.sm { width: 150px; }
.phone.lg { width: 240px; }
@media (min-width: 840px) { .phone.lg { width: 248px; } }

/* Google Play badge slot: the official badge file from Google goes here unchanged (D2 spec) */
.play { display: inline-flex; padding: 0; border-radius: 8px; min-height: 48px; text-decoration: none; }
.play-badge { display: grid; place-items: center; height: 48px; width: 162px; border-radius: 8px; border: 1px dashed var(--border-control);
  background: var(--surface-hover); color: var(--text-secondary); font-size: 0.75rem; line-height: 1.2; text-align: center; padding: 0 8px; }
.play.lg .play-badge { height: 56px; width: 189px; }
.play-note { font-size: var(--type-body-s-size); color: var(--text-secondary); }

/* Format grid */
.fgrid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 8px; list-style: none; margin: 0; padding: 0; }
@media (min-width: 600px) { .fgrid { grid-template-columns: repeat(3, 1fr); } }
@media (min-width: 840px) { .fgrid { grid-template-columns: repeat(5, 1fr); gap: 12px; } }
.fgrid a { display: flex; align-items: center; gap: 12px; min-height: 64px; padding: 10px 12px; border-radius: var(--radius-control);
  background: var(--surface-raised); border: 1px solid var(--border-subtle); color: var(--text-primary); text-decoration: none; }
.sec-alt .fgrid a { background: var(--surface-page); }
.fgrid a:hover { border-color: var(--border-control); }
.fgrid img { width: 36px; height: 36px; flex: none; }
.fgrid b { display: block; font-size: var(--type-label-l-size); }
.fgrid small { display: block; font-size: var(--type-body-s-size); color: var(--text-secondary); line-height: 1.3; }
.fgrid-more { margin-top: 16px; color: var(--text-secondary); font-size: var(--type-body-m-size); }

/* Three steps */
.steps { display: grid; gap: 16px; list-style: none; margin: 0; padding: 0; counter-reset: s; }
@media (min-width: 840px) { .steps { grid-template-columns: repeat(3, 1fr); gap: 24px; } }
.steps li { counter-increment: s; display: grid; grid-template-columns: 40px 1fr; gap: 4px 16px; align-items: start; }
.steps li::before { content: counter(s); grid-row: span 2; width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center;
  background: var(--accent-default); color: var(--text-on-accent); font-weight: 700; }
.steps h3 { font-size: var(--type-title-s-size); line-height: var(--type-title-s-line); }
.steps p { color: var(--text-secondary); font-size: var(--type-body-m-size); }

.steps[data-col="1"] { grid-template-columns: 1fr; }

/* Privacy band */
.pband { background: var(--privacy-surface); color: var(--privacy-text); border-radius: var(--radius-card); padding: 24px; display: grid; gap: 20px; }
.pband h2 { font-size: var(--type-title-l-size); line-height: var(--type-title-l-line); }
.pband ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 16px; }
.pband li { display: grid; grid-template-columns: 24px 1fr; gap: 12px; }
.pband li svg { width: 24px; height: 24px; }
.pband a { color: inherit; font-weight: 600; }
@media (min-width: 840px) { .pband { grid-template-columns: 2fr 3fr; padding: 40px; gap: 40px; } }

/* Features (product pages) */
.feats { display: grid; gap: 16px; list-style: none; margin: 0; padding: 0; }
@media (min-width: 600px) { .feats { grid-template-columns: 1fr 1fr; } }
@media (min-width: 840px) { .feats { grid-template-columns: repeat(3, 1fr); gap: 24px; } .feats.four { grid-template-columns: repeat(2, 1fr); } }
.feats li { background: var(--surface-raised); border: 1px solid var(--border-subtle); border-radius: var(--radius-card); padding: 20px; display: grid; gap: 8px; align-content: start; }
.feats .fi { width: 40px; height: 40px; border-radius: 12px; background: var(--surface-selected); color: var(--text-on-selected); display: grid; place-items: center; }
.feats .fi svg { width: 22px; height: 22px; }
.feats h3 { font-size: var(--type-title-s-size); line-height: var(--type-title-s-line); }
.feats p { color: var(--text-secondary); font-size: var(--type-body-m-size); }

/* Product hero */
.phero { padding-block: 32px 0; overflow: hidden; }
.phero-grid { display: grid; gap: 32px; }
.phero-id { display: flex; align-items: center; gap: 16px; margin-bottom: 20px; }
.phero-id img { width: 64px; height: 64px; }
.phero h1 { font-size: 2rem; line-height: 1.2; }
.phero .lead { margin-top: 12px; color: var(--text-secondary); max-width: 560px; }
.phero-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 20px; margin-top: 24px; }
.phero-note { margin-top: 12px; font-size: var(--type-body-s-size); color: var(--text-secondary); max-width: 520px; }
.phero-shots { display: flex; justify-content: center; gap: 16px; height: 360px; overflow: hidden; }
@media (min-width: 840px) {
  .phero { padding-block: 64px 0; }
  .phero-grid { grid-template-columns: 1fr 1fr; align-items: center; }
  .phero-copy { padding-bottom: 64px; }
  .phero h1 { font-size: 2.75rem; }
  .phero-shots { height: 520px; justify-content: flex-end; }
}
.phero-shots .phone:nth-child(2) { margin-top: 48px; display: none; }
@media (min-width: 600px) { .phero-shots .phone:nth-child(2) { display: block; } }

/* Screens strip */
.strip { display: flex; gap: 16px; overflow-x: auto; padding-bottom: 8px; scroll-snap-type: x mandatory; }
.strip figure { margin: 0; flex: none; scroll-snap-align: start; display: grid; gap: 12px; justify-items: center; width: 180px; }
.strip figcaption { font-size: var(--type-body-m-size); color: var(--text-secondary); text-align: center; }
@media (min-width: 840px) { .strip { justify-content: space-between; overflow: visible; } .strip figure { width: 200px; } .strip .phone { width: 200px; } }

/* Band towards the other surface (app or browser) */
.band { display: grid; gap: 16px; align-items: center; background: var(--surface-raised); border: 1px solid var(--border-subtle);
  border-radius: var(--radius-card); padding: 24px; }
.band h2 { font-size: var(--type-title-m-size); line-height: var(--type-title-m-line); }
.band p { color: var(--text-secondary); font-size: var(--type-body-m-size); margin-top: 4px; }
.band-id { display: flex; gap: 16px; align-items: center; }
.band-id img { width: 48px; height: 48px; flex: none; }
@media (min-width: 840px) { .band { grid-template-columns: 1fr auto; padding: 32px; } }

/* FAQ */
.faq { display: grid; gap: 8px; max-width: 800px; }
.faq details { background: var(--surface-raised); border: 1px solid var(--border-subtle); border-radius: var(--radius-control); }
.sec-alt .faq details { background: var(--surface-page); }
.faq summary { list-style: none; display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 56px;
  padding: 12px 16px; cursor: pointer; font-weight: 600; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary svg { width: 20px; height: 20px; flex: none; color: var(--text-secondary); transition: transform var(--motion-duration-fast) var(--motion-easing-standard); }
.faq details[open] summary svg { transform: rotate(180deg); }
.faq .ans { padding: 0 16px 16px; color: var(--text-secondary); }
.faq-group { margin-top: 40px; }
.faq-group:first-child { margin-top: 0; }
.faq-group h2 { font-size: var(--type-title-m-size); line-height: var(--type-title-m-line); margin-bottom: 16px; }
.faq-layout { display: grid; gap: 32px; }
.toc { display: none; }
@media (min-width: 840px) {
  .faq-layout { grid-template-columns: 220px 1fr; gap: 48px; align-items: start; }
  .toc { display: block; position: sticky; top: 24px; }
  .toc ul { list-style: none; margin: 0; padding: 0; border-inline-start: 2px solid var(--border-subtle); }
  .toc a { display: flex; align-items: center; min-height: 44px; padding-inline-start: 16px; color: var(--text-secondary); text-decoration: none; }
  .toc a:hover { color: var(--text-primary); }
}
@media (prefers-reduced-motion: reduce) { .faq summary svg { transition: none; } }

/* Page head (FAQ, support) */
.phead { padding-block: 32px; border-bottom: 1px solid var(--border-subtle); background: var(--surface-raised); }
.phead h1 { font-size: 2rem; line-height: 1.2; }
.phead p { margin-top: 8px; color: var(--text-secondary); max-width: 640px; }
@media (min-width: 840px) { .phead { padding-block: 56px; } .phead h1 { font-size: 2.5rem; } }

/* Support */
.sgrid { display: grid; gap: 16px; }
@media (min-width: 840px) { .sgrid { grid-template-columns: 3fr 2fr; gap: 24px; align-items: start; } }
.card { background: var(--surface-raised); border: 1px solid var(--border-subtle); border-radius: var(--radius-card); padding: 24px; display: grid; gap: 12px; align-content: start; }
.card h2 { font-size: var(--type-title-m-size); line-height: var(--type-title-m-line); }
.card p, .card li { color: var(--text-secondary); font-size: var(--type-body-m-size); }
.card ol, .card ul { margin: 0; padding-inline-start: 20px; display: grid; gap: 6px; }
.mail { display: flex; align-items: center; gap: 12px; font-size: var(--type-title-s-size); font-weight: 600; min-height: 48px; word-break: break-all; }
.mail svg { width: 24px; height: 24px; flex: none; }
.links { list-style: none; padding: 0; margin: 0; display: grid; }
.links a { display: flex; align-items: center; justify-content: space-between; min-height: 48px; border-bottom: 1px solid var(--border-subtle); text-decoration: none; color: var(--text-primary); }
.links a svg { width: 18px; height: 18px; color: var(--text-secondary); }
.links li:last-child a { border-bottom: 0; }

/* Format page extras */
.subtypes { display: flex; flex-wrap: wrap; gap: 8px; list-style: none; margin: 0; padding: 0; }
.subtypes li { padding: 6px 12px; border-radius: var(--radius-pill); background: var(--surface-raised); border: 1px solid var(--border-subtle); font-size: var(--type-body-m-size); }
.subtypes li.later { border-style: dashed; color: var(--text-secondary); }
.note { display: flex; gap: 10px; padding: 12px 16px; border-radius: var(--radius-control); background: var(--status-warning-surface); color: var(--status-warning-text); font-size: var(--type-body-m-size); max-width: 680px; margin-top: 16px; }
.note svg { width: 20px; height: 20px; flex: none; margin-top: 2px; }
.two { display: grid; gap: 32px; }
@media (min-width: 840px) { .two { grid-template-columns: 1fr 1fr; gap: 48px; } }

/* Footer */
.s-foot { background: var(--surface-raised); border-top: 1px solid var(--border-subtle); padding-block: 40px 24px; font-size: var(--type-body-m-size); }
.s-foot-grid { display: grid; gap: 32px; grid-template-columns: 1fr 1fr; }
.s-foot-brand { grid-column: 1 / -1; display: grid; gap: 12px; align-content: start; justify-items: start; }
.s-foot-brand img { height: 24px; width: auto; }
.s-foot-brand p { color: var(--text-secondary); max-width: 320px; }
.s-foot h2 { font-size: var(--type-label-l-size); margin-bottom: 4px; }
.s-foot ul { list-style: none; margin: 0; padding: 0; }
.s-foot li a { display: flex; align-items: center; min-height: 40px; color: var(--text-secondary); text-decoration: none; }
.s-foot li a:hover { color: var(--text-primary); text-decoration: underline; }
.s-foot-base { margin-top: 32px; padding-top: 16px; border-top: 1px solid var(--border-subtle); display: flex; flex-wrap: wrap; gap: 8px 24px;
  justify-content: space-between; align-items: center; color: var(--text-secondary); }
@media (min-width: 840px) {
  .s-foot-grid { grid-template-columns: 2fr 1fr 1fr 1fr; }
  .s-foot-brand { grid-column: auto; }
}

/* Component sheet (components.html only) */
.cs-sec { padding-block: 32px; border-bottom: 1px solid var(--border-subtle); }
.cs-sec > h2 { font-size: var(--type-title-m-size); margin-bottom: 4px; }
.cs-sec > p { color: var(--text-secondary); font-size: var(--type-body-m-size); margin-bottom: 20px; max-width: 760px; }
.cs-row { display: grid; gap: 16px; }
@media (min-width: 840px) { .cs-row.c2 { grid-template-columns: 1fr 1fr; } .cs-row.c4 { grid-template-columns: repeat(2, 1fr); } }
.cs-label { font-size: var(--type-label-m-size); font-weight: 600; color: var(--text-secondary); margin-bottom: 8px; }
.cs-frame { border: 1px solid var(--border-subtle); border-radius: var(--radius-control); overflow: hidden; position: relative; }
.cs-frame.narrow { max-width: 360px; }
.cs-frame .s-menu-panel { position: static; box-shadow: none; }
.cs-spec { margin: 12px 0 0; padding: 0; list-style: none; font-size: var(--type-body-s-size); color: var(--text-secondary); display: grid; gap: 4px; }
.cs-play { display: flex; flex-wrap: wrap; gap: 24px; align-items: center; }
.cs-clear { padding: 12px; border: 1px dashed var(--status-error-text); border-radius: 8px; }
