/* Book Seller Calculator Styles */
* { box-sizing: border-box; }
body { font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif; margin: 0; padding: 0; line-height: 1.6; color: #333; background: #fff; }
a { color: #0066cc; text-decoration: none; }
a:hover { text-decoration: underline; }
.container { max-width: 1200px; margin: 0 auto; padding: 1rem; }
.site-header { background: #f8f9fa; border-bottom: 1px solid #e9ecef; position: sticky; top: 0; z-index: 100; }
.site-header h1 { font-size: 1.5rem; margin: 0; color: #2c3e50; }
.nav { display: flex; gap: 1.5rem; }
.nav a { font-weight: 500; }
.book-form { display: grid; gap: 1rem; margin-bottom: 2rem; }
.form-group { display: flex; flex-direction: column; gap: 0.5rem; }
.form-group label { font-weight: 600; font-size: 0.9rem; }
.form-group input { padding: 0.75rem; border: 1px solid #ccc; border-radius: 4px; font-size: 1rem; }
.form-group input:focus { outline: 2px solid #0066cc; border-color: #0066cc; }
.condition-group { margin-top: 0.5rem; }
.condition-options { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 0.5rem; }
.condition-btn { padding: 0.5rem; border: 2px solid #ddd; border-radius: 4px; cursor: pointer; transition: all 0.2s; font-size: 0.85rem; text-align: left; }
.condition-btn.active, .condition-btn:hover { background: #0066cc; color: white; border-color: #0066cc; }
.calculate-btn { background: #28a745; color: white; border: none; padding: 1rem 2rem; border-radius: 4px; font-size: 1.1rem; font-weight: 600; cursor: pointer; align-self: flex-start; transition: background 0.2s; }
.calculate-btn:hover { background: #218838; }
.results-section { margin-top: 2rem; }
.result-card { background: #f8f9fa; border: 1px solid #e9ecef; border-radius: 8px; padding: 1.5rem; margin-bottom: 1rem; min-height: 120px; }
.result-card h3 { margin-top: 0; color: #2c3e50; }
.result-value { font-size: 2rem; font-weight: 700; color: #28a745; margin: 0.5rem 0; }
.result-label { font-size: 0.9rem; color: #666; }
.result-actions { display: flex; gap: 0.75rem; flex-wrap: wrap; margin-bottom: 1rem; }
.action-btn { background: #f0f0f0; border: 1px solid #ccc; padding: 0.75rem 1.25rem; border-radius: 4px; cursor: pointer; transition: all 0.2s; }
.action-btn:hover { background: #e9ecef; }
.guide-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 1rem; margin-top: 1rem; }
.guide-item { background: #fff; border: 1px solid #e9ecef; border-radius: 8px; padding: 1rem; }
.guide-item h4 { margin-top: 0; font-size: 1rem; color: #2c3e50; }
.guide-item p { margin: 0.25rem 0; font-size: 0.9rem; }
.example-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 1rem; margin-top: 1rem; }
.example-card { background: #f8f9fa; border: 1px solid #e9ecef; border-radius: 8px; padding: 1rem; }
.example-card h4 { margin-top: 0; font-size: 1rem; color: #2c3e50; }
.example-card p { font-size: 0.85rem; margin: 0.5rem 0; }
.load-example { background: #0066cc; color: white; border: none; padding: 0.5rem 1rem; border-radius: 4px; cursor: pointer; font-size: 0.85rem; margin-top: 0.5rem; }
.load-example:hover { background: #0056b3; }
.tips-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 1rem; margin-top: 1rem; }
.tip-card { background: #fff; border: 1px solid #e9ecef; border-radius: 8px; padding: 1rem; }
.tip-card h4 { margin-top: 0; font-size: 1rem; color: #2c3e50; }
.tip-card p { font-size: 0.85rem; margin: 0.5rem 0; }
.caveats-list { list-style: none; padding: 0; }
.caveats-list li { padding: 0.75rem; background: #fff; border-left: 4px solid #0066cc; margin-bottom: 0.5rem; }
.history-list { max-height: 200px; overflow-y: auto; }
.history-item { padding: 0.75rem; background: #f8f9fa; border-bottom: 1px solid #e9ecef; font-size: 0.9rem; }
.history-item:last-child { border-bottom: none; }
.site-footer { background: #2c3e50; color: white; padding: 1.5rem 0; margin-top: 2rem; }
.site-footer a { color: #a8dadd; }
@media (max-width: 768px) { .nav { flex-direction: column; gap: 0.5rem; } .example-cards, .tips-grid, .guide-grid { grid-template-columns: 1fr; } .result-actions { flex-direction: column; } }
@media (max-width: 480px) { .container { padding: 0.75rem; } .site-header h1 { font-size: 1.25rem; } }


/* 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;
}
