/* AtendePro Help Center - Styles */

:root {
    --background: 0 0% 100%;
    --foreground: 222.2 84% 4.9%;
    --card: 0 0% 100%;
    --card-foreground: 222.2 84% 4.9%;
    --primary: 212 82% 51%;  /* Azul AtendePro #4A7FC1 */
    --primary-foreground: 0 0% 100%;
    --secondary: 220 14.3% 95.9%;
    --secondary-foreground: 220.9 39.3% 11%;
    --muted: 220 14.3% 95.9%;
    --muted-foreground: 220 8.9% 46.1%;
    --accent: 212 82% 51%;
    --accent-foreground: 0 0% 100%;
    --border: 220 13% 91%;
    --ring: 212 82% 51%;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', system-ui, -apple-system, sans-serif;
    background-color: hsl(var(--background));
    color: hsl(var(--foreground));
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

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

/* Header */
.header {
    background: white;
    border-bottom: 1px solid hsl(var(--border));
    padding: 20px 0;
    position: sticky;
    top: 0;
    z-index: 100;
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    display: flex;
    align-items: center;
    gap: 12px;
}

.logo img {
    height: 45px;
    width: auto;
}

.nav {
    display: flex;
    gap: 10px;
}

.nav-link {
    padding: 8px 16px;
    color: hsl(var(--muted-foreground));
    text-decoration: none;
    border-radius: 8px;
    transition: all 0.3s;
    font-weight: 500;
}

.nav-link:hover,
.nav-link.active {
    background-color: hsl(var(--muted));
    color: hsl(var(--foreground));
}

/* Hero Section */
.hero {
    background: linear-gradient(135deg, #5B84B1 0%, #4A7FC1 50%, #4A6FA5 100%);
    color: white;
    padding: 80px 20px;
    text-align: center;
}

.hero-content {
    max-width: 800px;
    margin: 0 auto;
}

.hero .icon-wrapper {
    width: 80px;
    height: 80px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 20px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 24px;
}

.hero h1 {
    font-size: 48px;
    font-weight: 700;
    margin-bottom: 16px;
}

.hero p {
    font-size: 20px;
    opacity: 0.95;
    margin-bottom: 40px;
}

/* Search */
.search-container {
    position: relative;
    max-width: 600px;
    margin: 0 auto;
}

.search-icon {
    position: absolute;
    left: 24px;
    top: 50%;
    transform: translateY(-50%);
    color: hsl(var(--muted-foreground));
    pointer-events: none;
}

.search-input {
    width: 100%;
    padding: 16px 24px 16px 64px;
    font-size: 16px;
    border-radius: 16px;
    border: 0;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1);
    background: white;
    color: hsl(var(--foreground));
    outline: none;
    transition: all 0.3s;
}

.search-input:focus {
    box-shadow: 0 10px 40px rgba(91, 132, 177, 0.2);
    transform: translateY(-2px);
}

.search-results {
    position: absolute;
    top: calc(100% + 10px);
    left: 0;
    right: 0;
    background: white;
    border-radius: 16px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.15);
    max-height: 400px;
    overflow-y: auto;
    z-index: 50;
}

.search-result-item {
    padding: 16px 20px;
    border-bottom: 1px solid hsl(var(--border));
    cursor: pointer;
    transition: background 0.2s;
}

.search-result-item:hover {
    background: hsl(var(--muted));
}

.search-result-item:last-child {
    border-bottom: none;
}

.search-result-title {
    font-weight: 600;
    color: hsl(var(--foreground));
    margin-bottom: 4px;
}

.search-result-category {
    font-size: 14px;
    color: hsl(var(--muted-foreground));
}

/* Update Card */
.update-section {
    padding: 40px 20px;
}

.update-card {
    background: linear-gradient(135deg, #5B84B1 0%, #4A7FC1 100%);
    color: white;
    padding: 30px;
    border-radius: 16px;
    box-shadow: 0 4px 20px rgba(74, 127, 193, 0.2);
}

.update-badge {
    display: inline-block;
    background: rgba(255, 255, 255, 0.2);
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 12px;
}

.update-card h3 {
    font-size: 24px;
    margin-bottom: 8px;
}

.update-card p {
    font-size: 16px;
    opacity: 0.95;
}

/* Topics Section */
.topics-section {
    padding: 60px 20px;
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 32px;
}

.section-header h2 {
    font-size: 32px;
    font-weight: 700;
}

.view-all {
    display: flex;
    align-items: center;
    gap: 8px;
    color: hsl(var(--muted-foreground));
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s;
}

.view-all:hover {
    color: hsl(var(--foreground));
}

.topics-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
}

/* Category Card */
.category-card {
    background: white;
    border: 1px solid hsl(var(--border));
    border-radius: 16px;
    padding: 24px;
    cursor: pointer;
    transition: all 0.3s;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
}

.category-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 40px -12px rgba(91, 132, 177, 0.25);
}

.category-card-header {
    display: flex;
    align-items: flex-start;
    gap: 16px;
    margin-bottom: 12px;
}

.category-icon {
    width: 56px;
    height: 56px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.icon-blue { background: linear-gradient(135deg, hsl(210 90% 92%) 0%, hsl(210 80% 95%) 100%); }
.icon-pink { background: linear-gradient(135deg, hsl(340 80% 92%) 0%, hsl(340 70% 95%) 100%); }
.icon-yellow { background: linear-gradient(135deg, hsl(45 95% 88%) 0%, hsl(45 90% 92%) 100%); }
.icon-purple { background: linear-gradient(135deg, hsl(270 70% 92%) 0%, hsl(270 60% 95%) 100%); }
.icon-green { background: linear-gradient(135deg, hsl(150 70% 90%) 0%, hsl(150 60% 94%) 100%); }
.icon-orange { background: linear-gradient(135deg, hsl(25 95% 90%) 0%, hsl(25 90% 94%) 100%); }
.icon-teal { background: linear-gradient(135deg, hsl(174 60% 90%) 0%, hsl(174 50% 94%) 100%); }

.category-card h3 {
    font-size: 18px;
    font-weight: 600;
    color: hsl(var(--foreground));
    margin-bottom: 8px;
}

.category-card p {
    font-size: 14px;
    color: hsl(var(--muted-foreground));
    line-height: 1.5;
}

/* Article Content */
.doc-content {
    background: white;
    padding: 40px;
    border-radius: 16px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
    max-width: 800px;
    margin: 0 auto;
}

.doc-content h1 {
    font-size: 36px;
    font-weight: 700;
    margin-bottom: 16px;
    margin-top: 32px;
}

.doc-content h1:first-child {
    margin-top: 0;
}

.doc-content h2 {
    font-size: 28px;
    font-weight: 600;
    margin-top: 32px;
    margin-bottom: 16px;
    padding-bottom: 8px;
    border-bottom: 2px solid hsl(var(--border));
}

.doc-content h3 {
    font-size: 22px;
    font-weight: 600;
    margin-top: 24px;
    margin-bottom: 12px;
}

.doc-content p {
    margin-bottom: 16px;
    color: hsl(var(--muted-foreground));
    line-height: 1.8;
}

.doc-content ul,
.doc-content ol {
    margin-bottom: 16px;
    padding-left: 24px;
    color: hsl(var(--muted-foreground));
}

.doc-content li {
    margin-bottom: 8px;
    line-height: 1.6;
}

.doc-content code {
    background: hsl(var(--muted));
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 14px;
    font-family: 'Monaco', 'Courier New', monospace;
}

.doc-content pre {
    background: hsl(var(--muted));
    padding: 16px;
    border-radius: 8px;
    overflow-x: auto;
    margin-bottom: 16px;
}

.doc-content img {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    margin: 20px 0;
}

.doc-content blockquote {
    border-left: 4px solid hsl(var(--primary));
    padding-left: 16px;
    margin: 20px 0;
    font-style: italic;
    color: hsl(var(--muted-foreground));
}

.doc-content strong {
    font-weight: 600;
    color: hsl(var(--foreground));
}

/* Breadcrumb */
.breadcrumb {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 24px;
    font-size: 14px;
}

.breadcrumb a {
    color: hsl(var(--muted-foreground));
    text-decoration: none;
    transition: color 0.3s;
}

.breadcrumb a:hover {
    color: hsl(var(--primary));
}

.breadcrumb span {
    color: hsl(var(--muted-foreground));
}

/* Back Button */
.back-button {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: none;
    border: none;
    color: hsl(var(--muted-foreground));
    font-size: 14px;
    cursor: pointer;
    padding: 8px 0;
    margin-bottom: 24px;
    transition: color 0.3s;
}

.back-button:hover {
    color: hsl(var(--primary));
}

/* Glossary */
.glossary-list {
    display: grid;
    gap: 16px;
}

.glossary-term {
    background: white;
    border: 1px solid hsl(var(--border));
    border-radius: 12px;
    padding: 20px;
}

.glossary-term h3 {
    font-size: 20px;
    font-weight: 600;
    margin-bottom: 8px;
}

.glossary-term p {
    color: hsl(var(--muted-foreground));
    line-height: 1.6;
}

/* Updates */
.updates-list {
    display: grid;
    gap: 20px;
}

.update-item {
    background: white;
    border: 1px solid hsl(var(--border));
    border-radius: 12px;
    padding: 24px;
}

.update-item-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
}

.update-item h3 {
    font-size: 20px;
    font-weight: 600;
}

.update-version {
    background: hsl(var(--primary));
    color: white;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 14px;
    font-weight: 600;
}

.update-date {
    color: hsl(var(--muted-foreground));
    font-size: 14px;
    margin-bottom: 8px;
}

/* Footer */
.footer {
    background: hsl(var(--secondary));
    padding: 40px 20px;
    margin-top: 80px;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.footer-links {
    display: flex;
    gap: 24px;
}

.footer-links a {
    color: hsl(var(--muted-foreground));
    text-decoration: none;
    transition: color 0.3s;
}

.footer-links a:hover {
    color: hsl(var(--primary));
}

/* Back to Top */
.back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    background: hsl(var(--primary));
    color: white;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    transition: all 0.3s;
    z-index: 100;
}

.back-to-top:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 20px rgba(91, 191, 187, 0.3);
}

/* Utilities */
.page-title {
    font-size: 40px;
    font-weight: 700;
    margin-bottom: 12px;
}

.page-description {
    font-size: 18px;
    color: hsl(var(--muted-foreground));
    margin-bottom: 40px;
}

.modules-section,
.articles-section,
.glossary-section,
.updates-section,
.article-content-section {
    padding: 40px 20px;
}

.category-header {
    background: linear-gradient(135deg, #5B84B1 0%, #4A7FC1 100%);
    color: white;
    padding: 40px 20px;
}

.category-info {
    text-align: center;
    padding: 20px 0;
}

.category-info h1 {
    font-size: 36px;
    margin-bottom: 12px;
}

.category-info p {
    font-size: 18px;
    opacity: 0.95;
}

.articles-list {
    max-width: 800px;
    margin: 0 auto;
}

.article-item {
    background: white;
    border: 1px solid hsl(var(--border));
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 12px;
    cursor: pointer;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    gap: 16px;
}

.article-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
}

.article-icon {
    width: 40px;
    height: 40px;
    background: hsl(var(--muted));
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.article-info h3 {
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 4px;
}

.article-info p {
    font-size: 14px;
    color: hsl(var(--muted-foreground));
}

/* Responsive */
@media (max-width: 768px) {
    .header-content {
        flex-direction: column;
        gap: 16px;
    }
    
    .hero h1 {
        font-size: 32px;
    }
    
    .topics-grid,
    .modules-grid {
        grid-template-columns: 1fr;
    }
    
    .footer-content {
        flex-direction: column;
        gap: 20px;
        text-align: center;
    }
    
    .doc-content {
        padding: 20px;
    }
}

.modules-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
}

/* Loading Animation */
@keyframes fade-in {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in {
    animation: fade-in 0.4s ease-out;
}

/* Spin Animation for Loading */
@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}
