/* === B2B PRODUKTBESCHREIBUNG GENERATOR - STYLES === */
/* Angepasst an industrie-fachwissen.de Design */

:root { 
    --primary: #d97a1f; 
    --primary-hover: #c06a14; 
    --bg: #fafafa; 
    --text: #1a1a1a; 
    --dark: #333; 
    --gray: #666; 
    --gray-light: #999; 
    --border: #e5e5e5; 
    --white: #fff; 
    --header-bg: #1a1a1a; 
    --danger: #c00; 
    --success: #48bb78; 
    --ochre-light: #fff6ed;
    --font-body: 'DM Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    --font-heading: 'DM Serif Display', Georgia, 'Times New Roman', serif;
}

* { 
    box-sizing: border-box; 
    margin: 0; 
    padding: 0; 
}

body { 
    font-family: var(--font-body); 
    background: var(--bg); 
    color: var(--text); 
    height: 100vh; 
    overflow: hidden; 
    display: flex; 
    flex-direction: column; 
}

/* === ANNOUNCEMENT BAR === */
.announcement { 
    background: var(--header-bg); 
    color: white; 
    padding: 8px 20px; 
    text-align: center; 
    font-size: 12px; 
    font-weight: 600; 
    z-index: 100; 
}

.announcement a { 
    color: var(--primary); 
    text-decoration: underline; 
}

/* === HEADER/FOOTER (FIXED) === */
header, footer { 
    flex-shrink: 0; 
    background: var(--header-bg); 
    color: white; 
    padding: 15px 30px; 
    display: flex; 
    justify-content: space-between; 
    align-items: center; 
    z-index: 50; 
}

.logo { 
    font-family: var(--font-heading);
    font-size: 20px; 
    font-weight: 400; 
    color: var(--primary);
}

.logo span { 
    color: white; 
}

.user-menu { 
    font-size: 13px; 
    font-weight: 600; 
    display: flex; 
    gap: 15px; 
    align-items: center; 
}

.buy-btn { 
    background: var(--primary); 
    color: white; 
    padding: 6px 14px; 
    border-radius: 3px; 
    text-decoration: none; 
    border: none; 
    cursor: pointer; 
    font-size: 12px; 
    font-weight: 600;
    transition: background 0.15s;
}

.buy-btn:hover {
    background: var(--primary-hover);
}

.login-btn { 
    background: var(--primary); 
    color: white; 
    padding: 6px 14px; 
    border-radius: 3px; 
    border: none; 
    cursor: pointer; 
    font-size: 12px; 
    font-weight: 600;
    transition: background 0.15s;
}

.login-btn:hover {
    background: var(--primary-hover);
}

/* === MAIN SPLIT LAYOUT === */
.container { 
    flex: 1; 
    display: flex; 
    overflow: hidden; 
    gap: 20px; 
    padding: 20px; 
    max-width: 1600px; 
    margin: 0 auto; 
    width: 100%; 
}

.panel { 
    background: var(--white); 
    border: 1px solid var(--border);
    display: flex; 
    flex-direction: column; 
    height: 100%; 
    overflow: hidden; 
}

.panel-scroll { 
    flex: 1; 
    overflow-y: auto; 
    padding: 25px; 
    scrollbar-width: thin; 
}

.input-panel { 
    flex: 0 0 450px; 
    border-right: 1px solid var(--border); 
}

.output-panel { 
    flex: 1; 
}

/* === LANDING INTRO === */
.landing-intro { 
    padding: 40px 60px; 
    background: var(--ochre-light);
    border: 1px solid var(--border);
    max-width: 900px;
    margin: 0 auto;
}

.landing-intro h1 {
    font-family: var(--font-heading);
    font-size: 32px;
    color: var(--text);
    margin-bottom: 15px;
    border: none;
    padding: 0;
    font-weight: 400;
    -webkit-text-fill-color: initial;
    background: none;
    -webkit-background-clip: initial;
}

.landing-intro h2 {
    font-family: var(--font-heading);
    font-size: 20px;
    color: var(--text);
    margin: 25px 0 12px 0;
    font-weight: 400;
}

.landing-intro p {
    font-size: 15px;
    line-height: 1.7;
    color: var(--gray);
    margin-bottom: 15px;
}

.landing-intro ul {
    list-style: none;
    padding-left: 0;
    margin: 15px 0;
}

.landing-intro li {
    padding: 8px 0 8px 28px;
    position: relative;
    font-size: 14px;
    color: var(--dark);
    line-height: 1.6;
}

.landing-intro li:before {
    content: "✓";
    position: absolute;
    left: 0;
    color: var(--primary);
    font-weight: bold;
    font-size: 16px;
}

.feature-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 15px;
    margin: 20px 0;
}

.feature-card {
    background: white;
    padding: 15px;
    border: 1px solid var(--border);
    text-align: center;
}

.feature-card strong {
    display: block;
    color: var(--primary);
    font-size: 13px;
    margin-bottom: 5px;
}

.feature-card span {
    font-size: 12px;
    color: var(--gray-light);
}

.cta-intro {
    text-align: center;
    margin-top: 30px;
    padding: 20px;
    background: white;
    border: 2px solid var(--primary);
}

.cta-intro p {
    font-size: 16px;
    font-weight: 600;
    color: var(--primary);
    margin: 0;
}

/* === FORM STYLES === */
h1 { 
    font-family: var(--font-heading);
    font-size: 20px; 
    margin-bottom: 20px; 
    border-bottom: 2px solid var(--border); 
    padding-bottom: 10px; 
    font-weight: 400;
}

.form-group { 
    margin-bottom: 15px; 
}

label { 
    display: block; 
    margin-bottom: 5px; 
    font-size: 12px; 
    font-weight: 700; 
    color: var(--dark); 
}

label.required::after { 
    content: " *"; 
    color: var(--danger); 
}

input, textarea, select { 
    width: 100%; 
    padding: 10px; 
    border: 1px solid var(--border); 
    border-radius: 3px; 
    font-size: 13px; 
    font-family: inherit; 
}

input:focus, textarea:focus, select:focus {
    outline: 0;
    border-color: var(--primary);
}

textarea { 
    min-height: 80px; 
    resize: vertical; 
}

/* === COLLAPSIBLE === */
.collapsible { 
    border: 1px solid var(--border); 
    margin-bottom: 10px; 
    overflow: hidden; 
}

.c-head { 
    background: var(--bg); 
    padding: 10px 15px; 
    cursor: pointer; 
    font-weight: 600; 
    font-size: 13px; 
    display: flex; 
    justify-content: space-between; 
}

.c-head:hover {
    background: var(--ochre-light);
}

.c-body { 
    display: none; 
    padding: 15px; 
    border-top: 1px solid var(--border); 
    background: white; 
}

.c-body.active { 
    display: block; 
}

/* === BUILDER === */
.builder { 
    background: var(--bg); 
    padding: 10px; 
    border: 1px dashed var(--border); 
    margin-top: 10px; 
}

.blk { 
    background: white; 
    padding: 8px; 
    border: 1px solid var(--border); 
    margin-bottom: 5px; 
    display: flex; 
    justify-content: space-between; 
    font-size: 12px; 
    cursor: move; 
}

.mini-btn { 
    padding: 3px 8px; 
    font-size: 11px; 
    cursor: pointer; 
    border-radius: 3px; 
    border: 1px solid var(--border); 
    background: var(--bg); 
}

.mini-btn:hover {
    border-color: var(--primary);
    color: var(--primary);
}

/* === TABS & PREVIEW === */
.out-head { 
    padding: 15px; 
    border-bottom: 1px solid var(--border); 
    display: flex; 
    gap: 10px; 
    flex-wrap: wrap;
}

.tab-btn { 
    padding: 6px 12px; 
    background: var(--bg); 
    border: 1px solid var(--border); 
    border-radius: 3px; 
    cursor: pointer; 
    font-size: 12px; 
    font-weight: 600; 
    color: var(--gray); 
    transition: all 0.15s;
}

.tab-btn:hover {
    border-color: var(--primary);
    color: var(--primary);
}

.tab-btn.active { 
    background: var(--primary); 
    color: white; 
    border-color: var(--primary);
}

.tab-pane { 
    display: none; 
    margin-top: 15px; 
}

.tab-pane.active { 
    display: block; 
}

.preview-box { 
    padding: 25px; 
    border: 1px solid var(--border); 
    background: white; 
    min-height: 400px; 
}

.preview-box h1 { 
    font-family: var(--font-heading);
    font-size: 32px; 
    font-weight: 400; 
    line-height: 1.2; 
    margin: 0 0 24px 0; 
    color: var(--text); 
    border: none;
}

.preview-box h2 { 
    font-family: var(--font-heading);
    font-size: 22px; 
    font-weight: 400; 
    line-height: 1.3; 
    margin: 32px 0 16px 0; 
    color: var(--text); 
}

.preview-box h3 { 
    font-size: 18px; 
    font-weight: 600; 
    line-height: 1.4; 
    margin: 24px 0 12px 0; 
    color: var(--dark); 
}

.preview-box p { 
    font-size: 16px; 
    line-height: 1.7; 
    margin: 0 0 16px 0; 
    color: var(--dark); 
}

.preview-box ul, .preview-box ol { 
    margin: 16px 0; 
    padding-left: 24px; 
}

.preview-box li { 
    margin-bottom: 8px; 
    line-height: 1.6; 
}

.code-box { 
    background: var(--header-bg); 
    color: #e5e5e5; 
    padding: 20px; 
    font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace; 
    font-size: 13px; 
    line-height: 1.6;
    white-space: pre-wrap; 
    word-wrap: break-word;
    position: relative; 
    overflow-x: auto;
    max-height: 600px;
    overflow-y: auto;
}

.btn-gen { 
    width: 100%; 
    padding: 15px; 
    background: var(--primary); 
    color: white; 
    border: none; 
    border-radius: 3px; 
    font-weight: 700; 
    font-size: 14px;
    cursor: pointer; 
    margin-top: 20px; 
    transition: background 0.15s;
}

.btn-gen:hover {
    background: var(--primary-hover);
}

/* ENHANCED LOADER */
.loader-container {
    display: none;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    margin: 120px auto;
    text-align: center;
    max-width: 450px;
    padding: 40px 20px;
}

.loader-content {
    text-align: center;
}

.loader-spinner {
    width: 60px;
    height: 60px;
    border: 4px solid var(--border);
    border-top: 4px solid var(--primary);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 30px;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

.loader-status {
    font-family: var(--font-heading);
    font-size: 20px;
    font-weight: 400;
    color: var(--primary);
    margin-bottom: 12px;
    min-height: 28px;
    animation: fadeInUp 0.6s ease-out forwards;
    -webkit-text-fill-color: initial;
    background: none;
    -webkit-background-clip: initial;
}

.loader-substatus {
    font-size: 14px;
    color: var(--gray-light);
    margin-bottom: 30px;
    min-height: 20px;
    animation: fadeInUp 0.6s ease-out 0.15s forwards;
    opacity: 0;
}

.loader-progress-bar {
    width: 100%;
    max-width: 350px;
    height: 6px;
    background: var(--border);
    overflow: hidden;
    margin: 0 auto;
}

.loader-progress-fill {
    height: 100%;
    width: 0%;
    background: var(--primary);
    transition: width 0.6s ease;
}

/* === AUTH MODAL === */
.modal { 
    position: fixed; 
    top:0; 
    left:0; 
    width:100%; 
    height:100%; 
    background:rgba(0,0,0,0.5); 
    z-index:999; 
    display:none; 
    justify-content:center; 
    align-items:center; 
}

.modal-box { 
    background:white; 
    padding:30px; 
    width:100%; 
    max-width:420px; 
    border: 1px solid var(--border);
}

.auth-inp { 
    width:100%; 
    margin-bottom:10px; 
    padding:12px; 
    border:1px solid var(--border); 
    border-radius:3px; 
    font-family: var(--font-body);
}

.auth-inp:focus {
    outline: 0;
    border-color: var(--primary);
}

.auth-btn { 
    width:100%; 
    padding:12px; 
    background:var(--primary); 
    color:white; 
    border:none; 
    border-radius:3px; 
    font-weight:bold; 
    cursor:pointer; 
    font-family: var(--font-body);
    transition: background 0.15s;
}

.auth-btn:hover {
    background: var(--primary-hover);
}

.link { 
    color:var(--primary); 
    cursor:pointer; 
    text-decoration:underline; 
    font-size:12px; 
    background:none; 
    border:none; 
}

/* === SLIDER === */
.slider-container { 
    display: flex; 
    align-items: center; 
    gap: 10px; 
}

.slider { 
    flex: 1; 
}

.slider-value { 
    min-width: 40px; 
    font-weight: bold; 
    color: var(--primary); 
}

/* === LINK BLOCK === */
.link-block { 
    border: 1px solid var(--border); 
    padding: 10px; 
    margin-bottom: 10px; 
    background: var(--bg); 
}

.link-block-header { 
    display: flex; 
    justify-content: space-between; 
    align-items: center; 
    margin-bottom: 8px; 
    font-size: 11px; 
    font-weight: 600; 
    color: var(--dark); 
}

.link-position-btns { 
    display: flex; 
    gap: 5px; 
    margin-top: 5px; 
}

.pos-btn { 
    padding: 4px 10px; 
    font-size: 10px; 
    border: 1px solid var(--border); 
    background: white; 
    border-radius: 3px; 
    cursor: pointer; 
    transition: all 0.15s;
}

.pos-btn:hover {
    border-color: var(--primary);
    color: var(--primary);
}

.pos-btn.active { 
    background: var(--primary); 
    color: white; 
    border-color: var(--primary); 
}

.add-link-btn { 
    width: 100%; 
    padding: 8px; 
    background: var(--ochre-light); 
    color: var(--primary); 
    border: 1px dashed var(--primary); 
    cursor: pointer; 
    font-size: 11px; 
    font-weight: 600; 
    margin-top: 10px; 
    transition: background 0.15s;
}

.add-link-btn:hover {
    background: #ffe8d0;
}

/* === FILE UPLOAD === */
.file-display { 
    display: none; 
    background: var(--ochre-light); 
    border: 1px solid var(--primary); 
    padding: 8px; 
    margin-top: 5px; 
    font-size: 11px; 
    color: var(--dark); 
    align-items: center; 
    justify-content: space-between; 
}

.file-remove { 
    color: var(--danger); 
    cursor: pointer; 
    font-weight: bold; 
}

/* === ACTION BUTTONS === */
.action-btns { 
    display: flex; 
    gap: 8px; 
    margin-bottom: 10px; 
}

.action-btn { 
    padding: 8px 16px; 
    background: var(--primary); 
    color: white; 
    border: none; 
    border-radius: 3px; 
    cursor: pointer; 
    font-size: 12px; 
    font-weight: 600; 
    transition: background 0.15s;
}

.action-btn:hover { 
    background: var(--primary-hover); 
}

/* === WORD COUNT BADGE === */
.word-count-badge { 
    display: inline-block; 
    background: var(--primary); 
    color: white; 
    padding: 4px 12px; 
    border-radius: 3px; 
    font-size: 11px; 
    font-weight: 700; 
    margin-left: 10px; 
}

/* === LOGIN REQUIRED OVERLAY === */
.login-required {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 60vh;
    text-align: center;
    padding: 40px;
}

.login-required h2 {
    font-family: var(--font-heading);
    font-size: 28px;
    margin-bottom: 15px;
    color: var(--text);
    font-weight: 400;
    -webkit-text-fill-color: initial;
    background: none;
    -webkit-background-clip: initial;
}

.login-required p {
    color: var(--gray);
    font-size: 15px;
    margin-bottom: 25px;
    max-width: 500px;
}

.login-required .login-btn {
    padding: 12px 30px;
    font-size: 16px;
    font-weight: 700;
}

/* === API KEY SECTION === */
.api-key-section {
    background: var(--ochre-light);
    padding: 15px;
    margin-bottom: 15px;
    border-left: 4px solid var(--primary);
}

.api-key-section label {
    font-size: 13px;
    font-weight: 700;
    color: var(--dark);
}

/* === COPY FEEDBACK === */
.copy-success {
    display: inline-block;
    color: var(--success);
    font-size: 12px;
    font-weight: 600;
    opacity: 0;
    transition: opacity 0.3s;
    margin-left: 10px;
}

.copy-success.show {
    opacity: 1;
}

/* === RESPONSIVE === */
@media (max-width: 900px) { 
    .container { 
        flex-direction: column; 
        overflow: auto; 
    } 
    .input-panel { 
        flex: none; 
        max-height: 500px; 
    } 
    body { 
        overflow: auto; 
    }
    .landing-intro { 
        padding: 25px 20px; 
    }
    .landing-intro h1 { 
        font-size: 24px; 
    }
    .feature-grid { 
        grid-template-columns: 1fr; 
    }
    .out-head {
        flex-wrap: wrap;
    }
    header {
        flex-direction: column;
        gap: 10px;
        text-align: center;
    }
}

@media (max-width: 800px) {
    .cost-model-grid {
        grid-template-columns: 1fr !important;
    }
}

@media (max-width: 768px) {
    .loader-container { 
        margin: 80px auto; 
        padding: 30px 15px;
    }
    .loader-spinner { 
        width: 50px; 
        height: 50px; 
    }
    .loader-status { 
        font-size: 18px; 
    }
    .loader-substatus { 
        font-size: 13px; 
    }
}