/* Web review page (review.recapbooks.com). System fonts only: the page's
   Content-Security-Policy allows styles and fonts from this site alone. */
* { box-sizing: border-box; margin: 0; padding: 0; }

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
    background: #f5f7fa;
    color: #333;
    min-height: 100vh;
    display: flex;
    justify-content: center;
    padding: 24px 16px;
    line-height: 1.5;
}

.card {
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
    padding: 32px 24px;
    width: 100%;
    max-width: 640px;
    align-self: flex-start;
}

.logo { text-align: center; margin-bottom: 24px; }
.logo img { max-width: 180px; height: auto; }
.logo h1 { font-size: 26px; font-weight: 600; color: #2456A7; margin-top: 12px; }
.logo .sub { font-size: 14px; color: #666; }

.view h2 { font-size: 20px; color: #2456A7; margin-bottom: 8px; }
.view p { font-size: 16px; margin-bottom: 12px; }
.muted { color: #666; text-align: center; }
.muted-left { color: #666; font-size: 14px; }
.hidden { display: none !important; }   /* always wins over a component's display */

/* Groups picker */
.sticky {
    position: sticky;
    top: 0;
    background: #fff;
    padding: 10px 0;
    border-bottom: 1px solid #e3e8f0;
    margin-bottom: 12px;
    z-index: 2;
}
.estimate { font-size: 18px; font-weight: 600; color: #2456A7; margin-bottom: 4px; }
.row { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; }
.status { font-size: 14px; color: #666; margin-left: auto; }

button { font: inherit; cursor: pointer; }
button:focus-visible { outline: 3px solid #2456A7; outline-offset: 2px; }
.link { background: none; border: none; color: #2456A7; text-decoration: underline; padding: 8px 4px; min-height: 44px; }
.primary { background: #2456A7; color: #fff; border: none; border-radius: 8px; padding: 12px 28px; min-height: 48px; font-weight: 600; }
.primary:disabled { opacity: 0.6; cursor: default; }
.secondary { background: #fff; color: #2456A7; border: 2px solid #2456A7; border-radius: 8px; padding: 10px 22px; min-height: 48px; }

.group { border: 1px solid #e3e8f0; border-radius: 10px; padding: 14px; margin-bottom: 12px; }
.group.removed { background: #f7f7f7; }
.group.removed .group-name, .group.removed .group-meta { color: #999; text-decoration: line-through; }
.group.removed .samples { opacity: 0.35; }
.group-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; }
.group-name { font-size: 17px; font-weight: 600; color: #222; overflow-wrap: anywhere; }
.group-meta { font-size: 14px; color: #666; margin: 0; }

.switch {
    flex: 0 0 auto;
    min-width: 104px;
    min-height: 44px;
    border-radius: 22px;
    border: 2px solid #2456A7;
    background: #2456A7;
    color: #fff;
    font-weight: 600;
    padding: 8px 14px;
}
.switch[aria-pressed="false"] { background: #fff; color: #a33; border-color: #a33; }

.samples { display: flex; gap: 8px; margin-top: 10px; }
.sample {
    width: calc((100% - 16px) / 3);
    aspect-ratio: 1 / 1;
    object-fit: cover;
    border-radius: 6px;
    background: #eef2f8;
}

.done-row { text-align: center; margin: 20px 0 8px; }
.confirm {
    border: 2px solid #2456A7;
    border-radius: 10px;
    padding: 16px;
    margin-top: 12px;
    background: #f5f8fd;
}
.confirm h3 { font-size: 18px; color: #2456A7; margin-bottom: 6px; }

/* Posts step */
.notice { background: #eef6ee; border: 1px solid #b9dcb9; border-radius: 8px; padding: 12px; }
.panel { border: 1px solid #e3e8f0; border-radius: 10px; padding: 14px; margin: 14px 0; }
.panel h3 { font-size: 17px; color: #2456A7; margin-bottom: 6px; }
.field-label { font-size: 14px; font-weight: 600; color: #444; margin: 8px 0 4px; display: block; }
input[type="text"], select {
    font: inherit; font-size: 16px; padding: 10px; border: 1px solid #c7d0dd; border-radius: 8px;
    min-height: 44px; max-width: 100%;
}
input[type="text"] { width: 100%; margin-bottom: 8px; }
.primary.small { padding: 8px 18px; min-height: 44px; }
.tools { display: flex; flex-wrap: wrap; gap: 8px; margin: 8px 0; }
.tool {
    background: #fff; color: #2456A7; border: 1px solid #2456A7; border-radius: 20px;
    padding: 8px 14px; min-height: 44px; font-size: 15px;
}
.tool[aria-pressed="true"] { background: #fdeeee; color: #a33; border-color: #a33; }
.filters { margin-top: 6px; }
.cover-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(84px, 1fr)); gap: 8px; }
.cover-pick { padding: 0; border: 3px solid transparent; border-radius: 8px; background: none; line-height: 0; }
.cover-pick[aria-pressed="true"] { border-color: #2456A7; box-shadow: 0 0 0 2px #fff inset; }
.cover-thumb { width: 100%; aspect-ratio: 1 / 1; object-fit: cover; border-radius: 5px; background: #eef2f8; }

.year { margin-top: 18px; }
.year-head {
    display: flex; align-items: center; justify-content: space-between; gap: 12px;
    border-bottom: 2px solid #2456A7; padding-bottom: 6px; margin-bottom: 10px;
}
.year-title { font-size: 22px; color: #2456A7; }
.year-meta { font-size: 14px; color: #666; margin: 0; }

.post { border: 1px solid #e3e8f0; border-radius: 10px; padding: 12px; margin-bottom: 10px; }
.post.removed { background: #f7f7f7; }
.post.removed .post-info, .post.removed .post-text { color: #999; text-decoration: line-through; }
.post.removed .photos { opacity: 0.3; }
.post-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; }
.post-date { font-weight: 600; margin: 0; }
.post-title { font-size: 14px; color: #666; margin: 0; overflow-wrap: anywhere; }
.post-text { margin: 8px 0 0; white-space: pre-line; overflow-wrap: anywhere; }
.remove {
    flex: 0 0 auto; min-width: 96px; min-height: 44px; border-radius: 22px;
    border: 2px solid #a33; background: #fff; color: #a33; font-weight: 600; padding: 8px 14px;
}
.remove[aria-pressed="true"] { background: #2456A7; border-color: #2456A7; color: #fff; }
.photos { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; margin-top: 10px; position: relative; }
.thumb { width: 100%; aspect-ratio: 1 / 1; object-fit: cover; border-radius: 6px; background: #eef2f8; }
.more { align-self: center; justify-self: center; color: #666; font-weight: 600; }
.done-row .secondary { margin-left: 10px; }
