/* ── Teeholic Phone Case Builder v2 ── */

.tpcb-wrap { max-width: 760px; margin: 32px 0; font-family: inherit; }
.tpcb-hidden { display: none !important; }

.tpcb-step { margin-bottom: 32px; }
.tpcb-step-title { font-size: 18px; font-weight: 700; margin: 0 0 16px; display: flex; align-items: center; gap: 10px; }
.tpcb-step-num { background: #1a1a1a; color: #fff; width: 28px; height: 28px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; font-size: 13px; flex-shrink: 0; }

.tpcb-case-grid { display: grid; grid-template-columns: repeat(2,1fr); gap: 14px; margin-bottom: 20px; }
@media (min-width: 600px) { .tpcb-case-grid { grid-template-columns: repeat(4,1fr); } }

.tpcb-case-card { display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 16px 10px; border: 2px solid #e5e7eb; border-radius: 12px; cursor: pointer; transition: all .2s; text-align: center; user-select: none; }
.tpcb-case-card:hover { border-color: #6366f1; background: #f5f5ff; }
.tpcb-case-card.selected { border-color: #6366f1; background: #eef2ff; box-shadow: 0 0 0 3px rgba(99,102,241,.2); }
.tpcb-case-icon { font-size: 28px; }
.tpcb-case-name { font-size: 13px; font-weight: 600; color: #111; }
.tpcb-case-provider { font-size: 11px; color: #888; }
.tpcb-case-price { font-size: 15px; font-weight: 700; color: #6366f1; margin-top: 4px; }

.tpcb-brand-tabs { display: flex; gap: 8px; margin-bottom: 14px; }
.tpcb-brand-tab { padding: 8px 20px; border: 2px solid #e5e7eb; border-radius: 20px; background: #fff; cursor: pointer; font-size: 14px; font-weight: 500; transition: all .15s; }
.tpcb-brand-tab:hover, .tpcb-brand-tab.active { border-color: #6366f1; background: #6366f1; color: #fff; }

.tpcb-model-wrap { margin-bottom: 20px; }
.tpcb-model-select { width: 100%; max-width: 400px; padding: 10px 14px; border: 2px solid #e5e7eb; border-radius: 8px; font-size: 15px; background: #fff; cursor: pointer; }
.tpcb-model-select:focus { outline: none; border-color: #6366f1; }

.tpcb-step-nav { display: flex; gap: 12px; margin-top: 16px; }
.tpcb-btn { padding: 12px 24px; border: none; border-radius: 8px; font-size: 15px; font-weight: 600; cursor: pointer; transition: all .15s; }
.tpcb-btn-next { background: #6366f1; color: #fff; }
.tpcb-btn-next:hover { background: #4f46e5; }
.tpcb-btn-back { background: #f3f4f6; color: #374151; }
.tpcb-btn-back:hover { background: #e5e7eb; }
.tpcb-btn-ghost { background: transparent; border: 2px solid #d1d5db; color: #6b7280; font-size: 13px; padding: 8px 16px; margin-top: 12px; }
.tpcb-btn-ghost:hover { border-color: #6366f1; color: #6366f1; }

.tpcb-upload-area { border: 2px dashed #d1d5db; border-radius: 12px; padding: 48px 24px; text-align: center; cursor: pointer; transition: all .2s; background: #fafafa; }
.tpcb-upload-area:hover, .tpcb-upload-area.drag-over { border-color: #6366f1; background: #f5f5ff; }
.tpcb-upload-icon { font-size: 40px; margin-bottom: 12px; }
.tpcb-upload-text { font-size: 15px; color: #374151; margin: 0 0 8px; }
.tpcb-upload-label { color: #6366f1; text-decoration: underline; cursor: pointer; }
.tpcb-upload-hint { font-size: 12px; color: #9ca3af; margin: 0; }

.tpcb-lowres-warning { background: #fffbeb; border: 1px solid #fbbf24; color: #92400e; padding: 10px 14px; border-radius: 8px; font-size: 13px; margin: 12px 0; }

.tpcb-mockup-wrap { margin-top: 20px; }
.tpcb-mockup-spinner { text-align: center; padding: 40px 0; }
.tpcb-mockup-spinner p { color: #6b7280; margin-top: 12px; font-size: 14px; }

.tpcb-spinner { width: 44px; height: 44px; border: 4px solid #e5e7eb; border-top-color: #6366f1; border-radius: 50%; animation: tpcb-spin .8s linear infinite; margin: 0 auto; }
@keyframes tpcb-spin { to { transform: rotate(360deg); } }

.tpcb-mockup-gallery { display: grid; grid-template-columns: repeat(2,1fr); gap: 12px; margin-bottom: 12px; }
@media (min-width: 500px) { .tpcb-mockup-gallery { grid-template-columns: repeat(4,1fr); } }
.tpcb-mockup-img { width: 100%; border-radius: 10px; box-shadow: 0 2px 8px rgba(0,0,0,.1); }
.tpcb-mockup-note { font-size: 13px; color: #6b7280; text-align: center; margin: 4px 0 0; }

.tpcb-summary { background: #f9fafb; border: 1px solid #e5e7eb; border-radius: 12px; padding: 20px; margin-top: 24px; }
.tpcb-summary-table { width: 100%; border-collapse: collapse; font-size: 14px; }
.tpcb-summary-table th { text-align: left; color: #6b7280; font-weight: 500; padding: 6px 0; width: 120px; }
.tpcb-summary-table td { color: #111; font-weight: 600; }

.tpcb-error { background: #fef2f2; border: 1px solid #fca5a5; color: #991b1b; padding: 12px 16px; border-radius: 8px; margin-bottom: 16px; font-size: 14px; }
