/* ---------------------------------------------------------------------------
   Redgum Review — private book review area overlay styles.
   Loaded after style.css and components.css, so these rules can override.
--------------------------------------------------------------------------- */

/* --- Review header --- */
.review-header {
  background: var(--c-gum, #20241f);
  border-bottom: 3px solid var(--c-red, #D31145);
  padding: 0.75rem 1.5rem;
}
.review-header-inner {
  max-width: 1280px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 1rem;
}
.review-badge {
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--c-red, #D31145);
  background: rgba(211,17,69,0.12);
  border: 1px solid rgba(211,17,69,0.35);
  border-radius: 4px;
  padding: 0.2em 0.55em;
}

/* --- Review footer --- */
.review-footer {
  background: var(--c-gum, #20241f);
  color: #8a9490;
  padding: 1rem 1.5rem;
  font-size: 0.82rem;
  margin-top: 3rem;
}
.review-footer-inner {
  max-width: 1280px;
  margin: 0 auto;
  display: flex;
  gap: 1.5rem;
  align-items: center;
  flex-wrap: wrap;
}
.review-footer a { color: #8a9490; }
.review-footer-note { flex: 1; }

/* --- Landing page --- */
.review-landing { padding: 2rem 1.5rem; }
.review-books { display: grid; gap: 2.5rem; margin-top: 2rem; }
.review-book h2 { margin-bottom: 0.5rem; }
.review-chapter-list {
  list-style: decimal;
  padding-left: 1.5rem;
  margin-top: 0.75rem;
}
.review-chapter-item {
  padding: 0.4rem 0;
  font-size: 1rem;
  line-height: 1.5;
}
.review-chapter-item a {
  color: var(--c-euca, #22423a);
  font-weight: 500;
  text-decoration: none;
}
.review-chapter-item a:hover { text-decoration: underline; }
.review-chapter-item.coming-soon { color: #9aa49f; }
.chapter-status-badge {
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #9aa49f;
  margin-left: 0.5em;
}

/* --- Chapter shell --- */
.review-chapter-shell {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

/* --- Chapter navigation bar --- */
.review-nav {
  background: var(--c-euca-light, #eef3f0);
  border-bottom: 1px solid #ccd8d3;
  padding: 0.6rem 1.5rem;
  font-size: 0.85rem;
}
.review-nav-bottom {
  border-top: 1px solid #ccd8d3;
  border-bottom: none;
  margin-top: 2rem;
}
.review-nav-inner {
  max-width: 1280px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 1.25rem;
  flex-wrap: wrap;
}
.review-nav-link { color: var(--c-euca, #22423a); text-decoration: none; font-weight: 500; }
.review-nav-link:hover { text-decoration: underline; }
.review-nav-home { color: #5a6e69; text-decoration: none; }
.review-nav-home:hover { text-decoration: underline; }
.review-nav-next { margin-left: auto; }
.review-nav-feedback-jump {
  margin-left: auto;
  font-weight: 600;
  color: var(--c-red, #D31145);
  text-decoration: none;
  display: none; /* shown on mobile via media query */
}
.review-nav-feedback-jump:hover { text-decoration: underline; }

/* --- Split layout --- */
.review-split {
  flex: 1;
  display: grid;
  grid-template-columns: 1fr;
  gap: 0;
  max-width: 100%;
}

@media (min-width: 960px) {
  .review-split {
    grid-template-columns: 2fr 1fr;
    align-items: start;
  }
  .review-nav-feedback-jump { display: none !important; }
}

@media (max-width: 959px) {
  .review-nav-feedback-jump { display: inline; }
  .review-nav-next { margin-left: 0; }
}

/* --- Chapter content column --- */
.review-content {
  padding: 2rem 2rem 3rem;
  max-width: 780px;
}
.review-chapter-label {
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: #5a6e69;
  margin-bottom: 0.25rem;
}

/* --- Feedback panel --- */
.review-panel {
  background: #f5f8f6;
  border-left: 1px solid #ccd8d3;
  position: sticky;
  top: 0;
  max-height: 100vh;
  overflow-y: auto;
  padding: 0;
}
@media (max-width: 959px) {
  .review-panel {
    position: static;
    max-height: none;
    border-left: none;
    border-top: 2px solid var(--c-red, #D31145);
  }
}
.review-panel-inner {
  padding: 1.5rem 1.25rem 2rem;
}
.review-panel-heading {
  font-size: 1rem;
  font-weight: 700;
  color: var(--c-gum, #20241f);
  margin: 0 0 0.25rem;
}
.review-panel-hint {
  font-size: 0.82rem;
  color: #6b7e78;
  margin: 0 0 1.25rem;
}

/* --- Feedback form --- */
.review-form { display: flex; flex-direction: column; gap: 0.9rem; }
.review-field { display: flex; flex-direction: column; gap: 0.3rem; }
.review-field label {
  font-size: 0.82rem;
  font-weight: 600;
  color: #3a4e49;
}
.review-field-hint { font-weight: 400; color: #7a8e88; }
.review-input, .review-textarea {
  border: 1px solid #b8c8c3;
  border-radius: 6px;
  padding: 0.55rem 0.7rem;
  font-size: 0.92rem;
  font-family: inherit;
  background: #fff;
  color: var(--c-gum, #20241f);
  width: 100%;
  box-sizing: border-box;
}
.review-input:focus, .review-textarea:focus {
  outline: 2px solid var(--c-euca, #22423a);
  outline-offset: 1px;
  border-color: var(--c-euca, #22423a);
}
.review-textarea { resize: vertical; min-height: 120px; }
.review-submit {
  background: var(--c-red, #D31145);
  color: #fff;
  border: none;
  border-radius: 6px;
  padding: 0.65rem 1.25rem;
  font-size: 0.92rem;
  font-weight: 700;
  cursor: pointer;
  font-family: inherit;
  align-self: flex-start;
}
.review-submit:hover { background: #b80e39; }
.review-submit:disabled { opacity: 0.6; cursor: not-allowed; }
.review-form-status {
  font-size: 0.82rem;
  color: var(--c-euca, #22423a);
  min-height: 1.2em;
  margin: 0;
}

/* --- Notes list (round 2+) --- */
.review-notes { margin-top: 2rem; border-top: 1px solid #ccd8d3; padding-top: 1.25rem; }
.review-notes-heading { font-size: 0.88rem; font-weight: 700; color: #3a4e49; margin: 0 0 0.75rem; }
.review-note {
  background: #fff;
  border: 1px solid #d4e0da;
  border-radius: 6px;
  padding: 0.75rem 0.9rem;
  margin-bottom: 0.75rem;
}
.review-note-addressed { opacity: 0.6; }
.review-note-meta {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
  margin-bottom: 0.4rem;
}
.review-note-name { font-weight: 700; font-size: 0.82rem; color: #20241f; }
.review-note-time { font-size: 0.78rem; color: #7a8e88; }
.review-note-version {
  font-size: 0.72rem;
  color: #9aada8;
  background: #eef3f0;
  border-radius: 4px;
  padding: 0.1em 0.4em;
}
.review-note-addressed-badge {
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: #fff;
  background: var(--c-euca, #22423a);
  border-radius: 4px;
  padding: 0.1em 0.5em;
}
.review-note-body { font-size: 0.88rem; line-height: 1.6; color: #20241f; }
.review-notes-loading, .review-notes-empty, .review-notes-error {
  font-size: 0.82rem;
  color: #7a8e88;
  margin: 0.5rem 0;
}

/* --- v1.1 (2026-08-24): branded header badge, writing-as line, context chip --- */

/* Badge now sits in the main site's white header bar */
header.site .review-badge { margin-left: 4px; }

.review-writing-as {
  font-size: 0.85rem;
  color: #5a635e;
  margin: 0 0 0.75rem;
}
.review-writing-as strong { color: var(--ink, #20241f); }

.review-linklike {
  background: none;
  border: none;
  padding: 0;
  margin-left: 0.35em;
  font: inherit;
  font-size: 0.82rem;
  color: var(--sage-text, #22423a);
  text-decoration: underline;
  cursor: pointer;
}

.review-context-chip {
  display: inline-block;
  font-size: 0.78rem;
  color: #5a635e;
  background: #f0f3f1;
  border: 1px solid #dde3df;
  border-radius: 999px;
  padding: 0.2em 0.75em;
  margin: 0 0 0.75rem;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.review-note-context {
  font-size: 0.76rem;
  color: #7a837e;
  font-style: italic;
  margin-bottom: 0.25rem;
}

/* The hidden attribute must always win over display rules above */
.review-panel [hidden] { display: none !important; }

/* --- v1.2 (2026-08-24): book artwork --- */
.review-book.has-cover {
  display: grid;
  grid-template-columns: 250px 1fr;
  gap: 2.25rem;
  align-items: start;
}
.review-book-cover {
  width: 100%;
  height: auto;
  border-radius: 6px;
  box-shadow: 0 6px 24px rgba(32,36,31,0.18);
}
@media (max-width: 720px) {
  .review-book.has-cover { grid-template-columns: 1fr; }
  .review-book-cover { max-width: 260px; margin: 0 auto; }
}
.review-chapter-art {
  width: 100%;
  height: auto;
  border-radius: 8px;
  margin: 0.5rem 0 1.75rem;
}
