/* ═══════════════════════════════════════════════════════════════════════════
   GOAI Consent Checker, Public Shortcode Styles
   ═══════════════════════════════════════════════════════════════════════════ */

/* ─── Variables ─────────────────────────────────────────────────────────── */
.goai-cc {
    --cc-dark: #1b2028;
    --cc-gold: #ccac65;
    --cc-green: #01ce4c;
    --cc-white: #ffffff;
    --cc-bg: #f0f4f8;
    --cc-text: #1e293b;
    --cc-muted: #64748b;
    --cc-border: #e2e8f0;
    --cc-shadow: 0 1px 4px rgba(0,0,0,0.08), 0 4px 16px rgba(0,0,0,0.04);
    --cc-radius: 12px;

    --cc-critic: #dc2626;
    --cc-critic-bg: #fef2f2;
    --cc-high: #ea580c;
    --cc-high-bg: #fff7ed;
    --cc-med: #b45309;
    --cc-med-bg: #fefce8;
    --cc-ok: #01ce4c;
    --cc-ok-bg: #f0fdf4;
    --cc-orange: #d97706;
    --cc-red: #dc2626;

    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    max-width: 900px;
    margin: 0 auto;
    color: var(--cc-text);
    line-height: 1.6;
}

.goai-cc *, .goai-cc *::before, .goai-cc *::after {
    box-sizing: border-box;
}

/* ─── Header ────────────────────────────────────────────────────────────── */
.goai-cc-header {
    background: var(--cc-dark);
    background-image: radial-gradient(ellipse at 30% 50%, rgba(204,172,101,0.12) 0%, transparent 60%);
    color: var(--cc-white);
    padding: 36px 32px;
    border-radius: var(--cc-radius) var(--cc-radius) 0 0;
    text-align: center;
}

.goai-cc-brand {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin-bottom: 16px;
}

.goai-cc-logo {
    font-size: 24px;
    font-weight: 800;
    letter-spacing: 0.12em;
    color: var(--cc-gold);
}

.goai-cc-logo-sub {
    font-size: 14px;
    font-weight: 500;
    color: #94a3b8;
    border-left: 2px solid #334155;
    padding-left: 8px;
}

.goai-cc-title {
    font-size: 26px;
    font-weight: 700;
    margin: 0 0 8px;
    line-height: 1.2;
    color: var(--cc-white);
}

.goai-cc-subtitle {
    font-size: 14px;
    color: #94a3b8;
    margin: 0;
    max-width: 560px;
    margin-left: auto;
    margin-right: auto;
}

/* ─── Form ──────────────────────────────────────────────────────────────── */
.goai-cc-form {
    background: var(--cc-white);
    padding: 24px 32px;
    border-left: 1px solid var(--cc-border);
    border-right: 1px solid var(--cc-border);
}

.goai-cc-input-wrap {
    display: flex;
    gap: 12px;
    align-items: stretch;
}

.goai-cc-input {
    flex: 1;
    padding: 12px 16px;
    font-size: 15px;
    border: 2px solid var(--cc-border);
    border-radius: 8px;
    outline: none;
    transition: border-color 0.2s;
    color: var(--cc-text);
    background: var(--cc-white);
}

.goai-cc-input:focus {
    border-color: var(--cc-gold);
}

.goai-cc-hp {
    position: absolute;
    left: -9999px;
    opacity: 0;
    height: 0;
    width: 0;
    display: none;
}

.goai-cc-btn {
    padding: 12px 24px;
    font-size: 14px;
    font-weight: 700;
    border: none;
    border-radius: 8px;
    background: var(--cc-gold);
    color: var(--cc-dark);
    cursor: pointer;
    transition: background-color 0.2s, transform 0.1s;
    white-space: nowrap;
    display: flex;
    align-items: center;
    gap: 8px;
}

.goai-cc-btn:hover {
    background: #b8993f;
}

.goai-cc-btn:active {
    transform: scale(0.98);
}

.goai-cc-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.goai-cc-spinner {
    display: inline-block;
    width: 16px;
    height: 16px;
    border: 2px solid var(--cc-dark);
    border-top-color: transparent;
    border-radius: 50%;
    animation: goai-spin 0.7s linear infinite;
}

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

.goai-cc-error {
    margin-top: 12px;
    padding: 10px 14px;
    background: var(--cc-critic-bg);
    color: var(--cc-critic);
    border-radius: 6px;
    font-size: 13px;
    font-weight: 500;
}

/* ─── Progress ──────────────────────────────────────────────────────────── */
.goai-cc-progress {
    background: var(--cc-white);
    padding: 20px 32px;
    border-left: 1px solid var(--cc-border);
    border-right: 1px solid var(--cc-border);
}

.goai-cc-progress-bar {
    height: 6px;
    background: #e2e8f0;
    border-radius: 99px;
    overflow: hidden;
    margin-bottom: 10px;
}

.goai-cc-progress-fill {
    height: 100%;
    background: var(--cc-gold);
    border-radius: 99px;
    width: 0%;
    transition: width 0.5s ease;
}

.goai-cc-progress-text {
    font-size: 13px;
    color: var(--cc-muted);
    margin: 0;
    text-align: center;
}

/* ─── Results ───────────────────────────────────────────────────────────── */
.goai-cc-results {
    background: var(--cc-bg);
    padding: 28px 32px;
    border-left: 1px solid var(--cc-border);
    border-right: 1px solid var(--cc-border);
}

/* Overall Score */
.goai-cc-overall {
    display: flex;
    align-items: center;
    gap: 20px;
    background: var(--cc-white);
    border-radius: 10px;
    padding: 24px;
    box-shadow: var(--cc-shadow);
    margin-bottom: 20px;
}

.goai-cc-overall-circle {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    border: 5px solid;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 28px;
    font-weight: 800;
    flex-shrink: 0;
}

.goai-cc-overall-info h3 {
    font-size: 18px;
    font-weight: 700;
    margin: 0 0 4px;
}

.goai-cc-overall-info p {
    font-size: 13px;
    color: var(--cc-muted);
    margin: 0;
}

/* Score Cards */
.goai-cc-scores-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 12px;
    margin-bottom: 20px;
}

.goai-cc-score-card {
    background: var(--cc-white);
    border-radius: 10px;
    padding: 16px 10px;
    text-align: center;
    box-shadow: var(--cc-shadow);
}

.goai-cc-score-label {
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--cc-muted);
    margin-bottom: 6px;
}

.goai-cc-score-number {
    font-size: 32px;
    font-weight: 800;
    line-height: 1;
    margin-bottom: 8px;
}

.goai-cc-score-bar {
    height: 4px;
    background: #e2e8f0;
    border-radius: 99px;
    overflow: hidden;
}

.goai-cc-score-bar-fill {
    height: 100%;
    border-radius: 99px;
}

/* CMP Info */
.goai-cc-cmp-info {
    background: var(--cc-white);
    border-radius: 10px;
    padding: 16px 20px;
    margin-bottom: 20px;
    box-shadow: var(--cc-shadow);
    display: flex;
    align-items: center;
    gap: 12px;
}

.goai-cc-cmp-icon {
    font-size: 24px;
}

.goai-cc-cmp-label {
    font-size: 12px;
    color: var(--cc-muted);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.06em;
}

.goai-cc-cmp-name {
    font-size: 16px;
    font-weight: 700;
}

/* Params Table */
.goai-cc-params {
    background: var(--cc-white);
    border-radius: 10px;
    overflow: hidden;
    margin-bottom: 20px;
    box-shadow: var(--cc-shadow);
}

.goai-cc-params-title {
    background: var(--cc-dark);
    color: var(--cc-gold);
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    padding: 10px 16px;
}

.goai-cc-params table {
    width: 100%;
    border-collapse: collapse;
}

.goai-cc-params th {
    background: #f8fafc;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--cc-muted);
    padding: 8px 16px;
    text-align: left;
    border-bottom: 1px solid var(--cc-border);
}

.goai-cc-params td {
    padding: 8px 16px;
    font-size: 13px;
    border-bottom: 1px solid #f1f5f9;
}

.goai-cc-params tr:last-child td {
    border-bottom: none;
}

.goai-cc-param-status {
    display: inline-block;
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 11px;
    font-weight: 700;
}

.goai-cc-param-denied {
    background: var(--cc-ok-bg);
    color: var(--cc-ok);
}

.goai-cc-param-granted {
    background: var(--cc-critic-bg);
    color: var(--cc-critic);
}

.goai-cc-param-missing {
    background: #f1f5f9;
    color: var(--cc-muted);
}

/* Category Details */
.goai-cc-categories {
    margin-bottom: 20px;
}

.goai-cc-category {
    background: var(--cc-white);
    border-radius: 10px;
    overflow: hidden;
    margin-bottom: 12px;
    box-shadow: var(--cc-shadow);
}

.goai-cc-cat-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 16px;
    cursor: pointer;
    user-select: none;
    background: var(--cc-white);
    border-bottom: 1px solid transparent;
    transition: background-color 0.15s;
}

.goai-cc-cat-header:hover {
    background: #f8fafc;
}

.goai-cc-cat-header.open {
    border-bottom-color: var(--cc-border);
}

.goai-cc-cat-left {
    display: flex;
    align-items: center;
    gap: 10px;
}

.goai-cc-cat-icon {
    font-size: 18px;
}

.goai-cc-cat-name {
    font-size: 14px;
    font-weight: 700;
}

.goai-cc-cat-score {
    font-size: 14px;
    font-weight: 700;
}

.goai-cc-cat-arrow {
    font-size: 12px;
    color: var(--cc-muted);
    transition: transform 0.2s;
}

.goai-cc-cat-header.open .goai-cc-cat-arrow {
    transform: rotate(180deg);
}

.goai-cc-cat-body {
    display: none;
}

.goai-cc-cat-body.open {
    display: block;
}

.goai-cc-check {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 10px 16px;
    border-bottom: 1px solid #f1f5f9;
    font-size: 13px;
}

.goai-cc-check:last-child {
    border-bottom: none;
}

.goai-cc-check-icon {
    flex-shrink: 0;
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    margin-top: 1px;
}

.goai-cc-check-content {
    flex: 1;
}

.goai-cc-check-name {
    font-weight: 600;
    margin-bottom: 2px;
}

.goai-cc-check-detail {
    color: var(--cc-muted);
    font-size: 12px;
    line-height: 1.4;
}

.goai-cc-badge {
    display: inline-block;
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    flex-shrink: 0;
    margin-top: 2px;
}

.goai-cc-badge-ok     { background: var(--cc-ok-bg); color: var(--cc-ok); }
.goai-cc-badge-critic { background: var(--cc-critic-bg); color: var(--cc-critic); }
.goai-cc-badge-high   { background: var(--cc-high-bg); color: var(--cc-high); }
.goai-cc-badge-med    { background: var(--cc-med-bg); color: var(--cc-med); }

/* Report Link */
.goai-cc-report-link {
    text-align: center;
    padding: 16px;
}

.goai-cc-report-link a {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 24px;
    background: var(--cc-dark);
    color: var(--cc-gold);
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
    transition: background-color 0.2s;
}

.goai-cc-report-link a:hover {
    background: #2a3140;
}

/* ─── Footer ────────────────────────────────────────────────────────────── */
.goai-cc-footer {
    background: var(--cc-dark);
    color: #94a3b8;
    padding: 16px 32px;
    border-radius: 0 0 var(--cc-radius) var(--cc-radius);
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 12px;
}

.goai-cc-footer strong {
    color: var(--cc-gold);
    font-weight: 700;
}

.goai-cc-footer a {
    color: var(--cc-gold);
    text-decoration: none;
}

.goai-cc-footer a:hover {
    text-decoration: underline;
}

/* ─── Responsive ────────────────────────────────────────────────────────── */
@media (max-width: 768px) {
    .goai-cc-scores-grid {
        grid-template-columns: repeat(3, 1fr);
    }
    .goai-cc-input-wrap {
        flex-direction: column;
    }
    .goai-cc-header,
    .goai-cc-form,
    .goai-cc-progress,
    .goai-cc-results {
        padding-left: 16px;
        padding-right: 16px;
    }
    .goai-cc-title {
        font-size: 20px;
    }
}

@media (max-width: 480px) {
    .goai-cc-scores-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    .goai-cc-overall {
        flex-direction: column;
        text-align: center;
    }
}
