:root {
    --primary-color: #4361ee;
    --primary-dark: #3a56d4;
    --secondary-color: #3f37c9;
    --accent-color: #4895ef;
    --dark-color: #16213e;
    --light-color: #f8f9fa;
    --text-color: #e6f1ff;
    --text-secondary: #ccd6f6;
    --text-tertiary: #a8b2d1;
    --gray-color: #6c757d;
    --success-color: #4bb543;
    --error-color: #ff3333;
    --warning-color: #ffcc00;
    --footer-bg: #0a192f;
    --footer-text: #e6f1ff;
    --footer-link: #64ffda;
    --card-bg: rgba(16, 42, 87, 0.7);
    --card-border: rgba(67, 97, 238, 0.2);
    --tool-card-bg: rgba(16, 42, 87, 0.7);
    --accent-hover: #3a7bd5;
}


/* Base styles for above-the-fold content */

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    color: var(--text-color);
    background-color: #0a192f;
    background-image: linear-gradient(135deg, #0a192f 0%, #172a45 100%);
    margin: 0;
    padding: 0;
    overflow-x: hidden;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.header {
    text-align: center;
    padding: 40px 0 30px;
    min-height: 180px;
}

.header h1 {
    font-size: 2.5rem;
    margin-bottom: 10px;
    color: var(--primary-color);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.header .subtitle {
    font-size: 1.1rem;
    color: var(--text-secondary);
    max-width: 700px;
    margin: 0 auto;
}


/* Updated Tool Cards */

.tools-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 25px;
    margin-top: 20px;
}

.tool-card {
    background-color: var(--tool-card-bg);
    border-radius: 12px;
    padding: 25px;
    transition: all 0.3s ease;
    border: 1px solid var(--card-border);
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}

.tool-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
    border-color: var(--accent-color);
}

.tool-icon-container {
    width: 50px;
    height: 50px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 15px;
    font-size: 1.5rem;
    color: white;
}


/* Specific icon colors matching avif-to-pdf.php */

.icon-pdf {
    background-color: #e74c3c;
}

.icon-image {
    background-color: #3498db;
}

.icon-video {
    background-color: #9b59b6;
}

.icon-office {
    background-color: #f39c12;
}

.icon-converter {
    background-color: #1abc9c;
}

.icon-other {
    background-color: #2ecc71;
}

.icon-audio {
    background-color: #e84393;
}

.icon-compress {
    background-color: #16a085;
}

.icon-merge {
    background-color: #2980b9;
}

.tool-card h2 {
    color: var(--primary-color);
    margin-bottom: 12px;
    font-size: 1.2rem;
    font-weight: 600;
}

.tool-card p {
    color: var(--text-color);
    font-size: 0.95rem;
    margin-bottom: 20px;
    line-height: 1.5;
}

.tool-link {
    display: inline-flex;
    align-items: center;
    background-color: var(--accent-color);
    color: white;
    padding: 10px 18px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s;
    margin-top: auto;
}

.tool-link:hover {
    background-color: var(--accent-hover);
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.tool-link i {
    margin-left: 8px;
    font-size: 0.9rem;
    transition: transform 0.3s;
}

.tool-link:hover i {
    transform: translateX(3px);
}


/* Categories */

.categories {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin: 30px 0;
    justify-content: center;
}

.category {
    padding: 10px 20px;
    border-radius: 30px;
    background-color: rgba(67, 97, 238, 0.1);
    color: var(--primary-color);
    cursor: pointer;
    transition: all 0.3s;
    border: 1px solid rgba(67, 97, 238, 0.3);
}

.category:hover {
    background-color: rgba(67, 97, 238, 0.2);
}

.category.active {
    background-color: var(--primary-color);
    color: white;
}


/* Show All Tools Button */

.show-all-btn {
    display: block;
    margin: 30px auto;
    padding: 12px 25px;
    background-color: var(--primary-color);
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.3s;
}

.show-all-btn:hover {
    background-color: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}


/* Blog Section */

.blog-section {
    margin-top: 40px;
    padding: 30px;
    background-color: var(--card-bg);
    border-radius: 10px;
    border: 1px solid var(--card-border);
}

.blog-section h2 {
    color: var(--primary-color);
    margin-bottom: 20px;
    text-align: center;
}

.blog-articles {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
}

.blog-article {
    background-color: rgba(16, 42, 87, 0.5);
    border-radius: 8px;
    padding: 20px;
    transition: all 0.3s;
    border: 1px solid var(--card-border);
}

.blog-article:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}

.blog-article h3 {
    color: var(--primary-color);
    margin-bottom: 10px;
}

.blog-article p {
    color: var(--text-secondary);
    margin-bottom: 15px;
}

.blog-article a {
    color: var(--footer-link);
    text-decoration: none;
    font-weight: 500;
    display: inline-flex;
    align-items: center;
}

.blog-article a:hover {
    text-decoration: underline;
}

.blog-article a i {
    margin-left: 5px;
    transition: transform 0.3s;
}

.blog-article a:hover i {
    transform: translateX(3px);
}


/* FAQ Section */

.faq {
    margin: 40px 0;
}

.faq h2 {
    color: var(--primary-color);
    text-align: center;
    margin-bottom: 30px;
}

.faq-item {
    margin-bottom: 15px;
    border-radius: 8px;
    overflow: hidden;
    border: 1px solid var(--card-border);
}

.faq-question {
    width: 100%;
    padding: 18px 20px;
    text-align: left;
    background-color: rgba(16, 42, 87, 0.5);
    border: none;
    color: var(--text-color);
    font-size: 1rem;
    font-weight: 500;
    display: flex;
    justify-content: space-between;
    align-items: center;
    cursor: pointer;
    transition: background-color 0.3s;
}

.faq-question:hover {
    background-color: rgba(16, 42, 87, 0.7);
}

.faq-question i {
    transition: transform 0.3s;
}

.faq-question[aria-expanded="true"] i {
    transform: rotate(180deg);
}

.faq-answer {
    padding: 0 20px;
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease, padding 0.3s ease;
    background-color: rgba(16, 42, 87, 0.3);
}

.faq-question[aria-expanded="true"]+.faq-answer {
    padding: 20px;
    max-height: 500px;
}

.faq-answer p {
    margin: 0;
    line-height: 1.6;
    color: var(--text-secondary);
}