/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    line-height: 1.6;
    color: #333;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* Header Styles */
.header {
    padding: 2rem 0;
    text-align: center;
    color: white;
}

.header span {
    font-size: 0.8rem;
    color: white;
    opacity: 0.8;
    text-align: center;
    display: block;
    margin-top: 1rem;
}

.header-content {
    max-width: 600px;
    margin: 0 auto;
}

.logo {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    margin-bottom: 0.5rem;
}

.logo i {
    font-size: 2.5rem;
    color: #ffd700;
}

.logo h1 {
    font-size: 3rem;
    font-weight: 700;
    margin: 0;
}

.subtitle {
    font-size: 1.2rem;
    opacity: 0.9;
    font-weight: 300;
}

/* Main Content */
.main-content {
    flex: 1;
    padding: 2rem 0;
}

/* Search Section */
.search-section {
    background: white;
    border-radius: 20px;
    padding: 2.5rem;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
    margin-bottom: 2rem;
}

.search-form {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.form-label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 500;
    color: #374151;
    font-size: 0.95rem;
}

.form-label i {
    color: #667eea;
    width: 16px;
}

.form-input,
.form-select {
    padding: 1rem;
    border: 2px solid #e5e7eb;
    border-radius: 12px;
    font-size: 1rem;
    transition: all 0.3s ease;
    background: #fafafa;
}

.form-input:focus,
.form-select:focus {
    outline: none;
    border-color: #667eea;
    background: white;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.search-button {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    padding: 1.2rem 2rem;
    border-radius: 12px;
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    margin-top: 1rem;
}

.search-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(102, 126, 234, 0.3);
}

.search-button:disabled {
    opacity: 0.7;
    cursor: not-allowed;
    transform: none;
}

/* Loading Section */
.loading-section {
    background: white;
    border-radius: 20px;
    padding: 3rem;
    text-align: center;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
    margin-bottom: 2rem;
}

.loading-content h3 {
    color: #374151;
    margin-bottom: 1rem;
    font-size: 1.3rem;
}

.loading-spinner {
    margin-bottom: 2rem;
}

.spinner {
    width: 60px;
    height: 60px;
    border: 4px solid #e5e7eb;
    border-top: 4px solid #667eea;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.loading-bar {
    background: #e5e7eb;
    height: 8px;
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 1rem;
}

.loading-progress {
    height: 100%;
    background: linear-gradient(90deg, #667eea, #764ba2);
    border-radius: 4px;
    width: 0%;
    transition: width 0.3s ease;
    animation: pulse 2s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.7; }
}

.loading-text {
    color: #6b7280;
    font-size: 0.95rem;
}

/* Results Section */
.results-section {
    background: white;
    border-radius: 20px;
    padding: 2.5rem;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
    margin-bottom: 2rem;
}

.results-header {
    text-align: center;
    margin-bottom: 2rem;
}

.results-header h2 {
    color: #374151;
    font-size: 2rem;
    margin-bottom: 0.5rem;
}

.results-summary {
    color: #6b7280;
    font-size: 1.1rem;
}

.results-list {
    display: grid;
    gap: 1.5rem;
}

.restaurant-card {
    background: #f8fafc;
    border: 2px solid #e5e7eb;
    border-radius: 16px;
    padding: 1.5rem;
    transition: all 0.3s ease;
}

.restaurant-card:hover {
    border-color: #667eea;
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(102, 126, 234, 0.1);
}

.restaurant-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 1rem;
}

.restaurant-name {
    font-size: 1.3rem;
    font-weight: 600;
    color: #374151;
    margin: 0;
}

.restaurant-rating {
    display: flex;
    align-items: center;
    gap: 0.3rem;
    background: #10b981;
    color: white;
    padding: 0.3rem 0.8rem;
    border-radius: 20px;
    font-size: 0.9rem;
    font-weight: 500;
}

.restaurant-details {
    display: grid;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.restaurant-cuisine,
.restaurant-price,
.restaurant-address {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: #6b7280;
    font-size: 0.95rem;
}

.restaurant-cuisine i {
    color: #f59e0b;
}

.restaurant-price i {
    color: #10b981;
}

.restaurant-address i {
    color: #667eea;
}

.restaurant-description {
    color: #374151;
    line-height: 1.6;
    margin-bottom: 1rem;
}

.dietary-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.dietary-tag {
    background: #dbeafe;
    color: #1e40af;
    padding: 0.3rem 0.8rem;
    border-radius: 12px;
    font-size: 0.8rem;
    font-weight: 500;
}

.new-search-button {
    background: transparent;
    color: #667eea;
    border: 2px solid #667eea;
    padding: 1rem 2rem;
    border-radius: 12px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    margin: 2rem auto 0;
}

.new-search-button:hover {
    background: #667eea;
    color: white;
    transform: translateY(-2px);
}

/* Error Section */
.error-section {
    background: white;
    border-radius: 20px;
    padding: 3rem;
    text-align: center;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
    margin-bottom: 2rem;
}

.error-content {
    max-width: 400px;
    margin: 0 auto;
}

.error-icon {
    font-size: 3rem;
    color: #ef4444;
    margin-bottom: 1rem;
}

.error-content h3 {
    color: #374151;
    margin-bottom: 1rem;
    font-size: 1.5rem;
}

.error-content p {
    color: #6b7280;
    margin-bottom: 2rem;
    line-height: 1.6;
}

.retry-button {
    background: #ef4444;
    color: white;
    border: none;
    padding: 1rem 2rem;
    border-radius: 12px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    margin: 0 auto;
}

.retry-button:hover {
    background: #dc2626;
    transform: translateY(-2px);
}

/* Footer */
.footer {
    text-align: center;
    padding: 2rem 0;
    color: white;
    opacity: 0.8;
    font-size: 0.9rem;
}

/* Utility Classes */
.hidden {
    display: none !important;
}

/* Responsive Design */
@media (max-width: 768px) {
    .container {
        padding: 0 15px;
    }
    
    .logo h1 {
        font-size: 2rem;
    }
    
    .subtitle {
        font-size: 1rem;
    }
    
    .search-section,
    .results-section,
    .loading-section,
    .error-section {
        padding: 1.5rem;
        border-radius: 16px;
    }
    
    .form-row {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    
    .restaurant-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.5rem;
    }
    
    .restaurant-rating {
        align-self: flex-start;
    }
}

@media (max-width: 480px) {
    .logo {
        flex-direction: column;
        gap: 0.5rem;
    }
    
    .logo i {
        font-size: 2rem;
    }
    
    .logo h1 {
        font-size: 1.8rem;
    }
    
    .search-section,
    .results-section,
    .loading-section,
    .error-section {
        padding: 1rem;
        margin-bottom: 1rem;
    }
    
    .form-input,
    .form-select {
        padding: 0.8rem;
    }
    
    .search-button {
        padding: 1rem;
        font-size: 1rem;
    }
}
