/* Hong Kong Good Food - Modern Student Lunch Box Service */

/* Base Styles */
:root {
    --primary-color: #FF6B35;
    --primary-light: #FF8C61;
    --primary-dark: #E55A2B;
    --secondary-color: #F7931E;
    --accent-color: #FFB84D;
    --dark-color: #2C3E50;
    --light-color: #F8F9FA;
    --text-dark: #2C3E50;
    --text-muted: #6C757D;
    --border-color: #E9ECEF;
    --shadow: 0 0.125rem 0.25rem rgba(255, 107, 53, 0.1);
    --shadow-lg: 0 1rem 3rem rgba(255, 107, 53, 0.2);
    --gradient-primary: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    --gradient-light: linear-gradient(135deg, #FFF5F0 0%, #FFEDE0 100%);
}

* {
    box-sizing: border-box;
}

body {
    font-family: 'Inter', 'Noto Sans TC', 'Microsoft JhengHei', sans-serif;
    line-height: 1.6;
    color: var(--text-dark);
    background-color: #FAFAFA;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
    font-weight: 700;
    color: var(--text-dark);
    line-height: 1.3;
}

.display-1, .display-2, .display-3, .display-4, .display-5, .display-6 {
    font-weight: 800;
}

/* Custom Bootstrap overrides */
.btn-primary {
    background: var(--gradient-primary);
    border: none;
    color: #fff;
    font-weight: 600;
    border-radius: 50px;
    padding: 0.75rem 2rem;
    transition: all 0.3s ease;
    box-shadow: var(--shadow);
}

.btn-primary:hover,
.btn-primary:focus {
    background: linear-gradient(135deg, var(--primary-dark) 0%, var(--primary-color) 100%);
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
    border: none;
}

.btn-outline-primary {
    color: var(--primary-color);
    border: 2px solid var(--primary-color);
    border-radius: 50px;
    font-weight: 600;
    padding: 0.75rem 2rem;
    transition: all 0.3s ease;
}

.btn-outline-primary:hover {
    background: var(--gradient-primary);
    border-color: var(--primary-color);
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.text-primary {
    color: var(--primary-color) !important;
}

.bg-primary {
    background: var(--gradient-primary) !important;
}

/* Navigation */
.navbar {
    background: rgba(255, 255, 255, 0.95) !important;
    backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(255, 107, 53, 0.1);
    transition: all 0.3s ease;
    padding: 1rem 0;
}

.navbar.scrolled {
    background: rgba(255, 255, 255, 0.98) !important;
    box-shadow: var(--shadow);
}

.navbar-brand {
    font-size: 1.75rem;
    font-weight: 800;
    color: var(--primary-color) !important;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.navbar-brand i {
    font-size: 2rem;
    color: var(--secondary-color);
}

.navbar-nav .nav-link {
    font-weight: 600;
    padding: 0.75rem 1.25rem;
    border-radius: 25px;
    transition: all 0.3s ease;
    color: var(--text-dark) !important;
    margin: 0 0.25rem;
}

.navbar-nav .nav-link:hover,
.navbar-nav .nav-link.active {
    background: var(--gradient-light);
    color: var(--primary-color) !important;
    transform: translateY(-1px);
}

/* Main Content */
.main-content {
    margin-top: 80px;
}

/* Hero Section */
.min-vh-80 {
    min-height: auto;
}

.hero-section {
    min-height: 600px;
    max-height: 90vh;
    background: var(--gradient-primary);
    display: flex;
    align-items: center;
    position: relative;
    overflow: hidden;
    margin-top: -80px;
    padding-top: 80px;
    padding-bottom: 0;
}

@media (min-width: 992px) {
    .hero-section {
        min-height: 650px;
        max-height: 85vh;
    }
}

.hero-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="grid" width="10" height="10" patternUnits="userSpaceOnUse"><path d="M 10 0 L 0 0 0 10" fill="none" stroke="rgba(255,255,255,0.1)" stroke-width="0.5"/></pattern></defs><rect width="100" height="100" fill="url(%23grid)"/></svg>');
    opacity: 0.3;
    z-index: 1;
}

.hero-section .container {
    position: relative;
    z-index: 2;
}

.hero-content {
    position: relative;
    z-index: 2;
}

.hero-title {
    font-size: 4rem;
    font-weight: 900;
    color: white;
    margin-bottom: 1.5rem;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.2);
}

.hero-subtitle {
    font-size: 1.3rem;
    color: rgba(255, 255, 255, 0.95);
    margin-bottom: 2rem;
    font-weight: 500;
    text-shadow: 1px 1px 3px rgba(0,0,0,0.2);
    white-space: nowrap;
}

@media (max-width: 1400px) {
    .hero-subtitle {
        font-size: 1.2rem;
    }
}

@media (max-width: 1200px) {
    .hero-subtitle {
        font-size: 1rem;
    }
}

.hero-content p {
    text-shadow: 1px 1px 2px rgba(0,0,0,0.1);
}

.hero-description {
    max-width: 500px;
    margin-left: auto;
    margin-right: auto;
}

.hero-buttons {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    justify-content: center;
}

.hero-content .px-5 {
    max-width: 600px;
}

.hero-image-wrapper {
    position: relative;
    z-index: 2;
    width: 100%;
    height: 100%;
    min-height: 400px;
    max-height: 90vh;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
}

.hero-expert-image {
    width: 100%;
    height: 100%;
    min-height: 400px;
    max-height: 90vh;
    object-fit: cover;
    object-position: center;
    transition: transform 0.3s ease;
}

@media (min-width: 992px) {
    .hero-image-wrapper {
        min-height: 500px;
        max-height: 85vh;
    }
    
    .hero-expert-image {
        min-height: 500px;
        max-height: 85vh;
    }
}

.hero-expert-image:hover {
    transform: scale(1.02);
}

.hero-buttons .btn {
    border-radius: 50px;
    padding: 1rem 2.5rem;
    font-weight: 700;
    font-size: 1.1rem;
    transition: all 0.3s ease;
}

.hero-buttons .btn-light {
    background: white;
    color: var(--primary-color);
    border: none;
    box-shadow: var(--shadow);
}

.hero-buttons .btn-light:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-lg);
    background: #f8f9fa;
}

/* Page Headers */
.page-header {
    background: var(--gradient-primary);
    padding: 4rem 0;
    margin-top: 80px;
    position: relative;
    overflow: hidden;
}

.page-header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><circle cx="50" cy="50" r="2" fill="rgba(255,255,255,0.1)"/></svg>');
    opacity: 0.5;
}

.page-header h1 {
    color: white;
    font-weight: 800;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.1);
}

.page-header p {
    color: rgba(255, 255, 255, 0.9);
    font-size: 1.2rem;
}

/* Cards */
.card {
    border: none;
    border-radius: 20px;
    overflow: hidden;
    transition: all 0.3s ease;
    box-shadow: var(--shadow);
    background: white;
}

.card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-lg);
}

.feature-card {
    text-align: center;
    padding: 3rem 2rem;
    border-radius: 20px;
    background: white;
    border: 1px solid rgba(255, 107, 53, 0.1);
    height: 100%;
    transition: all 0.3s ease;
}

.feature-card:hover {
    transform: translateY(-10px);
    box-shadow: var(--shadow-lg);
    border-color: var(--primary-color);
}

.feature-icon {
    width: 80px;
    height: 80px;
    background: var(--gradient-primary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.5rem;
    color: white;
    font-size: 2rem;
}

/* Menu Cards */
.menu-card {
    border: none;
    border-radius: 20px;
    overflow: hidden;
    transition: all 0.3s ease;
    box-shadow: var(--shadow);
    background: white;
    height: 100%;
}

.menu-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-lg);
}

.menu-card-image {
    height: 220px;
    overflow: hidden;
    position: relative;
    background: var(--gradient-light);
}

.menu-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.menu-card:hover .menu-card-image img {
    transform: scale(1.1);
}

.placeholder-image {
    height: 100%;
    background: var(--gradient-light);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary-color);
}

/* PDF Preview Styles */
.pdf-preview-container {
    position: relative;
    width: 100%;
    overflow: hidden;
}

.pdf-preview {
    display: block;
    pointer-events: none;
}

.pdf-overlay-link {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    text-decoration: none;
    z-index: 10;
}

.pdf-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    background: rgba(255, 107, 53, 0.95);
    color: white;
    padding: 1rem;
    text-align: center;
    font-weight: 600;
    transform: translateY(100%);
    transition: transform 0.3s ease;
}

.pdf-preview-container:hover .pdf-overlay {
    transform: translateY(0);
}

.placeholder-pdf {
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Category Banner Styles */
.category-banner-section {
    width: 100%;
    overflow: hidden;
}

.banner-image-container {
    width: 100%;
    line-height: 0;
}

.banner-image {
    width: 100%;
    height: auto;
    display: block;
    max-height: 500px;
    object-fit: cover;
}

@media (max-width: 768px) {
    .banner-image {
        max-height: 300px;
    }
}

@media (max-width: 576px) {
    .banner-image {
        max-height: 200px;
    }
}

.catering-card,
.product-card {
    border: none;
    border-radius: 12px;
    overflow: hidden;
    transition: all 0.3s ease;
    box-shadow: var(--shadow);
    background: white;
}

.catering-card:hover,
.product-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

/* Catering Card Image Container */
.catering-card-image,
.product-card-image {
    position: relative;
    overflow: hidden;
}

/* Catering Card Body */
.catering-card .card-body,
.product-card .card-body {
    padding: 1.5rem;
}

/* Social Media Section */
.social-card {
    background: white;
    border-radius: 20px;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
}

.social-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
}

.btn-social {
    padding: 0.75rem 1.5rem;
    border-radius: 50px;
    font-weight: 600;
    border: none;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
}

.btn-social:hover {
    transform: scale(1.05);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

.social-icons {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 10px;
}

@media (max-width: 576px) {
    .social-icons {
        flex-direction: column;
    }
    
    .btn-social {
        width: 100%;
    }
}

/* View Gallery Button */
.view-gallery-btn {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: rgba(0, 0, 0, 0.8);
    color: white;
    border: 2px solid white;
    padding: 12px 24px;
    border-radius: 50px;
    font-size: 16px;
    font-weight: bold;
    cursor: pointer;
    opacity: 0;
    transition: all 0.3s ease;
    z-index: 100;
    white-space: nowrap;
}

.catering-card-image:hover .view-gallery-btn,
.product-card-image:hover .view-gallery-btn {
    opacity: 1;
}

.view-gallery-btn:hover {
    background: rgba(255, 255, 255, 0.9);
    color: #000;
    transform: translate(-50%, -50%) scale(1.05);
}

.catering-card-image:hover::after,
.product-card-image:hover::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.3);
    z-index: 50;
}

.price {
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--primary-color);
}

.badge {
    background: var(--gradient-primary);
    color: white;
    border-radius: 20px;
    padding: 0.5rem 1rem;
    font-weight: 600;
}

/* Forms */
.form-control,
.form-select {
    border-radius: 15px;
    border: 2px solid var(--border-color);
    padding: 1rem 1.25rem;
    transition: all 0.3s ease;
    font-size: 1rem;
    background: white;
}

.form-control:focus,
.form-select:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 0.2rem rgba(255, 107, 53, 0.15);
    background: white;
}

.form-label {
    font-weight: 700;
    color: var(--text-dark);
    margin-bottom: 0.75rem;
    font-size: 1rem;
}

/* Contact and Info Cards */
.contact-form-card,
.contact-info-card,
.reservation-card,
.info-card {
    background: white;
    border-radius: 25px;
    border: 1px solid rgba(255, 107, 53, 0.1);
    box-shadow: var(--shadow);
}

.contact-item {
    display: flex;
    align-items: flex-start;
    padding: 1.5rem 0;
    border-bottom: 1px solid rgba(255, 107, 53, 0.1);
}

.contact-item:last-child {
    border-bottom: none;
}

.contact-icon {
    width: 60px;
    height: 60px;
    background: var(--gradient-primary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 1.5rem;
    color: white;
    flex-shrink: 0;
}

.contact-details {
    flex: 1;
    min-width: 0;
}

.contact-details h5 {
    color: var(--text-dark);
    font-weight: 700;
    margin-bottom: 0.5rem;
}

.contact-details p {
    color: var(--text-muted);
    line-height: 1.8;
}

/* Statistics/Features Section */
.stats-section {
    background: var(--gradient-light);
    padding: 5rem 0;
}

.stat-card {
    text-align: center;
    padding: 2rem;
    background: white;
    border-radius: 20px;
    box-shadow: var(--shadow);
    transition: all 0.3s ease;
}

.stat-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.stat-number {
    font-size: 3rem;
    font-weight: 900;
    color: var(--primary-color);
    display: block;
    margin-bottom: 0.5rem;
}

.stat-label {
    font-weight: 600;
    color: var(--text-dark);
    font-size: 1.1rem;
}

/* CTA Sections */
.cta-section {
    background: var(--gradient-primary);
    padding: 5rem 0;
    position: relative;
    overflow: hidden;
}

.cta-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><polygon points="50,10 90,90 10,90" fill="rgba(255,255,255,0.05)"/></svg>');
    opacity: 0.3;
}

.cta-content {
    position: relative;
    z-index: 2;
}

.cta-section h2 {
    color: white;
    font-weight: 800;
    margin-bottom: 1.5rem;
}

.cta-section p {
    color: rgba(255, 255, 255, 0.9);
    font-size: 1.2rem;
    margin-bottom: 2rem;
}

/* Footer */
footer {
    background: #19284E;
    color: white;
    padding: 4rem 0 2rem;
}

footer h5 {
    color: var(--accent-color);
    font-weight: 700;
    margin-bottom: 1.5rem;
}

footer a {
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
    transition: color 0.3s ease;
}

footer a:hover {
    color: var(--accent-color);
}

.social-links a {
    width: 45px;
    height: 45px;
    background: var(--gradient-primary);
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin-right: 1rem;
    color: white;
    transition: all 0.3s ease;
}

.social-links a:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-lg);
}

/* Category Filter */
.category-filter .btn {
    margin: 0.5rem;
    border-radius: 25px;
    font-weight: 600;
    padding: 0.75rem 1.5rem;
    transition: all 0.3s ease;
}

/* Animations */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(50px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeInLeft {
    from {
        opacity: 0;
        transform: translateX(-50px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes fadeInRight {
    from {
        opacity: 0;
        transform: translateX(50px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.fade-in {
    animation: fadeInUp 0.8s ease forwards;
}

.fade-in-left {
    animation: fadeInLeft 0.8s ease forwards;
}

.fade-in-right {
    animation: fadeInRight 0.8s ease forwards;
}

/* Scroll to top button */
.scroll-to-top {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    width: 50px;
    height: 50px;
    min-width: 50px;
    min-height: 50px;
    max-width: 50px;
    max-height: 50px;
    background: var(--gradient-primary);
    border: none;
    border-radius: 50%;
    color: white;
    font-size: 1.25rem;
    cursor: pointer;
    transition: all 0.3s ease;
    z-index: 1000;
    box-shadow: var(--shadow-lg);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    aspect-ratio: 1 / 1;
    flex-shrink: 0;
    overflow: hidden;
}

.scroll-to-top:hover {
    transform: translateY(-5px) scale(1.05);
    box-shadow: 0 1.5rem 4rem rgba(255, 107, 53, 0.3);
}

.scroll-to-top i {
    line-height: 1;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Responsive Design */
@media (max-width: 768px) {
    .hero-title {
        font-size: 2.5rem;
    }
    
    .hero-subtitle {
        font-size: 1.2rem;
    }
    
    .hero-buttons {
        justify-content: center;
    }
    
    .hero-buttons .btn {
        width: 100%;
        margin: 0.5rem 0;
    }
    
    .hero-section {
        margin-top: -70px;
        padding-top: 110px;
        padding-bottom: 50px;
        min-height: auto;
        max-height: none;
    }
    
    .hero-content .px-5 {
        padding-left: 2rem !important;
        padding-right: 2rem !important;
    }
    
    .hero-image-wrapper {
        margin-top: 2rem;
        min-height: 350px;
        max-height: 500px;
    }
    
    .hero-expert-image {
        min-height: 350px;
        max-height: 500px;
        border-radius: 15px;
    }
    
    .placeholder-image {
        margin-top: 3rem;
        padding: 3rem 1.5rem !important;
    }
    
    .feature-card {
        margin-bottom: 2rem;
        padding: 2rem 1.5rem;
    }
    
    .main-content {
        margin-top: 70px;
    }
    
    .page-header {
        margin-top: 70px;
        padding: 3rem 0;
    }
    
    .contact-item {
        flex-direction: column;
        text-align: center;
        align-items: center;
    }
    
    .contact-icon {
        margin-right: 0;
        margin-bottom: 1rem;
    }
    
    .contact-details {
        width: 100%;
        text-align: center;
    }
    
    .contact-details h5 {
        text-align: center;
    }
    
    .contact-details p {
        text-align: center;
    }
    
    .stat-number {
        font-size: 2.5rem;
    }
}

@media (max-width: 576px) {
    .hero-section {
        min-height: auto;
        margin-top: -70px;
        padding-top: 100px;
        padding-bottom: 30px;
        max-height: none;
    }
    
    .hero-title {
        font-size: 2rem;
    }
    
    .hero-subtitle {
        font-size: 0.9rem;
        white-space: normal;
        overflow: visible;
        text-overflow: clip;
    }
    
    .hero-content {
        text-align: center;
        margin-bottom: 0;
    }
    
    .hero-content .px-5 {
        padding-left: 1.5rem !important;
        padding-right: 1.5rem !important;
        max-width: 100%;
    }
    
    .hero-buttons {
        justify-content: center;
        flex-direction: column;
    }
    
    .hero-buttons .btn {
        width: 100%;
    }
    
    .hero-image-wrapper {
        margin-top: 0;
        min-height: 300px;
        max-height: 400px;
    }
    
    .hero-expert-image {
        min-height: 300px;
        max-height: 400px;
        border-radius: 0;
    }
    
    .placeholder-image {
        margin-top: 3rem;
        margin-bottom: 2rem;
        padding: 2.5rem 1rem !important;
    }
    
    .placeholder-image h4 {
        font-size: 1.25rem;
        margin-top: 0.75rem;
    }
    
    .placeholder-image i {
        font-size: 3.5rem !important;
    }
    
    .navbar-brand {
        font-size: 1.5rem;
    }
    
    .feature-card {
        padding: 1.5rem 1rem;
    }
    
    .btn-primary,
    .btn-outline-primary {
        padding: 0.75rem 1.5rem;
        font-size: 0.9rem;
    }
    
    .scroll-to-top {
        bottom: 1.5rem;
        right: 1.5rem;
        width: 48px;
        height: 48px;
        min-width: 48px;
        min-height: 48px;
        max-width: 48px;
        max-height: 48px;
        font-size: 1.15rem;
    }
}

/* Loading states */
.loading {
    opacity: 0.7;
    pointer-events: none;
}

.spinner {
    width: 20px;
    height: 20px;
    border: 2px solid #ffffff;
    border-top: 2px solid transparent;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

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

/* Modern glassmorphism effects */
.glass {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

/* Custom scrollbar */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
}

::-webkit-scrollbar-thumb {
    background: var(--gradient-primary);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--primary-dark);
}

/* Footer tagline image */
.footer-tagline-image {
    display: inline-block;
    max-height: 5.85em;
    height: auto;
    width: auto;
    vertical-align: middle;
}

.footer-tagline-fallback {
    display: inline;
}

@media (max-width: 768px) {
    .footer-tagline-image {
        max-height: 2.5em;
    }
}