/* Form and responsive layout rules. */
.account-page {
  max-width: 1000px;
  padding-top: 3rem;
  padding-bottom: 4rem;
  min-height: 70vh;
}
.account-page h1 {
  font-size: clamp(2.6rem, 5vw, 4rem);
  margin: 0.7rem 0 1rem;
}
.account-intro {
  color: var(--muted);
  max-width: 560px;
}
.auth-panel {
  max-width: 480px;
  margin: 2rem auto 0;
  padding: 2rem;
  background: white;
  border: 1px solid var(--line);
  border-radius: 12px;
}
.auth-tabs {
  display: flex;
  gap: 1rem;
  border-bottom: 1px solid var(--line);
  margin-bottom: 1.5rem;
}
.auth-tabs button {
  background: none;
  border: 0;
  padding: 0.7rem 0.1rem;
  color: var(--muted);
  border-bottom: 2px solid transparent;
  font-weight: 600;
}
.auth-tabs button[aria-selected="true"] {
  color: var(--purple);
  border-color: var(--purple);
}
.field {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  margin-bottom: 1rem;
  font-size: 0.9rem;
  font-weight: 600;
}
.field input,
.field textarea {
  width: 100%;
  border: 1px solid #d5c9de;
  border-radius: 6px;
  background: white;
  min-height: 48px;
  padding: 0.75rem;
  color: var(--ink);
  font-weight: 400;
}
.field textarea {
  resize: vertical;
  min-height: 90px;
}
.form-note {
  font-size: 0.8rem;
  color: var(--muted);
  line-height: 1.6;
}
.auth-panel .button {
  width: 100%;
  margin-top: 0.3rem;
}
.list-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  margin: 2rem 0;
}
.list-header p {
  margin: 0;
  color: var(--muted);
}
.purchase-layout {
  display: grid;
  grid-template-columns: 300px 1fr;
  gap: 2rem;
  align-items: start;
}
.purchase-form {
  background: white;
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 1.5rem;
}
.purchase-form h2 {
  font-size: 1.6rem;
}
.purchase-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 0.75rem;
}
.purchase-item {
  display: flex;
  gap: 1rem;
  padding: 1.2rem;
  background: white;
  border: 1px solid var(--line);
  border-radius: 9px;
  align-items: start;
}
.purchase-item input[type="checkbox"] {
  accent-color: var(--purple);
  width: 22px;
  height: 22px;
  margin: 2px 0;
  flex-shrink: 0;
  cursor: pointer;
}
.purchase-item .item-content {
  flex: 1;
  min-width: 0;
}
.item-name {
  display: block;
  font-weight: 600;
  overflow-wrap: anywhere;
}
.purchase-item.purchased .item-name {
  text-decoration: line-through;
  color: var(--muted);
}
.item-notes {
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  font-size: 0.875rem;
  color: var(--muted);
  margin: 0.5rem 0;
}
.item-link {
  font-size: 0.85rem;
  overflow-wrap: anywhere;
}
.item-status {
  font-size: 0.75rem;
  color: var(--muted);
  display: block;
  margin-top: 0.5rem;
}
.delete-item {
  background: none;
  border: 0;
  color: var(--muted);
  font-size: 0.8rem;
  padding: 0.25rem;
}
.approval-row {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  align-items: center;
  padding: 1rem 0;
  border-bottom: 1px solid var(--line);
}
.approval-row p {
  margin: 0;
}
.approvals {
  border-top: 1px solid var(--line);
  margin-top: 3rem;
  padding-top: 1.5rem;
}
.approvals summary {
  cursor: pointer;
  font-weight: 600;
  color: var(--purple);
}
@media (max-width: 1000px) {
  .hero {
    gap: 3rem;
  }
  .site-header,
  main,
  footer {
    padding-left: 2rem;
    padding-right: 2rem;
  }
  .recipe-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .binder-card {
    padding: 2rem;
  }
  .hero h1 {
    font-size: 4rem;
  }
  .purchase-layout {
    grid-template-columns: 260px 1fr;
    gap: 1rem;
  }
}
@media (max-width: 700px) {
  .site-header {
    padding: 1rem 1.2rem;
    min-height: 85px;
    gap: 1rem;
    flex-wrap: wrap;
  }
  .site-header nav {
    gap: 1rem;
    flex: 1;
    justify-content: flex-end;
  }
  .site-header nav > a:first-child,
  .site-header nav > a:nth-child(2) {
    display: none;
  }
  .site-header nav .account-link {
    font-size: 0.875rem;
  }
  .brand {
    font-size: 0.8rem;
  }
  .brand img {
    width: 34px;
    height: 34px;
  }
  main {
    padding: 0 1.2rem;
  }
  .hero {
    grid-template-columns: 1fr;
    padding: 2.5rem 0;
    gap: 2rem;
  }
  .hero h1 {
    font-size: 3.8rem;
  }
  .hero-copy {
    font-size: 1rem;
  }
  .binder-card {
    padding: 1.7rem;
  }
  .binder-icon {
    margin-bottom: 1.3rem;
  }
  .binder-card h2 {
    max-width: none;
    font-size: 2rem;
  }
  .binder-card p {
    max-width: none;
  }
  .library {
    padding-top: 2rem;
  }
  .section-title {
    display: block;
  }
  .sort-label {
    margin-top: 1rem;
  }
  .section-title h2 {
    font-size: 2rem;
  }
  .filters {
    gap: 0.4rem;
  }
  .filter {
    font-size: 0.875rem;
    padding: 0.5rem 0.6rem;
  }
  .filter span {
    margin-left: 0.2rem;
  }
  .recipe-grid {
    grid-template-columns: 1fr;
  }
  .recipe-card {
    min-height: 210px;
    padding: 1.4rem;
  }
  .recipe-card h3 {
    font-size: 1.7rem;
  }
  .downloads {
    grid-template-columns: 1fr;
    gap: 1.3rem;
    padding: 1.6rem;
    margin: 2.5rem 0;
  }
  .downloads h2 {
    font-size: 2rem;
  }
  footer {
    padding: 1.5rem 1.2rem;
    flex-direction: column;
    gap: 0.5rem;
  }
  .recipe-page,
  .account-page {
    padding-top: 2rem;
    padding-bottom: 3rem;
  }
  .recipe-heading {
    padding: 2rem 0 1.5rem;
  }
  .recipe-facts {
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
    padding: 1rem;
  }
  .recipe-content p,
  .recipe-content li {
    font-size: 1rem;
  }
  .auth-panel {
    padding: 1.3rem;
  }
  .purchase-layout {
    grid-template-columns: 1fr;
  }
  .list-header {
    flex-wrap: wrap;
  }
  .purchase-item {
    gap: 0.75rem;
  }
  .approval-row {
    align-items: start;
    flex-wrap: wrap;
  }
}
@media (prefers-reduced-motion: reduce) {
  :root {
    scroll-behavior: auto;
  }
  .recipe-card {
    transition: none;
  }
}
@media print {
  .site-header,
  footer,
  .skip,
  .back-link,
  .recipe-actions,
  .original-page details {
    display: none !important;
  }
  :root {
    background: white;
  }
  main,
  .recipe-page {
    max-width: none;
    padding: 0;
  }
  .recipe-heading {
    padding: 0 0 1rem;
  }
  .recipe-heading h1 {
    font-size: 2rem;
  }
  .recipe-content {
    max-width: none;
    margin-top: 1rem;
  }
  .recipe-content h2 {
    font-size: 1.4rem;
    margin-top: 1.5rem;
  }
  .recipe-content li,
  .recipe-content p {
    font-size: 11pt;
    line-height: 1.5;
  }
  .recipe-facts {
    padding: 0.75rem;
    background: white;
    border: 1px solid #ccc;
  }
  .original-page {
    break-before: page;
  }
  .original-page h2 {
    display: none;
  }
  h2,
  h3 {
    break-after: avoid;
  }
  .recipe-content li {
    break-inside: avoid;
  }
  .account-page {
    display: none !important;
  }
}
