/* SCRUM-152: Google consent hint (dialog / bottom sheet) and the
   "One step missing" retry panel. Mobile first: works from 320 px, full-width
   buttons of at least 48 px, body text 16 px, and the actions stay visible
   (sticky) even on a phone in landscape. Dark like /connect and /user. */

body.gc-locked { overflow: hidden; }

.gc-overlay {
  position: fixed;
  inset: 0;
  z-index: 1000;
  background: rgba(0, 0, 0, 0.72);
  display: flex;
  align-items: flex-end;
  justify-content: center;
}

.gc-sheet {
  width: 100%;
  max-height: 100vh;
  max-height: 100dvh;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior: contain;
  background: #111;
  border: 1px solid #222;
  border-bottom: none;
  border-radius: 16px 16px 0 0;
  padding: 22px 16px 0;
  padding-left: max(16px, env(safe-area-inset-left));
  padding-right: max(16px, env(safe-area-inset-right));
}

@media (min-width: 600px) and (min-height: 520px) {
  .gc-overlay { align-items: center; padding: 24px; }
  .gc-sheet {
    max-width: 440px;
    max-height: calc(100vh - 48px);
    border-bottom: 1px solid #222;
    border-radius: 12px;
    padding: 28px 28px 0;
  }
}

.gc-panel { color: #fff; font-size: 16px; line-height: 1.45; }

.gc-panel-retry {
  background: #111;
  border: 1px solid #2a2a2a;
  border-radius: 10px;
  padding: 18px 16px 0;
  margin-bottom: 20px;
}

.gc-title {
  font-size: 1.2rem;
  font-weight: 700;
  margin: 0 0 8px;
  letter-spacing: -0.2px;
}
.gc-panel-retry .gc-title { color: #f5c26b; }

.gc-lead, .gc-instruction, .gc-why { margin: 0 0 10px; }
.gc-lead { color: #c9c9c9; }
.gc-instruction { color: #fff; }
.gc-instruction strong { color: var(--teal, #44bac1); }
.gc-why { color: #9a9a9a; font-size: 0.9rem; margin-top: 12px; }

/* The illustration: our colours, no Google branding, clearly an example. */
.gc-illus {
  position: relative;
  border: 1px dashed #3a3a3a;
  border-radius: 10px;
  padding: 14px 12px 6px;
  margin-top: 14px;
  background: #0b0b0b;
}
.gc-illus-tag {
  position: absolute;
  top: -9px;
  left: 10px;
  padding: 0 6px;
  background: #111;
  color: #8a8a8a;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.6px;
  text-transform: uppercase;
}
.gc-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 9px 2px;
  border-top: 1px solid #222;
  font-size: 0.92rem;
  color: #dcdcdc;
}
.gc-row-all { border-top: none; font-weight: 700; color: #fff; }
.gc-row-label { flex: 1; min-width: 0; overflow-wrap: anywhere; }
.gc-box {
  flex-shrink: 0;
  width: 22px;
  height: 22px;
  border-radius: 4px;
  background: var(--teal, #44bac1);
  position: relative;
}
.gc-box::after {
  content: "";
  position: absolute;
  left: 7px;
  top: 3px;
  width: 6px;
  height: 11px;
  border: solid #0a0a0a;
  border-width: 0 3px 3px 0;
  transform: rotate(45deg);
}

/* Actions stay in view while the rest scrolls (phones in landscape). */
.gc-actions {
  position: sticky;
  bottom: 0;
  background: #111;
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 14px 0 16px;
  padding-bottom: max(16px, env(safe-area-inset-bottom));
  margin-top: 4px;
}
.gc-primary, .gc-secondary {
  width: 100%;
  min-height: 48px;
  border-radius: 8px;
  font-family: inherit;
  font-size: 16px;
  font-weight: 700;
  cursor: pointer;
  touch-action: manipulation;
}
.gc-primary { background: #fff; color: #1f1f1f; border: none; }
.gc-primary:disabled { opacity: 0.7; cursor: progress; }
.gc-secondary { background: transparent; color: #bdbdbd; border: 1px solid #333; font-weight: 600; }
.gc-primary:focus-visible, .gc-secondary:focus-visible {
  outline: 2px solid var(--teal, #44bac1);
  outline-offset: 2px;
}

/* /connect in retry mode: the panel comes first, nothing to scroll past. */
.card.gc-retry-mode .logo,
.card.gc-retry-mode .subheading { display: none; }
.card.gc-retry-mode .heading { margin-bottom: 16px; }
/* The panel's button is the Google way back in; a second Google button
   below it would only compete. Microsoft and Apple stay as alternatives. */
.card.gc-retry-mode #btnGoogle { display: none; }

/* Phones: the retry panel already sits in the /connect card -- no second
   frame eating the narrow width. */
@media (max-width: 480px) {
  .gc-panel-retry { border: none; background: transparent; padding: 0; }
}

/* Low phone in landscape: less chrome around the content. */
@media (max-height: 480px) {
  .gc-sheet { padding-top: 14px; }
  .gc-title { font-size: 1.05rem; margin-bottom: 4px; }
  .gc-lead, .gc-instruction { margin-bottom: 6px; }
  .gc-illus { margin-top: 10px; }
  .gc-row { padding: 6px 2px; }
}
