<?php 

$meta_title = "Medications Information & Wellness Resources | MedsFAQ";
$meta_description = "Explore medication information, healthcare resources, wellness articles, and educational content related to mental health, pain management, anxiety, insomnia, and healthy living."; 
$meta_keywords = "medications, medication information, healthcare resources, anxiety medications, insomnia treatment, pain management, ADHD information, wellness resources, mental health support";

include 'includes/header.php'; ?>
<body>
    <!-- MAIN WRAPPER
    ================================================== -->
    <div class="main-wrapper">

        <!-- HEADER
        ================================================== -->
        <?php include 'includes/nav.php'; ?>

        <style>
        .alphabet-filter {
            display: flex;
            flex-wrap: wrap;
            justify-content: center;
            gap: 10px;
            background: #e4e4e4;
            padding: 12px 15px;
            border-radius: 10px;
            margin-top: 20px;
        }

        .alpha-btn {
            border: none;
            background: transparent;
            font-weight: 500;
            padding: 5px 8px;
            cursor: pointer;
        }

        .alpha-btn.active {
            color: #ffc400;
            font-weight: 600;
        }

        .alpha-btn:hover {
            color: #ffc400;
            background: #ffc4001f;
            font-weight: 600;
            transition: ease-in-out;
        }

        .medication-list {
            display: grid;
            grid-template-columns: repeat(3, 1fr);
            gap: 15px;
            /* margin-top: 30px; */
        }

        .medication-item a {
            text-decoration: underline;
            color: #000;
        }

        .show-more-wrap {
            display: flex;
            justify-content: center;
            padding: 0 0 50px;
        }

        .show-more-btn {
            padding: 12px 26px;
            border: none;
            border-radius: 8px;
            background: #ffc400;
            color: #000;
            cursor: pointer;
            transition: all 0.2s ease-in-out;
            font-weight: 600;
        }

        .show-more-btn:hover {
            background: #e6b000;
        }

        @media (max-width: 768px) {
            .medication-list {
                grid-template-columns: repeat(2, 1fr);
            }
        }

        @media (max-width: 480px) {
            .medication-list {
                grid-template-columns: 1fr;
            }
        }
    </style>

        <!-- PAGE TITLE
        ================================================== -->
        <section class="blog-section">
            <div class="container text-center">
                <h2 class="blog-title">Find medications</h2>

                <div class="alphabet-filter" id="alphabetContainer">
                    <!-- Alphabet buttons will render here -->
                </div>

            </div>
        </section>

        <!-- BLOG GRID
        ================================================== -->

        
            <div class="medication-list text-center py-5" id="blogContainer"></div>
            <div id="showMoreContainer"></div>
        
        <!-- FOOTER
        ================================================== -->
<?php include 'includes/footer.php'; ?>