/* Pinned items styling */
.pinned-foods {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    gap: 12px;
    margin: 20px 0;
}

.pinned-food {
    box-shadow: 0 1px 3px rgba(255,255,255,0.1);
    border: 1px solid #333333;
    border-radius: 8px;
    padding: 8px;
    background: #1a1a1a;
    color: #ffffff;
    width: 160px;
    height: 260px;
    position: relative;
    overflow: hidden;
}

.remove-btn {
    background: #dc3545;
    color: #ffffff;
    border: 2px solid #dc3545;
    border-radius: 18px;
    padding: 6px 12px;
    font-size: 0.8em;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: 0 2px 4px rgba(220, 53, 69, 0.3);
    display: flex;
    align-items: center;
    gap: 4px;
    margin: 0 auto;
    white-space: nowrap;
}

.remove-btn:hover {
    background: #c82333;
    color: #ffffff;
    border-color: #c82333;
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(220, 53, 69, 0.4);
}

.remove-btn:active {
    transform: translateY(0);
    box-shadow: 0 2px 4px rgba(220, 53, 69, 0.3);
}

/* Divider between search results and pinned items */
.divider {
    height: 2px;
    background: linear-gradient(to right, transparent, #ffffff, transparent);
    margin: 30px 0;
}

/* Pinned section styling */
.pinned-section {
    margin: 20px 0;
}

.pinned-section h2 {
    color: #ffffff;
    margin-bottom: 15px;
    font-size: 1.5em;
}

.totals-container {
    display: flex;
    gap: 20px;
    margin: 20px 0;
}

.totals {
    border: 2px solid #ffffff;
    padding: 15px;
    border-radius: 5px;
    background-color: #1a1a1a;
    color: #ffffff;
    flex: 1;
}

.totals h3 {
    margin-top: 0;
    color: #ffffff;
}

.totals .nutrition-row {
    font-weight: bold;
    font-size: 1em;
}

.entry-field {
    margin-bottom: 15px;
}

.entry-field label {
    display: block;
    margin-bottom: 5px;
    color: #ffffff;
    font-weight: bold;
    font-size: 0.9em;
}

.date-input {
    width: 100%;
    padding: 8px 12px;
    border: 1px solid #ffffff;
    border-radius: 4px;
    font-size: 0.9em;
    background-color: #333333;
    color: #ffffff;
    box-sizing: border-box;
}

.date-input:focus {
    outline: none;
    border-color: #ffffff;
    box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.25);
}

.comment-input {
    width: 100%;
    padding: 8px 12px;
    border: 1px solid #ffffff;
    border-radius: 4px;
    font-size: 0.9em;
    background-color: #333333;
    color: #ffffff;
    resize: vertical;
    min-height: 60px;
    font-family: inherit;
    box-sizing: border-box;
}

.comment-input:focus {
    outline: none;
    border-color: #ffffff;
    box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.25);
}

.comment-input::placeholder {
    color: #cccccc;
    font-style: italic;
}

.submit-food-btn {
    background: #28a745;
    color: #ffffff;
    border: 2px solid #28a745;
    border-radius: 5px;
    padding: 10px 20px;
    font-size: 1em;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: 0 2px 4px rgba(40, 167, 69, 0.3);
    width: 100%;
}

.submit-food-btn:hover:not(:disabled) {
    background: #218838;
    border-color: #218838;
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(40, 167, 69, 0.4);
}

.submit-food-btn:active:not(:disabled) {
    transform: translateY(0);
    box-shadow: 0 2px 4px rgba(40, 167, 69, 0.3);
}

.submit-food-btn:disabled {
    background: #6c757d;
    border-color: #6c757d;
    cursor: not-allowed;
    opacity: 0.6;
}

/* Notification Popup */
.notification-popup {
    position: fixed;
    top: 20px;
    right: 20px;
    background: #28a745;
    color: #ffffff;
    border: 2px solid #28a745;
    border-radius: 8px;
    padding: 15px 20px;
    box-shadow: 0 4px 12px rgba(40, 167, 69, 0.3);
    z-index: 1000;
    transform: translateX(100%);
    opacity: 0;
    transition: all 0.3s ease;
    min-width: 250px;
    max-width: 400px;
}

.notification-popup.show {
    transform: translateX(0);
    opacity: 1;
}

.notification-content {
    display: flex;
    align-items: center;
    gap: 10px;
}

.notification-icon {
    font-size: 1.2em;
    flex-shrink: 0;
}

.notification-message {
    font-weight: bold;
    font-size: 1em;
}

/* Error notification styling */
.notification-popup.error {
    background: #dc3545;
    border-color: #dc3545;
    box-shadow: 0 4px 12px rgba(220, 53, 69, 0.3);
}

.notification-popup.error .notification-icon {
    content: "❌";
}
