/* API Documentation Frontend Styles */

.api-docs-frontend {
    max-width: 1200px;
    margin: 0 auto;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

.api-docs-header {
    text-align: center;
    margin-bottom: 40px;
    padding: 30px 0;
    border-bottom: 2px solid #f1f3f4;
}

.api-docs-header h2 {
    font-size: 2.5rem;
    color: #1a1a1a;
    margin: 0 0 10px 0;
    font-weight: 600;
}

.api-docs-description {
    font-size: 1.1rem;
    color: #666;
    margin: 0;
    font-weight: 400;
}

.api-docs-no-results {
    text-align: center;
    padding: 60px 20px;
    color: #666;
    font-size: 1.1rem;
    background: #f9f9f9;
    border-radius: 8px;
    border: 1px solid #e1e1e1;
}

/* API Endpoint Cards */
.api-endpoint {
    background: #ffffff;
    border: 1px solid #e9ecef;
    border-radius: 12px;
    margin-bottom: 30px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
}

.api-endpoint:hover {
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15);
    transform: translateY(-2px);
}

.api-endpoint-header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    padding: 20px 25px;
    display: flex;
    align-items: center;
    gap: 15px;
    flex-wrap: wrap;
}

.api-method {
    padding: 6px 16px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 700;
    color: white;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
}

.method-get {
    background: rgba(97, 175, 254, 0.9);
    border-color: rgba(97, 175, 254, 0.5);
}

.method-post {
    background: rgba(73, 204, 144, 0.9);
    border-color: rgba(73, 204, 144, 0.5);
}

.method-put {
    background: rgba(252, 161, 48, 0.9);
    border-color: rgba(252, 161, 48, 0.5);
}

.method-delete {
    background: rgba(249, 62, 62, 0.9);
    border-color: rgba(249, 62, 62, 0.5);
}

.method-patch {
    background: rgba(80, 227, 194, 0.9);
    border-color: rgba(80, 227, 194, 0.5);
}

.api-path {
    font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
    font-size: 16px;
    font-weight: 600;
    color: white;
    background: rgba(255, 255, 255, 0.1);
    padding: 8px 16px;
    border-radius: 6px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(10px);
    word-break: break-all;
}

.endpoint-badges {
    display: flex;
    gap: 8px;
    align-items: center;
    margin-left: auto;
}

.version-badge {
    background: rgba(255, 255, 255, 0.2);
    color: white;
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 11px;
    font-weight: 600;
    border: 1px solid rgba(255, 255, 255, 0.3);
}

.deprecated-badge, .auth-required-badge {
    background: rgba(249, 62, 62, 0.9);
    color: white;
    padding: 4px 12px;
    border-radius: 12px;
    font-size: 11px;
    font-weight: bold;
    border: 1px solid rgba(249, 62, 62, 0.5);
}

.auth-required-badge {
    background: rgba(255, 193, 7, 0.9);
    border-color: rgba(255, 193, 7, 0.5);
    color: #212529;
}

/* API Content */
.api-content {
    padding: 30px;
}

.api-name {
    font-size: 1.8rem;
    color: #1a1a1a;
    margin: 0 0 15px 0;
    font-weight: 600;
    line-height: 1.3;
}

.api-description {
    font-size: 1rem;
    color: #555;
    margin-bottom: 25px;
    line-height: 1.6;
    padding: 15px;
    background: #f8f9fa;
    border-left: 4px solid #007cba;
    border-radius: 0 6px 6px 0;
}

.api-section {
    margin-bottom: 25px;
}

.api-section h4 {
    font-size: 1.2rem;
    color: #2c3e50;
    margin: 0 0 12px 0;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 8px;
}

.api-section h4::before {
    content: "";
    width: 4px;
    height: 20px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 2px;
}

/* Code Blocks */
.code-block {
    background: #f8f9fa;
    border: 1px solid #e9ecef;
    border-radius: 8px;
    padding: 20px;
    font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', 'Fira Code', monospace;
    font-size: 14px;
    line-height: 1.5;
    overflow-x: auto;
    position: relative;
    box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.1);
}

.code-block::before {
    content: "JSON";
    position: absolute;
    top: 8px;
    right: 12px;
    background: #6c757d;
    color: white;
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 10px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.code-block code {
    background: none;
    padding: 0;
    font-size: inherit;
    color:#ffffff;
    white-space: pre;
    display: block;
}

.content-type-label {
    background: #e9ecef;
    color: #495057;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 12px;
    font-family: monospace;
    margin-bottom: 10px;
    display: inline-block;
}

.parameter-display {
    background: #f8f9fa;
    border: 1px solid #e9ecef;
    border-radius: 6px;
    padding: 15px;
    margin-bottom: 15px;
}

.response-codes-display {
    background: #f8f9fa;
    border: 1px solid #e9ecef;
    border-radius: 6px;
    padding: 15px;
}

.api-endpoint.deprecated {
    opacity: 0.8;
    border-left: 4px solid #dc3545;
}

.api-endpoint.deprecated .api-endpoint-header {
    background: linear-gradient(135deg, #6c757d 0%, #495057 100%);
}

/* Tags */
.api-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.api-tag {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 4px 12px;
    border-radius: 16px;
    font-size: 12px;
    font-weight: 500;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

/* Responsive Design */
@media (max-width: 768px) {
    .api-docs-frontend {
        margin: 0 10px;
    }

    .api-docs-header {
        padding: 20px 0;
        margin-bottom: 25px;
    }

    .api-docs-header h2 {
        font-size: 2rem;
    }

    .api-endpoint-header {
        padding: 15px 20px;
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }

    .endpoint-badges {
        margin-left: 0;
        align-self: flex-start;
    }

    .api-path {
        font-size: 14px;
        word-break: break-all;
        width: 100%;
    }

    .api-content {
        padding: 20px;
    }

    .api-name {
        font-size: 1.5rem;
    }

    .code-block {
        padding: 15px;
        font-size: 13px;
    }
}

@media (max-width: 480px) {
    .api-docs-header h2 {
        font-size: 1.75rem;
    }

    .api-endpoint {
        margin-bottom: 20px;
    }

    .api-content {
        padding: 15px;
    }

    .api-name {
        font-size: 1.3rem;
    }

    .api-section h4 {
        font-size: 1.1rem;
    }
}

/* Print Styles */
@media print {
    .api-docs-frontend {
        max-width: none;
    }

    .api-endpoint {
        break-inside: avoid;
        box-shadow: none;
        border: 1px solid #000;
        margin-bottom: 20px;
    }

    .api-endpoint-header {
        background: #f0f0f0 !important;
        color: #000 !important;
    }

    .api-method,
    .api-path {
        color: #000 !important;
        background: #fff !important;
        border-color: #000 !important;
    }

    .code-block {
        background: #f9f9f9 !important;
        border: 1px solid #000;
    }
}

/* Dark mode support */
@media (prefers-color-scheme: dark) {
    .api-docs-frontend {
        color: #e1e5e9;
    }

    .api-docs-header h2 {
        color: #ffffff;
    }

    .api-docs-description {
        color: #a0a0a0;
    }

    .api-endpoint {
        background: #2d3748;
        border-color: #4a5568;
    }

    .api-name {
        color: #ffffff;
    }

    .api-description {
        background: #374151;
        color: #d1d5db;
        border-left-color: #60a5fa;
    }

    .api-section h4 {
        color: #f7fafc;
    }

    .code-block {
        background: #1a202c;
        border-color: #4a5568;
        color: #e2e8f0;
    }

    .code-block::before {
        background: #4a5568;
    }
}