* {
    box-sizing: border-box;
}

body {
    margin: 0;
    padding: 20px;
    font-family: Arial, Helvetica, sans-serif;
    background: linear-gradient(135deg, #fff3a0, #ffd261);
    color: #292929;
}

main {
    width: 100%;
    max-width: 780px;
    margin: 20px auto;
    padding: 28px;
    background: #ffffff;
    border-radius: 18px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.16);
}

h1 {
    margin-top: 0;
    color: #bd7000;
    text-align: center;
}

h2 {
    color: #8e5400;
}

.subtitle {
    color: #5e5e5e;
    text-align: center;
    font-style: italic;
}

.pickup-box,
.closed-box,
.card {
    margin: 18px 0;
    padding: 18px;
    border: 2px solid #d98900;
    border-radius: 12px;
    background: #fff8d9;
}

.pickup-box,
.closed-box {
    text-align: center;
}

.pickup-box strong {
    display: block;
    margin-bottom: 5px;
    color: #9d5b00;
    font-size: 19px;
}

.closed-box {
    font-size: 18px;
}


.menu-section {
    margin: 18px 0;
    border: 2px solid #d98900;
    border-radius: 12px;
    background: #fffdf4;
    overflow: hidden;
}

.menu-section summary {
    display: flex;
    justify-content: space-between;
    gap: 14px;
    align-items: center;
    padding: 17px 18px;
    background: #fff0aa;
    color: #8e5400;
    font-size: 20px;
    font-weight: 900;
    cursor: pointer;
    user-select: none;
}

.menu-section summary:hover {
    background: #ffe486;
}

.menu-count {
    color: #705500;
    font-size: 14px;
    font-weight: 800;
    text-align: right;
}

.menu-section-content {
    padding: 4px 14px 14px;
}

.menu-section-content > .card {
    margin: 12px 0;
}

.ice-panel {
    margin: 12px 0 4px;
    padding: 16px;
    border-top: 2px dashed #dfb43a;
}

.ice-panel > label:first-child {
    margin-top: 0;
}

.customize-box {
    grid-column: 1 / -1;
    margin-top: 3px;
    padding: 12px;
    border: 1px dashed #d98900;
    border-radius: 9px;
    background: #fff9df;
}

.customize-option {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 0;
    cursor: pointer;
}

.customize-option input[type="checkbox"] {
    width: 20px;
    height: 20px;
    margin: 0;
    flex: 0 0 auto;
}

.customization-details label {
    margin-top: 12px;
}

.merch-note {
    margin: 12px 4px 4px;
    color: #665100;
    font-size: 14px;
    font-weight: 700;
}

.receipt-detail {
    margin-top: 4px;
    color: #775800;
    font-size: 13px;
    font-weight: 700;
}

.drink-card {
    display: grid;
    grid-template-columns: 1fr 110px;
    gap: 15px;
    align-items: center;
}

.drink-name {
    font-size: 18px;
    font-weight: 800;
}

.price {
    margin-top: 5px;
    color: #616161;
}

label {
    display: block;
    margin: 18px 0 7px;
    font-weight: 800;
}

.drink-card label {
    margin-top: 0;
}

input[type="number"],
input[type="text"],
input[type="password"],
textarea {
    width: 100%;
    padding: 12px;
    border: 1px solid #999999;
    border-radius: 8px;
    font: inherit;
}

input[type="range"] {
    width: 100%;
}

textarea {
    min-height: 105px;
    resize: vertical;
}

.slider-labels {
    display: flex;
    justify-content: space-between;
    color: #666666;
    font-size: 13px;
}

#iceText {
    margin-top: 8px;
    color: #bd7000;
    font-size: 19px;
    font-weight: 800;
    text-align: center;
}

button,
.button {
    display: block;
    width: 100%;
    margin-top: 20px;
    padding: 14px;
    border: 0;
    border-radius: 9px;
    background: #d98900;
    color: #ffffff;
    font-size: 18px;
    font-weight: 800;
    text-align: center;
    text-decoration: none;
    cursor: pointer;
}

button:hover,
.button:hover {
    background: #b87000;
}

button:disabled {
    cursor: wait;
    opacity: 0.65;
}

.receipt-row {
    display: flex;
    justify-content: space-between;
    gap: 20px;
    padding: 11px 0;
    border-bottom: 1px solid #dddddd;
}

.total {
    margin-top: 10px;
    border-top: 3px solid #d98900;
    font-size: 22px;
    font-weight: 800;
}

.error,
.success {
    margin: 15px 0;
    padding: 14px;
    border-radius: 8px;
    font-weight: 800;
}

.error {
    background: #ffe4e4;
    color: #8b0000;
}

.success {
    background: #e6f7e9;
    color: #21652d;
    text-align: center;
}

.admin-page {
    background: #101010;
    color: #ffffff;
    font-family: Verdana, Arial, sans-serif;
    font-size: 18px;
}

.admin-page main {
    max-width: 1180px;
    background: #1e1e1e;
}

.admin-page h1,
.admin-page h2 {
    color: #ffe16b;
}

.admin-page .subtitle {
    color: #eeeeee;
}

.stats {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 12px;
    margin-bottom: 20px;
}

.stat {
    padding: 18px;
    border: 1px solid #555555;
    border-radius: 12px;
    background: #303030;
    text-align: center;
}

.stat strong {
    display: block;
    margin-top: 7px;
    color: #ffe16b;
    font-size: 30px;
}

.actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    align-items: center;
    margin-bottom: 20px;
}

.actions button,
.actions a {
    width: auto;
    margin: 0;
    padding: 11px 16px;
    font-size: 16px;
}

#storeButton.open {
    background: #2f7f43;
}

#storeButton.closed {
    background: #9d2525;
}

#audioNotice {
    margin-bottom: 18px;
    padding: 13px;
    border: 2px solid #ffe16b;
    border-radius: 10px;
    background: #423715;
    text-align: center;
    cursor: pointer;
}

.list {
    display: grid;
    gap: 16px;
}

.item {
    padding: 22px;
    border: 2px solid #666666;
    border-left: 9px solid #ffd04a;
    border-radius: 12px;
    background: #292929;
}

.item.completed {
    border-left-color: #66bf79;
    opacity: 0.72;
}

.item-header {
    display: flex;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 14px;
}

.item-number,
.item-total {
    color: #ffe16b;
    font-size: 24px;
    font-weight: 900;
}

.field {
    margin: 10px 0;
    padding: 13px 15px;
    border: 1px solid #555555;
    border-radius: 8px;
    background: #181818;
    overflow-wrap: anywhere;
}

.field strong {
    color: #ffe16b;
}


.admin-customization {
    margin-top: 6px;
    padding: 8px 10px;
    border-left: 4px solid #ffe16b;
    background: #34301f;
    color: #ffffff;
}

.item-buttons {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.item-buttons button {
    width: auto;
    margin-top: 14px;
    padding: 10px 15px;
    font-size: 16px;
}

.complete-button {
    background: #397f4b;
}

.delete-button {
    background: #a12626;
}

#popup {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 9999;
    display: none;
    width: min(500px, calc(100vw - 40px));
    padding: 26px;
    border: 5px solid #ffe16b;
    border-radius: 16px;
    background: #111111;
    color: #ffffff;
    font-size: 20px;
    font-weight: 700;
    box-shadow: 0 15px 45px rgba(0, 0, 0, 0.8);
}

#popup h2 {
    margin-top: 0;
    font-size: 30px;
}

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

    .item-header {
        display: block;
    }
}

@media (max-width: 520px) {
    body {
        padding: 10px;
    }

    main {
        padding: 18px;
    }

    .drink-card {
        grid-template-columns: 1fr 90px;
    }

    .receipt-row {
        display: block;
    }

    .stats {
        grid-template-columns: 1fr;
    }
}
