/* ============================
   BizCheck Marketing - Frontend
   Clean light theme
   ============================ */

/* Reset & Container */
.bizcheck-container {
    max-width: 720px;
    margin: 2rem auto;
    padding: 0 1rem;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    color: #1e293b;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

.bizcheck-container *,
.bizcheck-container *::before,
.bizcheck-container *::after {
    box-sizing: border-box;
}

/* Card */
.bizcheck-card {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04), 0 1px 2px rgba(0, 0, 0, 0.06);
    transition: box-shadow 0.2s ease;
}

.bizcheck-card:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.06), 0 2px 4px rgba(0, 0, 0, 0.04);
}

.bizcheck-card-mt {
    margin-top: 1rem;
}

.bizcheck-card-header {
    padding: 1.5rem 1.5rem 0;
}

.bizcheck-card-body {
    padding: 1rem 1.5rem 1.5rem;
}

/* Step badge */
.bizcheck-step-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: #3b82f6;
    color: #fff;
    font-size: 0.8rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
}

/* Typography */
.bizcheck-title {
    font-size: 1.25rem;
    font-weight: 700;
    color: #0f172a;
    margin: 0 0 0.25rem;
}

.bizcheck-subtitle {
    font-size: 0.875rem;
    color: #64748b;
    margin: 0;
}

.bizcheck-label {
    display: block;
    font-size: 0.875rem;
    font-weight: 600;
    color: #334155;
    margin-bottom: 0.5rem;
}

.bizcheck-hint {
    font-size: 0.75rem;
    color: #94a3b8;
    margin: 0.5rem 0 0;
}

.bizcheck-error {
    font-size: 0.8rem;
    color: #ef4444;
    margin: 0.5rem 0 0;
    padding: 0.5rem 0.75rem;
    background: #fef2f2;
    border-radius: 6px;
    border: 1px solid #fecaca;
}

/* Input group */
.bizcheck-input-group {
    margin: 0;
}

.bizcheck-input-wrap {
    display: flex;
    gap: 0.5rem;
}

.bizcheck-input {
    flex: 1;
    padding: 0.75rem 1rem;
    border: 1.5px solid #e2e8f0;
    border-radius: 8px;
    font-size: 1rem;
    color: #1e293b;
    background: #f8fafc;
    transition: border-color 0.2s, box-shadow 0.2s;
    outline: none;
}

.bizcheck-input:focus {
    border-color: #3b82f6;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.12);
    background: #fff;
}

.bizcheck-input::placeholder {
    color: #94a3b8;
}

/* Buttons */
.bizcheck-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.75rem 1.25rem;
    border: none;
    border-radius: 8px;
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.15s ease;
    white-space: nowrap;
}

.bizcheck-btn-primary {
    background: #3b82f6;
    color: #fff;
}

.bizcheck-btn-primary:hover {
    background: #2563eb;
}

.bizcheck-btn-primary:active {
    background: #1d4ed8;
    transform: scale(0.98);
}

.bizcheck-btn-primary:disabled {
    background: #93c5fd;
    cursor: not-allowed;
}

.bizcheck-btn-outline {
    background: #fff;
    color: #3b82f6;
    border: 1.5px solid #3b82f6;
}

.bizcheck-btn-outline:hover {
    background: #eff6ff;
}

.bizcheck-btn-back {
    margin-top: 1rem;
    font-size: 0.85rem;
    padding: 0.5rem 1rem;
}

/* Spinner */
.bizcheck-spinner {
    display: inline-block;
    width: 16px;
    height: 16px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-top-color: #fff;
    border-radius: 50%;
    animation: bizcheck-spin 0.6s linear infinite;
}

@keyframes bizcheck-spin {
    to { transform: rotate(360deg); }
}

/* Status card */
.bizcheck-status-card {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem;
    background: #f8fafc;
    border-radius: 8px;
    border: 1px solid #e2e8f0;
}

.bizcheck-dot {
    display: block;
    width: 14px;
    height: 14px;
    border-radius: 50%;
    background: #94a3b8;
    box-shadow: 0 0 0 4px rgba(148, 163, 184, 0.15);
}

.bizcheck-dot.green {
    background: #22c55e;
    box-shadow: 0 0 0 4px rgba(34, 197, 94, 0.15);
}

.bizcheck-dot.orange {
    background: #f97316;
    box-shadow: 0 0 0 4px rgba(249, 115, 22, 0.15);
}

.bizcheck-dot.red {
    background: #ef4444;
    box-shadow: 0 0 0 4px rgba(239, 68, 68, 0.15);
}

.bizcheck-status-brn {
    font-size: 1.1rem;
    font-weight: 700;
    color: #0f172a;
    font-variant-numeric: tabular-nums;
}

.bizcheck-status-label {
    font-size: 0.9rem;
    font-weight: 600;
}

.bizcheck-status-detail {
    font-size: 0.8rem;
    color: #64748b;
    margin-top: 0.125rem;
}

/* ======= Validate Card ======= */

.bizcheck-required {
    color: #ef4444;
    font-weight: 700;
}

.bizcheck-validate-toggle {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    padding: 1rem 1.5rem;
    background: #f8fafc;
    border: none;
    cursor: pointer;
    font-size: 0.95rem;
    font-weight: 600;
    color: #334155;
    transition: background 0.2s, color 0.2s;
}

.bizcheck-validate-toggle:hover {
    background: #f1f5f9;
    color: #1e293b;
}

.bizcheck-validate-toggle.active {
    background: #eff6ff;
    color: #2563eb;
}

.bizcheck-validate-toggle-arrow {
    font-size: 0.7rem;
    transition: transform 0.2s;
}

.bizcheck-validate-panel {
    animation: bizcheck-slideDown 0.25s ease;
}

@keyframes bizcheck-slideDown {
    from { opacity: 0; max-height: 0; }
    to { opacity: 1; max-height: 600px; }
}

.bizcheck-validate-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.75rem;
}

.bizcheck-validate-grid .bizcheck-input-group {
    margin: 0;
}

.bizcheck-input-full {
    grid-column: 1 / -1;
}

.bizcheck-validate-grid .bizcheck-input-group:last-child:nth-child(odd) {
    grid-column: 1 / -1;
}

.bizcheck-validate-more-toggle {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    background: none;
    border: none;
    color: #64748b;
    font-size: 0.8rem;
    font-weight: 500;
    cursor: pointer;
    padding: 0.5rem 0;
    margin-top: 0.5rem;
    transition: color 0.2s;
}

.bizcheck-validate-more-toggle:hover {
    color: #3b82f6;
}

.bizcheck-validate-more-toggle span {
    font-size: 0.6rem;
}

.bizcheck-validate-more-panel {
    margin-top: 0.5rem;
    animation: bizcheck-slideDown 0.25s ease;
}

.bizcheck-validate-actions {
    margin-top: 1rem;
}

/* Validate result */
.bizcheck-validate-result {
    margin-top: 1rem;
}

.bizcheck-validate-result-inner {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 1rem;
    border-radius: 8px;
    animation: bizcheck-fadeIn 0.35s ease;
}

.bizcheck-validate-result-inner.bizcheck-validate-match {
    background: #f0fdf4;
    border: 1px solid #bbf7d0;
}

.bizcheck-validate-result-inner.bizcheck-validate-mismatch {
    background: #fef2f2;
    border: 1px solid #fecaca;
}

.bizcheck-validate-result-inner.bizcheck-validate-unknown {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
}

.bizcheck-validate-badge {
    flex-shrink: 0;
    font-size: 0.75rem;
    font-weight: 700;
    padding: 0.25rem 0.75rem;
    border-radius: 999px;
    white-space: nowrap;
}

.bizcheck-validate-badge.bizcheck-validate-match {
    background: #dcfce7;
    color: #16a34a;
}

.bizcheck-validate-badge.bizcheck-validate-mismatch {
    background: #fee2e2;
    color: #dc2626;
}

.bizcheck-validate-badge.bizcheck-validate-unknown {
    background: #e2e8f0;
    color: #64748b;
}

.bizcheck-validate-msg {
    font-size: 0.85rem;
    color: #475569;
    line-height: 1.4;
}

/* Step transition animation */
.bizcheck-step {
    animation: bizcheck-fadeIn 0.35s ease;
}

@keyframes bizcheck-fadeIn {
    from { opacity: 0; transform: translateY(12px); }
    to { opacity: 1; transform: translateY(0); }
}

/* ======= Step 3: Results ======= */

/* Loading card */
.bizcheck-loading-card {
    text-align: center;
    padding: 3rem 1.5rem;
}

.bizcheck-loading-spinner {
    width: 48px;
    height: 48px;
    border: 3px solid #e2e8f0;
    border-top-color: #3b82f6;
    border-radius: 50%;
    margin: 0 auto 1rem;
    animation: bizcheck-spin 0.8s linear infinite;
}

.bizcheck-loading-text {
    font-size: 1rem;
    font-weight: 600;
    color: #334155;
    margin: 0 0 1rem;
}

.bizcheck-loading-channel {
    font-size: 0.85rem;
    color: #64748b;
    margin-top: 0.5rem;
}

.bizcheck-progress-bar {
    width: 100%;
    max-width: 300px;
    height: 6px;
    background: #e2e8f0;
    border-radius: 3px;
    margin: 0 auto;
    overflow: hidden;
}

.bizcheck-progress-fill {
    height: 100%;
    width: 0%;
    background: linear-gradient(90deg, #3b82f6, #60a5fa);
    border-radius: 3px;
    transition: width 0.5s ease;
}

/* Grade card */
.bizcheck-grade-card {
    padding: 1.5rem;
    margin-bottom: 1rem;
}

.bizcheck-grade-wrapper {
    display: flex;
    align-items: center;
    gap: 1.5rem;
}

.bizcheck-grade-circle {
    flex-shrink: 0;
    width: 80px;
    height: 80px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f1f5f9;
    border: 4px solid #3b82f6;
}

.bizcheck-grade-letter {
    font-size: 2rem;
    font-weight: 800;
    color: #3b82f6;
}

.bizcheck-grade-title {
    font-size: 1.15rem;
    font-weight: 700;
    color: #0f172a;
    margin: 0 0 0.25rem;
}

.bizcheck-grade-score {
    font-size: 0.95rem;
    color: #475569;
}

.bizcheck-grade-label {
    font-size: 0.85rem;
    font-weight: 600;
    margin-top: 0.25rem;
}

/* Channel grid */
.bizcheck-channels-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.75rem;
    margin-bottom: 1rem;
}

/* Channel card */
.bizcheck-channel-card {
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    padding: 1.25rem;
    transition: box-shadow 0.2s;
}

.bizcheck-channel-card:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.06);
}

.bizcheck-channel-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 0.75rem;
}

.bizcheck-channel-icon {
    width: 36px;
    height: 36px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
    font-weight: 700;
    color: #fff;
}

.bizcheck-channel-icon.blog    { background: #03c75a; }
.bizcheck-channel-icon.place   { background: #1ec800; }
.bizcheck-channel-icon.youtube { background: #ff0000; }
.bizcheck-channel-icon.instagram { background: linear-gradient(45deg, #f09433, #e6683c, #dc2743, #cc2366, #bc1888); }
.bizcheck-channel-icon.tiktok  { background: #010101; }
.bizcheck-channel-icon.homepage { background: #3b82f6; }

.bizcheck-channel-badge {
    font-size: 0.7rem;
    font-weight: 700;
    padding: 0.2rem 0.5rem;
    border-radius: 999px;
}

.bizcheck-channel-badge.found {
    background: #dcfce7;
    color: #16a34a;
}

.bizcheck-channel-badge.not-found {
    background: #fef2f2;
    color: #dc2626;
}

.bizcheck-channel-name {
    font-size: 0.85rem;
    font-weight: 600;
    color: #334155;
    margin-bottom: 0.5rem;
}

/* Score bar */
.bizcheck-score-bar {
    width: 100%;
    height: 8px;
    background: #f1f5f9;
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 0.5rem;
}

.bizcheck-score-fill {
    height: 100%;
    border-radius: 4px;
    background: #3b82f6;
    transition: width 0.8s ease;
}

.bizcheck-score-text {
    font-size: 0.8rem;
    color: #64748b;
}

.bizcheck-score-text strong {
    color: #1e293b;
}

.bizcheck-channel-link {
    display: inline-block;
    margin-top: 0.5rem;
    font-size: 0.75rem;
    color: #3b82f6;
    text-decoration: none;
}

.bizcheck-channel-link:hover {
    text-decoration: underline;
}

/* Recommendations */
.bizcheck-recs-card {
    margin-bottom: 1rem;
}

.bizcheck-recs-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.bizcheck-recs-list li {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    padding: 0.75rem 0;
    border-bottom: 1px solid #f1f5f9;
}

.bizcheck-recs-list li:last-child {
    border-bottom: none;
}

.bizcheck-rec-priority {
    flex-shrink: 0;
    font-size: 0.65rem;
    font-weight: 700;
    text-transform: uppercase;
    padding: 0.15rem 0.5rem;
    border-radius: 999px;
}

.bizcheck-rec-priority.high {
    background: #fef2f2;
    color: #dc2626;
}

.bizcheck-rec-priority.medium {
    background: #fffbeb;
    color: #d97706;
}

.bizcheck-rec-priority.low {
    background: #f0fdf4;
    color: #16a34a;
}

.bizcheck-rec-text {
    font-size: 0.85rem;
    color: #475569;
    line-height: 1.5;
}

/* Actions */
.bizcheck-actions {
    text-align: center;
    margin-top: 0.5rem;
}

/* ======= Responsive ======= */

@media (max-width: 768px) {
    .bizcheck-container {
        margin: 1rem auto;
    }

    .bizcheck-channels-grid {
        grid-template-columns: 1fr;
    }

    .bizcheck-validate-grid {
        grid-template-columns: 1fr;
    }

    .bizcheck-grade-wrapper {
        flex-direction: column;
        text-align: center;
    }

    .bizcheck-input-wrap {
        flex-direction: column;
    }

    .bizcheck-btn {
        width: 100%;
    }
}

@media (max-width: 480px) {
    .bizcheck-card-header {
        padding: 1rem 1rem 0;
    }

    .bizcheck-card-body {
        padding: 0.75rem 1rem 1rem;
    }

    .bizcheck-title {
        font-size: 1.1rem;
    }

    .bizcheck-grade-circle {
        width: 64px;
        height: 64px;
    }

    .bizcheck-grade-letter {
        font-size: 1.6rem;
    }

    .bizcheck-channel-card {
        padding: 1rem;
    }
}
