* {
    box-sizing: border-box;
}

body {
    margin: 0;
    background: #fffdf7;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
    color: #14251f;
}

.page {
    max-width: 1100px;
    margin: 0 auto;
    padding: 40px 24px 80px;
}

header h1 {
    font-size: 42px;
    font-weight: 800;
    margin: 0 0 8px;
    color: #0f2a22;
}

.subtitle {
    color: #6b7b76;
    font-size: 16px;
    margin: 0 0 28px;
}

.banner {
    border-radius: 10px;
    padding: 20px 24px;
    margin-bottom: 20px;
    border-left: 6px solid #2f9e5e;
    background: #e9fbf0;
}

.banner-warn {
    border-left-color: #d99a2b;
    background: #fff6e3;
}

.banner-title {
    font-weight: 700;
    font-size: 18px;
    margin-bottom: 12px;
}

.login-info-row {
    color: #33443e;
    font-size: 14px;
    margin: 4px 0;
}

.login-form {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.field-row {
    display: flex;
    gap: 10px;
}

.field-row input {
    flex: 1;
    padding: 10px 12px;
    border-radius: 8px;
    border: 1px solid #cfd6d3;
    font-size: 14px;
}

.hidden {
    display: none !important;
}

.btn {
    cursor: pointer;
    border: none;
    border-radius: 10px;
    font-weight: 600;
    font-size: 14px;
    padding: 12px 16px;
}

.btn-primary {
    background: #e6702b;
    color: #fff;
}

.btn-primary:hover {
    background: #d4611f;
}

.btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.status-msg {
    min-height: 20px;
    font-size: 14px;
    margin-bottom: 12px;
    color: #b3261e;
}

.status-msg.ok {
    color: #1e7f43;
}

.btn-card {
    background: #fff;
    border: 1px solid #dde3e0;
    border-radius: 10px;
    padding: 20px 10px;
    text-align: center;
    color: #14251f;
}

.btn-card:hover {
    border-color: #b8c1bd;
}

.btn-highlight {
    background: #e6702b;
    color: #fff;
    border-color: #e6702b;
}

.btn-highlight:hover {
    background: #d4611f;
}

.btn-dark {
    background: #0f2a22;
    color: #fff;
}

.btn-dark:hover {
    background: #0a1f19;
}

.btn-link {
    background: none;
    color: #1e6b8c;
    padding: 6px 0;
    text-decoration: underline;
}

.btn-choose {
    background: #fff;
    border: 1px solid #cfd6d3;
    color: #14251f;
    padding: 8px 14px;
}

.btn-choose:hover {
    border-color: #b8c1bd;
}

.csv-status,
.automation-status {
    background: #f4f6f5;
    border-radius: 10px;
    padding: 20px 24px;
    margin-bottom: 16px;
}

.csv-status-title {
    font-weight: 700;
    margin-bottom: 6px;
}

.csv-status-body {
    color: #33443e;
    font-size: 14px;
    white-space: pre-line;
}

.drop-zone {
    border: 2px dashed #c7d0cc;
    border-radius: 10px;
    background: #f4f6f5;
    text-align: center;
    padding: 40px 20px;
    margin-bottom: 16px;
    cursor: pointer;
}

.drop-zone.drag-over {
    border-color: #e6702b;
    background: #fff3ea;
}

.drop-icon {
    font-size: 30px;
    margin-bottom: 8px;
}

.drop-text {
    font-size: 15px;
    color: #33443e;
}

.drop-subtext {
    font-size: 13px;
    color: #7a8985;
    margin-bottom: 12px;
}

.drop-file-row {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    font-size: 13px;
    color: #33443e;
}

.progress-card {
    background: #eef4f1;
    border-left: 6px solid #2f9e5e;
    border-radius: 10px;
    padding: 20px 24px;
    margin-bottom: 16px;
}

.progress-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

.progress-badge {
    font-weight: 700;
    color: #1e6b8c;
    font-size: 14px;
}

.progress-bar-track {
    background: #dbe3df;
    border-radius: 6px;
    height: 8px;
    margin-bottom: 10px;
    overflow: hidden;
}

.progress-bar-fill {
    background: #e6702b;
    height: 100%;
    width: 0%;
    transition: width 0.3s ease;
}

.progress-text {
    color: #33443e;
    font-size: 14px;
    margin-bottom: 2px;
}

.progress-actions {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-top: 14px;
}

.stats-row {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
    margin-bottom: 16px;
}

.stat-card {
    background: #f4f6f5;
    border-left: 4px solid #e6702b;
    border-radius: 8px;
    padding: 18px 20px;
}

.stat-number {
    font-size: 30px;
    font-weight: 800;
    color: #0f2a22;
}

.stat-label {
    color: #6b7b76;
    font-size: 14px;
    margin-top: 4px;
}

.response-mix {
    background: #fff;
    border: 1px solid #dde3e0;
    border-radius: 10px;
    padding: 20px 24px;
    margin-bottom: 24px;
}

.mix-row {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-top: 10px;
}

.mix-label {
    width: 90px;
    font-size: 14px;
    color: #33443e;
}

.mix-bar-track {
    flex: 1;
    background: #eef1f0;
    border-radius: 6px;
    height: 14px;
    overflow: hidden;
}

.mix-bar {
    height: 100%;
    width: 0%;
    transition: width 0.3s ease;
}

.mix-success {
    background: #2f9e5e;
}

.mix-failed {
    background: #e6702b;
}

.mix-pending {
    background: #5f746d;
}

.mix-count {
    width: 60px;
    text-align: right;
    font-weight: 600;
    font-size: 14px;
}

.ledger-header {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    margin-bottom: 12px;
}

.ledger-header h2 {
    margin: 0;
    font-size: 20px;
}

.ledger-count {
    color: #6b7b76;
    font-size: 14px;
}

.ledger-filters {
    display: flex;
    gap: 10px;
    margin-bottom: 14px;
}

.ledger-filters input,
.ledger-filters select {
    padding: 10px 12px;
    border-radius: 8px;
    border: 1px solid #cfd6d3;
    font-size: 14px;
}

.ledger-filters input {
    flex: 1;
}

.ledger-table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 14px;
    font-size: 14px;
    table-layout: fixed;
}

.ledger-table thead tr {
    background: #0f2a22;
    color: #fff;
}

.ledger-table th,
.ledger-table td {
    padding: 10px 12px;
    text-align: left;
    overflow-wrap: break-word;
}

.ledger-table th:nth-child(5),
.ledger-table td:nth-child(5) {
    width: 32%;
}

.ledger-table th:nth-child(6),
.ledger-table td:nth-child(6) {
    width: 12%;
}

.ledger-table tbody tr:nth-child(even) {
    background: #f7f9f8;
}

.status-pill {
    padding: 3px 10px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 600;
    display: inline-block;
}

.status-success {
    background: #dff5e6;
    color: #1e7f43;
}

.status-already_registered {
    background: #fff0d6;
    color: #a06a0f;
}

.status-failed {
    background: #fde3e0;
    color: #b3261e;
}

.status-pending {
    background: #eef1f0;
    color: #5f746d;
}

.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 16px;
    margin-bottom: 40px;
}

@media (max-width: 800px) {
    .stats-row {
        grid-template-columns: 1fr;
    }
}
