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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
    background: #CCC5B9;
    color: #C1121F;
    min-height: 100vh;
    padding: 40px;
    display: flex;
    flex-direction: column;
}

.header {
    text-align: center;
    margin-bottom: 20px;
}

h1 {
    color: #C1121F;
    font-size: 2rem;
    font-weight: 800;
    letter-spacing: 0.2em;
    margin-bottom: 15px;
}

#statusBox {
    background: #27272a;
    border: 1px solid #3f3f46;
    color: #10b981;
    padding: 8px 16px;
    border-radius: 6px;
    display: inline-block;
    font-size: 1rem;
    font-weight: 500;
}

.main-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    max-width: 1600px;
    margin: 0 auto;
    width: 100%;
    gap: 15px;
}

.text-box {
    background: #18181b;
    border: 1px solid #27272a;
    border-radius: 8px;
    flex: 1;
    display: flex;
    flex-direction: column;
    min-height: 0;
}

.text-box h2 {
    background: #403D39;
    color: #ffffff;
    padding: 12px 16px;
    margin: 0;
    font-size: 0.875rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    border-bottom: 1px solid #3f3f46;
}

.text-container {
    flex: 1;
    padding: 16px;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
    /*font-family: 'SF Mono', 'Monaco', 'Inconsolata', 'Roboto Mono', monospace; */
    font-size: 18px;
    line-height: 1.5;
    border: none;
    outline: none;
    background: #FFFCF2;
    color: #000000;
    resize: none;
    overflow-y: auto;
    min-height: 200px;
}

.text-container:focus {
    background: #FFFCF2;
}

#diffContainer {
    white-space: pre-wrap;
    word-wrap: break-word;
}

.button-row {
    display: flex;
    justify-content: center;
    gap: 12px;
    padding: 0 20px;
}

button {
    background: #403D39;
    color: #FFFCF2;
    border: 1px solid #3f3f46;
    padding: 10px 20px;
    border-radius: 6px;
    font-size: 0.875rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.15s ease;
}

button:hover {
    background: #3f3f46;
    border-color: #52525b;
}

button:active {
    background: #18181b;
}

#sendButton {
    background: #403D39;
    border-color: #3b82f6;
}

#sendButton:hover {
    background: #1d4ed8;
    border-color: #2563eb;
}

/* Custom scrollbar */
.text-container::-webkit-scrollbar {
    width: 8px;
}

.text-container::-webkit-scrollbar-track {
    background: #18181b;
}

.text-container::-webkit-scrollbar-thumb {
    background: #3f3f46;
    border-radius: 4px;
}

.text-container::-webkit-scrollbar-thumb:hover {
    background: #52525b;
}

/* Layout for desktop */
@media (min-width: 768px) {
    .main-content {
        flex-direction: row;
        height: calc(100vh - 140px);
    }

    .text-box {
        flex: 1;
        max-width: calc(50% - 80px);
    }

    .button-row {
        flex-direction: column;
        width: 160px;
        justify-content: center;
        align-items: center;
        padding: 20px;
    }

    button {
        width: 60%;
        margin: 0;
    }
}



.insert {
    background: #d8eed3;
}


/* Mobile adjustments */
@media (max-width: 800px) {
    .main-content {
        height: calc(100vh - 120px);
    }

    .text-container {
        min-height: 150px;
    }
}