:root {
  --paper: #fff;
  --card: #fff;
  --line: #e5e7eb;
  --ink: #202124;
  --muted: #5f6368;
  --sage: #1a73e8;
  --sage-dark: #1558b0;
}

body { background: #fff; }
.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  height: 64px;
  background: rgba(255, 255, 255, 0.94);
  backdrop-filter: blur(16px);
}
.brand { font-family: inherit; font-weight: 600; }
.brand-mark { background: #1a73e8; }
.view-tabs { display: flex; align-self: stretch; gap: 4px; }
.view-tab {
  position: relative;
  border: 0;
  background: transparent;
  color: #5f6368;
  padding: 0 16px;
  font: 600 14px/1 inherit;
  cursor: pointer;
}
.view-tab[aria-selected="true"] { color: #1a73e8; }
.view-tab[aria-selected="true"]::after {
  content: "";
  position: absolute;
  inset: auto 10px 0;
  height: 3px;
  border-radius: 3px 3px 0 0;
  background: #1a73e8;
}
main { width: min(1440px, calc(100% - 32px)); }
.hero {
  min-height: 220px;
  grid-template-columns: 1fr auto;
  padding: 38px 0;
}
.hero h1 {
  font-family: inherit;
  font-size: clamp(38px, 5vw, 64px);
  font-weight: 500;
  letter-spacing: -0.045em;
}
.hero-copy { font-family: inherit; font-size: 17px; }
.privacy-card { max-width: 340px; border-radius: 24px; }
.connect-panel { padding: 28px 0 34px; }
.source-card { min-height: 130px; border-radius: 16px; padding: 20px; }
.source-card h3, .section-heading h2, .person-card h3 {
  font-family: inherit;
  font-weight: 500;
}
.library { padding-top: 28px; }
.library .section-heading { position: sticky; top: 64px; z-index: 10; padding: 14px 0; background: rgba(255,255,255,.94); backdrop-filter: blur(12px); }
.gallery {
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  gap: 3px;
  max-height: none;
  overflow: visible;
  padding: 0;
}
.gallery-date {
  grid-column: 1 / -1;
  margin: 26px 0 9px;
  font-size: 15px;
  font-weight: 600;
  color: #3c4043;
}
.gallery-date:first-child { margin-top: 4px; }
.photo { border-radius: 3px; background: #f1f3f4; }
.photo-meta { font-size: 11px; }
.gallery-more {
  display: block;
  margin: 24px auto 8px;
  border: 1px solid #dadce0;
  border-radius: 999px;
  background: #fff;
  color: #1a73e8;
  padding: 11px 22px;
  font-weight: 600;
  cursor: pointer;
}
.people { margin-top: 42px; }
.model-note { opacity: .72; }
.app-account {
  position: fixed;
  z-index: 25;
  top: max(12px, env(safe-area-inset-top));
  right: 14px;
  border: 0;
  background: rgba(255,255,255,.9);
  box-shadow: 0 2px 12px rgba(32,33,36,.14);
  backdrop-filter: blur(12px);
}
main {
  width: min(1440px, calc(100% - 32px));
  padding-top: 10px;
  padding-bottom: calc(88px + env(safe-area-inset-bottom));
}
.library .section-heading {
  top: 0;
  padding-right: 96px;
}
.library-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 12px;
}
.install-button {
  border: 1px solid #dadce0;
  border-radius: 999px;
  padding: 8px 13px;
}
.install-dialog {
  width: min(420px, calc(100% - 28px));
  max-width: none;
  border: 1px solid #dadce0;
  border-radius: 22px;
  background: #fff;
  color: var(--ink);
  padding: 20px;
  box-shadow: 0 24px 70px rgba(32, 33, 36, .3);
}
.install-dialog::backdrop {
  background: rgba(32, 33, 36, .45);
  backdrop-filter: blur(6px);
}
.install-mark {
  width: 54px;
  height: 54px;
  display: grid;
  place-items: center;
  border-radius: 15px;
  background: #1a73e8;
  color: #fff;
  font-size: 25px;
  font-weight: 750;
}
.install-dialog h2 {
  margin: 14px 0 8px;
  font-size: 25px;
  font-weight: 600;
}
.install-dialog p {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.5;
}
.install-steps {
  margin: 14px 0 0;
  padding-left: 20px;
  font-size: 13px;
  line-height: 1.5;
}
.install-steps li + li {
  margin-top: 7px;
}
.install-actions {
  display: flex;
  gap: 8px;
  margin-top: 18px;
}
.install-hint {
  margin-bottom: 0;
  font-size: 11px !important;
}
.phone-tabs {
  position: fixed;
  z-index: 30;
  left: 50%;
  bottom: max(12px, env(safe-area-inset-bottom));
  display: grid;
  grid-template-columns: repeat(4, minmax(64px, 1fr));
  width: min(420px, calc(100% - 28px));
  min-height: 62px;
  transform: translateX(-50%);
  border: 1px solid rgba(32,33,36,.12);
  border-radius: 22px;
  background: rgba(255,255,255,.92);
  box-shadow: 0 12px 34px rgba(32,33,36,.22);
  backdrop-filter: blur(18px);
}
.phone-tabs .view-tab {
  min-height: 62px;
  padding: 0 12px;
  border-radius: 20px;
}
.phone-tabs .view-tab[aria-selected="true"] {
  background: rgba(26,115,232,.1);
}
.phone-tabs .view-tab[aria-selected="true"]::after {
  inset: auto 28px 8px;
  height: 2px;
  border-radius: 999px;
}
.gallery {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 2px;
}
.photo {
  margin: 0;
  border: 0;
  border-radius: 0;
  box-shadow: none;
}
.photo-meta { display: none; }
.photo-tags { top: 7px; left: 7px; right: 7px; }

@media (max-width: 700px) {
  main { width: 100%; }
  .connect-panel, .people { margin-inline: 14px; }
  .account-button { padding: 8px 10px; font-size: 12px; }
  .source-grid { grid-template-columns: 1fr 1fr; gap: 8px; }
  .source-card { display: block; min-height: 112px; padding: 14px; }
  .source-card > div:nth-child(2) p { display: none; }
  .source-icon { width: 36px; height: 36px; margin-bottom: 9px; }
  .source-card h3 { font-size: 16px; }
  .source-actions { gap: 4px; margin-top: 8px; }
  .source-actions .status { display: none; }
  .library .section-heading { padding-inline: 14px; }
  .gallery { grid-template-columns: repeat(3, 1fr); gap: 2px; }
  .gallery-date { padding-inline: 14px; margin-top: 22px; }
  .person-card { grid-template-columns: 1fr; }
  .person-actions { flex-wrap: wrap; }
  .library .section-heading { padding-right: 86px; }
  .library-actions { gap: 7px; }
  .install-button { padding: 7px 10px; }
  .gallery { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0; }
  .photo-tags { top: 5px; left: 5px; right: 5px; }
}
