*{box-sizing:border-box}body,html{margin:0;padding:0;font-family:system-ui,-apple-system,Segoe UI,Hiragino Sans,Hiragino Kaku Gothic ProN,Meiryo,sans-serif;font-size:15px;line-height:1.5;color:#1e293b;background:#f4f6f9}a{color:#2563eb}a:hover{text-decoration:underline}main{max-width:1240px;margin:0 auto;padding:1.25rem 1.5rem 3rem}h1{font-size:1.3rem;color:#1c2b4a;margin:0 0 1rem}.topbar{background:#fff;border-bottom:1px solid #e8ecf1}.topbar-inner{max-width:1240px;margin:0 auto;padding:.85rem 1.5rem;gap:1rem}.topbar-inner,.topbar-title{display:flex;align-items:center}.topbar-title{gap:.55rem;font-size:1.2rem;font-weight:700;color:#1c2b4a;white-space:nowrap}.topbar-title,.topbar-title:hover{text-decoration:none}.topbar-title svg{flex:0 0 auto}.topbar-sections{display:flex;align-items:center;gap:.25rem;padding:.2rem;border-radius:10px;background:#f1f5f9}.topbar-sections a{padding:.35rem .75rem;border-radius:8px;color:#64748b;font-size:.85rem;font-weight:700;text-decoration:none;white-space:nowrap}.topbar-sections a:hover{color:#1c2b4a;text-decoration:none}.topbar-sections a.active{color:#1d4ed8;background:#fff;box-shadow:0 1px 2px rgba(16,24,40,.08)}.topbar-right{margin-left:auto;display:flex;align-items:center;gap:1.6rem}.topbar-stat{display:flex;flex-direction:column;align-items:flex-start;line-height:1.25}.topbar-stat .stat-label{font-size:.72rem;font-weight:600;color:#64748b}.topbar-stat .stat-value{font-size:1.25rem;font-weight:700;color:#1c2b4a}.topbar-stat .stat-value.stat-warn{color:#f59e0b}.topbar-stat .stat-value.stat-ok{color:#16a34a}.table-card{background:#fff;border-radius:14px;box-shadow:0 1px 3px rgba(16,24,40,.07);overflow-x:auto}table{width:100%;border-collapse:collapse;background:transparent}td,th{text-align:left;padding:.85rem 1rem;border-bottom:1px solid #eef1f5;vertical-align:middle}tbody tr:last-child td{border-bottom:none}th{background:transparent;color:#64748b;font-size:.8rem;font-weight:600}.cell-name{font-weight:700;color:#1c2b4a}.cell-sub{font-size:.8rem;color:#94a3b8;font-weight:400}.card{background:#fff;padding:1.25rem;border-radius:14px;box-shadow:0 1px 3px rgba(16,24,40,.07)}.muted{color:#64748b;font-size:.9rem}.err{color:#b00020;margin-top:.5rem}label{display:block;font-weight:600;margin-bottom:.25rem}input[type=date],input[type=email],input[type=password],input[type=text],select{width:100%;max-width:360px;padding:.5rem .7rem;border:1px solid #dfe5ec;border-radius:10px;background:#fff;font-size:.9rem}.button-link,button{display:inline-block;padding:.5rem 1.1rem;border-radius:9px;border:none;background:#2563eb;color:#fff;font-weight:600;cursor:pointer;text-decoration:none;font-size:.9rem}button.secondary{background:#e9edf2;color:#334155}button:disabled{opacity:.6;cursor:not-allowed}.nav{display:flex;gap:1rem;align-items:center;margin-bottom:1.25rem}pre.raw-json{white-space:pre-wrap;word-break:break-word;font-size:.85rem;background:#f8fafc;padding:.75rem;border-radius:10px;border:1px solid #eef1f5}.toolbar{display:flex;gap:.75rem;align-items:center;flex-wrap:wrap;margin-bottom:1.1rem}.pill-switch{display:inline-flex;background:#e9edf2;border-radius:12px;padding:4px;gap:2px}.pill-switch a{padding:.42rem 1.3rem;border-radius:9px;text-decoration:none;color:#64748b;font-weight:600;font-size:.9rem;border:2px solid transparent}.pill-switch a.active{background:#fff;color:#1c2b4a;border-color:#2563eb;box-shadow:0 1px 2px rgba(16,24,40,.08)}.pill-switch a:hover{text-decoration:none}.toolbar select{width:auto;min-width:170px}.board{display:flex;gap:.85rem;overflow-x:auto;padding-bottom:.5rem;align-items:flex-start}.board-col{flex:0 0 210px;background:#edf1f6;border-radius:14px;padding:.55rem;min-height:300px}.board-col-over{outline:2px dashed #2563eb;outline-offset:-2px}.board-col-head{display:flex;gap:.45rem;font-size:.88rem;padding:.35rem .45rem .6rem}.board-col-head,.board-count{align-items:center;font-weight:700;color:#1c2b4a}.board-count{margin-left:auto;background:#fff;font-size:.75rem;border-radius:999px;min-width:1.5rem;height:1.5rem;display:inline-flex;justify-content:center;padding:0 .4rem}.dot{width:9px;height:9px;border-radius:50%;display:inline-block;flex:0 0 auto}.dot-new{background:#f59e0b}.dot-contacted,.dot-estimating,.dot-quoted{background:#2563eb}.dot-won{background:#16a34a}.dot-lost{background:#dc2626}.dot-closed{background:#94a3b8}.dot-in_production{background:#6366f1}.dot-awaiting_payment{background:#f59e0b}.dot-delivered{background:#16a34a}.board-card{background:#fff;border-radius:10px;box-shadow:0 1px 2px rgba(16,24,40,.08);padding:.65rem .75rem;margin-bottom:.55rem;cursor:-webkit-grab;cursor:grab;font-size:.85rem}.board-card:active{cursor:-webkit-grabbing;cursor:grabbing}.board-card-date{font-size:.75rem;color:#94a3b8;display:flex;justify-content:space-between;margin-bottom:.15rem}.board-card-name{font-weight:700;color:#1c2b4a;margin-bottom:.15rem}.badge-service{font-size:.72rem;background:#e8effc;color:#1d4ed8;border-radius:6px;padding:.08rem .45rem}.badge-service,.badge-status{display:inline-block;font-weight:600}.badge-status{font-size:.78rem;border-radius:7px;padding:.14rem .55rem;background:#eef1f5}.status-new{background:#fef3e2;color:#b45309}.status-contacted,.status-estimating,.status-quoted{background:#e8effc;color:#1d4ed8}.status-won{background:#e6f6ec;color:#15803d}.status-lost{background:#fdeaea;color:#b91c1c}.status-closed{background:#eef1f5;color:#64748b}.status-in_production{background:#eef0ff;color:#4338ca}.status-awaiting_payment{background:#fef3c7;color:#b45309}.status-delivered{background:#e6f6ec;color:#15803d}.meta-form{display:flex;gap:1rem;align-items:flex-end;flex-wrap:wrap}.meta-form label{font-size:.85rem}.meta-form label.inline{display:inline-flex;align-items:center;gap:.3rem}.meta-form input[type=date],.meta-form input[type=text]{display:block;margin-top:.25rem;width:auto}.notes{list-style:none;padding:0;margin:1rem 0 0}.notes li{border-top:1px solid #eef1f5;padding:.6rem 0}textarea{border:1px solid #dfe5ec;border-radius:10px;padding:.55rem .7rem;font-family:inherit;font-size:.9rem}.row-click{cursor:pointer}.row-click:hover td{background:#f8fafc}.cell-check{width:2.2rem;text-align:center}.cell-check input[type=checkbox]{width:1rem;height:1rem;cursor:pointer;accent-color:#2563eb}.bulk-bar{display:flex;gap:.6rem;align-items:center;flex-wrap:wrap;background:#fff;border:1px solid #fecaca;border-radius:12px;padding:.55rem .9rem;margin-bottom:.8rem}.bulk-bar .bulk-count{font-weight:600;color:#334155;font-size:.9rem}.bulk-bar .err{margin-top:0;font-size:.85rem}button.bulk-delete{background:#fff;color:#dc2626;border:1px solid #fecaca}button.bulk-delete:hover:not(:disabled){background:#fef2f2}.drawer-overlay{position:fixed;inset:0;background:rgba(15,23,42,.35);z-index:40}.drawer{position:fixed;top:0;right:0;bottom:0;width:min(480px,94vw);background:#fff;z-index:50;display:flex;flex-direction:column;box-shadow:-8px 0 30px rgba(15,23,42,.18)}.drawer-head{padding:1.1rem 1.3rem .9rem;background:#f8fafc;border-bottom:1px solid #eef1f5;position:relative}.drawer-close{position:absolute;top:.7rem;right:.8rem;background:transparent;color:#64748b;font-size:1.3rem;padding:.1rem .5rem;border-radius:8px}.drawer-close:hover{background:#e9edf2}.drawer-title{margin:0 1.8rem .25rem 0;font-size:1.15rem;color:#1c2b4a}.drawer-subtitle{margin:0}.drawer-body{flex:1 1;overflow-y:auto;padding:.4rem 1.3rem 1rem}.drawer-body section{padding:.8rem 0;border-bottom:1px solid #f1f5f9}.drawer-body h3{margin:0 0 .3rem;font-size:.8rem;font-weight:700;color:#64748b}.drawer-meta{display:flex;gap:.9rem;align-items:flex-end;flex-wrap:wrap}.drawer-meta label{font-size:.8rem;margin-bottom:0}.drawer-meta label.inline{display:inline-flex;align-items:center;gap:.3rem}.drawer-meta input[type=date],.drawer-meta input[type=text]{display:block;margin-top:.2rem;width:auto;max-width:170px}.drawer-foot{border-top:1px solid #eef1f5;padding:.9rem 1.3rem 1.1rem;background:#fff}.drawer-actions{display:flex;gap:.6rem;align-items:center;justify-content:space-between;margin:.6rem 0}.drawer-actions select{width:auto;min-width:140px}.danger-outline{width:100%;background:#fff;color:#dc2626;border:1px solid #fecaca;border-radius:9px;font-weight:600}.danger-outline:hover{background:#fef2f2}.page-heading{display:flex;align-items:flex-start;justify-content:space-between;gap:1rem;margin-bottom:1rem}.page-heading h1,.page-heading p{margin-bottom:.25rem}.solicitation-entry{margin-bottom:1rem;padding:1rem 1.25rem;border:1px solid #dfe5ec;border-radius:14px;background:#fff;box-shadow:0 1px 3px rgba(16,24,40,.07)}.solicitation-entry>summary{cursor:pointer;color:#1c2b4a;font-weight:700}.solicitation-form{display:grid;grid-gap:.9rem;gap:.9rem;margin-top:1rem}.solicitation-form label{display:grid;grid-gap:.25rem;gap:.25rem;margin:0;font-size:.85rem}.solicitation-form input,.solicitation-form select,.solicitation-form textarea{width:100%;max-width:none}.form-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));grid-gap:.8rem;gap:.8rem}.required{color:#dc2626;font-size:.72rem}.form-submit-row{display:flex;align-items:center;gap:.8rem;flex-wrap:wrap}.form-submit-row .err{margin:0}.warn{color:#b45309}.ok,.warn{font-weight:600}.ok{color:#15803d}.solicitation-toolbar{display:flex;align-items:center;justify-content:space-between;gap:1rem;margin-bottom:.8rem}.solicitation-search{display:flex;align-items:center;gap:.5rem;flex:1 1}.solicitation-search input[type=text]{max-width:500px}.secondary-link:hover{text-decoration:none}.solicitation-list{display:grid;grid-gap:.8rem;gap:.8rem}.solicitation-company{border:1px solid #dfe5ec;border-radius:14px;background:#fff;box-shadow:0 1px 3px rgba(16,24,40,.07);overflow:hidden}.solicitation-company.repeated{border-color:#f59e0b}.solicitation-company>summary{display:flex;align-items:center;gap:1rem;padding:1rem 1.25rem;cursor:pointer}.solicitation-company>summary::marker{color:#64748b}.company-main{display:grid;grid-gap:.15rem;gap:.15rem;min-width:0}.company-name{color:#1c2b4a;font-weight:700}.company-identifiers{color:#64748b;font-size:.8rem;overflow-wrap:anywhere}.company-summary-meta{display:flex;align-items:center;justify-content:flex-end;gap:.65rem;margin-left:auto;color:#64748b;font-size:.8rem;white-space:nowrap}.decision,.repeat-badge,.single-badge{display:inline-flex;align-items:center;border-radius:999px;padding:.18rem .6rem;font-size:.75rem;font-weight:700}.repeat-badge{color:#b45309;background:#fef3c7}.single-badge{color:#475569;background:#f1f5f9}.decision{color:#475569;background:#eef1f5}.decision-no_reply{color:#475569;background:#e2e8f0}.decision-blocked,.decision-declined{color:#b91c1c;background:#fee2e2}.decision-pending{color:#b45309;background:#fef3c7}.duplicate-warning{margin:0;padding:.65rem 1.25rem;color:#92400e;background:#fffbeb;border-top:1px solid #fde68a;font-size:.85rem;font-weight:600}.solicitation-history{border-top:1px solid #eef1f5}.solicitation-history-item{padding:1rem 1.25rem;border-bottom:1px solid #eef1f5}.solicitation-history-item:last-child{border-bottom:0}.history-head{display:flex;align-items:center;gap:.65rem;margin-bottom:.75rem;color:#64748b;font-size:.82rem}.history-head strong{color:#1c2b4a}.history-delete-wrap{display:inline-flex;align-items:center;gap:.5rem;margin-left:auto}button.history-delete{padding:.3rem .75rem;color:#dc2626;background:#fff;border:1px solid #fecaca}button.history-delete:hover:not(:disabled){background:#fef2f2}.history-delete-wrap .err{margin:0;font-size:.78rem}.solicitation-history dl{display:grid;grid-gap:.55rem;gap:.55rem;margin:0}.solicitation-history dl>div{display:grid;grid-template-columns:7rem minmax(0,1fr);grid-gap:.75rem;gap:.75rem}.solicitation-history dt{color:#64748b;font-size:.8rem;font-weight:700}.solicitation-history dd{margin:0;overflow-wrap:anywhere}.pre-wrap{white-space:pre-wrap}@media (max-width:960px){.topbar-inner{align-items:flex-start;flex-wrap:wrap}.topbar-right{width:100%;margin-left:0;flex-wrap:wrap;gap:.8rem}.form-grid{grid-template-columns:repeat(2,minmax(0,1fr))}}@media (max-width:640px){.topbar-inner,main{padding-right:1rem;padding-left:1rem}.topbar-sections,.topbar-title{width:100%}.topbar-sections a{flex:1 1;text-align:center}.form-grid{grid-template-columns:1fr}.company-summary-meta,.solicitation-company>summary,.solicitation-search,.solicitation-toolbar{align-items:stretch;flex-direction:column}.company-summary-meta{margin-left:0;white-space:normal}.solicitation-history dl>div{grid-template-columns:1fr;gap:.15rem}.history-head{align-items:flex-start;flex-wrap:wrap}.history-delete-wrap{width:100%;margin-left:0}}.topbar-stat .stat-value.stat-danger{color:#dc2626}input[type=number],input[type=url]{width:100%;max-width:360px;padding:.5rem .7rem;border:1px solid #dfe5ec;border-radius:10px;background:#fff;font-size:.9rem}.relationship-alert-grid,.relationship-summary-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));grid-gap:.8rem;gap:.8rem;margin-bottom:1rem}.relationship-alert-card{display:flex;align-items:center;justify-content:space-between;gap:.8rem;padding:.9rem 1rem;color:#1c2b4a;background:#fff;border:1px solid #e8ecf1;border-radius:12px;box-shadow:0 1px 3px rgba(16,24,40,.05);font-weight:700;text-decoration:none}.relationship-alert-card:hover{border-color:#bfdbfe;text-decoration:none}.relationship-alert-card strong{font-size:1.35rem}.relationship-alert-card.alert-danger{color:#b91c1c;background:#fff7f7;border-color:#fecaca}.relationship-alert-card.alert-warning{color:#b45309;background:#fffbeb;border-color:#fde68a}.relationship-alert-card.alert-muted{color:#475569;background:#f8fafc}.relationship-toolbar input[type=text]{max-width:420px}.secondary-link{color:#334155;background:#e9edf2}.badge-alert,.badge-relationship{display:inline-block;padding:.16rem .55rem;border-radius:7px;font-size:.78rem;font-weight:700;white-space:nowrap}.relationship-active{color:#15803d;background:#e6f6ec}.relationship-follow_up{color:#1d4ed8;background:#e8effc}.relationship-dormant{color:#92400e;background:#fef3c7}.relationship-ended{color:#64748b;background:#eef1f5}.badge-alert.alert-danger{color:#b91c1c;background:#fee2e2}.badge-alert.alert-warning{color:#b45309;background:#fef3c7}.badge-alert.alert-ok{color:#15803d;background:#e6f6ec}.badge-alert.alert-muted{color:#64748b;background:#eef1f5}.company-detail-heading{align-items:center}.company-detail-badges{display:flex;gap:.5rem;align-items:center}.relationship-summary-card{display:flex;flex-direction:column;gap:.25rem;padding:.9rem 1rem}.relationship-summary-card span{color:#64748b;font-size:.78rem;font-weight:700}.relationship-summary-card strong{color:#1c2b4a;font-size:1.1rem}.company-detail-grid{display:grid;grid-template-columns:minmax(0,1.2fr) minmax(0,.8fr);grid-gap:1rem;gap:1rem;align-items:start}.company-detail-grid h2,.relationship-section h2{margin:0 0 .75rem;color:#1c2b4a;font-size:1.05rem}.company-contact-form,.company-profile-form{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));grid-gap:.8rem;gap:.8rem}.company-contact-form label,.company-profile-form label{display:grid;grid-gap:.25rem;gap:.25rem;margin:0;font-size:.82rem}.company-contact-form input,.company-contact-form select,.company-contact-form textarea,.company-profile-form input,.company-profile-form select,.company-profile-form textarea{width:100%;max-width:none}.company-contact-form .full,.company-profile-form .full{grid-column:1/-1}.section-divider{padding-top:1rem;margin-top:1rem!important;border-top:1px solid #eef1f5}.activity-timeline,.contact-list{list-style:none;padding:0;margin:0}.contact-list li{display:flex;flex-direction:column;gap:.1rem;padding:.55rem 0;border-top:1px solid #eef1f5}.contact-list li span{color:#64748b;font-size:.82rem;overflow-wrap:anywhere}.relationship-section{margin-top:1rem}.embedded-table{box-shadow:none;border:1px solid #eef1f5}.activity-timeline li{position:relative;padding:.75rem 0 .75rem 1.2rem;border-left:2px solid #dbeafe}.activity-timeline li:before{position:absolute;top:1rem;left:-.38rem;width:.65rem;height:.65rem;content:"";background:#2563eb;border:2px solid #fff;border-radius:50%;box-shadow:0 0 0 1px #bfdbfe}.activity-timeline p{margin:.35rem 0 0;white-space:pre-wrap}.activity-head{display:flex;align-items:center;gap:.55rem;flex-wrap:wrap}@media (max-width:900px){.relationship-alert-grid,.relationship-summary-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.company-detail-grid{grid-template-columns:1fr}}@media (max-width:640px){.company-contact-form,.company-profile-form,.relationship-alert-grid,.relationship-summary-grid{grid-template-columns:1fr}.company-detail-badges{align-items:flex-start;flex-direction:column}}