/* ========================================
   透明感のある美しい四柱推命学習サイト
   ======================================== */

/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Noto Sans JP', 'Hiragino Sans', 'Yu Gothic UI', sans-serif;
    line-height: 1.8;
    color: #2c3e50;
    background: linear-gradient(135deg, 
        rgba(255, 255, 255, 0.9) 0%, 
        rgba(240, 248, 255, 0.8) 50%, 
        rgba(230, 245, 255, 0.9) 100%);
    min-height: 100vh;
    position: relative;
}

body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: 
        radial-gradient(circle at 20% 80%, rgba(120, 140, 255, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 80% 20%, rgba(255, 120, 140, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 40% 40%, rgba(140, 255, 200, 0.1) 0%, transparent 50%);
    z-index: -1;
    pointer-events: none;
}

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

/* Glass Morphism Effect */
.glass {
    background: rgba(255, 255, 255, 0.25);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.18);
    box-shadow: 0 8px 32px 0 rgba(31, 38, 135, 0.37);
}

.glass-dark {
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    box-shadow: 0 8px 32px 0 rgba(31, 38, 135, 0.2);
}

/* Header */
header {
    background: linear-gradient(135deg, 
        rgba(67, 56, 202, 0.8) 0%, 
        rgba(139, 69, 19, 0.6) 50%,
        rgba(79, 70, 229, 0.8) 100%);
    backdrop-filter: blur(20px);
    color: white;
    padding: 60px 0;
    text-align: center;
    position: relative;
    overflow: hidden;
}

header::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(45deg, transparent, rgba(255, 255, 255, 0.1), transparent);
    animation: shimmer 3s infinite linear;
}

@keyframes shimmer {
    0% { transform: translateX(-100%) translateY(-100%) rotate(30deg); }
    100% { transform: translateX(100%) translateY(100%) rotate(30deg); }
}

header h1 {
    font-size: 3rem;
    margin-bottom: 15px;
    font-weight: 300;
    letter-spacing: 2px;
    text-shadow: 0 2px 20px rgba(255, 255, 255, 0.3);
    position: relative;
    z-index: 1;
}

.subtitle {
    font-size: 1.3rem;
    opacity: 0.9;
    font-weight: 300;
    letter-spacing: 1px;
    position: relative;
    z-index: 1;
}

/* Navigation */
nav {
    background: rgba(44, 62, 80, 0.9);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: 0 2px 20px rgba(44, 62, 80, 0.3);
}

.nav-wrapper {
    position: relative;
}

.nav-main {
    display: flex;
    list-style: none;
    margin: 0;
    padding: 0;
    gap: 2rem;
    justify-content: center;
}

.nav-main > li > a {
    display: block;
    color: rgba(255, 255, 255, 0.95);
    text-decoration: none;
    padding: 20px 25px;
    transition: all 0.3s ease;
    font-weight: 500;
    letter-spacing: 1px;
    position: relative;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
}

.nav-main > li > a:hover,
.nav-main > li > a.active {
    color: white;
    background: rgba(67, 56, 202, 0.8);
    border-radius: 10px;
    transform: translateY(-2px);
    box-shadow: 0 4px 20px rgba(67, 56, 202, 0.4);
}

/* Dropdown Styles */
.dropdown {
    position: relative;
}

.dropdown-toggle {
    cursor: pointer;
    text-decoration: none;
    color: rgba(255, 255, 255, 0.95);
    padding: 20px 25px;
    display: block;
    transition: all 0.3s ease;
    font-weight: 500;
    letter-spacing: 1px;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
}

.dropdown-toggle:hover {
    color: white;
    background: rgba(67, 56, 202, 0.8);
    border-radius: 10px;
    transform: translateY(-2px);
    box-shadow: 0 4px 20px rgba(67, 56, 202, 0.4);
}

.dropdown-menu {
    position: absolute;
    top: 100%;
    left: 0;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(20px);
    min-width: 220px;
    border-radius: 15px;
    box-shadow: 0 15px 35px rgba(31, 38, 135, 0.3);
    list-style: none;
    margin: 0;
    padding: 10px 0;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 1000;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.dropdown:hover .dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.dropdown-menu li a {
    display: block;
    padding: 12px 25px;
    color: #1a202c;
    text-decoration: none;
    transition: all 0.3s ease;
    font-weight: 500;
    border-radius: 8px;
    margin: 2px 10px;
}

.dropdown-menu li a:hover,
.dropdown-menu li a.active {
    background: linear-gradient(135deg, rgba(67, 56, 202, 0.15), rgba(79, 70, 229, 0.15));
    color: #4338ca;
    transform: translateX(5px);
    font-weight: 600;
}

/* Mobile Navigation */
.mobile-nav {
    display: none;
}

.mobile-menu-toggle {
    display: flex;
    flex-direction: column;
    background: none;
    border: none;
    cursor: pointer;
    padding: 15px;
}

.mobile-menu-toggle span {
    width: 25px;
    height: 3px;
    background: white;
    margin: 3px 0;
    transition: 0.3s;
    border-radius: 2px;
}

.mobile-menu {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(20px);
    border-radius: 0 0 20px 20px;
    box-shadow: 0 15px 35px rgba(31, 38, 135, 0.3);
    padding: 20px;
    display: none;
    z-index: 1000;
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-top: none;
}

.mobile-category {
    margin: 20px 0;
}

.mobile-category h4 {
    color: #4338ca;
    margin-bottom: 10px;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-weight: 600;
}

.mobile-menu a {
    display: block;
    padding: 12px 0;
    color: #1a202c;
    text-decoration: none;
    border-bottom: 1px solid rgba(255, 255, 255, 0.3);
    transition: all 0.3s ease;
    font-weight: 500;
}

.mobile-menu a:hover,
.mobile-menu a.active {
    color: #4338ca;
    padding-left: 10px;
}

/* Hero Section */
.hero {
    background: linear-gradient(135deg, 
        rgba(67, 56, 202, 0.1) 0%, 
        rgba(139, 69, 19, 0.05) 50%,
        rgba(79, 70, 229, 0.1) 100%);
    color: #2c3e50;
    text-align: center;
    padding: 100px 0;
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: 
        radial-gradient(circle at 30% 30%, rgba(67, 56, 202, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 70% 70%, rgba(139, 69, 19, 0.1) 0%, transparent 50%);
    z-index: 0;
}

.hero h2 {
    font-size: 2.8rem;
    margin-bottom: 25px;
    font-weight: 300;
    letter-spacing: 1px;
    position: relative;
    z-index: 1;
}

.hero p {
    font-size: 1.2rem;
    max-width: 800px;
    margin: 0 auto;
    opacity: 0.8;
    line-height: 1.8;
    position: relative;
    z-index: 1;
}

/* Learning Menu */
.learning-menu {
    padding: 100px 0;
    background: transparent;
}

.learning-menu h2 {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 60px;
    color: #2c3e50;
    font-weight: 300;
    letter-spacing: 1px;
}

.menu-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 30px;
}

.menu-item {
    background: rgba(255, 255, 255, 0.4);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    padding: 40px;
    border-radius: 20px;
    border: 1px solid rgba(255, 255, 255, 0.3);
    box-shadow: 0 8px 32px rgba(31, 38, 135, 0.2);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
}

.menu-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: all 0.6s;
}

.menu-item:hover::before {
    left: 100%;
}

.menu-item:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(31, 38, 135, 0.3);
    background: rgba(255, 255, 255, 0.5);
}

.menu-item h3 {
    color: #2c3e50;
    font-size: 1.5rem;
    margin-bottom: 20px;
    font-weight: 400;
    letter-spacing: 0.5px;
}

.menu-item p {
    margin-bottom: 25px;
    color: rgba(44, 62, 80, 0.8);
    line-height: 1.7;
}

.btn {
    display: inline-block;
    background: linear-gradient(135deg, #4338ca, #6366f1);
    color: white;
    padding: 15px 30px;
    text-decoration: none;
    border-radius: 50px;
    transition: all 0.4s ease;
    font-weight: 400;
    letter-spacing: 0.5px;
    box-shadow: 0 4px 15px rgba(67, 56, 202, 0.3);
    position: relative;
    overflow: hidden;
}

.btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: all 0.6s;
}

.btn:hover::before {
    left: 100%;
}

.btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(67, 56, 202, 0.4);
}

/* Intro Section */
.intro {
    padding: 100px 0;
    background: transparent;
}

.intro h2 {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 50px;
    color: #2c3e50;
    font-weight: 300;
    letter-spacing: 1px;
}

.intro p {
    max-width: 800px;
    margin: 0 auto 25px;
    font-size: 1.2rem;
    color: rgba(44, 62, 80, 0.8);
    text-align: center;
    line-height: 1.8;
}

/* Features Section */
.features {
    padding: 100px 0;
    background: transparent;
}

.features h2 {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 60px;
    color: #2c3e50;
    font-weight: 300;
    letter-spacing: 1px;
}

.feature-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 40px;
}

.feature {
    text-align: center;
    padding: 40px;
    background: rgba(255, 255, 255, 0.3);
    backdrop-filter: blur(10px);
    border-radius: 20px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    transition: all 0.4s ease;
}

.feature:hover {
    transform: translateY(-5px);
    background: rgba(255, 255, 255, 0.4);
    box-shadow: 0 10px 30px rgba(31, 38, 135, 0.2);
}

.feature h3 {
    color: #4338ca;
    font-size: 1.4rem;
    margin-bottom: 20px;
    font-weight: 400;
    letter-spacing: 0.5px;
}

.feature p {
    color: rgba(44, 62, 80, 0.8);
    line-height: 1.7;
}

/* Page Header */
.page-header {
    background: linear-gradient(135deg, 
        rgba(67, 56, 202, 0.8) 0%, 
        rgba(139, 69, 19, 0.6) 50%,
        rgba(79, 70, 229, 0.8) 100%);
    backdrop-filter: blur(20px);
    color: white;
    text-align: center;
    padding: 80px 0;
    position: relative;
    overflow: hidden;
}

.page-header::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(45deg, transparent, rgba(255, 255, 255, 0.1), transparent);
    animation: shimmer 4s infinite linear;
}

.page-header h1 {
    font-size: 2.8rem;
    margin-bottom: 15px;
    font-weight: 300;
    letter-spacing: 1px;
    position: relative;
    z-index: 1;
}

.page-header p {
    font-size: 1.2rem;
    opacity: 0.9;
    position: relative;
    z-index: 1;
}

/* Section */
.section {
    padding: 80px 0;
    background: transparent;
}

.section h2 {
    font-size: 2.2rem;
    color: #2c3e50;
    margin-bottom: 40px;
    border-bottom: 3px solid;
    border-image: linear-gradient(135deg, #4338ca, #6366f1) 1;
    padding-bottom: 15px;
    font-weight: 300;
    letter-spacing: 0.5px;
}

.section h3 {
    font-size: 1.6rem;
    color: #2c3e50;
    margin-bottom: 25px;
    margin-top: 50px;
    font-weight: 400;
}

.section h4 {
    font-size: 1.3rem;
    color: #4338ca;
    margin-bottom: 20px;
    margin-top: 40px;
    font-weight: 400;
}

/* Card Styles */
.qa-item,
.item-card,
.dict-item,
.personality-item {
    background: rgba(255, 255, 255, 0.4);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    padding: 30px;
    margin-bottom: 25px;
    border-radius: 20px;
    border: 1px solid rgba(255, 255, 255, 0.3);
    box-shadow: 0 8px 32px rgba(31, 38, 135, 0.15);
    transition: all 0.4s ease;
    position: relative;
    overflow: hidden;
}

.qa-item::before,
.item-card::before,
.dict-item::before,
.personality-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: all 0.6s;
}

.qa-item:hover::before,
.item-card:hover::before,
.dict-item:hover::before,
.personality-item:hover::before {
    left: 100%;
}

.qa-item:hover,
.item-card:hover,
.dict-item:hover,
.personality-item:hover {
    transform: translateY(-5px);
    background: rgba(255, 255, 255, 0.5);
    box-shadow: 0 15px 40px rgba(31, 38, 135, 0.25);
}

.qa-item {
    border-left: 4px solid #4338ca;
}

/* Grid Layouts */
.item-grid,
.dictionary-grid,
.personality-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    margin-top: 40px;
}

/* Element Badges */
.item-card .reading {
    color: rgba(44, 62, 80, 0.6);
    font-size: 0.9rem;
    margin-bottom: 15px;
    font-weight: 300;
}

.item-card .element {
    background: linear-gradient(135deg, #4338ca, #6366f1);
    color: white;
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 0.8rem;
    display: inline-block;
    margin-bottom: 15px;
    font-weight: 400;
    letter-spacing: 0.5px;
    box-shadow: 0 2px 8px rgba(67, 56, 202, 0.3);
}

/* Table Styles */
table {
    width: 100%;
    border-collapse: collapse;
    margin: 30px 0;
    background: rgba(255, 255, 255, 0.4);
    backdrop-filter: blur(15px);
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 8px 32px rgba(31, 38, 135, 0.15);
    border: 1px solid rgba(255, 255, 255, 0.3);
}

th, td {
    padding: 15px 20px;
    text-align: left;
    border-bottom: 1px solid rgba(255, 255, 255, 0.3);
}

th {
    background: rgba(67, 56, 202, 0.1);
    font-weight: 500;
    color: #2c3e50;
    letter-spacing: 0.5px;
}

tr:hover {
    background: rgba(255, 255, 255, 0.2);
}

/* Highlight Box */
.highlight-box {
    background: rgba(67, 56, 202, 0.1);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(67, 56, 202, 0.2);
    border-left: 4px solid #4338ca;
    padding: 30px;
    margin: 30px 0;
    border-radius: 15px;
    box-shadow: 0 8px 32px rgba(67, 56, 202, 0.1);
}

.highlight-box h3 {
    color: #2c3e50;
    margin-bottom: 20px;
    font-weight: 400;
}

/* Footer */
footer {
    background: rgba(44, 62, 80, 0.9);
    backdrop-filter: blur(20px);
    color: white;
    text-align: center;
    padding: 40px 0;
    margin-top: 100px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

/* Responsive */
@media (max-width: 768px) {
    .nav-main {
        display: none;
    }
    
    .mobile-nav {
        display: block;
    }
    
    header h1 {
        font-size: 2.2rem;
    }
    
    .subtitle {
        font-size: 1.1rem;
    }
    
    .hero h2 {
        font-size: 2rem;
    }
    
    .menu-grid,
    .feature-grid,
    .item-grid,
    .dictionary-grid,
    .personality-grid {
        grid-template-columns: 1fr;
    }
    
    .container {
        padding: 0 15px;
    }
    
    .section {
        padding: 60px 0;
    }
    
    .learning-menu,
    .intro,
    .features {
        padding: 80px 0;
    }
}

/* Special Styles for Advanced Pages */
.climate-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 25px;
    margin: 30px 0;
}

.climate-card {
    padding: 25px;
    border-radius: 20px;
    color: white;
    text-align: center;
    backdrop-filter: blur(15px);
    border: 1px solid rgba(255, 255, 255, 0.3);
    transition: all 0.4s ease;
    position: relative;
    overflow: hidden;
}

.climate-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: all 0.6s;
}

.climate-card:hover::before {
    left: 100%;
}

.climate-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.2);
}

.climate-card.cold {
    background: linear-gradient(135deg, rgba(33, 150, 243, 0.8), rgba(13, 71, 161, 0.9));
}

.climate-card.warm {
    background: linear-gradient(135deg, rgba(255, 87, 34, 0.8), rgba(211, 47, 47, 0.9));
}

.climate-card.dry {
    background: linear-gradient(135deg, rgba(255, 152, 0, 0.8), rgba(230, 81, 0, 0.9));
}

.climate-card.wet {
    background: linear-gradient(135deg, rgba(76, 175, 80, 0.8), rgba(46, 125, 50, 0.9));
}

.chokou-sections {
    margin: 40px 0;
}

.chokou-section {
    margin: 40px 0;
    background: rgba(255, 255, 255, 0.3);
    backdrop-filter: blur(15px);
    border-radius: 20px;
    padding: 40px;
    border: 1px solid rgba(255, 255, 255, 0.3);
    box-shadow: 0 8px 32px rgba(31, 38, 135, 0.15);
}

.table-container {
    overflow-x: auto;
    margin: 20px 0;
    border-radius: 15px;
}

.chokou-table {
    width: 100%;
    border-collapse: collapse;
    min-width: 800px;
    background: rgba(255, 255, 255, 0.5);
    backdrop-filter: blur(10px);
}

.chokou-table th,
.chokou-table td {
    padding: 12px;
    border: 1px solid rgba(255, 255, 255, 0.3);
    text-align: left;
}

.chokou-table th {
    background: rgba(67, 56, 202, 0.2);
    color: #2c3e50;
    font-weight: 500;
}

.chokou-table tr.spring {
    background: linear-gradient(90deg, rgba(76, 175, 80, 0.1), rgba(129, 199, 132, 0.1));
}

.chokou-table tr.summer {
    background: linear-gradient(90deg, rgba(255, 87, 34, 0.1), rgba(255, 138, 101, 0.1));
}

.chokou-table tr.autumn {
    background: linear-gradient(90deg, rgba(255, 152, 0, 0.1), rgba(255, 183, 77, 0.1));
}

.chokou-table tr.winter {
    background: linear-gradient(90deg, rgba(33, 150, 243, 0.1), rgba(100, 181, 246, 0.1));
}

/* Dictionary specific styles */
.dictionary-nav {
    margin-bottom: 40px;
    text-align: center;
}

.index-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 15px;
    margin-top: 20px;
}

.index-grid a {
    background: linear-gradient(135deg, #4338ca, #6366f1);
    color: white;
    padding: 12px 20px;
    border-radius: 50px;
    text-decoration: none;
    transition: all 0.3s ease;
    font-weight: 400;
    letter-spacing: 0.5px;
    box-shadow: 0 4px 15px rgba(67, 56, 202, 0.2);
}

.index-grid a:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(67, 56, 202, 0.3);
}

.dictionary-section {
    margin-bottom: 50px;
}

.dictionary-section h2 {
    color: #2c3e50;
    border-bottom: 3px solid;
    border-image: linear-gradient(135deg, #4338ca, #6366f1) 1;
    padding-bottom: 10px;
    margin-bottom: 30px;
    font-weight: 300;
}

.term-list {
    display: grid;
    gap: 20px;
}

.term-item {
    background: rgba(255, 255, 255, 0.4);
    backdrop-filter: blur(15px);
    padding: 25px;
    border-radius: 15px;
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-left: 4px solid #4338ca;
    box-shadow: 0 8px 32px rgba(31, 38, 135, 0.15);
    transition: all 0.3s ease;
}

.term-item:hover {
    transform: translateY(-3px);
    background: rgba(255, 255, 255, 0.5);
    box-shadow: 0 12px 35px rgba(31, 38, 135, 0.2);
}

.term-item h3 {
    color: #2c3e50;
    margin-bottom: 10px;
    font-size: 1.3rem;
    font-weight: 400;
}

.term-item p {
    color: rgba(44, 62, 80, 0.8);
    line-height: 1.7;
}

/* Animation for page load */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.menu-item,
.feature,
.qa-item,
.item-card {
    animation: fadeInUp 0.6s ease-out;
}

.menu-item:nth-child(2) { animation-delay: 0.1s; }
.menu-item:nth-child(3) { animation-delay: 0.2s; }
.menu-item:nth-child(4) { animation-delay: 0.3s; }
.menu-item:nth-child(5) { animation-delay: 0.4s; }
.menu-item:nth-child(6) { animation-delay: 0.5s; }