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

html {
    scroll-behavior: smooth;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    background: #ffffff;
    color: #333;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}

/* Splash Screen */
.splash-screen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background: #ffffff;
    z-index: 9999;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    animation: fadeOut 0.5s ease-in-out 2s forwards;
}

@keyframes fadeOut {
    to {
        opacity: 0;
        visibility: hidden;
    }
}

.splash-logo {
    position: absolute;
    top: 40px;
    height: 40px;
    width: auto;
    animation: fadeIn 0.5s ease-in-out;
}

.splash-machine {
    max-width: 300px;
    width: 80%;
    height: auto;
    margin-bottom: 30px;
    animation: fadeIn 0.8s ease-in-out;
}

.splash-title {
    font-size: 32px;
    font-weight: 700;
    color: #0e3386;
    animation: fadeIn 1s ease-in-out;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Header */
header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: #ffffff;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
    z-index: 100;
    padding: 0;
}

.header-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 15px 20px;
    max-width: 500px;
    margin: 0 auto;
}

.menu-btn {
    background: none;
    border: none;
    color: #0e3386;
    cursor: pointer;
    padding: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.2s;
}

.menu-btn:active {
    transform: scale(0.95);
}

.logo {
    height: 32px;
    width: auto;
}

/* Sidebar Menu */
.sidebar {
    position: fixed;
    left: -100%;
    top: 0;
    width: 85%;
    max-width: 350px;
    height: 100vh;
    background: #ffffff;
    box-shadow: 2px 0 20px rgba(0,0,0,0.1);
    z-index: 200;
    transition: left 0.3s ease;
    overflow-y: auto;
}

.sidebar.active {
    left: 0;
}

.sidebar-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    background: #0e3386;
    color: white;
}

.sidebar-header h2 {
    font-size: 24px;
    font-weight: 600;
}

.close-btn {
    background: none;
    border: none;
    color: white;
    font-size: 36px;
    cursor: pointer;
    padding: 0;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
}

.sidebar-content {
    padding: 20px;
    background: #ffffff;
}

.menu-section {
    margin-bottom: 25px;
}

.menu-section h3 {
    font-size: 16px;
    color: #0e3386;
    margin-bottom: 12px;
    font-weight: 600;
    padding-left: 18px;
}

.menu-item {
    display: block;
    width: 100%;
    padding: 14px 18px 14px 35px;
    margin-bottom: 8px;
    background: transparent;
    border: none;
    border-radius: 0;
    text-align: left;
    font-size: 15px;
    color: #333;
    cursor: pointer;
    transition: all 0.2s;
}

.menu-item:active {
    background: #f0f0f0;
    transform: scale(0.98);
}

/* Overlay */
.sidebar::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0,0,0,0.5);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s;
    z-index: -1;
}

.sidebar.active::before {
    opacity: 1;
    visibility: visible;
}

/* Main Content */
main {
    padding-top: 70px;
    min-height: 100vh;
    background: #ffffff;
}

.coffee-container {
    max-width: 500px;
    margin: 0 auto;
    padding: 20px 0;
    position: relative;
    overflow: hidden;
}

/* Navigation Arrows */
.nav-arrow {
    position: fixed;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255, 255, 255, 0.3);
    border: none;
    border-radius: 50%;
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 10;
    color: rgba(14, 51, 134, 0.4);
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
}

.nav-arrow:hover {
    background: rgba(255, 255, 255, 0.5);
    color: rgba(14, 51, 134, 0.7);
}

.nav-arrow:active {
    transform: translateY(-50%) scale(0.95);
}

.nav-arrow-left {
    left: 10px;
}

.nav-arrow-right {
    right: 10px;
}

.nav-arrow.disabled {
    opacity: 0.2;
    cursor: not-allowed;
    pointer-events: none;
}

.coffee-slider {
    display: flex;
    overflow: visible;
    scrollbar-width: none;
    -ms-overflow-style: none;
    height: auto;
    min-height: 100vh;
    transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.coffee-slider::-webkit-scrollbar {
    display: none;
}

.coffee-card {
    min-width: 100%;
    flex-shrink: 0;
    padding: 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
    background: #ffffff;
    min-height: 100vh;
    overflow-y: auto;
}

.coffee-image {
    width: 100%;
    max-width: 300px;
    height: 300px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 20px;
    background: #ffffff;
}

.coffee-image img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    filter: none;
}

.coffee-name {
    font-size: 28px;
    font-weight: 700;
    color: #0e3386;
    margin-bottom: 20px;
    text-align: center;
}

.coffee-details {
    width: 100%;
    max-width: 320px;
    background: #f8f9fa;
    border-radius: 16px;
    padding: 20px;
    margin-top: 20px;
    margin-bottom: 20px;
}

.detail-row {
    display: flex;
    align-items: center;
    padding: 12px 0;
    font-size: 16px;
    border-bottom: 1px solid #e9ecef;
}

.detail-row:last-child {
    border-bottom: none;
}

.detail-row .icon {
    display: none;
}

.description {
    width: 100%;
    max-width: 320px;
    background: linear-gradient(135deg, #f5f5f5 0%, #e8e8e8 100%);
    border-radius: 16px;
    padding: 20px;
    margin-top: 20px;
    color: #333;
}

.description h3 {
    font-size: 20px;
    margin-bottom: 12px;
    font-weight: 600;
    color: #0e3386;
}

.description p {
    font-size: 15px;
    line-height: 1.8;
    color: #555;
}

.preparation {
    width: 100%;
    max-width: 320px;
    background: linear-gradient(135deg, #0e3386 0%, #1a4ba8 100%);
    border-radius: 16px;
    padding: 20px;
    margin-top: 20px;
    color: white;
}

.preparation h3 {
    font-size: 20px;
    margin-bottom: 12px;
    font-weight: 600;
}

.preparation p {
    font-size: 15px;
    line-height: 1.8;
}

/* Navigation Dots */
.dots {
    display: none;
}

.dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #d0d0d0;
    transition: all 0.3s;
    cursor: pointer;
}

.dot.active {
    background: #0e3386;
    width: 24px;
    border-radius: 4px;
}

/* Swipe Indicator */
.swipe-indicator {
    text-align: center;
    padding: 10px;
    color: #999;
    font-size: 14px;
    animation: fadeOut 3s forwards;
}

@keyframes fadeOut {
    0%, 50% {
        opacity: 1;
    }
    100% {
        opacity: 0;
        pointer-events: none;
    }
}

/* Modal */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0,0,0,0.5);
    z-index: 300;
    padding: 20px;
    overflow-y: auto;
}

.modal.active {
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-content {
    background: white;
    border-radius: 20px;
    width: 100%;
    max-width: 500px;
    max-height: 85vh;
    overflow-y: auto;
    position: relative;
    box-shadow: 0 10px 40px rgba(0,0,0,0.2);
}

.modal-close {
    position: absolute;
    top: 15px;
    right: 15px;
    background: #0e3386;
    color: white;
    border: none;
    font-size: 28px;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10;
}

.modal-body {
    padding: 60px 30px 30px 30px;
}

.modal-body h2 {
    color: #0e3386;
    font-size: 24px;
    margin-bottom: 20px;
}

.modal-body h3 {
    color: #0e3386;
    font-size: 20px;
    margin-top: 25px;
    margin-bottom: 15px;
}

.modal-body p {
    line-height: 1.8;
    margin-bottom: 15px;
    color: #333;
}

.modal-body ul {
    margin-left: 20px;
    margin-bottom: 15px;
}

.modal-body li {
    line-height: 1.8;
    margin-bottom: 8px;
}

.info-section {
    background: #f8f9fa;
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 20px;
}

.warning-box {
    background: #fff3cd;
    border-left: 4px solid #ffc107;
    padding: 15px;
    margin: 15px 0;
    border-radius: 8px;
}

.tip-box {
    background: #d1ecf1;
    border-left: 4px solid #17a2b8;
    padding: 15px;
    margin: 15px 0;
    border-radius: 8px;
}

/* Responsive */
@media (max-width: 380px) {
    .coffee-image {
        max-width: 250px;
        height: 250px;
    }
    
    .coffee-name {
        font-size: 24px;
    }
    
    .detail-row {
        font-size: 14px;
    }
    
    .preparation p {
        font-size: 14px;
    }
}

/* Touch improvements */
button, .menu-item, .dot {
    -webkit-tap-highlight-color: transparent;
}

body {
    touch-action: pan-y pinch-zoom;
}

.coffee-slider {
    touch-action: pan-x;
}