/* Tropicana - Main Stylesheet */

:root {
    --background: #0A0A0A;
    --foreground: #FAFAFA;
    --card: #121212;
    --card-foreground: #FAFAFA;
    --primary: #00E676;
    --primary-foreground: #000000;
    --secondary: #FF6D00;
    --secondary-foreground: #FAFAFA;
    --muted: #262626;
    --muted-foreground: #A3A3A3;
    --accent: #1A1A1A;
    --border: #262626;
    --destructive: #EF4444;
    --radius: 0.75rem;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--background);
    color: var(--foreground);
    min-height: 100vh;
    line-height: 1.6;
}

h1, h2, h3, h4, h5, h6 {
    font-family: 'Manrope', sans-serif;
    font-weight: 700;
}

.container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 1rem;
}

/* Glass Effect */
.glass {
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

/* Header */
.header {
    position: sticky;
    top: 0;
    z-index: 40;
    padding: 1rem 0;
}

.header-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.logo {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.logo h1 {
    font-size: 1.5rem;
    color: var(--foreground);
}

.icon-primary {
    color: var(--primary);
    width: 2rem;
    height: 2rem;
}

/* Cart Button */
.cart-btn {
    position: relative;
    background: transparent;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    color: var(--foreground);
    transition: background-color 0.2s;
}

.cart-btn:hover {
    background: rgba(255, 255, 255, 0.05);
}

.cart-badge {
    position: absolute;
    top: -8px;
    right: -8px;
    background: var(--primary);
    color: var(--primary-foreground);
    font-size: 0.75rem;
    font-weight: 600;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Background */
.background-image {
    position: fixed;
    inset: 0;
    background-size: cover;
    background-position: center;
    filter: brightness(0.4);
    z-index: -2;
}

.background-overlay {
    position: fixed;
    inset: 0;
    background: rgba(10, 10, 10, 0.8);
    z-index: -1;
}

/* Main Content */
.main-content {
    position: relative;
    padding: 1.5rem 0 6rem;
}

/* Categories */
.categories-nav {
    display: flex;
    gap: 0.5rem;
    overflow-x: auto;
    padding-bottom: 0.5rem;
    margin-bottom: 2rem;
    -ms-overflow-style: none;
    scrollbar-width: none;
}

.categories-nav::-webkit-scrollbar {
    display: none;
}

.category-tab {
    padding: 0.5rem 1rem;
    border-radius: 9999px;
    font-size: 0.875rem;
    font-weight: 500;
    border: none;
    cursor: pointer;
    white-space: nowrap;
    transition: background-color 0.2s, color 0.2s;
    background: var(--muted);
    color: var(--muted-foreground);
}

.category-tab:hover {
    background: rgba(38, 38, 38, 0.8);
}

.category-tab.active {
    background: var(--primary);
    color: var(--primary-foreground);
}

/* Menu Grid */
.menu-grid {
    display: grid;
    grid-template-columns: repeat(1, 1fr);
    gap: 1.5rem;
}

@media (min-width: 768px) {
    .menu-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (min-width: 1024px) {
    .menu-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

/* Menu Card */
.menu-card {
    background: var(--card);
    border-radius: 1rem;
    border: 1px solid rgba(255, 255, 255, 0.05);
    overflow: hidden;
    cursor: pointer;
    transition: transform 0.2s, box-shadow 0.2s, border-color 0.2s;
}

.menu-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 0 30px rgba(0, 230, 118, 0.1);
    border-color: rgba(0, 230, 118, 0.3);
}

.menu-card-image {
    position: relative;
    aspect-ratio: 16/9;
    overflow: hidden;
}

.menu-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.menu-card-content {
    padding: 1rem;
}

.menu-card-content h3 {
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 0.25rem;
    color: var(--foreground);
}

.menu-card-content p {
    font-size: 0.875rem;
    color: var(--muted-foreground);
    margin-bottom: 0.75rem;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.menu-card-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

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

/* Badges */
.badge {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    border-radius: 9999px;
    font-size: 0.75rem;
    font-weight: 600;
}

.badge-warning {
    position: absolute;
    top: 0.5rem;
    right: 0.5rem;
    background: var(--secondary);
    color: var(--secondary-foreground);
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    border-radius: 9999px;
    font-size: 1rem;
    font-weight: 600;
    border: none;
    cursor: pointer;
    transition: transform 0.15s, box-shadow 0.15s, background-color 0.15s;
}

.btn-primary {
    background: var(--primary);
    color: var(--primary-foreground);
}

.btn-primary:hover {
    transform: scale(1.02);
    box-shadow: 0 0 20px rgba(0, 230, 118, 0.4);
}

.btn-primary:active {
    transform: scale(0.98);
}

.btn-outline {
    background: transparent;
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: var(--foreground);
}

.btn-outline:hover {
    background: rgba(255, 255, 255, 0.05);
}

.btn-block {
    width: 100%;
}

.btn-icon {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    border: none;
    cursor: pointer;
    transition: background-color 0.15s;
}

.btn-primary-light {
    background: rgba(0, 230, 118, 0.1);
    color: var(--primary);
}

.btn-primary-light:hover {
    background: rgba(0, 230, 118, 0.2);
}

/* Cart Sidebar */
.cart-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(4px);
    z-index: 50;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s, visibility 0.3s;
}

.cart-overlay.open {
    opacity: 1;
    visibility: visible;
}

.cart-sidebar {
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    width: 100%;
    max-width: 400px;
    background: var(--background);
    border-left: 1px solid rgba(255, 255, 255, 0.1);
    z-index: 51;
    display: flex;
    flex-direction: column;
    transform: translateX(100%);
    transition: transform 0.3s ease;
}

.cart-sidebar.open {
    transform: translateX(0);
}

.cart-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1.5rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.cart-header h2 {
    font-size: 1.25rem;
}

.cart-items {
    flex: 1;
    overflow-y: auto;
    padding: 1rem;
}

.cart-empty {
    text-align: center;
    color: var(--muted-foreground);
    padding: 3rem 0;
}

.cart-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem;
    background: var(--accent);
    border-radius: var(--radius);
    margin-bottom: 0.75rem;
}

.cart-item img {
    width: 64px;
    height: 64px;
    border-radius: 0.5rem;
    object-fit: cover;
}

.cart-item-info {
    flex: 1;
    min-width: 0;
}

.cart-item-name {
    font-weight: 500;
    color: var(--foreground);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.cart-item-accomp {
    font-size: 0.75rem;
    color: var(--muted-foreground);
}

.cart-item-price {
    color: var(--primary);
    font-weight: 600;
}

.cart-item-qty {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.qty-btn {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: var(--muted);
    border: none;
    color: var(--foreground);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background-color 0.15s;
}

.qty-btn:hover {
    background: rgba(163, 163, 163, 0.3);
}

.cart-footer {
    padding: 1.5rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.cart-total {
    display: flex;
    justify-content: space-between;
    font-size: 1.125rem;
    margin-bottom: 1rem;
}

.cart-total span:last-child {
    font-weight: 700;
    color: var(--foreground);
}

/* Modal */
.modal {
    position: fixed;
    inset: 0;
    z-index: 60;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s, visibility 0.3s;
}

.modal.open {
    opacity: 1;
    visibility: visible;
}

.modal-overlay {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(4px);
}

.modal-content {
    position: relative;
    background: var(--card);
    border-radius: 1rem;
    border: 1px solid rgba(255, 255, 255, 0.1);
    width: 100%;
    max-width: 480px;
    max-height: 90vh;
    overflow-y: auto;
    padding: 1.5rem;
    transform: scale(0.95);
    transition: transform 0.3s;
}

.modal.open .modal-content {
    transform: scale(1);
}

.modal-close {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: transparent;
    border: none;
    color: var(--muted-foreground);
    cursor: pointer;
    padding: 0.25rem;
}

.modal-close:hover {
    color: var(--foreground);
}

/* Item Modal Content */
.item-modal-image {
    width: 100%;
    aspect-ratio: 16/9;
    border-radius: 0.75rem;
    object-fit: cover;
    margin-bottom: 1rem;
}

.item-modal-desc {
    color: var(--muted-foreground);
    margin-bottom: 1rem;
}

.item-modal-price {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary);
    margin-bottom: 1rem;
}

/* Radio Group */
.radio-group {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.radio-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.radio-item input[type="radio"] {
    accent-color: var(--primary);
}

.radio-item label {
    font-size: 0.875rem;
    cursor: pointer;
}

/* Quantity Selector */
.qty-selector {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 1rem;
}

.qty-selector-label {
    color: var(--foreground);
}

.qty-selector-controls {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.qty-value {
    font-size: 1.125rem;
    font-weight: 700;
    width: 2rem;
    text-align: center;
}

/* Forms */
.form-group {
    margin-bottom: 1rem;
}

.form-group label {
    display: block;
    font-size: 0.875rem;
    font-weight: 500;
    margin-bottom: 0.5rem;
    color: var(--foreground);
}

.input-icon {
    position: relative;
}

.input-icon svg {
    position: absolute;
    left: 0.75rem;
    top: 50%;
    transform: translateY(-50%);
    width: 20px;
    height: 20px;
    color: var(--muted-foreground);
}

.input-icon input,
.input-icon textarea {
    width: 100%;
    padding: 0.75rem 0.75rem 0.75rem 2.5rem;
    background: rgba(38, 38, 38, 0.5);
    border: 1px solid transparent;
    border-radius: var(--radius);
    color: var(--foreground);
    font-size: 1rem;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.input-icon input::placeholder,
.input-icon textarea::placeholder {
    color: var(--muted-foreground);
}

.input-icon input:focus,
.input-icon textarea:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 2px rgba(0, 230, 118, 0.2);
}

.input-icon textarea {
    min-height: 80px;
    resize: none;
}

.checkout-total {
    display: flex;
    justify-content: space-between;
    font-size: 1.125rem;
    padding: 1rem 0;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    margin-bottom: 1rem;
}

.checkout-total span:last-child {
    font-weight: 700;
    color: var(--foreground);
}

.loyalty-info {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.875rem;
    color: var(--primary);
    margin-top: 0.5rem;
}

/* Footer */
.footer {
    position: relative;
    text-align: center;
    padding: 1.5rem;
    font-size: 0.875rem;
    color: var(--muted-foreground);
    border-top: 1px solid rgba(255, 255, 255, 0.05);
}

.footer a {
    color: var(--primary);
    text-decoration: none;
}

.footer a:hover {
    text-decoration: underline;
}

/* Mobile Cart FAB */
.mobile-cart-fab {
    position: fixed;
    bottom: 1.5rem;
    left: 1rem;
    right: 1rem;
    background: var(--primary);
    color: var(--primary-foreground);
    padding: 1rem;
    border-radius: 9999px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    font-weight: 600;
    cursor: pointer;
    box-shadow: 0 0 20px rgba(0, 230, 118, 0.4);
    z-index: 30;
}

@media (min-width: 768px) {
    .mobile-cart-fab {
        display: none !important;
    }
}

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

.menu-card {
    animation: fadeIn 0.5s ease-out forwards;
}

.menu-card:nth-child(1) { animation-delay: 0.05s; }
.menu-card:nth-child(2) { animation-delay: 0.1s; }
.menu-card:nth-child(3) { animation-delay: 0.15s; }
.menu-card:nth-child(4) { animation-delay: 0.2s; }
.menu-card:nth-child(5) { animation-delay: 0.25s; }
.menu-card:nth-child(6) { animation-delay: 0.3s; }

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

::-webkit-scrollbar-track {
    background: var(--muted);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb {
    background: rgba(163, 163, 163, 0.3);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: rgba(163, 163, 163, 0.5);
}
