/* ===================================
   Professional Business Theme
   Color Palette:
   - Primary: #0f172a (Navy)
   - Secondary: #1e293b (Slate)
   - Accent: #3b82f6 (Blue)
   - Success: #10b981 (Green)
   - Text: #334155, #64748b
   - Background: #ffffff, #f8fafc

   Last updated: 2025-12-08
   =================================== */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    overflow-x: hidden;
    max-width: 100%;
}

:root {
    --color-primary: #0f172a;
    --color-secondary: #1e293b;
    --color-accent: #3b82f6;
    --color-success: #10b981;
    --color-text-dark: #334155;
    --color-text-light: #64748b;
    --color-text-lighter: #94a3b8;
    --color-bg-white: #ffffff;
    --color-bg-light: #f8fafc;
    --color-bg-gray: #f1f5f9;
    --color-border: #e2e8f0;
    --color-border-light: #cbd5e1;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    background: linear-gradient(180deg, #f0f4ff 0%, #f8fafc 100%);
    min-height: 100vh;
    color: var(--color-text-dark);
    line-height: 1.6;
    display: flex;
    flex-direction: column;
    position: relative;
    overflow-x: hidden;
    max-width: 100%;
}

/* Subtle background texture */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image:
        radial-gradient(circle at 20% 50%, rgba(59, 130, 246, 0.03) 0%, transparent 50%),
        radial-gradient(circle at 80% 80%, rgba(16, 185, 129, 0.02) 0%, transparent 50%);
    pointer-events: none;
    z-index: 0;
}

/* ===================================
   TOP BANNER
   =================================== */

.top-banner {
    background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%);
    color: white;
    padding: 12px 20px;
    text-align: center;
    font-size: 0.9375rem;
    position: relative;
    z-index: 10;
    box-shadow: 0 2px 8px rgba(59, 130, 246, 0.15);
}

.top-banner-content {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.top-banner-icon {
    font-size: 1.125rem;
}

.top-banner-text {
    font-weight: 500;
}

/* ===================================
   HEADER
   =================================== */

.header {
    background: var(--color-bg-white);
    border-bottom: 1px solid var(--color-border);
    padding: 24px 0;
    box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.05);
    position: relative;
    z-index: 1;
}

.header .logo {
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 0 12px 0;
}

.logo-icon {
    width: 180px;
    height: auto;
    display: block;
}

h1 {
    color: var(--color-primary);
    font-size: 2rem;
    font-weight: 700;
    letter-spacing: -0.025em;
}

.subtitle {
    color: var(--color-text-light);
    font-size: 1.125rem;
    font-weight: 400;
    margin-top: 8px;
    text-align: center;
}

/* ===================================
   CONTAINER & CONTENT
   =================================== */

.container {
    max-width: 840px;
    width: 100%;
    margin: 0 auto;
    padding: 0 20px;
}

.content {
    padding: 48px 0;
}

/* ===================================
   INFO BOXES
   =================================== */

.info-box-small {
    background: var(--color-bg-white);
    border: 1px solid var(--color-border);
    border-left: 3px solid var(--color-accent);
    padding: 20px 24px;
    margin-bottom: 32px;
    border-radius: 6px;
    font-size: 0.9375rem;
    color: var(--color-text-dark);
    line-height: 1.7;
    box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.05);
}

.info-box-small strong {
    color: var(--color-primary);
    font-weight: 600;
}

.info-box-small a,
.info-box-small a:visited {
    color: var(--color-accent);
    text-decoration: none;
    border-bottom: 1px solid rgba(59, 130, 246, 0.3);
    transition: all 0.2s ease;
}

.info-box-small a:hover {
    border-bottom-color: var(--color-accent);
    color: #2563eb;
}

.info-box-detailed {
    background: var(--color-bg-white);
    border: 1px solid var(--color-border);
    border-left: 3px solid var(--color-primary);
    padding: 24px 28px;
    margin-top: 32px;
    border-radius: 6px;
    font-size: 0.9375rem;
    color: var(--color-text-dark);
    line-height: 1.7;
    box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.05);
}

.info-box-detailed strong {
    color: var(--color-primary);
    font-weight: 600;
}

.info-box-detailed a,
.info-box-detailed a:visited {
    color: var(--color-accent);
    text-decoration: none;
    border-bottom: 1px solid rgba(59, 130, 246, 0.3);
    transition: all 0.2s ease;
}

.info-box-detailed a:hover {
    border-bottom-color: var(--color-accent);
    color: #2563eb;
}

.info-box-detailed ul {
    margin: 16px 0;
    padding-left: 24px;
}

.info-box-detailed li {
    margin: 10px 0;
    color: var(--color-text-dark);
}

/* ===================================
   FORM ELEMENTS
   =================================== */

.textarea-wrapper {
    margin-bottom: 24px;
}

label {
    display: block;
    margin-bottom: 10px;
    color: var(--color-primary);
    font-weight: 600;
    font-size: 0.875rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

textarea,
.rich-text-input {
    width: 100%;
    max-width: 100%;
    min-height: 180px;
    padding: 16px;
    border: 1px solid var(--color-border);
    border-radius: 6px;
    font-size: 0.9375rem;
    font-family: inherit;
    resize: vertical;
    transition: all 0.2s ease;
    background: var(--color-bg-white);
    color: var(--color-text-dark);
    overflow-y: auto;
}

.rich-text-input {
    resize: none;
}

.rich-text-input:empty:before {
    content: attr(data-placeholder);
    color: var(--color-text-lighter);
}

textarea::placeholder {
    color: var(--color-text-lighter);
}

textarea:focus,
.rich-text-input:focus {
    outline: none;
    border-color: var(--color-accent);
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

#outputRich {
    background: var(--color-bg-white);
    color: var(--color-text-dark);
    border: 1px solid var(--color-border);
    border-left: 3px solid var(--color-success);
}

#outputRich:empty:before {
    color: var(--color-text-lighter);
}

#outputRich:focus {
    border-color: var(--color-success);
    box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.1);
}

.rich-text-input strong,
#outputRich strong {
    color: var(--color-primary);
    font-weight: 600;
}

.rich-text-input em {
    font-style: italic;
}

.rich-text-input ul,
.rich-text-input ol,
#outputRich ul,
#outputRich ol {
    margin: 10px 0;
    padding-left: 25px;
}

.rich-text-input li,
#outputRich li {
    margin: 6px 0;
    color: var(--color-text-dark);
}

.rich-text-input code,
#outputRich code {
    background: var(--color-bg-gray);
    padding: 2px 6px;
    border-radius: 3px;
    color: var(--color-accent);
    font-family: 'SF Mono', 'Monaco', 'Inconsolata', 'Fira Code', monospace;
    font-size: 0.875em;
}

#outputRich h1,
#outputRich h2,
#outputRich h3,
#outputRich h4 {
    color: var(--color-primary);
    margin: 16px 0 10px 0;
}

#outputRich h1 {
    font-size: 2em;
}

#outputRich h2 {
    font-size: 1.5em;
}

#outputRich h3 {
    font-size: 1.2em;
}

.hidden {
    display: none !important;
}

/* ===================================
   OPTIONS / TOGGLES
   =================================== */

.options-wrapper {
    margin-bottom: 24px;
    padding: 20px;
    background: var(--color-bg-white);
    border-radius: 6px;
    border: 1px solid var(--color-border);
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
    box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.05);
}

@media (max-width: 768px) {
    .options-wrapper {
        grid-template-columns: 1fr;
    }
}

.option-item {
    display: flex;
    align-items: center;
    gap: 12px;
}

.toggle-switch {
    position: relative;
    width: 50px;
    height: 26px;
    flex-shrink: 0;
}

.toggle-switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: var(--color-border-light);
    transition: .3s;
    border-radius: 26px;
}

.slider:before {
    position: absolute;
    content: "";
    height: 20px;
    width: 20px;
    left: 3px;
    bottom: 3px;
    background-color: white;
    transition: .3s;
    border-radius: 50%;
    box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1);
}

input:checked + .slider {
    background-color: var(--color-accent);
}

input:checked + .slider:before {
    transform: translateX(24px);
}

.option-label {
    color: var(--color-text-dark);
    font-size: 0.9375rem;
    cursor: pointer;
    user-select: none;
}

/* ===================================
   BUTTONS
   =================================== */

.button-group {
    display: flex;
    gap: 12px;
    margin-bottom: 24px;
    flex-wrap: wrap;
}

button {
    flex: 1;
    min-width: 140px;
    padding: 12px 24px;
    font-size: 0.9375rem;
    font-weight: 600;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s ease;
    letter-spacing: 0.025em;
}

.btn-clean {
    background: var(--color-accent);
    color: white;
    box-shadow: 0 1px 3px 0 rgba(59, 130, 246, 0.2);
}

.btn-clean:hover {
    background: #2563eb;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.3);
}

.btn-clean:active {
    transform: translateY(0);
}

.btn-copy {
    background: var(--color-success);
    color: white;
    box-shadow: 0 1px 3px 0 rgba(16, 185, 129, 0.2);
}

.btn-copy:hover {
    background: #059669;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(16, 185, 129, 0.3);
}

.btn-copy:active {
    transform: translateY(0);
}

.btn-clear {
    background: var(--color-bg-white);
    color: var(--color-text-dark);
    border: 1px solid var(--color-border);
    box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.05);
}

.btn-clear:hover {
    background: var(--color-bg-gray);
    border-color: var(--color-border-light);
}

/* ===================================
   STATS & WARNINGS
   =================================== */

.stats {
    background: var(--color-bg-white);
    padding: 20px 24px;
    border-radius: 6px;
    margin-top: 24px;
    font-size: 0.875rem;
    color: var(--color-text-light);
    border: 1px solid var(--color-border);
    box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.05);
}

.stats-item {
    display: inline-block;
    margin-right: 24px;
    margin-bottom: 8px;
}

.stats-item strong {
    color: var(--color-primary);
    font-weight: 600;
}

.ai-detection-warning {
    background: #fef3c7;
    border: 1px solid #fbbf24;
    border-left: 3px solid #f59e0b;
    border-radius: 6px;
    padding: 20px 24px;
    margin-top: 24px;
    display: none;
    box-shadow: 0 1px 3px 0 rgba(245, 158, 11, 0.1);
}

.ai-detection-warning h4 {
    color: #92400e;
    margin: 0 0 12px 0;
    font-size: 1rem;
    font-weight: 600;
}

.ai-detection-warning p {
    color: #92400e;
    margin: 8px 0;
    line-height: 1.6;
    font-size: 0.9375rem;
}

.ai-detection-warning .ai-details {
    font-size: 0.875rem;
    color: #78350f;
    background: rgba(251, 191, 36, 0.1);
    padding: 10px 14px;
    border-radius: 4px;
    margin: 12px 0;
}

.ai-detection-warning .ai-note {
    font-size: 0.875rem;
    margin-top: 12px;
    padding-top: 12px;
    border-top: 1px solid rgba(251, 191, 36, 0.3);
}

.ai-detection-warning a,
.ai-detection-warning a:visited {
    color: var(--color-accent);
    text-decoration: none;
    border-bottom: 1px solid rgba(59, 130, 246, 0.3);
    transition: all 0.2s ease;
}

.ai-detection-warning a:hover {
    border-bottom-color: var(--color-accent);
    color: #2563eb;
}

.markdown-preview {
    background: var(--color-bg-white);
    border: 1px solid var(--color-border);
    border-radius: 6px;
    padding: 20px 24px;
    margin-top: 24px;
    display: none;
}

.markdown-preview > h3 {
    color: var(--color-text-dark);
    margin-bottom: 14px;
    font-size: 1rem;
    font-weight: 600;
    padding-bottom: 10px;
    border-bottom: 1px solid var(--color-border);
}

.markdown-preview-content {
    color: var(--color-text-dark);
    line-height: 1.6;
}

.markdown-preview-content h1,
.markdown-preview-content h2,
.markdown-preview-content h3,
.markdown-preview-content h4 {
    color: var(--color-text-dark);
    margin: 14px 0 8px 0;
    font-weight: 600;
}

.markdown-preview-content h1 {
    font-size: 1.5em;
}

.markdown-preview-content h2 {
    font-size: 1.25em;
}

.markdown-preview-content h3 {
    font-size: 1.1em;
}

.markdown-preview-content strong {
    font-weight: 600;
    color: var(--color-text-dark);
}

.markdown-preview-content code {
    background: var(--color-bg-gray);
    padding: 2px 6px;
    border-radius: 3px;
    color: var(--color-text-dark);
    font-family: 'SF Mono', 'Monaco', 'Inconsolata', monospace;
    font-size: 0.9em;
}

.markdown-preview-content pre {
    background: var(--color-bg-gray);
    padding: 12px 16px;
    border-radius: 6px;
    overflow-x: auto;
    margin: 12px 0;
}

.markdown-preview-content pre code {
    background: none;
    padding: 0;
}

.markdown-preview-content ul,
.markdown-preview-content ol {
    margin: 12px 0;
    padding-left: 25px;
}

.markdown-preview-content li {
    margin: 4px 0;
    color: var(--color-text-dark);
}

.markdown-preview-content a,
.markdown-preview-content a:visited {
    color: var(--color-accent);
    text-decoration: none;
}

.markdown-preview-content a:hover {
    text-decoration: underline;
}

/* ===================================
   NOTIFICATION
   =================================== */

.notification {
    position: fixed;
    top: 20px;
    right: 20px;
    background: var(--color-success);
    color: white;
    padding: 14px 20px;
    border-radius: 6px;
    box-shadow: 0 10px 25px rgba(16, 185, 129, 0.3);
    opacity: 0;
    transform: translateX(400px);
    transition: all 0.3s ease;
    z-index: 1000;
    font-size: 0.9375rem;
    font-weight: 600;
}

.notification.show {
    opacity: 1;
    transform: translateX(0);
}

/* ===================================
   FOOTER
   =================================== */

footer {
    background: var(--color-bg-white);
    border-top: 1px solid var(--color-border);
    color: var(--color-text-light);
    text-align: center;
    margin-top: auto;
    padding: 32px 20px;
    font-size: 0.875rem;
}

footer a,
footer a:visited {
    color: var(--color-text-dark);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.2s ease;
    padding: 0 8px;
}

footer a:hover {
    color: var(--color-accent);
}

footer .separator {
    color: var(--color-border-light);
    margin: 0 4px;
}

/* ===================================
   CONTENT PAGES (Impressum, Datenschutz)
   =================================== */

.content-page {
    max-width: 100%;
    color: var(--color-text-dark);
    line-height: 1.7;
}

.content-page h1 {
    color: var(--color-primary);
    font-size: 2rem;
    margin: 0 0 32px 0;
    padding-bottom: 16px;
    border-bottom: 2px solid var(--color-border);
    font-weight: 700;
    letter-spacing: -0.025em;
}

.content-page h2 {
    color: var(--color-primary);
    font-size: 1.375rem;
    margin: 32px 0 16px 0;
    font-weight: 600;
}

.content-page h3 {
    color: var(--color-secondary);
    font-size: 1.125rem;
    margin: 24px 0 12px 0;
    font-weight: 600;
}

.content-page p {
    margin: 16px 0;
    color: var(--color-text-dark);
    font-size: 1rem;
}

.content-page ul,
.content-page ol {
    margin: 16px 0;
    padding-left: 28px;
}

.content-page li {
    margin: 10px 0;
    color: var(--color-text-dark);
    line-height: 1.7;
}

.content-page a,
.content-page a:visited {
    color: var(--color-accent);
    text-decoration: none;
    border-bottom: 1px solid rgba(59, 130, 246, 0.3);
    transition: all 0.2s ease;
}

.content-page a:hover {
    border-bottom-color: var(--color-accent);
    color: #2563eb;
}

.content-page strong {
    color: var(--color-primary);
    font-weight: 600;
}

.content-page code {
    background: var(--color-bg-gray);
    padding: 2px 6px;
    border-radius: 3px;
    color: var(--color-accent);
    font-family: 'SF Mono', 'Monaco', monospace;
    font-size: 0.875em;
}

/* ===================================
   INFO BOX VARIANTS & ELEMENTS
   =================================== */

.info-box-detailed.success-border {
    border-left-color: var(--color-success);
}

/* Override default padding for donate box */
.success-border.info-box-detailed {
    padding: 16px 20px;
}

.info-box-heading {
    color: var(--color-primary);
    font-size: 1.5rem;
    margin-bottom: 24px;
    padding-bottom: 12px;
    border-bottom: 2px solid var(--color-border);
}

.info-box-subheading {
    color: var(--color-primary);
    font-size: 1.125rem;
    margin-top: 24px;
    margin-bottom: 12px;
}

.info-box-subheading.success-color {
    color: var(--color-success);
    font-size: 1.25rem;
    margin-top: 0;
    margin-bottom: 16px;
}

.info-box-note {
    font-size: 0.875rem;
    color: var(--color-text-light);
}

/* ===================================
   DONATE SECTION
   =================================== */

.donate-buttons {
    margin: 20px 0;
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

/* Make donate button more specific to override link styles */
.info-box-detailed .donate-button,
.info-box-detailed .donate-button:visited {
    display: inline-block;
    padding: 12px 24px;
    text-decoration: none;
    border-radius: 6px;
    font-weight: 600;
    transition: all 0.2s ease;
    color: white;
    border-bottom: none;
}

.info-box-detailed .donate-button.kofi {
    background: var(--color-success);
}

.info-box-detailed .donate-button.kofi:hover {
    background: #059669;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(16, 185, 129, 0.3);
}

.info-box-detailed .donate-button.github {
    background: var(--color-primary);
}

.info-box-detailed .donate-button.github:hover {
    background: var(--color-secondary);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(15, 23, 42, 0.3);
}
