[hidden] {
  display: none !important;
}
:root {
  font-family: Arial, Helvetica, sans-serif;
  color: #30222c;
  background: #f7f5f7;
  font-synthesis: none;
  --wine: #6d1749;
  --rose: #f5e5ee;
  --line: #e6dce3;
  --muted: #70646d;
  --white: #fff;
  --gold: #bc7d32;
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
  font-size: 16px;
  line-height: 1.55;
}
button,
input,
select,
textarea {
  font: inherit;
}
a {
  color: var(--wine);
}
button,
a,
input,
textarea,
select {
  touch-action: manipulation;
}
button,
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  border: 1px solid transparent;
  border-radius: 10px;
  padding: 11px 18px;
  background: var(--wine);
  color: #fff;
  font-weight: 700;
  cursor: pointer;
  text-decoration: none;
  min-height: 44px;
}
button:disabled {
  opacity: 0.55;
  cursor: not-allowed;
}
button.secondary,
.button.secondary {
  background: var(--rose);
  color: var(--wine);
}
button.quiet {
  background: transparent;
  color: var(--wine);
  border-color: var(--line);
}
button.danger {
  background: #fff;
  color: #a02439;
  border-color: #edcbd0;
}
:focus-visible {
  outline: 3px solid #ce913d;
  outline-offset: 3px;
}
input,
select,
textarea {
  border: 1px solid #cdbdca;
  border-radius: 9px;
  padding: 11px 12px;
  color: inherit;
  background: #fff;
  width: 100%;
  min-width: 0;
}
textarea {
  resize: vertical;
  min-height: 120px;
}
input[type="checkbox"] {
  width: 20px;
  height: 20px;
  margin: 0;
  accent-color: var(--wine);
}
label {
  display: block;
  font-size: 15px;
  font-weight: 700;
  margin-bottom: 7px;
}
h1,
h2,
h3,
p {
  margin-top: 0;
}
h1,
h2 {
  font-family: Georgia, serif;
  font-weight: 400;
  line-height: 1.15;
  letter-spacing: -0.025em;
}
h1 {
  font-size: clamp(2rem, 4vw, 3.1rem);
  margin-bottom: 12px;
}
h2 {
  font-size: 1.75rem;
  margin-bottom: 15px;
}
h3 {
  font-size: 1.05rem;
  margin-bottom: 8px;
}
small,
.small {
  font-size: 14px;
  color: var(--muted);
}
.muted {
  color: var(--muted);
}
.overline {
  text-transform: uppercase;
  font-size: 12px;
  letter-spacing: 0.15em;
  font-weight: 700;
}
.layout {
  display: grid;
  grid-template-columns: 240px minmax(0, 1fr);
  min-height: 100vh;
}
.rail {
  background: #35112a;
  color: white;
  padding: 30px 20px;
  display: flex;
  flex-direction: column;
  position: sticky;
  top: 0;
  height: 100vh;
}
.brand {
  font-family: Georgia, serif;
  font-size: 27px;
  text-decoration: none;
  color: inherit;
  margin-bottom: 3px;
}
.rail .overline {
  color: #e4b1cf;
}
.nav {
  display: grid;
  gap: 6px;
  margin-top: 36px;
}
.nav button {
  justify-content: flex-start;
  text-align: left;
  background: transparent;
  color: #d9c8d4;
  font-size: 15px;
  padding: 12px 14px;
}
.nav button.active {
  background: #fff;
  color: #57133c;
}
.rail-bottom {
  margin-top: auto;
  padding-top: 30px;
  font-size: 14px;
}
.rail-bottom button {
  margin-top: 14px;
  color: #fff;
  border-color: #755466;
  width: 100%;
}
.workspace {
  max-width: 1260px;
  width: 100%;
  padding: 35px 45px 70px;
  margin: 0 auto;
}
.top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 28px;
}
.top p {
  margin-bottom: 5px;
}
.badge {
  font-size: 13px;
  font-weight: 700;
  display: inline-flex;
  padding: 6px 10px;
  border-radius: 7px;
  background: var(--rose);
  color: var(--wine);
  white-space: nowrap;
}
.context {
  display: grid;
  grid-template-columns: minmax(180px, 1fr) minmax(150px, 220px);
  gap: 15px;
  margin-bottom: 24px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 16px;
}
.card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 15px;
  padding: 25px;
  margin-bottom: 20px;
}
.focus-card {
  background: var(--wine);
  color: white;
  border: 0;
}
.focus-card .muted,
.focus-card .small {
  color: #ebd7e4;
}
.focus-card .overline {
  color: #eabe8c;
}
.focus-card blockquote {
  font-family: Georgia, serif;
  font-size: 1.8rem;
  line-height: 1.4;
  margin: 14px 0 0;
}
.grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}
.grid.three {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}
.field {
  margin-bottom: 20px;
}
.field:last-child {
  margin-bottom: 0;
}
.check {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 400;
  margin-top: 10px;
}
.actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 20px;
}
.help {
  font-size: 14px;
  color: var(--muted);
  margin: 8px 0 0;
}
.note {
  padding: 14px 17px;
  background: #f9eef4;
  border-left: 3px solid var(--wine);
  border-radius: 6px;
  margin-bottom: 20px;
}
.success {
  color: #146046;
}
.empty {
  padding: 28px 12px;
  color: var(--muted);
  text-align: center;
}
.entry {
  border-top: 1px solid var(--line);
  padding: 20px 0;
}
.entry:first-child {
  border-top: 0;
  padding-top: 0;
}
.entry:last-child {
  padding-bottom: 0;
}
.prose {
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}
.stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
  margin-bottom: 24px;
}
.stat {
  border: 1px solid var(--line);
  background: #fff;
  padding: 16px;
  border-radius: 12px;
}
.stat strong {
  display: block;
  font-family: Georgia, serif;
  font-size: 2rem;
  line-height: 1.2;
}
.stat span {
  font-size: 13px;
  color: var(--muted);
}
.photo {
  width: 100%;
  aspect-ratio: 3/4;
  object-fit: contain;
  background: #f5f1f4;
  border-radius: 9px;
}
.placeholder {
  aspect-ratio: 3/4;
  border: 1px dashed #c5afbe;
  border-radius: 9px;
  display: grid;
  place-items: center;
  color: var(--muted);
  padding: 20px;
  text-align: center;
}
.photo-card .actions {
  gap: 6px;
  margin-top: 12px;
}
.photo-card button {
  padding: 9px 12px;
  font-size: 14px;
}
.photo-card input[type="file"] {
  font-size: 14px;
  padding: 8px;
  margin-top: 12px;
}
.photo-card .field {
  margin: 0;
}
.guide {
  width: 100%;
  height: auto;
  border-radius: 10px;
  display: block;
}
.table-wrap {
  overflow: auto;
}
table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
  font-size: 14px;
}
th,
td {
  padding: 12px 10px;
  border-bottom: 1px solid var(--line);
  vertical-align: top;
}
th {
  font-weight: 700;
  white-space: nowrap;
}
td {
  min-width: 80px;
}
progress {
  width: 100%;
  height: 8px;
  accent-color: var(--wine);
  border: 0;
}
.login {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 1fr 1fr;
}
.login-art {
  background: #35112a;
  color: white;
  padding: 10vh 8vw;
  display: flex;
  flex-direction: column;
  justify-content: center;
}
.login-art .brand {
  margin-bottom: 60px;
}
.login-art h1 {
  font-size: clamp(2.8rem, 5vw, 4.8rem);
  max-width: 650px;
}
.login-art p {
  max-width: 460px;
  color: #e3cedc;
}
.login-panel {
  padding: 10vh 7vw;
  display: flex;
  flex-direction: column;
  justify-content: center;
}
.login-panel .button {
  align-self: flex-start;
  margin: 16px 0;
}
.loading {
  display: grid;
  place-items: center;
  min-height: 70vh;
}
.member-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 16px;
  padding: 18px 0;
  border-bottom: 1px solid var(--line);
}
.member-row p {
  margin-bottom: 4px;
}
.member-row .actions {
  margin: 0;
}
.member-search {
  margin-bottom: 16px;
}
.compare {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}
.inline {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}
.inline > label {
  margin: 0;
}
.pill-group {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.pill-group label {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0;
  border: 1px solid var(--line);
  padding: 8px 12px;
  border-radius: 8px;
}
.pill-group input {
  width: auto;
}
#status {
  position: fixed;
  bottom: 22px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 99;
  max-width: 90vw;
  background: #30222c;
  color: #fff;
  padding: 13px 22px;
  border-radius: 10px;
  box-shadow: 0 8px 32px #0003;
}
#status.error {
  background: #8a2036;
}
dialog {
  border: 0;
  border-radius: 16px;
  padding: 24px;
  max-width: min(1000px, 94vw);
  max-height: 92vh;
  overflow: auto;
  width: 100%;
}
dialog::backdrop {
  background: #1b071dcc;
}
dialog #closeDialog {
  display: flex;
  margin-left: auto;
  margin-bottom: 15px;
}
dialog .guide {
  max-height: 75vh;
  object-fit: contain;
}
.access-banner {
  background: #fff2d8;
  border: 1px solid #efd29a;
  border-radius: 10px;
  padding: 16px;
  margin-bottom: 22px;
}
.compact {
  max-width: 730px;
}
.skeleton {
  color: var(--muted);
  padding: 50px;
}
.calc-result {
  font-size: 2.7rem;
  font-family: Georgia, serif;
  color: var(--wine);
}
.formerror {
  color: #98283d;
  background: #fff0f2;
  padding: 12px;
  border-radius: 8px;
  margin-bottom: 15px;
}
.nowrap {
  white-space: nowrap;
}
.coach-heading {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 15px;
}
.privacy {
  font-size: 13px;
  color: var(--muted);
  margin-top: 30px;
}
.view-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 20px;
}
.view-heading h2 {
  margin: 0;
}
.doc-actions {
  margin-top: 10px;
}
.subtle {
  background: #faf7f9;
}
.affirmation {
  font-family: Georgia, serif;
  font-size: 1.3rem;
  color: var(--wine);
  margin-bottom: 25px;
}
.history-summary {
  cursor: pointer;
  font-weight: 700;
  padding: 8px 0;
}
.danger-zone {
  margin-top: 24px;
}
.meta-row {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 10px;
}
.photo-title {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
}
#dialogBody .photo {
  max-height: 70vh;
}
.page-heading {
  margin-bottom: 25px;
}
.file-title {
  overflow-wrap: anywhere;
}
.read-label {
  margin-bottom: 3px;
  font-weight: 700;
  font-size: 14px;
}
@media (max-width: 1050px) {
  .workspace {
    padding: 28px 24px;
  }
  .layout {
    grid-template-columns: 210px minmax(0, 1fr);
  }
  .rail {
    padding: 25px 14px;
  }
  .grid.three {
    gap: 12px;
  }
  .stats {
    grid-template-columns: repeat(2, 1fr);
  }
}
@media (max-width: 760px) {
  .layout {
    display: block;
  }
  .rail {
    position: relative;
    height: auto;
    padding: 17px 16px 0;
  }
  .rail .brand {
    font-size: 24px;
  }
  .rail > .overline {
    display: none;
  }
  .nav {
    display: flex;
    overflow-x: auto;
    margin: 14px -16px 0;
    padding: 0 12px 10px;
    gap: 4px;
  }
  .nav button {
    white-space: nowrap;
    flex-shrink: 0;
    padding: 10px 12px;
    font-size: 14px;
  }
  .rail-bottom {
    display: none;
  }
  .workspace {
    padding: 24px 16px 55px;
  }
  .top {
    margin-bottom: 20px;
  }
  .top h1 {
    font-size: 2rem;
  }
  .top .badge {
    font-size: 12px;
  }
  .context {
    grid-template-columns: 1fr;
    padding: 13px;
    gap: 12px;
  }
  .context label {
    font-size: 14px;
  }
  .card {
    padding: 20px 17px;
  }
  .grid {
    grid-template-columns: 1fr;
    gap: 0;
  }
  .grid.three {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 8px;
  }
  .photo-card {
    padding: 12px 9px;
  }
  .photo-card h3 {
    font-size: 14px;
  }
  .photo-card .actions {
    display: grid;
  }
  .photo-card .placeholder {
    font-size: 13px;
    padding: 8px;
  }
  .photo-card input[type="file"] {
    max-width: 100%;
    font-size: 12px;
  }
  .photo-card button {
    font-size: 13px;
    padding: 7px;
    min-height: 40px;
  }
  .compare {
    gap: 12px;
  }
  .login {
    grid-template-columns: 1fr;
  }
  .login-art {
    padding: 35px 25px;
  }
  .login-art .brand {
    margin-bottom: 30px;
  }
  .login-art h1 {
    font-size: 2.5rem;
  }
  .login-panel {
    padding: 32px 25px;
  }
  .member-row {
    grid-template-columns: 1fr;
  }
  .view-heading {
    align-items: flex-start;
  }
  .view-heading h2 {
    font-size: 1.65rem;
  }
  .focus-card blockquote {
    font-size: 1.5rem;
  }
  .mobile-logout {
    display: inline-flex;
  }
  .stats {
    gap: 8px;
  }
  .stat {
    padding: 13px;
  }
  .stat strong {
    font-size: 1.6rem;
  }
  .photo-title {
    display: block;
  }
  .photo-title small {
    font-size: 12px;
  }
  .coach-heading {
    align-items: flex-start;
  }
  .badge {
    white-space: normal;
  }
  dialog {
    padding: 15px;
  }
}
@media (min-width: 761px) {
  .mobile-logout {
    display: none;
  }
}
@media (prefers-reduced-motion: no-preference) {
  button,
  .button {
    transition:
      background 0.15s,
      opacity 0.15s;
  }
}
@media print {
  .rail,
  .actions,
  button,
  .context,
  #status {
    display: none;
  }
  .layout {
    display: block;
  }
  .workspace {
    padding: 0;
    max-width: none;
  }
  .card {
    break-inside: avoid;
  }
}
