/* モバイル対応のめっちゃ可愛いレスポンシブデザイン */

/* タブレット (768px - 1024px) */
@media (max-width: 1024px) {
    .hero-title {
        font-size: 2.5rem;
    }
    
    .quick-cards {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .category-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .plant-character {
        width: 70px;
        height: 70px;
        font-size: 2.5rem;
    }
}

/* スマートフォン (768px以下) */
@media (max-width: 768px) {
    body::before {
        background-image: 
            radial-gradient(circle at 50% 20%, rgba(168, 213, 186, 0.25) 0%, transparent 40%),
            radial-gradient(circle at 50% 80%, rgba(178, 223, 219, 0.25) 0%, transparent 40%);
    }
    
    .site-header {
        position: fixed;
        width: 100%;
        z-index: 9999;
    }
    
    main {
        padding-top: 80px;
    }
    
    .nav-menu {
        position: fixed;
        top: 70px;
        left: -100%;
        width: 100%;
        height: calc(100vh - 70px);
        background: linear-gradient(135deg, 
            rgba(168, 213, 186, 0.98), 
            rgba(255, 236, 179, 0.98),
            rgba(178, 223, 219, 0.98));
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: start;
        padding-top: 2rem;
        gap: 1.5rem;
        transition: left 0.3s cubic-bezier(0.68, -0.55, 0.265, 1.55);
        backdrop-filter: blur(10px);
        overflow-y: auto;
    }
    
    .nav-menu.active {
        left: 0;
    }
    
    .nav-menu a {
        font-size: 1.2rem;
        padding: 1rem 2rem;
        width: 80%;
        text-align: center;
        background: rgba(255, 255, 255, 0.9);
        border-radius: 25px;
        box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    }
    
    .nav-toggle {
        display: flex;
        position: relative;
        z-index: 10000;
    }
    
    .nav-toggle span {
        background: var(--text-kawaii);
        border-radius: 3px;
        transition: all 0.3s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    }
    
    .nav-toggle.active span:nth-child(1) {
        transform: rotate(45deg) translate(7px, 7px);
        background: white;
    }
    
    .nav-toggle.active span:nth-child(2) {
        opacity: 0;
        transform: scale(0);
    }
    
    .nav-toggle.active span:nth-child(3) {
        transform: rotate(-45deg) translate(7px, -7px);
        background: white;
    }
    
    /* ヒーローセクション */
    .hero-section {
        padding: 3rem 0;
    }
    
    .hero-title {
        font-size: 1.8rem;
        line-height: 1.4;
    }
    
    .hero-title span {
        font-size: 1.5rem !important;
    }
    
    .hero-subtitle {
        font-size: 1rem;
        padding: 0 1rem;
    }
    
    /* セクションタイトル */
    .section-title {
        font-size: 1.5rem;
        margin-bottom: 2rem;
    }
    
    .section-title::before,
    .section-title::after {
        display: none;
    }
    
    /* カード類 */
    .quick-cards,
    .category-grid,
    .basics-grid,
    .user-cards {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    
    .quick-card,
    .category-card,
    .user-card,
    .basics-card {
        padding: 1.5rem;
    }
    
    .quick-icon {
        font-size: 2.5rem;
        padding: 15px !important;
    }
    
    /* ランキング */
    .ranking-wrapper {
        grid-template-columns: 1fr;
    }
    
    .ranking-table {
        font-size: 0.9rem;
    }
    
    .ranking-table th,
    .ranking-table td {
        padding: 0.5rem;
    }
    
    /* FAQ */
    .faq-question {
        font-size: 1rem;
        padding: 1rem;
    }
    
    .faq-answer {
        padding: 0 1rem 1rem;
        font-size: 0.9rem;
    }
    
    /* CTA */
    .cta-buttons {
        flex-direction: column;
        align-items: center;
    }
    
    .btn-large {
        width: 100%;
        max-width: 300px;
    }
    
    /* フッター */
    .footer-content {
        grid-template-columns: 1fr;
        text-align: center;
    }
    
    .footer-section {
        margin-bottom: 2rem;
    }
    
    /* 植物キャラクター */
    .plant-character {
        width: 60px;
        height: 60px;
        font-size: 2rem;
        bottom: 15px;
        right: 15px;
    }
    
    /* 浮遊する絵文字 */
    .floating-emoji {
        font-size: 1.2rem;
    }
    
    /* アニメーション調整 */
    @keyframes icon-wiggle {
        0%, 100% { transform: rotate(-3deg); }
        50% { transform: rotate(3deg); }
    }
    
    @keyframes plant-grow {
        0%, 100% { transform: scale(1); }
        50% { transform: scale(1.05) rotate(3deg); }
    }
}

/* 小さいスマートフォン (480px以下) */
@media (max-width: 480px) {
    .container {
        padding: 0 1rem;
    }
    
    .hero-title {
        font-size: 1.5rem;
    }
    
    .section-title {
        font-size: 1.3rem;
    }
    
    h3 {
        font-size: 1.2rem;
    }
    
    .btn-primary,
    .btn-secondary,
    .btn-outline {
        padding: 0.8rem 1.5rem;
        font-size: 0.95rem;
    }
    
    .quick-card h3,
    .category-card h3,
    .user-card h3,
    .basics-card h3 {
        font-size: 1.1rem;
    }
    
    .purpose-list li {
        font-size: 0.9rem;
        padding: 0.8rem;
        padding-left: 2.5rem;
    }
    
    .purpose-list li:before {
        left: 0.8rem;
    }
}

/* アクセシビリティ向上 */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
    
    .floating-emoji,
    .bubble,
    .sparkle,
    .confetti {
        display: none;
    }
}

/* ダークモード対応 */
@media (prefers-color-scheme: dark) {
    :root {
        --bg-white: #2C2C2C;
        --bg-light: #3A3A3A;
        --bg-gray: #454545;
        --text-primary: #FFFFFF;
        --text-secondary: #E0E0E0;
        --text-kawaii: #FFB8D1;
    }
    
    body {
        background: linear-gradient(135deg, #3A2E3C 0%, #2E3A3C 50%, #2E3C2E 100%);
    }
    
    .quick-card,
    .category-card,
    .user-card,
    .basics-card,
    .faq-item {
        background: linear-gradient(135deg, rgba(60, 60, 60, 0.9), rgba(80, 80, 80, 0.9));
        color: var(--text-primary);
    }
    
    .site-header {
        background: linear-gradient(90deg, 
            rgba(168, 213, 186, 0.3) 0%, 
            rgba(188, 220, 188, 0.3) 25%, 
            rgba(255, 245, 157, 0.3) 50%, 
            rgba(178, 223, 219, 0.3) 75%, 
            rgba(225, 190, 231, 0.3) 100%);
        backdrop-filter: blur(10px);
        background-color: rgba(44, 44, 44, 0.9);
    }
}

/* 横向きモバイル対応 */
@media (max-width: 768px) and (orientation: landscape) {
    .hero-section {
        padding: 2rem 0;
    }
    
    .hero-title {
        font-size: 1.5rem;
    }
    
    .quick-cards,
    .category-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .plant-character {
        width: 50px;
        height: 50px;
        font-size: 1.8rem;
    }
}