/* Library Book Sale Maximizer Styles */
* { box-sizing: border-box; margin: 0; padding: 0; }
body { font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif; line-height: 1.6; color: #333; background: #fff; min-height: 100vh; }
a { color: #0066cc; text-decoration: none; }
a:hover { text-decoration: underline; }
header { background: #f5f5f5; padding: 1rem 2rem; border-bottom: 1px solid #e0e0e0; position: sticky; top: 0; z-index: 10; }
header h1 { font-size: 1.5rem; margin-bottom: 0.5rem; }
nav { display: flex; gap: 1.5rem; font-size: 0.9rem; }
nav a { color: #0066cc; }
main { max-width: 900px; margin: 0 auto; padding: 2rem; }
section { margin-bottom: 2.5rem; }
h2, h3, h4 { color: #222; margin-bottom: 0.5rem; }
h2 { font-size: 1.8rem; border-bottom: 2px solid #0066cc; padding-bottom: 0.3rem; }
h3 { font-size: 1.4rem; }
h4 { font-size: 1rem; color: #555; }
.hero { text-align: center; padding: 1.5rem; background: #f9f9f9; border-radius: 8px; margin-bottom: 2rem; }
.save-status { font-size: 0.85rem; color: #666; margin-top: 0.5rem; }
.genre-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(120px, 1fr)); gap: 0.75rem; margin-bottom: 1.5rem; }
.genre-btn { padding: 0.75rem 1rem; border: 2px solid #ddd; border-radius: 6px; background: #fff; cursor: pointer; transition: all 0.2s; font-size: 0.95rem; }
.genre-btn.active { background: #0066cc; color: white; border-color: #0066cc; }
.genre-btn:hover { background: #f0f0f0; }
.genre-panel { position: fixed; top: 0; right: -100%; width: 320px; height: 100vh; background: white; box-shadow: -2px 0 8px rgba(0,0,0,0.1); transition: right 0.3s ease; z-index: 100; display: flex; flex-direction: column; }
.genre-panel.open { right: 0; }
.panel-header { display: flex; justify-content: space-between; align-items: center; padding: 1rem; background: #f5f5f5; border-bottom: 1px solid #e0e0e0; }
.panel-title { font-weight: bold; }
.close-btn { background: none; border: none; font-size: 1.2rem; cursor: pointer; color: #666; }
.panel-content { flex: 1; padding: 1rem; overflow-y: auto; }
.panel-actions { padding: 1rem; border-top: 1px solid #e0e0e0; }
.trackGenre { font-size: 0.95rem; }
.primary-btn, .secondary-btn { padding: 0.6rem 1.2rem; border: none; border-radius: 4px; cursor: pointer; font-size: 0.9rem; }
.primary-btn { background: #0066cc; color: white; }
.secondary-btn { background: #e0e0e0; color: #333; }
.primary-btn:hover { background: #0055a3; }
.secondary-btn:hover { background: #d0d0d0; }
.timeline-steps { display: flex; flex-direction: column; gap: 1.5rem; }
.step { display: flex; gap: 1rem; }
.step-number { width: 24px; height: 24px; line-height: 24px; text-align: center; border-radius: 50%; background: #0066cc; color: white; font-weight: bold; flex-shrink: 0; }
.step div { flex: 1; }
.framework-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 1rem; }
.framework-item { background: #f9f9f9; padding: 1rem; border-radius: 6px; border-left: 4px solid #0066cc; }
.framework-item h4 { font-size: 0.95rem; margin-bottom: 0.3rem; }
.examples table { width: 100%; border-collapse: collapse; margin-top: 0.5rem; }
.examples th, .examples td { padding: 0.75rem; text-align: left; border-bottom: 1px solid #e0e0e0; }
.examples th { background: #f5f5f5; font-weight: bold; }
.examples tr:hover { background: #f0f0f0; }
.export-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 1rem; }
.export-item { background: #f9f9f9; padding: 1rem; border-radius: 6px; }
footer { text-align: center; padding: 1.5rem; background: #f5f5f5; border-top: 1px solid #e0e0e0; font-size: 0.9rem; color: #666; }
@media (max-width: 700px) { 
  main { padding: 1rem; }
  header { padding: 1rem; }
  nav { flex-direction: column; gap: 0.5rem; }
  .timeline { flex-direction: column; }
  .genre-panel { width: 100%; max-width: 400px; }
}
@media (max-width: 500px) { 
  .hero { padding: 1rem; }
  .genre-btn { font-size: 0.85rem; padding: 0.6rem 0.8rem; }
  .primary-btn, .secondary-btn { width: 100%; }
}


/* Factory-injected deployment helpers. The AI owns the site design above this block. */
.ad-unit {
  width: min(100%, 720px);
  min-height: 120px;
  margin: 24px auto;
  display: block;
}

.legal-page {
  width: min(900px, calc(100% - 32px));
  margin: 40px auto;
}

.factory-fallback-nav {
  width: min(900px, calc(100% - 32px));
  margin: 24px auto 0;
  display: flex;
  flex-wrap: wrap;
  gap: 10px 16px;
  align-items: center;
  font-size: 0.95rem;
}

.factory-fallback-nav a {
  color: inherit;
  text-decoration: none;
  border-bottom: 1px solid currentColor;
}
