/* General Body Styles */
body {
    font-family: 'Inter', sans-serif;
    background-color: #f0f4f8; /* Light blue-gray background */
    color: #333;
    margin: 0;
    padding: 20px;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Header Styles */
.header {
    text-align: center;
    margin-bottom: 2rem;
    position: relative; /* Needed for positioning the lang toggle button */
}

/* NEW: Language Toggle Button for PAD pages */
.lang-toggle-btn {
    position: absolute;
    top: 0;
    right: 0;
    font-size: 0.9rem;
    font-weight: 500;
    color: #3f51b5;
    text-decoration: none;
    padding: 6px 12px;
    border-radius: 6px;
    background-color: #e8eaf6;
    transition: background-color 0.2s ease;
}
.lang-toggle-btn:hover {
    background-color: #c5cae9;
}

.logo-container {
    margin-bottom: 1rem;
}

.logo-container img {
    max-width: 120px; /* Controls the size of your logo */
    height: auto;
}

.header h1 {
    font-family: 'Poppins', sans-serif;
    font-size: 2.2rem;
    color: #1a237e; /* Deep navy blue */
    margin: 0;
    line-height: 1.2;
}

.header h2 {
    font-weight: 400;
    font-size: 1.1rem;
    color: #546e7a; /* Muted blue-gray */
    margin-top: 0.25rem;
}

/* Main Container */
.container {
    max-width: 800px;
    margin: 0 auto;
    background-color: #ffffff;
    padding: 1.5rem 2rem;
    border-radius: 12px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

.section-title {
    text-align: center;
    color: #546e7a;
    font-weight: 500;
    margin-bottom: 1rem;
}

/* Language Selector Styles */
.language-selector {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-bottom: 1.5rem;
    flex-wrap: wrap;
}

.lang-btn {
    font-family: 'Poppins', sans-serif;
    font-size: 1rem;
    padding: 10px 20px;
    border-radius: 8px;
    border: 1px solid #c5cae9;
    background-color: #ffffff;
    color: #3f51b5;
    cursor: pointer;
    transition: background-color 0.2s ease, color 0.2s ease, transform 0.2s ease;
    font-weight: 500;
}

.lang-btn:hover {
    background-color: #e8eaf6;
    transform: translateY(-2px);
}

.lang-btn.active {
    background-color: #3f51b5;
    color: #ffffff;
    border-color: #3f51b5;
}

/* General Search Input Styles */
.search-container {
    text-align: center;
    margin-bottom: 1.5rem;
}

#search-input {
    width: 100%;
    max-width: 400px;
    padding: 12px 15px;
    border-radius: 8px;
    border: 1px solid #ccc;
    font-size: 1rem;
    box-sizing: border-box;
}

/* Menu Card Styles */
#menu-container {
    display: grid;
    gap: 1rem;
}

.menu-card {
    background-color: #fff;
    padding: 1rem;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}

.card-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 0.5rem;
    gap: 1rem;
}

.card-header h3 {
    margin: 0;
    color: #1a237e;
    font-size: 1.2rem;
    flex-grow: 1;
    overflow-wrap: break-word;
    word-wrap: break-word;
    word-break: break-word;
}

.price {
    font-weight: 700;
    color: #c62828;
    font-size: 1.2rem;
    white-space: nowrap;
    flex-shrink: 0;
}

.menu-card p {
    margin: 0;
    color: #616161;
}


/* PAD Items Page Specific Styles */
.search-section {
    margin-bottom: 1.5rem;
}

.search-section label {
    font-weight: 600;
    color: #1a237e;
    margin-bottom: 0.5rem;
    display: block;
}

#general-search {
    width: 100%;
    padding: 12px 15px;
    font-size: 1rem;
    border-radius: 8px;
    border: 1px solid #ccc;
    box-sizing: border-box;
}

#search-results-container {
    margin-top: 0.5rem;
    max-height: 250px;
    overflow-y: auto;
    border: 1px solid #ddd;
    border-radius: 8px;
    background-color: #fff;
    display: none; /* Initially hidden */
}

.search-result-item {
    padding: 12px 15px;
    cursor: pointer;
    border-bottom: 1px solid #eee;
}

.search-result-item:last-child {
    border-bottom: none;
}

.search-result-item:hover {
    background-color: #f0f4f8;
}

.search-result-item small {
    display: block;
    color: #546e7a;
    margin-top: 2px;
}

.separator {
    border: none;
    height: 1px;
    background-color: #e0e0e0;
    margin: 2rem 0;
}

.browse-label {
    text-align: center;
    color: #546e7a;
    font-weight: 500;
    margin-bottom: 1.5rem;
}

#controls {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.control-group {
    display: flex;
    flex-direction: column;
}

.control-group label {
    font-weight: 600;
    color: #1a237e;
    margin-bottom: 0.5rem;
}

select {
    width: 100%;
    padding: 12px;
    border-radius: 8px;
    border: 1px solid #ccc;
    font-size: 1rem;
    background-color: #fff;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='%233f51b5' viewBox='0 0 16 16'%3E%3Cpath fill-rule='evenodd' d='M7.247 11.14 2.451 5.658C1.885 5.013 2.345 4 3.204 4h9.592a1 1 0 0 1 .753 1.659l-4.796 5.48a1 1 0 0 1-1.506 0z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 1rem center;
    background-size: 1em;
}

.details-card {
    margin-top: 1rem;
    padding: 1.5rem;
    border: 1px solid #c5cae9;
    border-radius: 8px;
    background-color: #f8f9fc;
}

.details-card h4 {
    margin-top: 0;
    margin-bottom: 1rem;
    color: #1a237e;
    font-size: 1.5rem;
}

.details-card p {
    margin: 0.5rem 0;
    line-height: 1.6;
}

.btn {
    display: inline-block;
    margin-top: 1rem;
    padding: 10px 20px;
    background-color: #3f51b5;
    color: white;
    text-decoration: none;
    border-radius: 8px;
    font-weight: 500;
    transition: background-color 0.2s ease;
}

.btn:hover {
    background-color: #303f9f;
}

/* Loader and Helper Classes */
.loader, .error-card, .info-card {
    text-align: center;
    padding: 2rem;
    font-size: 1.1rem;
    border-radius: 8px;
}

.loader {
    color: #546e7a;
}

.error-card {
    background-color: #ffebee;
    color: #c62828;
    border: 1px solid #ef9a9a;
}

.info-card {
    background-color: #e3f2fd;
    color: #1565c0;
    border: 1px solid #90caf9;
}

/* CSS classes for credit days */
.credit-days-safe {
    color: #2e7d32; /* Dark Green */
    font-weight: 600;
}

.credit-days-warning {
    color: #c62828; /* Dark Red */
    font-weight: 600;
}

