/* DogPet widget - the strip the puppy lives in. Host page decides the size/position of .dogpet. */
.dogpet, .dogpet *, .dp-test, .dp-test * { -webkit-tap-highlight-color: transparent; }
.dogpet {
  -webkit-touch-callout: none; outline: none;
  position: relative; overflow: hidden; user-select: none; -webkit-user-select: none;
  font: 600 12px/1.2 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; color: #4a3424;
  background: linear-gradient(to top, rgba(247, 236, 219, 0.97) 0%, rgba(247, 236, 219, 0.85) 22%, rgba(247, 236, 219, 0) 70%);
}
.dogpet .dp-canvas { position: absolute; inset: 0; width: 100%; height: 100%; touch-action: pan-y; cursor: pointer; }
.dogpet .dp-ui { position: absolute; left: 8px; top: 8px; display: flex; gap: 6px; z-index: 2; }
.dogpet .dp-ui button {
  display: inline-flex; align-items: center; gap: 4px; padding: 6px 10px; border: 0; border-radius: 999px;
  background: rgba(255, 255, 255, 0.82); box-shadow: 0 1px 4px rgba(90, 60, 30, 0.18); color: inherit; font: inherit;
  cursor: pointer; backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); transition: transform .12s, background .12s;
}
.dogpet .dp-ui button:hover { background: #fff; transform: translateY(-1px); }
.dogpet .dp-ui button:active { transform: scale(0.95); }
.dogpet .dp-ui button:focus-visible { outline: 2px solid #e07a2a; outline-offset: 2px; }
.dogpet .dp-gifts {
  position: absolute; left: 8px; right: 8px; top: 46px; z-index: 6; margin: 0 auto; max-width: 620px;
  padding: 8px 10px 10px; border-radius: 18px; background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); box-shadow: 0 6px 22px rgba(90, 60, 30, 0.22);
  animation: dpPop .16s ease-out;
}
@keyframes dpPop { from { opacity: 0; transform: translateY(-6px) scale(.98); } to { opacity: 1; transform: none; } }
.dogpet .dp-gifts[hidden] { display: none; }
.dogpet .dp-gifts-head { display: flex; align-items: center; justify-content: space-between; margin: 0 2px 6px; font-weight: 700; }
.dogpet .dp-gifts-x { border: 0; background: transparent; color: inherit; font: inherit; cursor: pointer; padding: 2px 6px;
  border-radius: 999px; }
.dogpet .dp-gifts-x:hover { background: #f4e7d8; }
.dogpet .dp-gifts-row { display: flex; flex-wrap: wrap; gap: 6px; justify-content: center; }
.dogpet .dp-gifts-row button {
  display: flex; flex-direction: column; align-items: center; gap: 2px; width: 60px; padding: 6px 2px 5px; border: 0;
  border-radius: 12px; background: #fbf3e8; color: inherit; font: inherit; cursor: pointer;
  box-shadow: 0 1px 3px rgba(90, 60, 30, 0.12); transition: transform .12s, background .12s, box-shadow .12s;
}
.dogpet .dp-gifts-row button b { font-size: 26px; line-height: 30px; font-weight: 400; }
.dogpet .dp-gifts-row button i { font-style: normal; font-size: 10px; opacity: .75; white-space: nowrap; }
.dogpet .dp-gifts-row button:hover { background: #f6e1c8; transform: translateY(-2px); box-shadow: 0 4px 10px rgba(90, 60, 30, 0.18); }
.dogpet .dp-gifts-row button:active { transform: scale(.94); }
.dogpet .dp-gifts-row button:focus-visible { outline: 2px solid #e07a2a; outline-offset: 2px; }
@media (max-width: 560px) { .dogpet .dp-gifts-row button { width: 50px; } .dogpet .dp-gifts-row button i { display: none; } }
.dp-test {
  font: 600 12px/1.2 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; color: #4a3424;
  position: absolute; right: 8px; top: 64px; bottom: 8px; z-index: 5; width: 270px; display: flex; flex-direction: column;
  border-radius: 16px; background: rgba(255, 255, 255, 0.88); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
  box-shadow: 0 6px 20px rgba(90, 60, 30, 0.2); overflow: hidden;
}
.dp-test.min { bottom: auto; }
.dp-test.min .dp-test-grid { display: none; }
.dp-test-head { display: flex; align-items: center; gap: 8px; padding: 7px 8px 5px 12px; }
.dp-test-head b { flex: 1; font-size: 12px; }
.dp-test-head label { display: flex; align-items: center; gap: 3px; font-size: 11px; cursor: pointer; }
.dp-test-min { border: 0; background: #f4e7d8; color: inherit; border-radius: 999px; width: 22px; height: 22px;
  cursor: pointer; font: inherit; line-height: 1; }
.dp-test-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 5px; padding: 2px 8px 8px; overflow-y: auto; }
.dp-test-grid button {
  border: 0; border-radius: 9px; padding: 5px 2px; background: #fbf3e8; color: inherit; font: inherit; font-size: 11px;
  cursor: pointer; white-space: nowrap; box-shadow: 0 1px 2px rgba(90, 60, 30, 0.1); transition: background .12s, transform .12s;
}
.dp-test-grid button:hover { background: #f6e1c8; transform: translateY(-1px); }
.dp-test-grid button.on { background: #e07a2a; color: #fff; }
@media (max-width: 700px) { .dp-test { width: 200px; } .dp-test-grid { grid-template-columns: repeat(2, 1fr); } }
.dogpet .dp-meters { position: absolute; right: 10px; top: 10px; display: grid; gap: 3px; z-index: 2; pointer-events: none; }
.dogpet .dp-meters div { display: flex; align-items: center; gap: 4px; font-size: 11px; }
.dogpet .dp-meters i { display: block; width: 54px; height: 6px; border-radius: 3px; background: rgba(120, 80, 40, 0.15); overflow: hidden; }
.dogpet .dp-meters b { display: block; height: 100%; width: 50%; border-radius: 3px; background: linear-gradient(90deg, #f3a43b, #e9692c);
  transition: width .6s; }
.dogpet .dp-tap {
  position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); z-index: 3; padding: 10px 16px;
  border-radius: 999px; background: rgba(255, 255, 255, 0.95); box-shadow: 0 2px 10px rgba(90, 60, 30, 0.25); cursor: pointer;
}
.dogpet .dp-videos { position: absolute; left: 0; top: 0; width: 1px; height: 1px; overflow: hidden; opacity: 0; pointer-events: none; }
.dogpet .dp-videos video { width: 1px; height: 1px; }
@media (max-width: 560px) {
  .dogpet .dp-ui button span { display: none; }
  .dogpet .dp-ui button { padding: 6px 8px; }
  .dogpet .dp-meters i { width: 38px; }
}

/* phones: the test panel floats ABOVE the strip (it covered the dog and the bowl) */
.dp-test.float { position: fixed; top: auto; right: 8px; width: min(320px, calc(100% - 16px)); max-height: 46vh; z-index: 30; }
.dp-test.float .dp-test-grid { grid-template-columns: repeat(3, 1fr); }
.dogpet .dp-canvas:focus, .dogpet .dp-canvas:active { outline: none; }

/* first-load popup: Floopy is coming + circular progress */
.dogpet .dp-loading { position: absolute; inset: 0; z-index: 8; display: flex; align-items: center; justify-content: center;
  pointer-events: none; transition: opacity .4s; }
.dogpet .dp-loading.done { opacity: 0; }
.dogpet .dp-loading-card { display: flex; align-items: center; gap: 14px; padding: 12px 20px 12px 12px; border-radius: 999px;
  background: rgba(255, 255, 255, 0.94); box-shadow: 0 8px 26px rgba(90, 60, 30, 0.22); animation: dpPop .2s ease-out; }
.dogpet .dp-ring { position: relative; width: 74px; height: 74px; flex: none; }
.dogpet .dp-ring svg { position: absolute; inset: 0; transform: rotate(-90deg); }
.dogpet .dp-ring circle { fill: none; stroke-width: 7; }
.dogpet .dp-ring .bg { stroke: #f1e3d2; }
.dogpet .dp-ring .fg { stroke: #e07a2a; stroke-linecap: round; stroke-dasharray: 282.74; stroke-dashoffset: 282.74;
  transition: stroke-dashoffset .25s; }
.dogpet .dp-ring img { position: absolute; inset: 9px; width: 56px; height: 56px; border-radius: 50%; object-fit: cover;
  background: #fbf0e2; }
.dogpet .dp-loading-txt { display: flex; flex-direction: column; gap: 3px; }
.dogpet .dp-loading-txt b { font-size: 15px; }
.dogpet .dp-loading-txt span { font-size: 12px; opacity: .7; }
