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

body {
    font-family: Arial, sans-serif;
    background-color: #ffffff;
    line-height: 1.4;
    font-size: 16px;
    padding-bottom: 90px;
}

body::after {
    content: "Writing Practice";
    position: fixed;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%) rotate(-20deg);
    font-size: 72px;
    font-weight: 800;
    letter-spacing: 2px;
    color: #000000;
    opacity: 0.02;
    pointer-events: none;
    z-index: 0;
    white-space: nowrap;
}

.header {
    background-color: #ffffff;
    padding: 12px 20px;
    border-bottom: 1px solid #e0e0e0;
    display: flex;
    justify-content: flex-start;
    align-items: center;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 100;
    height: 60px;
    gap: 20px;
}

.header-logo {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.header-logo img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.header-title-section {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    justify-content: center;
    gap: 2px;
}

.header-title-section > div:first-child {
    font-size: 18px;
    font-weight: bold;
    color: #333;
}

.main-container {
    margin-top: 60px;
    display: flex;
    background: #ffffff;
    padding-bottom: 100px;
    overflow: hidden;
}

.left-panel {
    width: 50%;
    flex: 0 0 auto;
    padding: 30px;
    overflow-y: auto;
    height: calc(100vh - 195px);
    border-right: 1px solid #e0e0e0;
}

.right-panel {
    width: 50%;
    flex: 0 0 auto;
    padding: 30px;
    overflow-y: auto;
    height: calc(100vh - 195px);
    display: flex;
    flex-direction: column;
}

.resizer {
    width: 10px;
    background-color: #e0e0e0;
    cursor: col-resize;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    border-left: 1px solid #ccc;
    border-right: 1px solid #ccc;
    transition: background-color 0.2s;
    height: calc(100vh - 195px);
}

.resizer:hover,
.resizer.active {
    background-color: #d0d0d0;
}

.resizer-handle {
    width: 24px;
    height: 40px;
    background: #fff;
    border: 1px solid #aaa;
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    color: #555;
    font-weight: bold;
    user-select: none;
    cursor: col-resize;
}

.page {
    display: none;
}

.page.active {
    display: block;
}

.page-title {
    font-size: 22px;
    font-weight: bold;
    margin-bottom: 20px;
    color: #333;
}

.task-description {
    font-size: 16px;
    line-height: 1.8;
    color: #555;
    margin-bottom: 20px;
    padding: 15px;
    background: #f8f9fa;
    border-radius: 8px;
    border-left: 4px solid #0056e0;
}

.task-hints {
    margin-top: 15px;
    padding: 12px;
    background: #f0f7ff;
    border-radius: 6px;
    font-size: 14px;
    color: #0056e0;
}

.task-hints strong {
    display: block;
    margin-bottom: 8px;
}

.textarea {
    width: 100%;
    height: 400px;
    border: 2px solid #ddd;
    border-radius: 8px;
    padding: 15px;
    font-family: Arial, sans-serif;
    font-size: 14px;
    resize: vertical;
    transition: border-color 0.3s;
    background-color: #ffffff;
    min-height: 200px;
}

.textarea:focus {
    outline: none;
    border-color: #0056e0;
    box-shadow: 0 0 8px rgba(0, 86, 224, 0.1);
}

.word-count {
    font-size: 13px;
    color: #666;
    margin-top: 8px;
    text-align: right;
}

.word-count.warning {
    color: #ff9800;
    font-weight: bold;
}

.word-count.error {
    color: #dc3545;
    font-weight: bold;
}

.file-input-group {
    margin-top: 20px;
}

.file-label {
    display: block;
    font-weight: bold;
    margin-bottom: 8px;
    color: #333;
}

input[type=file] {
    margin-top: 10px;
    padding: 8px;
}

.nav-row {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: #ffffff;
    padding: 0;
    display: flex;
    align-items: center;
    height: 80px;
    z-index: 100;
    border-top: 1px solid #e0e0e0;
    overflow-x: auto;
    overflow-y: hidden;
    white-space: nowrap;
}

.footer__questionWrapper___1tZ46 {
    display: flex;
    align-items: center;
    margin-right: 20px;
    margin-left: 20px;
    flex-shrink: 0;
}

.footer__questionNo___3WNct {
    background: none;
    border: none;
    padding: 10px 15px;
    font-size: 16px;
    font-weight: 600;
    color: #333;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 5px;
    transition: background-color 0.2s;
    border-radius: 4px;
}

.footer__questionNo___3WNct:hover {
    background-color: #f8f9fa;
}

.footer__questionNo___3WNct.active {
    background-color: #0056e0;
    color: white;
}

.footer__deliverButton___3FM07 {
    margin-left: auto;
    margin-right: 10px;
    background-color: #f0f0f0;
    color: #333;
    border: 1px solid #ccc;
    padding: 12px 20px;
    border-radius: 4px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: background-color 0.2s, border-color 0.2s;
    min-width: 170px;
    justify-content: center;
    flex-shrink: 0;
}

.footer__deliverButton___3FM07:hover {
    background-color: #e0e0e0;
    border-color: #bbb;
}

.footer__deliverButton___3FM07.success {
    background-color: #28a745;
    color: #fff;
    border-color: #28a745;
}

.footer__deliverButton___3FM07.success:hover {
    background-color: #218838;
    border-color: #1e7e34;
}

.footer__deliverButton___3FM07:disabled {
    background: #e9ecef;
    color: #6c757d;
    cursor: not-allowed;
    border-color: #ddd;
}

.footer__exitButton___3FM07 {
    margin-right: 20px;
    background-color: #f0f0f0;
    color: #333;
    border: 1px solid #ccc;
    padding: 12px 20px;
    border-radius: 4px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: background-color 0.2s, border-color 0.2s;
    min-width: 100px;
    justify-content: center;
    flex-shrink: 0;
}

.footer__exitButton___3FM07:hover {
    background-color: #e0e0e0;
    border-color: #bbb;
}

.nav-arrows {
    position: fixed;
    bottom: 100px;
    right: 20px;
    display: flex;
    gap: 10px;
    z-index: 101;
}

.nav-btn {
    width: 50px;
    height: 50px;
    background: #f5f5f5;
    color: #888;
    border: 2px solid #d0d0d0;
    border-radius: 8px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.nav-btn:hover:not(:disabled) {
    background: #e8e8e8;
    border-color: #bbb;
}

.nav-btn:disabled {
    background: #f5f5f5;
    border-color: #e0e0e0;
    color: #ccc;
    opacity: 0.5;
    cursor: not-allowed;
}

.nav-btn svg {
    pointer-events: none;
}

.fa-check::before {
    content: "✓";
}

.back-link {
    color: #0056e0;
    text-decoration: none;
    font-weight: 600;
    margin-right: 20px;
    flex-shrink: 0;
}

.back-link:hover {
    text-decoration: underline;
}

.timer-display {
    font-size: 13px;
    font-weight: normal;
    color: #666;
    padding: 4px 8px;
    background: transparent;
    border-radius: 4px;
    text-align: center;
}

.timer-display.warning {
    color: #ff6b00;
}

.timer-display.critical {
    color: #dc3545;
    animation: pulse-timer 1s infinite;
}

@keyframes pulse-timer {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.7; }
}

@media (max-width: 1024px) {
    .left-panel {
        width: 45%;
        padding: 20px;
    }

    .right-panel {
        width: 55%;
        padding: 20px;
    }

    .textarea {
        height: 300px;
    }
}

@media (max-width: 768px) {
    .main-container {
        flex-direction: column;
    }

    .left-panel {
        width: 100%;
        height: auto;
        border-right: none;
        border-bottom: 1px solid #e0e0e0;
        padding: 20px;
    }

    .right-panel {
        width: 100%;
        height: auto;
        padding: 20px;
    }

    .textarea {
        height: 250px;
    }
}
