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

body {
    font-family: Arial, sans-serif;
    background-color: #f5f5f5;
    color: #333;
    line-height: 1.6;
}

.container {
    max-width: 800px;
    margin: 0 auto;
    padding: 20px;
    background-color: white;
    min-height: 100vh;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
}

header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 12px;
    border-bottom: 2px solid #ff7b00;
}

h1 {
    color: #8b4513;
    font-size: 2em;
    font-weight: bold;
}

.language-selector {
    display: flex;
    gap: 8px;
    align-items: center;
}

.flag-btn {
    background: none;
    border: 2px solid transparent;
    border-radius: 6px;
    padding: 6px 8px;
    font-size: 20px;
    cursor: pointer;
    transition: all 0.2s ease;
    opacity: 0.6;
}

.flag-btn:hover {
    opacity: 1;
    transform: scale(1.1);
    border-color: #ff7b00;
}

.flag-btn.active {
    opacity: 1;
    border-color: #ff7b00;
    background-color: rgba(255, 123, 0, 0.1);
}

.status-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 6px 12px;
    margin-bottom: 12px;
    background-color: #f9f9f9;
    border-radius: 4px;
    border-left: 3px solid #28a745;
}

.status-bar.warning {
    border-left-color: #ffc107;
}

.status-bar.danger {
    border-left-color: #dc3545;
}

.status-indicator {
    display: flex;
    align-items: center;
    gap: 8px;
}

.status-icon {
    font-size: 20px;
    color: #28a745;
}

.status-bar.warning .status-icon {
    color: #ffc107;
}

.status-bar.danger .status-icon {
    color: #dc3545;
}

.list-title-section {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.title-with-status {
    display: flex;
    align-items: center;
    gap: 8px;
}

.title-with-status .status-icon {
    font-size: 16px;
    color: #28a745;
    cursor: help;
}

.title-with-status .status-icon.warning {
    color: #ffc107;
}

.title-with-status .status-icon.danger {
    color: #dc3545;
}

.list-totals {
    font-weight: normal;
    color: #666;
    font-size: 12px;
}

.settings {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
    margin-bottom: 25px;
    padding: 20px;
    background-color: #f9f9f9;
    border-radius: 8px;
}

.settings-item {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.settings-item label {
    font-weight: bold;
    color: #8b4513;
}

.settings-item input {
    padding: 8px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
}

.add-item-form {
    background-color: #f9f9f9;
    padding: 20px;
    border-radius: 8px;
    margin-bottom: 25px;
}

.form-group {
    margin-bottom: 15px;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
}

.form-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: bold;
    color: #8b4513;
}

.form-group input {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
}

.form-group input:focus {
    outline: none;
    border-color: #ff7b00;
    box-shadow: 0 0 5px rgba(255, 123, 0, 0.3);
}

button {
    background-color: #ff7b00;
    color: white;
    border: none;
    padding: 12px 20px;
    border-radius: 5px;
    cursor: pointer;
    font-size: 14px;
    font-weight: bold;
    transition: background-color 0.2s;
}

button:hover {
    background-color: #e66a00;
}

button:active {
    transform: translateY(1px);
}


.lists-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin-bottom: 25px;
}

.list-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 1px solid #ddd;
}

.list-section h2 {
    color: #8b4513;
    margin: 0;
}

.list-actions {
    display: flex;
    gap: 8px;
    align-items: center;
}

.add-item-btn,
.list-action-btn {
    background: none;
    border: none;
    font-size: 20px;
    cursor: pointer;
    padding: 8px;
    border-radius: 50%;
    transition: background-color 0.2s, transform 0.1s;
    color: #ff7b00;
}

.add-item-btn:hover,
.list-action-btn:hover {
    background-color: #f0f0f0;
    transform: scale(1.1);
}

.add-item-btn:active,
.list-action-btn:active {
    transform: scale(0.95);
}

.items-list {
    list-style: none;
}

.item {
    background-color: #f9f9f9;
    padding: 15px;
    margin-bottom: 10px;
    border-radius: 5px;
    border-left: 4px solid #ff7b00;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.item.completed {
    opacity: 0.7;
    border-left-color: #28a745;
    background-color: #f0f8f0;
}

.item-info {
    flex: 1;
}

.item-name {
    font-weight: bold;
    color: #8b4513;
    margin-bottom: 5px;
}

.item-details {
    font-size: 12px;
    color: #666;
}

.item-actions {
    display: flex;
    gap: 8px;
}

.item-actions button {
    padding: 8px 12px;
    font-size: 16px;
    min-width: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: none;
    border: none;
    cursor: pointer;
    border-radius: 50%;
    transition: background-color 0.2s, transform 0.1s;
}

.item-actions button:hover {
    background-color: #f0f0f0;
    transform: scale(1.1);
}

.item-actions button:active {
    transform: scale(0.95);
}

.actions {
    display: flex;
    gap: 10px;
    margin-bottom: 30px;
    flex-wrap: wrap;
    justify-content: center;
}

.integrations-options {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.integration-btn {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 10px;
    padding: 15px 20px;
    border: 2px solid #ddd;
    border-radius: 8px;
    background-color: white;
    color: #8b4513;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.2s ease;
    font-size: 16px;
    font-weight: bold;
    width: 100%;
    text-align: left;
}

.integration-btn:hover {
    border-color: #ff7b00;
    background-color: rgba(255, 123, 0, 0.05);
    transform: translateY(-1px);
}

.integration-icon {
    font-size: 20px;
    min-width: 24px;
    display: inline-block;
    text-align: center;
}


footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 0;
    border-top: 1px solid #ddd;
    color: #666;
    font-size: 14px;
}

.footer-buttons {
    display: flex;
    gap: 8px;
    align-items: center;
}

.footer-content {
    flex: 1;
    text-align: center;
}

footer a {
    color: #ff7b00;
    text-decoration: none;
}

footer a:hover {
    text-decoration: underline;
}

/* Dark Mode Styles */
body.dark-mode {
    background-color: #1a1a1a;
    color: #e0e0e0;
}

body.dark-mode .container {
    background-color: #2d2d2d;
    box-shadow: 0 0 10px rgba(255, 255, 255, 0.1);
}

body.dark-mode header {
    border-bottom: 2px solid #8b4513;
}

body.dark-mode h1 {
    color: #ff7b00;
}

body.dark-mode .flag-btn:hover {
    border-color: #8b4513;
}

body.dark-mode .flag-btn.active {
    border-color: #8b4513;
    background-color: rgba(139, 69, 19, 0.1);
}

body.dark-mode .dark-mode-btn {
    background: none;
    border: 2px solid transparent;
    border-radius: 6px;
    padding: 6px 8px;
    font-size: 20px;
    cursor: pointer;
    transition: all 0.2s ease;
    opacity: 0.6;
    color: #e0e0e0;
}

body.dark-mode .dark-mode-btn:hover {
    opacity: 1;
    transform: scale(1.1);
    border-color: #8b4513;
}

.dark-mode-btn {
    background: none;
    border: 2px solid transparent;
    border-radius: 6px;
    padding: 6px 8px;
    font-size: 20px;
    cursor: pointer;
    transition: all 0.2s ease;
    opacity: 0.6;
    color: #333;
}

.dark-mode-btn:hover {
    opacity: 1;
    transform: scale(1.1);
    border-color: #ff7b00;
}

body.dark-mode .status-bar {
    background-color: #3a3a3a;
}

body.dark-mode .list-header {
    border-bottom: 1px solid #555;
}

body.dark-mode .list-section h2 {
    color: #ff7b00;
}

body.dark-mode .add-item-btn,
body.dark-mode .list-action-btn {
    color: #8b4513;
}

body.dark-mode .add-item-btn:hover,
body.dark-mode .list-action-btn:hover {
    background-color: #444;
}

body.dark-mode .item {
    background-color: #3a3a3a;
    border-left-color: #8b4513;
}

body.dark-mode .item.completed {
    background-color: #2a3a2a;
}

body.dark-mode .item-name {
    color: #ff7b00;
}

body.dark-mode .item-details {
    color: #bbb;
}

body.dark-mode .item-actions button:hover {
    background-color: #444;
}

body.dark-mode .integration-btn {
    border: 2px solid #555;
    background-color: #2d2d2d;
    color: #ff7b00;
}

body.dark-mode .integration-btn:hover {
    border-color: #8b4513;
    background-color: rgba(139, 69, 19, 0.05);
}

body.dark-mode footer {
    border-top: 1px solid #555;
    color: #bbb;
}

body.dark-mode footer a {
    color: #8b4513;
}

body.dark-mode .settings-button {
    color: #ff7b00;
}

body.dark-mode .settings-button:hover {
    background-color: #444;
}

body.dark-mode .modal {
    background-color: rgba(0, 0, 0, 0.8);
}

body.dark-mode .modal-content {
    background-color: #2d2d2d;
}

body.dark-mode .modal-header {
    background-color: #3a3a3a;
    border-bottom: 1px solid #555;
}

body.dark-mode .modal-header h2 {
    color: #ff7b00;
}

body.dark-mode .close {
    color: #bbb;
}

body.dark-mode .close:hover {
    color: #e0e0e0;
}

body.dark-mode .settings-form label {
    color: #ff7b00;
}

body.dark-mode .settings-form input {
    background-color: #3a3a3a;
    border: 2px solid #555;
    color: #e0e0e0;
}

body.dark-mode .settings-form input:focus {
    border-color: #8b4513;
    box-shadow: 0 0 5px rgba(139, 69, 19, 0.3);
}

body.dark-mode .settings-form small {
    color: #bbb;
}

body.dark-mode .modal-footer {
    background-color: #3a3a3a;
    border-top: 1px solid #555;
}

body.dark-mode .btn-primary {
    background-color: transparent;
    color: #ff7b00;
}

body.dark-mode .btn-primary:hover {
    background-color: rgba(255, 123, 0, 0.1);
    color: #ff7b00;
}

body.dark-mode button {
    background-color: transparent;
    color: #ff7b00;
}

body.dark-mode button:hover {
    background-color: rgba(255, 123, 0, 0.1);
    color: #ff7b00;
}

body.dark-mode .list-totals {
    color: #bbb;
}

.settings-button {
    background: none;
    border: none;
    font-size: 18px;
    cursor: pointer;
    padding: 8px;
    border-radius: 50%;
    transition: background-color 0.2s;
    color: #8b4513;
}

.settings-button:hover {
    background-color: #f0f0f0;
}

.settings-button:active {
    transform: scale(0.95);
}

/* Modal Styles */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    animation: fadeIn 0.3s ease-out;
}

.modal.show {
    display: flex;
    align-items: center;
    justify-content: center;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.modal-content {
    background-color: white;
    border-radius: 10px;
    width: 90%;
    max-width: 500px;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
    animation: slideIn 0.3s ease-out;
}

@keyframes slideIn {
    from {
        transform: translateY(-30px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 25px;
    border-bottom: 1px solid #ddd;
    background-color: #f8f9fa;
    border-radius: 10px 10px 0 0;
}

.modal-header h2 {
    color: #8b4513;
    margin: 0;
    font-size: 1.5em;
}

.close {
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
    color: #999;
    transition: color 0.2s;
}

.close:hover {
    color: #333;
}

.modal-body {
    padding: 25px;
}

.settings-form {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.settings-form .form-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.settings-form label {
    font-weight: bold;
    color: #8b4513;
    font-size: 14px;
}

.settings-form input {
    padding: 12px;
    border: 2px solid #ddd;
    border-radius: 6px;
    font-size: 14px;
    transition: border-color 0.2s;
}

.settings-form input:focus {
    outline: none;
    border-color: #ff7b00;
    box-shadow: 0 0 5px rgba(255, 123, 0, 0.3);
}

.settings-form small {
    color: #666;
    font-size: 12px;
    font-style: italic;
}

.modal-footer {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    padding: 20px 25px;
    border-top: 1px solid #ddd;
    background-color: #f8f9fa;
    border-radius: 0 0 10px 10px;
}

.btn-primary {
    background-color: #ff7b00;
    color: white;
    border: none;
    padding: 12px 20px;
    border-radius: 5px;
    cursor: pointer;
    font-size: 14px;
    font-weight: bold;
    transition: background-color 0.2s;
}

.btn-primary:hover {
    background-color: #e66a00;
}

.btn-secondary {
    background-color: #6c757d;
    color: white;
    border: none;
    padding: 12px 20px;
    border-radius: 5px;
    cursor: pointer;
    font-size: 14px;
    font-weight: bold;
    transition: background-color 0.2s;
}

.btn-secondary:hover {
    background-color: #5a6268;
}

/* Responsive Design */
@media (max-width: 768px) {
    .container {
        padding: 15px;
    }
    
    header {
        flex-direction: column;
        gap: 15px;
        text-align: center;
    }
    
    h1 {
        font-size: 2em;
    }
    
    .status-bar {
        flex-direction: column;
        gap: 10px;
        text-align: center;
    }
    
    .settings {
        grid-template-columns: 1fr;
    }
    
    .form-row {
        grid-template-columns: 1fr;
    }
    
    .lists-container {
        grid-template-columns: 1fr;
    }
    
    .item {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }
    
    .item-actions {
        align-self: stretch;
        justify-content: center;
        gap: 15px;
    }
    
    .item-actions button {
        min-width: 45px;
        padding: 10px;
    }
    
    .actions {
        flex-direction: column;
    }
    
    footer {
        flex-direction: column;
        gap: 15px;
        text-align: center;
    }
    
    .modal-content {
        width: 95%;
        margin: 10px;
    }
    
    .modal-header,
    .modal-body,
    .modal-footer {
        padding: 15px 20px;
    }
    
    .modal-footer {
        flex-direction: column;
        gap: 10px;
    }
    
    .btn-primary,
    .btn-secondary {
        width: 100%;
    }
}