
* {
    box-sizing: border-box;
}

body {
    margin: 0;
    font-family: Arial, sans-serif;
    background: #f5f5f5;
    color: #222;
}

.screen {
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20px;
}

.card {
    width: 100%;
    max-width: 400px;
    background: white;
    padding: 30px;
    border-radius: 20px;
    box-shadow: 0 5px 25px rgba(0, 0, 0, 0.08);
}

h1 {
    margin-top: 0;
}

input {
    width: 100%;
    padding: 14px;
    border: 1px solid #ccc;
    border-radius: 10px;
    font-size: 16px;
    margin-bottom: 10px;
}

button {
    border: none;
    border-radius: 10px;
    padding: 13px 18px;
    font-size: 16px;
    cursor: pointer;
    background: #222;
    color: white;
}

button:hover {
    opacity: 0.85;
}

.secondary {
    background: #ddd;
    color: #222;
}

.hidden {
    display: none;
}

#app {
    max-width: 700px;
    margin: auto;
    padding: 20px;
}

header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 15px;
    margin-bottom: 25px;
}

header p {
    margin: 0;
    color: #777;
}

.add-item {
    display: flex;
    gap: 10px;
    margin-bottom: 25px;
}

.add-item input {
    margin: 0;
}

.add-item button {
    white-space: nowrap;
}

#shoppingList {
    list-style: none;
    padding: 0;
    margin: 0;
}

.shopping-item {
    background: white;
    border-radius: 12px;
    padding: 16px 18px;
    margin-bottom: 10px;

    display: flex;
    align-items: center;
    gap: 15px;
}

.shopping-item.checked {
    opacity: 0.40;
}

.shopping-item.checked .item-name {
    text-decoration: line-through;
}

.item-info {
    flex: 1;
    min-width: 0;
}

.item-name {
    font-size: 18px;
    text-align: left;
}

.item-author {
    font-size: 13px;
    color: #888;
    margin-top: 4px;
    text-align: left;
}

/* Große Checkbox rechts */
.shopping-item input[type="checkbox"] {
    width: 25px;
    height: 25px;
    margin: 0;
    flex-shrink: 0;
    cursor: pointer;
}

.delete-button {
    background: #e74c3c;
    padding: 8px 12px;
}



@media (max-width: 600px) {

    header {
        align-items: flex-start;
    }

    .add-item {
        flex-direction: column;
    }

    .add-item button {
        width: 100%;
    }

    header .secondary {
        font-size: 13px;
        padding: 9px;
    }
}

