/* Text Analysis Tools CSS - Exact Match Design */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --space-xs: 0.25rem;
    --space-sm: 0.5rem;
    --space-md: 1rem;
    --space-lg: 1.5rem;
    --space-xl: 2rem;
    --space-2xl: 2.5rem;
    --space-3xl: 3rem;
    --space-4xl: 4rem;
    --radius-sm: 0.375rem;
    --radius-md: 0.5rem;
    --radius-lg: 0.75rem;
    --radius-xl: 1rem;
    --radius-2xl: 1.5rem;
    --radius-full: 9999px;
    --text-primary-color: #ffffff;
    --background-color: #000000;
}

body {
    font-family: 'Inter', sans-serif;
    background: linear-gradient(rgba(0, 0, 0, 0.7), rgba(0, 0, 0, 0.7)), url('../images/desktop Bg image.webp');
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    min-height: 100vh;
    color: white;
    
    /* Typography Scale */
    --font-xs: 0.75rem;
    --font-sm: 0.875rem;
    --font-base: 1rem;
    --font-lg: 1.125rem;
    --font-xl: 1.25rem;
    --font-2xl: 1.5rem;
    --font-3xl: 1.875rem;
    --font-4xl: 2.25rem;
    --font-5xl: 3rem;
    
    /* Font Weights */
    --font-light: 300;
    --font-normal: 400;
    --font-medium: 500;
    --font-semibold: 600;
    --font-bold: 700;
    --font-extrabold: 800;
}

/* Mobile background */
@media (max-width: 768px) {
    body {
        background: linear-gradient(rgba(0, 0, 0, 0.7), rgba(0, 0, 0, 0.7)), url('../images/mobile Bg image.webp');
        background-size: cover;
        background-position: center;
        background-attachment: fixed;
    }
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.card {
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    transition: all 0.3s ease;
}

/* Header */
.page-header {
    text-align: center;
    padding: 80px 0 60px;
}

.page-header h1 {
    font-size: clamp(var(--font-4xl), 5vw, var(--font-5xl));
    font-weight: var(--font-extrabold);
    margin-bottom: 20px;
    background: linear-gradient(135deg, #ffffff, #4ade80);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.page-header p {
    font-size: 1.2rem;
    opacity: 0.9;
    max-width: 700px;
    margin: 0 auto 30px;
    line-height: 1.6;
}

.back-button {
    position: absolute;
    top: 30px;
    left: 30px;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: white;
    padding: 12px 20px;
    border-radius: 25px;
    text-decoration: none;
    font-weight: 500;
    backdrop-filter: blur(10px);
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 8px;
}

.back-button:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: translateY(-2px);
}

.breadcrumb {
    display: flex;
    align-items: center;
    gap: 8px;
    justify-content: center;
    margin-bottom: 20px;
    font-size: 0.9rem;
    opacity: 0.8;
}

.breadcrumb a {
    color: #4ade80;
    text-decoration: none;
}

.breadcrumb span {
    color: rgba(255, 255, 255, 0.6);
}

/* Tool Categories Navigation */
.tool-nav {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin: 40px 0;
    flex-wrap: wrap;
}

.nav-btn {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: white;
    padding: 12px 24px;
    border-radius: 25px;
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 8px;
}

.nav-btn:hover,
.nav-btn.active {
    background: linear-gradient(135deg, #4ade80, #22c55e);
    color: black;
    transform: translateY(-2px);
}

/* Tool Sections */
.tool-section {
    margin-bottom: 80px;
}

.section-header {
    text-align: center;
    margin-bottom: 50px;
}

.section-title {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 15px;
    background: linear-gradient(135deg, #ffffff, #4ade80);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.section-description {
    font-size: 1.1rem;
    opacity: 0.8;
    max-width: 600px;
    margin: 0 auto;
    line-height: 1.6;
}

.tools-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 25px;
}

.tool-card {
    background: linear-gradient(145deg, rgba(255, 255, 255, 0.1), rgba(255, 255, 255, 0.05));
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: var(--radius-xl);
    padding: 30px;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: pointer;
    position: relative;
    overflow: hidden;
    min-height: 200px;
    display: flex;
    flex-direction: column;
}

.tool-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, #4ade80, #22c55e, #16a34a);
    opacity: 0;
    transition: opacity 0.4s ease;
    border-radius: var(--radius-xl) var(--radius-xl) 0 0;
}

.tool-card:hover::before {
    opacity: 1;
}

.tool-card:hover {
    transform: translateY(-10px) scale(1.02);
    border-color: rgba(74, 222, 128, 0.5);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3), 0 10px 30px rgba(74, 222, 128, 0.3);
}

.tool-icon {
    font-size: 3rem;
    margin-bottom: 20px;
    display: block;
}

.tool-name {
    font-size: 1.4rem;
    font-weight: 700;
    color: white;
    margin-bottom: 12px;
    line-height: 1.3;
}

.tool-card:hover .tool-name {
    color: rgba(74, 222, 128, 1);
    text-shadow: 0 2px 8px rgba(74, 222, 128, 0.3);
}

.tool-description {
    opacity: 0.8;
    line-height: 1.6;
    margin-bottom: 20px;
    flex-grow: 1;
}

.tool-card:hover .tool-description {
    opacity: 0.95;
}

.tool-features {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 20px;
}

.feature-tag {
    background: rgba(74, 222, 128, 0.2);
    color: #4ade80;
    padding: 4px 10px;
    border-radius: var(--radius-full);
    font-size: 0.8rem;
    font-weight: 500;
    border: 1px solid rgba(74, 222, 128, 0.3);
}

.tool-stats {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 15px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.tool-rating {
    display: flex;
    align-items: center;
    gap: 5px;
    font-size: 0.9rem;
}

.tool-usage {
    font-size: 0.85rem;
    opacity: 0.7;
}

/* Responsive Design */
@media (max-width: 768px) {
    .page-header h1 {
        font-size: 2.5rem;
    }

    .page-header p {
        font-size: 1rem;
    }

    .tool-nav {
        gap: 10px;
        margin: 30px 0;
    }

    .nav-btn {
        padding: 10px 18px;
        font-size: 0.9rem;
    }

    .tools-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .tool-card {
        padding: 25px;
        min-height: auto;
    }

    .section-title {
        font-size: 2rem;
    }

    .back-button {
        top: 20px;
        left: 20px;
        padding: 10px 16px;
    }

    .container {
        padding: 0 15px;
    }
}

@media (max-width: 480px) {
    .page-header {
        padding: 60px 0 40px;
    }

    .page-header h1 {
        font-size: 2rem;
    }

    .tool-nav {
        flex-direction: column;
        align-items: center;
    }

    .nav-btn {
        width: auto;
        min-width: 150px;
        justify-content: center;
    }

    .tool-features {
        justify-content: center;
    }

    .tool-stats {
        flex-direction: column;
        gap: 8px;
        text-align: center;
    }

    .section-title {
        font-size: 1.8rem;
    }
}

.tool-icon {
    font-size: 3rem;
    margin-bottom: 20px;
    display: block;
}

.tool-name {
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: 15px;
    color: #f1f5f9;
}

.tool-description {
    font-size: 1rem;
    line-height: 1.6;
    margin-bottom: 25px;
    opacity: 0.8;
    color: #cbd5e1;
}

.tool-features {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 20px;
}

.feature-tag {
    background: rgba(74, 222, 128, 0.1);
    color: #4ade80;
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 500;
    border: 1px solid rgba(74, 222, 128, 0.2);
}

.tool-stats {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    font-size: 0.9rem;
}

.tool-rating {
    color: #fbbf24;
    font-weight: 500;
}

.tool-usage {
    color: #94a3b8;
}

/* Responsive Design */
@media (max-width: 768px) {
    .container {
        padding: 0 15px;
    }

    .page-header {
        padding: 80px 0 40px;
    }

    .page-header h1 {
        font-size: 2.5rem;
    }

    .page-header p {
        font-size: 1rem;
    }

    .tool-nav {
        gap: 10px;
    }

    .nav-btn {
        padding: 10px 20px;
        font-size: 0.9rem;
    }

    .tools-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .tool-card {
        padding: 30px 20px;
    }

    .section-title {
        font-size: 2rem;
    }

    .tool-section {
        padding: 60px 0;
    }

    .back-button {
        position: relative;
        top: 0;
        left: 0;
        margin: 20px;
        display: inline-flex;
    }
}

@media (max-width: 480px) {
    .page-header h1 {
        font-size: 2rem;
    }

    .tool-features {
        justify-content: center;
    }

    .tool-stats {
        flex-direction: column;
        gap: 8px;
        text-align: center;
    }
}

/* FAQ Section */
.faq {
    padding: var(--space-5xl) 0;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.02) 0%, rgba(255, 255, 255, 0.01) 100%);
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.faq-header {
    text-align: center;
    margin-bottom: var(--space-4xl);
}

.faq-header .section-title {
    font-size: 2.5rem;
    font-weight: 700;
    background: linear-gradient(135deg, var(--primary-color), var(--accent-color));
    background-clip: text;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    margin-bottom: var(--space-md);
}

.faq-header .section-subtitle {
    font-size: 1.1rem;
    color: var(--text-secondary-color);
    max-width: 600px;
    margin: 0 auto;
    line-height: 1.6;
}

.faq-container {
    max-width: 800px;
    margin: 0 auto;
}

.faq-item {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    margin-bottom: var(--space-lg);
    overflow: hidden;
    transition: all 0.3s ease;
}

.faq-item:hover {
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(255, 255, 255, 0.2);
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}

.faq-item.active {
    background: rgba(255, 255, 255, 0.08);
    border-color: var(--primary-color);
}

.faq-question {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: var(--space-xl);
    cursor: pointer;
    transition: all 0.3s ease;
}

.faq-question h3 {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-primary-color);
    margin: 0;
    line-height: 1.4;
    flex-grow: 1;
    margin-right: var(--space-md);
}

.faq-toggle {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    color: var(--primary-color);
    font-size: 1.5rem;
    font-weight: 300;
    transition: all 0.3s ease;
    flex-shrink: 0;
}

.faq-item.active .faq-toggle {
    background: var(--primary-color);
    color: white;
    transform: rotate(45deg);
}

.faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease, padding 0.3s ease;
}

.faq-item.active .faq-answer {
    max-height: 200px;
    padding: 0 var(--space-xl) var(--space-xl);
}

.faq-answer p {
    color: var(--text-secondary-color);
    line-height: 1.6;
    margin: 0;
    font-size: 0.95rem;
}

/* Mobile Responsive FAQ */
@media (max-width: 768px) {
    .faq-header .section-title {
        font-size: 2rem;
    }
    
    .faq-question {
        padding: var(--space-lg);
    }
    
    .faq-question h3 {
        font-size: 1rem;
    }
    
    .faq-item.active .faq-answer {
        padding: 0 var(--space-lg) var(--space-lg);
    }
}