:root {
    --primary-color: #FF9E2C;
    --secondary-color: #96C839;
    --accent-color: #4CC4E7;
    --background-light: #FFFDF2;
    --text-dark: #5D4037;
    --text-light: #FFFDF2;
    --border-color: #5D4037;
    --shadow-color: rgba(93, 64, 55, 0.3);
}

/* 自訂游標 - 楓之谷黃色手套 */
* {
    cursor: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24"><path fill="%23FFD700" stroke="%235D4037" stroke-width="1.5" d="M8 2a2 2 0 0 1 2 2v4h2V4a2 2 0 1 1 4 0v4h1a2 2 0 1 1 0 4v6a4 4 0 0 1-8 0v-6H8V6a2 2 0 0 1 0-4z"/></svg>'), auto;
}

a, button {
    cursor: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24"><path fill="%23FFD700" stroke="%235D4037" stroke-width="2" d="M8 2a2 2 0 0 1 2 2v4h2V4a2 2 0 1 1 4 0v4h1a2 2 0 1 1 0 4v6a4 4 0 0 1-8 0v-6H8V6a2 2 0 0 1 0-4z"/></svg>'), pointer !important;
}

/* General Styles */
body {
    font-family: 'Microsoft JhengHei', 'Noto Sans TC', sans-serif;
    background-color: var(--background-light);
    background-image: 
        repeating-linear-gradient(90deg, transparent, transparent 50px, rgba(255, 158, 44, 0.03) 50px, rgba(255, 158, 44, 0.03) 51px),
        repeating-linear-gradient(0deg, transparent, transparent 50px, rgba(150, 200, 57, 0.03) 50px, rgba(150, 200, 57, 0.03) 51px);
}

/* Navbar Styles - 改為遊戲風格 */
.navbar-custom {
    background: #FFFFFF;
    padding: 1rem 0;
    box-shadow: 0 4px 0 var(--border-color);
    border-bottom: 3px solid var(--border-color);
    position: relative;
}

.navbar-custom::after {
    content: '';
    position: absolute;
    bottom: -8px;
    left: 0;
    right: 0;
    height: 8px;
    background: repeating-linear-gradient(
        90deg,
        var(--primary-color) 0px,
        var(--primary-color) 15px,
        var(--secondary-color) 15px,
        var(--secondary-color) 30px,
        var(--accent-color) 30px,
        var(--accent-color) 45px
    );
}

.navbar-custom .nav-link {
    color: var(--text-dark) !important;
    font-weight: 700;
    padding: 0.6rem 1.2rem;
    margin: 0 0.3rem;
    border-radius: 25px;
    border: 2px solid transparent;
    transition: all 0.3s ease;
    position: relative;
    background: transparent;
    text-shadow: 1px 1px 0 rgba(255, 255, 255, 0.5);
}

.navbar-custom .nav-link:hover,
.navbar-custom .nav-link:focus {
    background: var(--primary-color);
    color: white !important;
    border: 2px solid var(--border-color);
    transform: translateY(-3px);
    box-shadow: 0 4px 0 rgba(93, 64, 55, 0.3);
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.3);
}

.navbar-custom .nav-link:active {
    transform: translateY(-1px);
    box-shadow: 0 2px 0 rgba(93, 64, 55, 0.3);
}

/* Hero Section - 遊戲Logo風格 */
.hero-section {
    background: linear-gradient(rgba(0, 0, 0, 0.5), rgba(0, 0, 0, 0.5)),
        url('/images/maple-bg.jpg') center/cover;
    height: 80vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: var(--text-light);
    position: relative;
    border-bottom: 5px solid var(--border-color);
}

.hero-content {
    max-width: 800px;
    padding: 2rem;
}

.hero-title {
    font-size: 4rem;
    font-weight: 900;
    margin-bottom: 1rem;
    animation: fadeInDown 1s ease;
    text-shadow: 
        3px 3px 0 var(--primary-color),
        -2px -2px 0 var(--secondary-color),
        5px 5px 10px rgba(0,0,0,0.8),
        0 0 20px rgba(255, 158, 44, 0.5);
    -webkit-text-stroke: 2px var(--border-color);
    paint-order: stroke fill;
}

.hero-subtitle {
    font-size: 1.5rem;
    margin-bottom: 2rem;
    animation: fadeInUp 1s ease 0.5s;
    opacity: 0;
    animation-fill-mode: forwards;
    text-shadow: 
        2px 2px 0 var(--border-color),
        4px 4px 8px rgba(0,0,0,0.6);
    font-weight: 700;
}

/* Announcement Cards - 任務卡片風格 */
.announcement-card {
    background: white;
    border-radius: 20px;
    border: 3px solid var(--border-color);
    box-shadow: 0 6px 0 rgba(0, 0, 0, 0.15);
    transition: all 0.3s ease;
    margin-bottom: 1.5rem;
    overflow: hidden;
    position: relative;
}

.announcement-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 5px;
    background: linear-gradient(90deg, var(--primary-color), var(--secondary-color), var(--accent-color));
}

.announcement-card:hover {
    transform: translateY(-5px) rotate(1deg);
    box-shadow: 0 10px 0 rgba(0, 0, 0, 0.2);
}

.announcement-header {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: var(--text-light);
    padding: 1.2rem;
    font-weight: 700;
    text-shadow: 2px 2px 0 rgba(0,0,0,0.3);
}

/* Interactive Features - 道具卡片 */
.stat-card {
    background: white;
    border-radius: 15px;
    border: 3px solid var(--border-color);
    padding: 1.5rem;
    text-align: center;
    transition: all 0.3s ease;
    box-shadow: 0 5px 0 rgba(0, 0, 0, 0.15);
    position: relative;
    overflow: hidden;
}

.stat-card::before {
    content: '';
    position: absolute;
    top: -2px;
    left: -2px;
    right: -2px;
    height: 8px;
    background: linear-gradient(90deg, var(--primary-color), var(--accent-color));
    border-radius: 15px 15px 0 0;
}

.stat-card:hover {
    transform: translateY(-8px) scale(1.05);
    box-shadow: 0 10px 0 rgba(0, 0, 0, 0.2);
    border-color: var(--primary-color);
}

.stat-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
    filter: drop-shadow(2px 2px 0 var(--primary-color));
}

.stat-card:nth-child(1) .stat-icon {
    color: var(--primary-color);
}

.stat-card:nth-child(2) .stat-icon {
    color: var(--secondary-color);
}

.stat-card:nth-child(3) .stat-icon {
    color: var(--accent-color);
}

.stat-card:nth-child(4) .stat-icon {
    color: #E74C3C;
}

.stat-card h3 {
    font-weight: 900;
    color: var(--text-dark);
    font-size: 2rem;
    text-shadow: 1px 1px 0 rgba(255, 158, 44, 0.3);
}

.stat-card p {
    color: var(--text-dark);
    font-weight: 600;
    margin-bottom: 0;
}

/* Floating Action Button */
.fab-button {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    width: 70px;
    height: 70px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 5px 0 rgba(0, 0, 0, 0.2);
    transition: all 0.3s ease;
    border: 3px solid var(--border-color);
}

.fab-button:hover {
    transform: scale(1.15) rotate(10deg);
    box-shadow: 0 8px 0 rgba(0, 0, 0, 0.25);
}

.fab-button:active {
    transform: scale(1.05);
    box-shadow: 0 3px 0 rgba(0, 0, 0, 0.2);
}

/* Animations */
@keyframes float {
    0%, 100% {
        transform: translateY(0px);
    }
    50% {
        transform: translateY(-15px);
    }
}

@keyframes fadeInDown {
    from {
        opacity: 0;
        transform: translateY(-50px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(50px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.floating {
    animation: float 3s ease-in-out infinite;
}

/* Logo 樣式 */
.navbar-custom .navbar-brand {
    color: var(--text-dark);
    font-size: 1.8rem;
    font-weight: 900;
    transition: transform 0.3s ease;
    text-shadow: 
        2px 2px 0 rgba(255, 158, 44, 0.3),
        -1px -1px 0 rgba(255, 158, 44, 0.2);
    display: flex;
    align-items: center;
    gap: 10px;
}

.navbar-custom .navbar-brand:hover {
    transform: scale(1.08) rotate(-2deg);
    color: var(--primary-color);
}

.navbar-logo {
    height: 48px;
    width: auto;
    filter: drop-shadow(2px 2px 0 rgba(93, 64, 55, 0.3));
    transition: transform 0.3s ease;
}

.navbar-custom .navbar-brand:hover .navbar-logo {
    transform: rotate(10deg) scale(1.1);
}

.brand-text {
    font-size: 1.8rem;
    line-height: 48px;
    display: block;
    margin: 0;
    padding: 0;
    white-space: nowrap;
}

/* 響應式調整 */
@media (max-width: 768px) {
    .navbar-logo {
        height: 35px;
    }

    .brand-text {
        font-size: 1.3rem;
        line-height: 35px;
    }

    .hero-title {
        font-size: 2.5rem;
    }

    .hero-subtitle {
        font-size: 1.2rem;
    }

    .navbar-custom .nav-link {
        margin: 0.3rem 0;
    }
}