/**
 * GEO Citation Widget – Frontend Styles
 *
 * Minimales, professionelles Design.
 * Kompatibel mit den meisten WordPress-Themes.
 */

.gcw-citation-box {
    position: relative;
    margin: 2em 0;
    padding: 1.5em 1.8em;
    background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
    border-top: 1px solid #e2e8f0 !important;
    border-right: 1px solid #e2e8f0 !important;
    border-bottom: 1px solid #e2e8f0 !important;
    border-left: 1px solid #e2e8f0 !important;
    border-radius: 8px;
    font-family: inherit;
    font-size: inherit;
    line-height: inherit;
    scroll-margin-top: 80px;
}

/* Header mit Icon und Frage */
.gcw-citation-header {
    display: flex;
    align-items: flex-start;
    gap: 0.6em;
    margin-bottom: 0.8em;
}

.gcw-citation-icon {
    flex-shrink: 0;
    color: #3b82f6;
    margin-top: 0.15em;
}

.gcw-citation-question {
    margin: 0 !important;
    padding: 0 !important;
    font-size: 1.1em;
    font-weight: 700;
    color: inherit;
    line-height: 1.4;
}

/* Antwort */
.gcw-answer-text {
    margin: 0 0 0.8em 0;
    color: inherit;
    font-size: inherit;
}

/* Kernpunkte */
.gcw-citation-box .gcw-keypoints {
    margin: 0.6em 0 0.4em 0;
    padding: 0;
}

.gcw-citation-box .gcw-keypoint-item {
    padding: 0.25em 0;
    color: inherit;
    font-size: inherit;
    line-height: 1.6;
}

.gcw-citation-box .gcw-check {
    color: #22c55e;
    font-weight: 700;
    margin-right: 0.3em;
}

/* Datum */
.gcw-citation-date {
    margin-top: 0.6em;
    font-size: 0.85em;
    color: #94a3b8;
}

/* Quellen */
.gcw-citation-sources {
    margin-top: 1em;
    padding-top: 0.8em;
    border-top: 1px solid #e2e8f0;
}

.gcw-sources-label {
    font-size: 0.85em;
    font-weight: 600;
    color: #64748b;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.gcw-citation-box .gcw-sources-list {
    margin: 0.4em 0 0 0;
    padding: 0;
    display: flex;
    flex-wrap: wrap;
    gap: 0.4em 1em;
}

.gcw-citation-box .gcw-source-item {
    font-size: inherit;
}

.gcw-sources-list a {
    color: #3b82f6;
    text-decoration: none;
    border-bottom: 1px solid transparent;
    transition: border-color 0.2s ease;
}

.gcw-sources-list a:hover {
    border-bottom-color: #3b82f6;
}

/* Action-Buttons */
.gcw-citation-actions {
    display: flex;
    gap: 0.6em;
    margin-top: 1em;
    padding-top: 0.8em;
    border-top: 1px solid #e2e8f0;
}

.gcw-copy-link,
.gcw-copy-citation {
    display: inline-flex;
    align-items: center;
    gap: 0.4em;
    padding: 0.4em 0.8em;
    background: #ffffff;
    border: 1px solid #cbd5e1;
    border-radius: 6px;
    font-size: 0.82em;
    color: #475569;
    cursor: pointer;
    transition: all 0.2s ease;
    font-family: inherit;
    line-height: 1.4;
}

.gcw-copy-link:hover,
.gcw-copy-citation:hover {
    background: #f1f5f9;
    border-color: #3b82f6;
    color: #3b82f6;
}

.gcw-copy-link:focus,
.gcw-copy-citation:focus {
    outline: 2px solid #3b82f6;
    outline-offset: 2px;
}

.gcw-copy-link svg,
.gcw-copy-citation svg {
    flex-shrink: 0;
}

.gcw-copy-link.gcw-copied,
.gcw-copy-citation.gcw-copied {
    background: #f0fdf4;
    border-color: #22c55e;
    color: #16a34a;
}

/* Responsive */
@media (max-width: 600px) {
    .gcw-citation-box {
        padding: 1.2em 1em;
        margin: 1.5em 0;
    }

    .gcw-citation-actions {
        flex-direction: column;
    }

    .gcw-copy-link,
    .gcw-copy-citation {
        justify-content: center;
    }
}

/* Dark Mode Unterstützung */
@media (prefers-color-scheme: dark) {
    .gcw-citation-box {
        background: linear-gradient(135deg, #1e293b 0%, #0f172a 100%);
        border-color: #334155;
    }

    .gcw-citation-question {
        color: #f1f5f9;
    }

    .gcw-answer-text {
        color: #cbd5e1;
    }

    .gcw-citation-box .gcw-keypoint-item {
        color: #94a3b8;
    }

    .gcw-citation-sources {
        border-top-color: #334155;
    }

    .gcw-citation-actions {
        border-top-color: #334155;
    }

    .gcw-copy-link,
    .gcw-copy-citation {
        background: #1e293b;
        border-color: #475569;
        color: #94a3b8;
    }

    .gcw-copy-link:hover,
    .gcw-copy-citation:hover {
        background: #334155;
    }
}

/* Print */
@media print {
    .gcw-citation-actions {
        display: none;
    }

    .gcw-citation-box {
        border: 1px solid #999;
        page-break-inside: avoid;
    }
}
