/* Basic Reset and Variables */
:root {
    --primary-color: #702c44;
    --text-color: #333;
    --light-bg: #f9f9f9;
    --white: #ffffff;
    --font-family: 'Roboto', sans-serif;
}

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

html, body {
    font-family: var(--font-family);
    color: var(--text-color);
    line-height: 1.6;
    overflow-x: hidden;
    width: 100%;
}

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

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 35px;
}

/* Header */
.header {
    background-color: transparent;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    transition: background-color 0.3s, box-shadow 0.3s;
}

.header.scrolled {
    background-color: rgba(0, 0, 0, 0.5);
}
body.contact-page .header {
    background-color: rgba(0, 0, 0, 0.5);
}


.header-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 35px;
}

.logo img {
    filter: drop-shadow(0 0 10px rgba(0,0,0,0.8));
}

.nav-menu > ul {
    list-style: none;
    display: flex;
    align-items: center;
    gap: 20px;
}

.nav-menu a {
    text-decoration: none;
    color: var(--white);
    font-weight: 500;
    font-size: 1.2rem;
    padding: 8px 16px;
    border-radius: 20px;
    text-shadow: 0 0 10px rgba(0,0,0,0.8), 0 0 20px rgba(0,0,0,0.5);
    transition: background-color 0.3s, color 0.3s, text-shadow 0.3s;
}

html[lang="kr"] .nav-menu > ul > li > a {
    font-weight: 700;
}

.nav-menu a:hover {
    background-color: var(--primary-color);
    color: var(--white);
    text-shadow: none;
}

/* Language Switcher */
.lang-menu {
    position: relative;
    display: flex;
    align-items: center;
}

.lang-btn {
    background-color: transparent;
    color: var(--white);
    padding: 8px 16px;
    font-size: 1.2rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 16px;
    border: none;
    transform: translateY(-2px);
}

.lang-dropdown {
    position: absolute;
    top: 100%;
    right: 0;
    background-color: #fff;
    border-radius: 4px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.2);
    margin-top: 10px;
    min-width: 150px;
    display: none !important;
    flex-direction: column;
    padding: 5px 0;
    z-index: 1000;
}

.lang-dropdown.active {
    display: flex !important;
}

.lang-dropdown li {
    list-style: none;
}

.nav-menu .lang-dropdown a {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 15px;
    color: #333;
    text-decoration: none;
    font-size: 0.95rem;
    font-weight: normal;
    text-shadow: none;
    border-radius: 0;
    background-color: transparent;
}

.nav-menu .lang-dropdown a:hover, .nav-menu .lang-dropdown li.active a {
    background-color: #2095d3;
    color: #fff;
}

/* Typography */
.section-title {
    font-size: 2.5rem;
    font-weight: 700;
    text-align: center;
    margin-bottom: 40px;
    color: var(--white);
    letter-spacing: 2px;
}

.section-title.dark {
    color: var(--primary-color);
}

/* Home Section */
.hero-section {
    height: 100vh;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: var(--white);
    background-color: #000;
    overflow: hidden;
}

.hero-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    opacity: 0;
    animation: fadeBg 50s infinite;
    z-index: 1;
}

.bg1 { background-image: url('images/Cover_BG_001.jpg'); animation-delay: 0s; }
.bg2 { background-image: url('images/Cover_BG_002.jpg'); animation-delay: 10s; }
.bg3 { background-image: url('images/Cover_BG_003.jpg'); animation-delay: 20s; }
.bg4 { background-image: url('images/Cover_BG_004.jpg'); animation-delay: 30s; }
.bg5 { background-image: url('images/Cover_BG_005.jpg'); animation-delay: 40s; }

@keyframes fadeBg {
    0%   { opacity: 0; }
    6%   { opacity: 1; }
    20%  { opacity: 1; }
    26%  { opacity: 0; }
    100% { opacity: 0; }
}

.hero-content {
    position: relative;
    z-index: 2;
    text-shadow: 0 0 10px rgba(0,0,0,0.8), 0 0 20px rgba(0,0,0,0.8), 0 0 30px rgba(0,0,0,1);
}

.hero-content h1 {
    font-size: 4rem;
    margin-bottom: 0;
    font-weight: 300;
}

.hero-content h2 {
    font-size: 1.5rem;
    font-weight: 300;
    margin-top: 0;
}

.hero-link {
    margin-top: 70px;
    font-weight: bold;
    font-size: 2.2rem;
}

.hero-link a {
    color: #fff;
    text-decoration: underline !important;
}

/* Hero Balloon */
.hero-balloon {
    position: absolute;
    bottom: 30px;
    right: 30px;
    background-color: white;
    border-radius: 20px;
    padding: 25px;
    display: flex;
    align-items: center;
    gap: 25px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    text-decoration: none;
    z-index: 10;
    max-width: 600px;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.hero-balloon:hover {
    transform: translateY(-5px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
}

.hero-balloon img {
    width: 220px;
    border-radius: 8px;
    object-fit: cover;
}

.hero-balloon span {
    color: #333;
    font-size: 1.4rem;
    font-weight: 500;
    line-height: 1.4;
}

/* Our Story Section */
.story-section {
    padding: 105px 0 100px;
    background: url('images/Story_BG.jpg') center/cover no-repeat;
    position: relative;
    color: var(--white);
}

.story-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(112, 44, 68, 0.8); /* 80% transparency of #702C44 */
}

.story-container {
    position: relative;
    z-index: 2;
    text-align: center;
}

.story-logo {
    margin-bottom: 20px;
}

.story-logo img {
    width: 100px;
}

.story-text {
    max-width: 1200px;
    margin: 0 auto 40px;
    font-size: 1.1rem;
    font-weight: 300;
}

.story-text p {
    margin-bottom: 30px;
    line-height: 2.1;
}

/* Image Slider */
.slider-container {
    max-width: 1200px;
    margin: 40px auto 0;
    position: relative;
    padding: 0 40px 40px 40px;
}

.slider-viewport {
    overflow: hidden;
    width: 100%;
}

.slider-wrapper {
    display: flex;
    transition: transform 0.5s ease-in-out;
    gap: 16px;
}

.slider-slide {
    flex: 0 0 calc(33.333% - 10px);
}

.slider-slide img {
    width: 100%;
    height: 300px;
    display: block;
    object-fit: cover;
    border-radius: 8px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.3);
}

/* Dots */
.slider-dots {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    display: flex;
    justify-content: center;
    gap: 16px;
}

.slider-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: rgba(255,255,255,0.5);
    cursor: pointer;
    transition: background 0.3s;
}

.slider-dot.active {
    background: rgba(255,255,255,1);
}

.slider-btn {
    position: absolute;
    top: calc(50% - 20px);
    transform: translateY(-50%);
    background: transparent;
    color: white;
    border: none;
    padding: 10px;
    cursor: pointer;
    font-size: 30px;
    transition: transform 0.3s;
}

.slider-btn:hover {
    transform: translateY(-50%) scale(1.2);
    background: transparent;
}

.slider-prev {
    left: 0;
}

.slider-next {
    right: 0;
}

/* Product Section */
.product-section {
    padding: 105px 0 80px;
    background-color: var(--white);
}

.product-row {
    display: flex;
    align-items: center;
    margin-bottom: 80px;
    gap: 40px;
}

.product-row.reverse {
    flex-direction: row-reverse;
}

.product-image {
    flex: 1;
    text-align: center;
    display: flex;
    justify-content: center;
    align-items: center;
}

.product-image img {
    height: auto;
    max-width: 100%;
    transform: scale(1.1);
}

.img-miyabi {
    width: 65%;
    mix-blend-mode: multiply;
    transform: scale(0.9) !important;
}

.img-takara {
    transform: scale(0.9) !important;
}

.img-shizuku {
    width: 70%;
    margin: -40px 0;
}

.img-tsuya {
    width: 80%;
    margin: -40px 0;
}

.img-megumi {
    width: 65%;
    margin: -40px 0;
}

.product-info {
    flex: 1;
}

.product-row.reverse .product-info {
    text-align: right;
}

.product-info h2 {
    color: var(--primary-color);
    font-size: 2rem;
    margin-bottom: 20px;
}

.product-info p {
    font-size: 1.1rem;
    color: #555;
}

/* Store Section */
.store-section {
    padding: 105px 0 100px;
    background: url('images/store-bg.jpg') center/cover no-repeat;
    text-align: center;
    position: relative;
    color: var(--white);
}

.store-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.4);
}

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

.store-list {
    margin-top: 40px;
    display: flex;
    flex-direction: column;
    gap: 30px;
    align-items: center;
}

.store-row {
    display: flex;
    justify-content: center;
    gap: 30px;
    flex-wrap: wrap;
}

.store-row a img {
    width: 200px;
    height: 200px;
    transition: transform 0.3s;
}

.store-row a:hover img {
    transform: scale(1.1);
}

/* About Us Section */
.about-section {
    padding: 105px 0 100px;
    background-color: var(--white);
}

.about-row {
    display: flex;
    gap: 40px;
    align-items: flex-start;
}

.about-info {
    flex: 1;
}

.about-info p {
    margin-bottom: 20px;
    font-size: 1.1rem;
}

.map-container {
    margin-top: 20px;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 4px 10px rgba(0,0,0,0.1);
}

.map-container iframe {
    display: block;
    width: 100%;
}

.about-image {
    flex: 1;
}

.about-image img {
    width: 100%;
    height: auto;
    object-fit: cover;
    border-radius: 8px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.1);
}

/* Footer */
.footer {
    background-color: #20222b;
    color: #fff;
    padding: 30px 0;
    font-size: 0.9rem;
}

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

.footer-left p {
    margin-bottom: 5px;
}

.footer-left a {
    color: #ccc;
}

.footer-left a:hover {
    color: #fff;
}

.social-link {
    color: #fff;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 10px;
}

/* Back to Top Button */
.back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background-color: var(--primary-color);
    color: white;
    text-align: center;
    line-height: 50px;
    font-size: 18px;
    cursor: pointer;
    box-shadow: 0 4px 10px rgba(0,0,0,0.3);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s, visibility 0.3s, background-color 0.3s;
    z-index: 1000;
}

.back-to-top.show {
    opacity: 1;
    visibility: visible;
}

.back-to-top:hover {
    background-color: #4e1e2f;
}

/* Hamburger Menu */
.hamburger-menu {
    display: none;
    flex-direction: column;
    cursor: pointer;
    gap: 7px;
    z-index: 1001;
    filter: drop-shadow(0 0 10px rgba(0,0,0,0.8));
}

.hamburger-menu .bar {
    width: 35px;
    height: 4px;
    background-color: var(--white);
    border-radius: 4px;
    transition: 0.3s;
}

.hamburger-menu.active .bar:nth-child(1) {
    transform: translateY(11px) rotate(45deg);
}

.hamburger-menu.active .bar:nth-child(2) {
    opacity: 0;
}

.hamburger-menu.active .bar:nth-child(3) {
    transform: translateY(-11px) rotate(-45deg);
}

/* Responsive */
/* Contact Section */
.contact-section {
    padding: 180px 0 100px;
    background-image: url('images/Cover_BG_001.jpg');
    background-size: cover;
    background-position: center;
    position: relative;
    min-height: 100vh;
}
.contact-section::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    background-color: rgba(0,0,0,0.4);
}
.contact-container {
    width: calc(100% - 40px);
    max-width: 800px;
    margin: 0 auto;
    padding: 40px 35px;
    background-color: #fff;
    border-radius: 10px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
    position: relative;
    z-index: 2;
}
.contact-form {
    display: flex;
    flex-direction: column;
    gap: 20px;
    margin-top: 40px;
}
.form-group {
    display: flex;
    flex-direction: column;
    gap: 16px;
    text-align: left;
}
.form-group label {
    font-weight: 500;
    color: #333;
    font-family: 'Prompt', sans-serif;
}
.form-group input, .form-group textarea {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid #ccc;
    border-radius: 5px;
    font-family: inherit;
    font-size: 1rem;
    background-color: #fafafa;
}
.form-group input:focus, .form-group textarea:focus {
    outline: none;
    border-color: #4e1e2f;
    background-color: #fff;
}
.form-group textarea {
    resize: vertical;
    min-height: 150px;
}
.contact-form button {
    background-color: #4e1e2f;
    color: #fff;
    border: none;
    padding: 15px 40px;
    font-size: 1.1rem;
    border-radius: 5px;
    cursor: pointer;
    transition: background 0.3s;
    align-self: center;
    margin-top: 20px;
    font-family: 'Prompt', sans-serif;
}
.contact-form button:hover {
    background-color: #7a324b;
}

@media (max-width: 1024px) {
    html {
        font-size: 150%;
    }

    .logo img {
        height: 66px !important;
    }

    .img-miyabi {
        transform: scale(1.1) !important;
    }

    .hero-balloon {
        width: 50%;
        max-width: none;
        padding: 20px;
        gap: 20px;
        flex-direction: column;
        text-align: center;
    }
    
    .hero-balloon img {
        width: 100%;
        max-width: 300px;
        height: auto;
    }
    
    .hero-balloon span {
        font-size: 1.2rem;
    }

    html:not([lang="kr"]) .about-title-desktop {
        display: none !important;
    }

    html:not([lang="kr"]) .about-title-mobile {
        display: block !important;
        text-align: center;
        margin-bottom: 30px;
    }

    html:not([lang="kr"]) .map-desktop {
        display: none !important;
    }

    html:not([lang="kr"]) .map-mobile {
        display: block !important;
        width: 100%;
        margin-top: 30px;
    }

    .hamburger-menu {
        display: flex;
    }

    .nav-menu {
        position: fixed;
        top: 0;
        right: -100%;
        width: 250px;
        height: 100vh;
        background-color: rgba(112, 44, 67, 0.9);
        display: flex;
        flex-direction: column;
        align-items: center;
        padding-top: 80px;
        transition: right 0.3s ease-in-out;
        z-index: 1000;
    }

    .nav-menu.active {
        right: 0;
    }

    .nav-menu > ul {
        flex-direction: column;
        gap: 20px;
        text-align: center;
    }
    
    .lang-dropdown {
        right: auto;
        left: 50%;
        transform: translateX(-50%);
        width: 200px;
    }
    
    .hero-content h1 {
        font-size: 2.5rem;
    }
    
    .hero-content h2 {
        font-size: 1.2rem;
    }

    .hero-link {
        font-size: 1.6rem;
        margin-top: 60px;
    }

    .section-title.dark {
        text-align: center !important;
    }
    
    .footer-container {
        flex-direction: column-reverse;
        gap: 20px;
        text-align: center;
    }
}

@media (max-width: 768px) {
    html {
        font-size: 100%;
    }

    .logo img {
        height: 60px !important;
    }

    .hamburger-menu {
        gap: 6px;
    }
    
    .hamburger-menu .bar {
        width: 30px;
        height: 3px;
    }

    .hamburger-menu.active .bar:nth-child(1) {
        transform: translateY(9px) rotate(45deg);
    }
    
    .hamburger-menu.active .bar:nth-child(3) {
        transform: translateY(-9px) rotate(-45deg);
    }

    .slider-wrapper {
        gap: 0;
    }

    .slider-slide {
        flex: 0 0 100%;
    }

    .product-row, .product-row.reverse {
        flex-direction: column;
        text-align: center;
        gap: 30px; /* Base mobile gap */
    }

    .product-row:nth-of-type(1) {
        gap: 60px; /* Miyabi gap (+30px) */
        margin-top: 100px;
    }

    .img-miyabi {
        transform: scale(1.6) !important;
    }

    .product-row:nth-of-type(2) {
        gap: 0px; /* Takara gap (reduced) */
    }
    
    .product-info,
    .product-row.reverse .product-info {
        text-align: center !important;
    }

    .product-image img {
        margin: 0 auto !important; /* Reset any margins */
    }

    .about-row {
        flex-direction: column-reverse;
        text-align: center;
        gap: 16px;
    }
    
    .about-info {
        margin-top: 10px;
        margin-bottom: 20px;
    }

    .about-title-desktop {
        display: none !important;
    }

    .about-title-mobile {
        display: block !important;
        text-align: center;
        margin-bottom: 30px;
    }

    .map-desktop {
        display: none !important;
    }

    .map-mobile {
        display: block !important;
        width: 100%;
        margin-top: 30px;
    }

    .hero-content {
        padding: 0 20px;
    }

    .bg3, .bg5 {
        display: none !important;
    }

    .bg1 { animation: fadeBg3 30s infinite; animation-delay: 0s; }
    .bg2 { animation: fadeBg3 30s infinite; animation-delay: 10s; }
    .bg4 { animation: fadeBg3 30s infinite; animation-delay: 20s; }
}

@keyframes fadeBg3 {
    0%   { opacity: 0; }
    10%  { opacity: 1; }
    33%  { opacity: 1; }
    43%  { opacity: 0; }
    100% { opacity: 0; }
}

@media (max-width: 576px) {
    .hero-balloon {

        bottom: 20px;
        right: auto;
        left: 50%;
        transform: translateX(-50%);
        width: calc(100% - 40px);
        max-width: none;
        flex-direction: column;
        text-align: center;
        padding: 15px;
        gap: 16px;
    }

    .hero-balloon:hover {
        transform: translate(-50%, -5px);
    }
    
    .hero-balloon img {
        width: 100%;
        max-width: 240px;
        height: auto;
    }
    
    .hero-balloon span {
        font-size: 1.1rem;
    }
}


/* Underline for contact form links */
.about-info a[href*="contact"] {
    text-decoration: underline !important;
    text-decoration-color: currentColor;
}


@media (max-width: 576px) {
    .store-list {
        gap: 16px;
    }

    .store-row {
        gap: 16px;
    }
    .store-row a {
        flex: 0 0 calc(50% - 8px);
        display: flex;
        justify-content: center;
    }
    .store-row a img {
        width: 100%;
        max-width: 170px;
        height: auto;
        aspect-ratio: 1/1;
    }
}

@media (max-width: 576px) {
    .contact-container {
        padding: 30px 25px;
    }
}
