:root {
  --oog-progress-teal: #2c3e47;
  --oog-progress-soft: #bdd4d4;
  --oog-progress-orange: #ff6f3c;
  --oog-progress-bg: #ffffff;
  --oog-progress-muted: #6f7b80;
  --oog-progress-border: rgba(44, 62, 71, 0.14);
  --oog-progress-side: 22px;
  --oog-progress-bottom: 22px;
  --oog-progress-z: 9000;
}

.oog-progress-root,
.oog-progress-root * {
  box-sizing: border-box;
}

.oog-progress-root[hidden] {
  display: none !important;
}

.oog-progress-root button,
.oog-progress-root input,
.oog-progress-root select {
  font-family: inherit;
  text-transform: none;
  letter-spacing: normal;
}

/*
 * Theme-conflict shield for the floating trigger.
 * Elementor and some themes style every <button> globally. The stronger,
 * tightly scoped rules below keep only this plugin control in OOG styling.
 */
html body .oog-progress-root button.oog-progress-trigger {
  all: unset;
  -webkit-appearance: none;
  appearance: none;
  box-sizing: border-box;
  position: fixed !important;
  z-index: var(--oog-progress-z) !important;
  bottom: calc(var(--oog-progress-bottom) + env(safe-area-inset-bottom, 0px)) !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: flex-start !important;
  gap: 11px !important;
  min-width: 0 !important;
  max-width: calc(100vw - 28px) !important;
  min-height: 58px !important;
  margin: 0 !important;
  padding: 9px 18px 9px 10px !important;
  border: 1px solid rgba(44, 62, 71, 0.16) !important;
  border-radius: 18px !important;
  background: #ffffff !important;
  background-color: #ffffff !important;
  background-image: none !important;
  color: var(--oog-progress-teal) !important;
  box-shadow: 0 10px 30px rgba(20, 37, 44, 0.15) !important;
  filter: none !important;
  font-family: inherit !important;
  font-size: 16px !important;
  font-style: normal !important;
  font-weight: 700 !important;
  line-height: 1.2 !important;
  letter-spacing: normal !important;
  text-align: left !important;
  text-decoration: none !important;
  text-shadow: none !important;
  text-transform: none !important;
  white-space: nowrap !important;
  opacity: 1 !important;
  cursor: pointer !important;
  transition: transform 0.18s ease, box-shadow 0.18s ease !important;
}

html body.oog-progress-position-right .oog-progress-root button.oog-progress-trigger {
  right: calc(var(--oog-progress-side) + env(safe-area-inset-right, 0px)) !important;
  left: auto !important;
}

html body.oog-progress-position-left .oog-progress-root button.oog-progress-trigger {
  right: auto !important;
  left: calc(var(--oog-progress-side) + env(safe-area-inset-left, 0px)) !important;
}

html body .oog-progress-root button.oog-progress-trigger:hover,
html body .oog-progress-root button.oog-progress-trigger:focus,
html body .oog-progress-root button.oog-progress-trigger:active {
  border-color: rgba(44, 62, 71, 0.22) !important;
  background: #ffffff !important;
  background-color: #ffffff !important;
  color: var(--oog-progress-teal) !important;
  box-shadow: 0 13px 34px rgba(20, 37, 44, 0.19) !important;
}

html body .oog-progress-root button.oog-progress-trigger:hover {
  transform: translateY(-2px) !important;
}

html body .oog-progress-root button.oog-progress-trigger:active {
  transform: translateY(0) !important;
}

html body .oog-progress-root button.oog-progress-trigger:focus-visible {
  outline: 3px solid rgba(255, 111, 60, 0.38) !important;
  outline-offset: 3px !important;
}

html body .oog-progress-root button.oog-progress-trigger::before,
html body .oog-progress-root button.oog-progress-trigger::after {
  display: none !important;
  content: none !important;
}

html body .oog-progress-root .oog-progress-trigger__icon {
  display: grid !important;
  flex: 0 0 38px !important;
  place-items: center !important;
  width: 38px !important;
  height: 38px !important;
  margin: 0 !important;
  padding: 0 !important;
  border: 0 !important;
  border-radius: 50% !important;
  background: rgba(189, 212, 212, 0.58) !important;
  color: var(--oog-progress-teal) !important;
  font-size: 21px !important;
  font-style: normal !important;
  font-weight: 800 !important;
  line-height: 1 !important;
}

html body .oog-progress-root .oog-progress-trigger__label {
  display: inline !important;
  margin: 0 !important;
  padding: 0 !important;
  color: var(--oog-progress-teal) !important;
  font-family: inherit !important;
  font-size: 16px !important;
  font-weight: 700 !important;
  line-height: 1.2 !important;
  letter-spacing: normal !important;
  text-transform: none !important;
  white-space: nowrap !important;
}

html body .oog-progress-root .oog-progress-trigger__count {
  display: inline !important;
  margin: 0 !important;
  padding: 0 !important;
  color: var(--oog-progress-orange) !important;
  font-family: inherit !important;
  font-size: 16px !important;
  font-weight: 700 !important;
  line-height: 1.2 !important;
  letter-spacing: normal !important;
  text-transform: none !important;
  white-space: nowrap !important;
}

.oog-progress-backdrop {
  position: fixed;
  z-index: calc(var(--oog-progress-z) + 1);
  inset: 0;
  background: rgba(24, 39, 45, 0.20);
}

.oog-progress-panel {
  position: fixed;
  z-index: calc(var(--oog-progress-z) + 2);
  top: 0;
  bottom: 0;
  width: min(390px, calc(100vw - 24px));
  margin: 0;
  padding: 24px 24px calc(24px + env(safe-area-inset-bottom, 0px));
  overflow-y: auto;
  overscroll-behavior: contain;
  background: var(--oog-progress-bg);
  color: var(--oog-progress-teal);
  box-shadow: 0 18px 55px rgba(20, 37, 44, 0.16);
  visibility: hidden;
  pointer-events: none;
  transition: transform 0.25s ease, visibility 0s linear 0.25s;
}

.oog-progress-position-right .oog-progress-panel {
  right: 0;
  transform: translateX(104%);
  border-radius: 18px 0 0 18px;
}

.oog-progress-position-left .oog-progress-panel {
  left: 0;
  transform: translateX(-104%);
  border-radius: 0 18px 18px 0;
}

.oog-progress-panel.is-open {
  transform: translateX(0);
  visibility: visible;
  pointer-events: auto;
  transition-delay: 0s;
}

body.oog-progress-open {
  overflow: hidden;
}

.oog-progress-panel__header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 18px;
  margin-bottom: 15px;
}

.oog-progress-panel h2 {
  margin: 0 0 4px;
  padding: 0;
  color: var(--oog-progress-teal);
  font-size: 24px;
  font-weight: 700;
  line-height: 1.2;
}

.oog-progress-panel__header p {
  margin: 0;
  color: var(--oog-progress-muted);
  font-size: 14px;
  line-height: 1.45;
}

html body .oog-progress-root button.oog-progress-close {
  appearance: none !important;
  flex: 0 0 auto !important;
  width: 38px !important;
  height: 38px !important;
  min-width: 38px !important;
  min-height: 38px !important;
  margin: 0 !important;
  padding: 0 !important;
  border: 0 !important;
  border-radius: 50% !important;
  background: #f1f5f5 !important;
  background-image: none !important;
  color: var(--oog-progress-teal) !important;
  box-shadow: none !important;
  font-family: inherit !important;
  font-size: 27px !important;
  font-weight: 400 !important;
  line-height: 1 !important;
  text-transform: none !important;
  cursor: pointer !important;
}

.oog-progress-meter {
  height: 8px;
  margin: 0 0 20px;
  overflow: hidden;
  border-radius: 999px;
  background: #e9eeee;
}

.oog-progress-meter span {
  display: block;
  width: 0;
  height: 100%;
  border-radius: inherit;
  background: var(--oog-progress-orange);
  transition: width 0.3s ease;
}

.oog-progress-current-action {
  margin: 0 0 14px;
}

html body .oog-progress-root .oog-progress-current-action button {
  appearance: none !important;
  width: 100% !important;
  margin: 0 !important;
  padding: 11px 14px !important;
  border: 0 !important;
  border-radius: 12px !important;
  background: var(--oog-progress-orange) !important;
  background-image: none !important;
  color: #ffffff !important;
  box-shadow: none !important;
  font-family: inherit !important;
  font-size: 14px !important;
  font-weight: 700 !important;
  line-height: 1.4 !important;
  text-transform: none !important;
  cursor: pointer !important;
}

.oog-progress-resume {
  margin: 0 0 20px;
  padding: 14px;
  border-radius: 14px;
  background: rgba(189, 212, 212, 0.32);
}

.oog-progress-resume span {
  display: block;
  margin-bottom: 4px;
  color: var(--oog-progress-muted);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.oog-progress-resume a,
.oog-progress-item a {
  color: var(--oog-progress-teal);
  text-decoration: none;
}

.oog-progress-resume a {
  font-weight: 700;
}

.oog-progress-resume a:hover,
.oog-progress-item a:hover {
  text-decoration: underline;
  text-underline-offset: 2px;
}

.oog-progress-section,
.oog-progress-route {
  padding: 17px 0;
  border-top: 1px solid var(--oog-progress-border);
}

.oog-progress-section h3,
.oog-progress-route h3 {
  margin: 0 0 10px;
  padding: 0;
  color: var(--oog-progress-teal);
  font-size: 12px;
  font-weight: 800;
  line-height: 1.3;
  letter-spacing: 0.07em;
  text-transform: uppercase;
}

.oog-progress-section ul,
.oog-progress-route ul {
  margin: 0;
  padding: 0;
  list-style: none;
}

.oog-progress-item {
  display: grid;
  grid-template-columns: 25px minmax(0, 1fr);
  align-items: start;
  gap: 9px;
  margin: 0;
  padding: 8px 0;
  font-size: 14px;
  line-height: 1.4;
}

.oog-progress-item__icon {
  display: grid;
  place-items: center;
  width: 21px;
  height: 21px;
  border: 1px solid var(--oog-progress-border);
  border-radius: 50%;
  color: #8b969a;
  font-size: 12px;
  font-weight: 800;
}

.oog-progress-item--read .oog-progress-item__icon {
  border-color: transparent;
  background: var(--oog-progress-soft);
  color: var(--oog-progress-teal);
}

.oog-progress-item--started .oog-progress-item__icon {
  border-color: rgba(255, 111, 60, 0.45);
  color: var(--oog-progress-orange);
}

.oog-progress-item--unread {
  opacity: 0.68;
}

.oog-progress-route__heading {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 14px;
}

.oog-progress-route__heading span {
  color: var(--oog-progress-muted);
  font-size: 12px;
  font-weight: 700;
}

.oog-progress-route__meter {
  height: 5px;
  margin: 0 0 10px;
  overflow: hidden;
  border-radius: 999px;
  background: #e9eeee;
}

.oog-progress-route__meter span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: var(--oog-progress-orange);
}

.oog-progress-local-note {
  margin: 18px 0 8px;
  color: var(--oog-progress-muted);
  font-size: 12px;
  line-height: 1.45;
}

html body .oog-progress-root button.oog-progress-reset {
  appearance: none !important;
  width: 100% !important;
  margin: 0 !important;
  padding: 11px 14px !important;
  border: 1px solid var(--oog-progress-border) !important;
  border-radius: 12px !important;
  background: #ffffff !important;
  background-image: none !important;
  color: var(--oog-progress-muted) !important;
  box-shadow: none !important;
  font-family: inherit !important;
  font-size: 13px !important;
  line-height: 1.4 !important;
  text-transform: none !important;
  cursor: pointer !important;
}

html body .oog-progress-root button.oog-progress-reset:hover,
html body .oog-progress-root button.oog-progress-reset:focus {
  border-color: rgba(44, 62, 71, 0.28) !important;
  background: #ffffff !important;
  color: var(--oog-progress-teal) !important;
}

.oog-progress-trigger:focus-visible,
.oog-progress-close:focus-visible,
.oog-progress-reset:focus-visible,
.oog-progress-panel a:focus-visible,
.oog-progress-current-action button:focus-visible {
  outline: 3px solid rgba(255, 111, 60, 0.35);
  outline-offset: 3px;
}

.admin-bar .oog-progress-panel {
  top: 32px;
}

@media (max-width: 782px) {
  .admin-bar .oog-progress-panel {
    top: 46px;
  }
}

@media (max-width: 767px) {
  html body .oog-progress-root button.oog-progress-trigger {
    gap: 8px !important;
    max-width: calc(100vw - 20px) !important;
    min-height: 52px !important;
    padding: 8px 13px 8px 8px !important;
    border-radius: 16px !important;
  }

  html body .oog-progress-root .oog-progress-trigger__icon {
    flex-basis: 34px !important;
    width: 34px !important;
    height: 34px !important;
    font-size: 18px !important;
  }

  html body .oog-progress-root .oog-progress-trigger__label,
  html body .oog-progress-root .oog-progress-trigger__count {
    display: inline !important;
    font-size: 13px !important;
  }

  .oog-progress-panel,
  .admin-bar .oog-progress-panel {
    top: auto;
    right: 0;
    bottom: 0;
    left: 0;
    width: 100%;
    max-height: 88vh;
    padding: 20px 20px calc(20px + env(safe-area-inset-bottom, 0px));
    border-radius: 20px 20px 0 0 !important;
    transform: translateY(104%);
  }

  .oog-progress-panel.is-open {
    transform: translateY(0);
  }
}

@media (prefers-reduced-motion: reduce) {
  html body .oog-progress-root button.oog-progress-trigger {
    transition: none !important;
  }

  .oog-progress-panel,
  .oog-progress-meter span {
    transition: none;
  }
}
