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

body {
    font-family: 'Noto Sans TC', 'Microsoft JhengHei', sans-serif; /* Recommended rounded font */
    line-height: 1.6;
    color: #555;
    background-color: #F8F5F1; /* Cream color palette */
    font-size: 16px;
}

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

a {
    text-decoration: none;
    color: #A9B7A4; /* Pale green or Morandi pink */
}

a:hover {
    color: #E0BBE4; /* Morandi pink */
}

ul {
    list-style: none;
}

img {
    max-width: 100%;
    height: auto;
    display: block; /* Remove extra space below images */
}

/* Header */
header {
    background-color: #FFF;
    padding: 20px 0;
    border-bottom: 1px solid #eee;
    box-shadow: 0 2px 5px rgba(0,0,0,0.05);
    position: relative;
    z-index: 100;
}

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

.logo img {
    height: 50px;
}

nav ul {
    display: flex; /* Default: horizontal menu */
}

nav ul li {
    margin-left: 30px;
}

nav ul li a {
    font-weight: bold;
    color: #777;
    transition: color 0.3s ease;
}

nav ul li a:hover {
    color: #E0BBE4; /* Morandi pink */
}

/* Hamburger Menu Button (hidden by default) */
.hamburger-menu {
    display: none; /* Hidden on large screens */
    width: 30px;
    height: 24px;
    background: none;
    border: none;
    cursor: pointer;
    position: relative;
    z-index: 101; /* Ensure it's above everything */
    padding: 0;
}

.hamburger-menu span {
    display: block;
    width: 100%;
    height: 3px;
    background-color: #6C5B7B; /* Bar color */
    border-radius: 2px;
    position: absolute;
    left: 0;
    transition: all 0.3s ease-in-out;
}

.hamburger-menu span:nth-child(1) { top: 0; }
.hamburger-menu span:nth-child(2) { top: 50%; transform: translateY(-50%); }
.hamburger-menu span:nth-child(3) { bottom: 0; }

/* Hamburger Menu Animation when active (optional but good) */
.hamburger-menu.active span:nth-child(1) {
    transform: translateY(10.5px) rotate(45deg); /* Adjust based on exact height */
}
.hamburger-menu.active span:nth-child(2) {
    opacity: 0;
}
.hamburger-menu.active span:nth-child(3) {
    transform: translateY(-10.5px) rotate(-45deg); /* Adjust based on exact height */
}


/* Buttons */
.button {
    display: inline-block;
    background-color: #E0BBE4;
    color: #FFF;
    padding: 12px 25px;
    border-radius: 30px;
    margin-top: 20px;
    transition: background-color 0.3s ease, transform 0.2s ease;
    font-weight: bold;
    letter-spacing: 1px;
}

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

.button-small {
    display: inline-block;
    background-color: #A9B7A4;
    color: #FFF;
    padding: 8px 15px;
    border-radius: 20px;
    margin-top: 10px;
    font-size: 0.9em;
    transition: background-color 0.3s ease;
}

.button-small:hover {
    background-color: #8D9B8A;
}


/* Main Content Sections */
main {
    padding-top: 0;
    padding-bottom: 40px;
}

section {
    padding: 60px 0;
    text-align: center;
}

section:nth-of-type(even) {
    background-color: #FDF9F7;
}

h1, h2, h3 {
    color: #6C5B7B;
    margin-bottom: 20px;
    font-weight: normal;
}

h1 {
    font-size: 3em;
}

h2 {
    font-size: 2.5em;
    margin-bottom: 40px;
}

h3 {
    font-size: 1.8em;
    margin-bottom: 15px;
    color: #888;
}

p {
    margin-bottom: 15px;
    line-height: 1.8;
}

/* VIDEO HERO SECTION STYLES */
.video-hero-section {
    position: relative;
    width: 100%;
    height: 600px;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #FFF;
    text-shadow: 0 2px 5px rgba(0,0,0,0.5);
    /* Fallback image if video fails to load or for non-supporting browsers */
    background-image: url('../images/hero_banner.jpg');
    background-size: cover;
    background-position: center;
}

.video-hero-section video {
    position: absolute;
    top: 50%;
    left: 50%;
    min-width: 100%;
    min-height: 100%;
    width: auto;
    height: auto;
    z-index: -1;
    transform: translate(-50%, -50%);
    object-fit: cover;
    filter: brightness(70%);
}

.hero-content-overlay {
    position: relative;
    z-index: 1;
    text-align: center;
    max-width: 800px;
    padding: 20px;
}

.hero-content-overlay h1 {
    color: #FFF;
    font-size: 3.5em;
    margin-bottom: 20px;
}

.hero-content-overlay p {
    color: #EEE;
    font-size: 1.2em;
    margin-bottom: 30px;
}


/* Featured Products */
.featured-products .product-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 30px;
    margin-top: 50px;
}

.product-item {
    background-color: #FFF;
    border-radius: 15px;
    padding: 25px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.08);
    text-align: center;
    transition: transform 0.3s ease;
}

.product-item:hover {
    transform: translateY(-8px);
}

.product-item img {
    width: 100%;
    height: 200px;
    object-fit: cover;
    border-radius: 10px;
    margin-bottom: 15px;
}

.product-item h3 {
    margin-top: 10px;
    margin-bottom: 10px;
    color: #6C5B7B;
}

.product-item p {
    font-size: 0.95em;
    color: #777;
    margin-bottom: 15px;
}

.product-item .price {
    font-weight: bold;
    color: #D3B9EE;
    font-size: 1.1em;
    margin-bottom: 15px;
}

/* Call to Action */
.call-to-action {
    background-color: #F8E8D9;
    color: #555;
    padding: 80px 0;
}

.call-to-action h2 {
    color: #6C5B7B;
}

/* Footer */
footer {
    background-color: #EAE3D9;
    color: #777;
    padding: 40px 0;
    font-size: 0.9em;
    text-align: center;
}

footer .container {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-around;
    align-items: flex-start;
    gap: 30px;
}

.footer-links ul {
    padding: 0;
    text-align: left;
}

.footer-links ul li {
    margin-bottom: 10px;
}

.footer-links ul li a {
    color: #777;
    transition: color 0.3s ease;
}

.footer-links ul li a:hover {
    color: #6C5B7B;
}

.social-media p {
    margin-bottom: 15px;
    font-weight: bold;
    color: #666;
}

.social-media a img {
    width: 30px;
    height: 30px;
    margin: 0 8px;
    display: inline-block;
    vertical-align: middle;
}

.copyright {
    margin-top: 20px;
    flex-basis: 100%;
}

/* About Page Specific Styles */
.about-page section, .shop-page section, .characters-page section, .news-page section, .contact-page section {
    padding: 80px 0;
}

.about-intro, .shop-intro, .characters-intro, .news-intro, .contact-intro {
    background-color: #FCF9F6;
    padding: 60px 0;
}

.about-intro h1, .shop-intro h1, .characters-intro h1, .news-intro h1, .contact-intro h1 {
    font-size: 3.2em;
    color: #6C5B7B;
}

.about-intro p, .shop-intro p, .characters-intro p, .news-intro p, .contact-intro p {
    max-width: 800px;
    margin: 0 auto;
    font-size: 1.1em;
    color: #666;
}

.brand-philosophy-extended ul {
    text-align: left;
    max-width: 800px;
    margin: 30px auto;
}

.brand-philosophy-extended ul li {
    margin-bottom: 15px;
    line-height: 1.8;
}

.target-market ul {
    text-align: left;
    max-width: 600px;
    margin: 30px auto;
}

.target-market ul li {
    margin-bottom: 10px;
}

/* Shop Page Specific Styles */
.product-category {
    padding-top: 40px;
    padding-bottom: 40px;
    border-bottom: 1px solid #eee;
}

.product-category:last-of-type {
    border-bottom: none;
}

/* Characters Page Specific Styles */
.character-card {
    background-color: #FFF;
    border-radius: 15px;
    padding: 30px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.08);
    margin-bottom: 30px;
    text-align: center;
    transition: transform 0.3s ease;
}

.character-card:hover {
    transform: translateY(-5px);
}

.character-card img {
    width: 200px;
    height: 200px;
    object-fit: contain;
    border-radius: 50%;
    margin: 0 auto 20px auto;
    border: 5px solid #E0BBE4;
}

.character-list {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    margin-top: 50px;
}

.character-card h2 {
    font-size: 2em;
    margin-bottom: 10px;
    color: #6C5B7B;
}

.character-card h3 {
    font-size: 1.2em;
    color: #A9B7A4;
    margin-bottom: 15px;
}

.character-card p {
    font-size: 0.95em;
    color: #777;
}

/* News Page Specific Styles */
.news-articles .news-item {
    background-color: #FFF;
    border-radius: 15px;
    padding: 30px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.08);
    margin-bottom: 40px;
    text-align: left;
}

.news-item img {
    width: 100%;
    height: 300px;
    object-fit: cover;
    border-radius: 10px;
    margin-bottom: 20px;
}

.news-item h2 {
    font-size: 1.8em;
    margin-bottom: 10px;
    color: #6C5B7B;
}

.news-item .news-date {
    font-size: 0.9em;
    color: #999;
    margin-bottom: 15px;
}

/* Contact Page Specific Styles */
.contact-info {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    margin-top: 50px;
    text-align: left;
}

.contact-method {
    background-color: #FFF;
    border-radius: 15px;
    padding: 30px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.08);
}

.contact-method h2 {
    font-size: 1.5em;
    color: #6C5B7B;
    margin-bottom: 20px;
}

.contact-method p {
    margin-bottom: 10px;
    color: #666;
}

.contact-method a {
    color: #A9B7A4;
    font-weight: bold;
}

.social-links a {
    display: inline-block;
    background-color: #F8E8D9;
    color: #6C5B7B;
    padding: 8px 15px;
    border-radius: 20px;
    margin-right: 10px;
    margin-bottom: 10px;
    transition: background-color 0.3s ease;
}

.social-links a:hover {
    background-color: #E0BBE4;
    color: #FFF;
}


/* Responsive Design */
@media (max-width: 768px) {
    h1 {
        font-size: 2.5em;
    }

    h2 {
        font-size: 2em;
    }

    .video-hero-section {
        height: 400px;
    }

    .hero-content-overlay h1 {
        font-size: 2.5em;
    }

    .hero-content-overlay p {
        font-size: 1em;
    }

    /* Hamburger menu displayed */
    .hamburger-menu {
        display: block; /* Show hamburger button */
    }

    /* Hide default navigation and style as mobile menu */
    nav {
        /* This ensures the nav container doesn't block clicks when menu is closed */
        position: absolute;
        top: 0;
        right: 0;
        width: 0;
        height: 0;
        overflow: hidden;
    }

    nav ul {
        flex-direction: column;
        align-items: center;
        background-color: #F8F5F1; /* Menu background */
        position: fixed; /* Fixed position for overlay */
        top: 0;
        right: 0; /* Starts off-screen to the right */
        width: 100vw; /* Full viewport width */
        height: 100vh; /* Full viewport height */
        padding-top: 100px; /* Space for logo/header, adjust as needed */
        box-shadow: -2px 0 10px rgba(0,0,0,0.1);
        transform: translateX(100%); /* Initially hide by moving off-screen */
        transition: transform 0.3s ease-in-out;
        z-index: 99; /* Below hamburger button but above content */
        justify-content: flex-start; /* Align items to top, instead of center */
    }

    nav ul.nav-active { /* Class toggled by JS */
        transform: translateX(0); /* Slide into view */
    }

    nav ul li {
        margin: 20px 0; /* More spacing for vertical menu items */
    }

    nav ul li a {
        font-size: 1.5em; /* Larger font for mobile */
        color: #6C5B7B; /* Consistent brand color for links */
    }

    footer .footer-links ul {
        text-align: center;
        margin-bottom: 20px;
    }

    footer .footer-links, .social-media, .copyright {
        flex-basis: auto;
    }

    .product-grid, .character-list, .contact-info {
        grid-template-columns: 1fr;
    }

    /* Adjust padding for smaller containers to avoid overflow */
    .container {
        padding: 0 15px;
    }
    section {
        padding: 40px 0;
    }
    .featured-products .product-grid,
    .character-list,
    .contact-info {
        gap: 20px;
    }
    .product-item, .character-card, .news-item, .contact-method {
        padding: 20px;
    }
    .hero-content-overlay h1 {
        font-size: 2.2em; /* Adjusted for readability on smaller screens */
    }
    .hero-content-overlay p {
        font-size: 0.9em; /* Adjusted for readability on smaller screens */
        margin-bottom: 20px;
    }
    .button {
        padding: 10px 20px;
        font-size: 0.9em;
    }
}

@media (max-width: 480px) {
    h1 {
        font-size: 2em;
    }
    h2 {
        font-size: 1.8em;
    }
    .video-hero-section {
        height: 280px;
    }
    .hero-content-overlay h1 {
        font-size: 1.6em;
    }
    .hero-content-overlay p {
        font-size: 0.8em; /* Even smaller for very small screens */
    }
    .button {
        padding: 8px 18px;
        font-size: 0.85em;
    }
}