body.api-page {
    font-family: 'Inter', sans-serif;
    line-height: 1.6;
    color: var(--text-dark);
    margin: 0;
    background: linear-gradient(rgba(255, 255, 255, 0.75), rgba(255, 255, 255, 0.75)), url('../background3.png') repeat 0 0;
}

h1, h2, h3, h4, .badge {
    font-family: 'Outfit', sans-serif;
}

/* Navbar */
.navbar.api-nav {
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid #e2e8f0;
    position: sticky;
    top: 0;
    z-index: 1000;
    display: flex;
    align-items: center;
    height: var(--navbar-height, 80px);
}

.navbar.api-nav .nav-links a {
    color: var(--text-dark);
}

.navbar.api-nav .nav-links a:hover {
    color: var(--primary-color);
}

/* Hero */
.api-hero {
    padding: 6rem 0;
    text-align: center;
    background: linear-gradient(135deg, rgba(26, 42, 68, 0.9), rgba(0, 128, 128, 0.8)), url('../background2.png') center/cover;
    color: white;
}

.api-hero .badge {
    background: var(--accent-color);
    color: var(--secondary-color);
    padding: 0.5rem 1rem;
    border-radius: 2rem;
    font-weight: 700;
    font-size: 0.85rem;
    text-transform: uppercase;
    display: inline-block;
    margin-bottom: 1rem;
}

.api-hero h1 {
    font-size: 3.5rem;
    margin: 1rem 0;
}

.api-hero h1 span {
    color: var(--accent-color);
}

.api-hero p {
    font-size: 1.2rem;
    color: #cbd5e1;
    max-width: 600px;
    margin: 0 auto 2.5rem;
}

.api-hero .hero-actions {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
}

.api-hero .btn-primary {
    background: var(--primary-color);
    color: white;
}

.api-hero .btn-primary:hover {
    background: #006666;
    transform: translateY(-3px);
    box-shadow: 0 10px 20px rgba(0, 128, 128, 0.3);
}

.api-hero .btn-secondary {
    background: transparent;
    color: white;
    border: 2px solid white;
}

.api-hero .btn-secondary:hover {
    background: white;
    color: var(--secondary-color);
}

/* Sections */
.api-section {
    padding: 5rem 0;
}

.section-header {
    text-align: center;
    margin-bottom: 3rem;
}

.section-header h2 {
    font-size: 2.2rem;
    color: var(--secondary-color);
    margin-bottom: 0.5rem;
}

.section-header p {
    color: #64748b;
}

/* Doc Cards */
.docs-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.doc-card {
    background: white;
    padding: 2.5rem;
    border-radius: 1rem;
    box-shadow: var(--card-shadow);
    transition: transform 0.3s ease;
}

.doc-card:hover {
    transform: translateY(-5px);
}

.doc-card i {
    font-size: 2rem;
    color: var(--primary-color);
    margin-bottom: 1.5rem;
}

.doc-card h3 {
    margin-bottom: 0.75rem;
    color: var(--secondary-color);
}

.doc-card p {
    color: #64748b;
    font-size: 0.95rem;
}

.doc-card code {
    color: var(--primary-color);
    font-size: 0.85rem;
}

/* Key Management */
.key-features {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
}

.key-card {
    background: white;
    padding: 2rem;
    border-radius: 1rem;
    box-shadow: var(--card-shadow);
}

.key-card i {
    font-size: 1.5rem;
    color: var(--primary-color);
    margin-bottom: 1rem;
}

.key-card h3 {
    margin-bottom: 0.5rem;
    color: var(--secondary-color);
}

.key-card p {
    color: #64748b;
    font-size: 0.9rem;
}

.key-card code {
    color: var(--primary-color);
    font-size: 0.85rem;
}

.note-card {
    background: linear-gradient(135deg, rgba(0, 212, 255, 0.08), rgba(0, 128, 128, 0.08));
    border: 1px solid rgba(0, 128, 128, 0.15);
    padding: 1.25rem 1.5rem;
    border-radius: 0.75rem;
    margin-top: 2rem;
    display: flex;
    align-items: center;
    gap: 1rem;
    color: #64748b;
}

.note-card i {
    color: var(--primary-color);
    font-size: 1.25rem;
}

.note-card a {
    color: var(--primary-color);
    text-decoration: underline;
}

/* Code Window */
.code-window {
    background: #0f172a;
    border-radius: 12px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.3);
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.window-header {
    background: #1e293b;
    padding: 0.75rem 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.window-header .title {
    margin-left: auto;
    font-size: 0.75rem;
    color: #94a3b8;
    font-family: 'Fira Code', monospace;
}

.dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
}

.dot.red { background: #ff5f56; }
.dot.yellow { background: #ffbd2e; }
.dot.green { background: #27c93f; }

.code-window pre {
    padding: 1.5rem;
    margin: 0;
    font-family: 'Fira Code', monospace;
    font-size: 0.9rem;
    color: #addb67;
    overflow-x: auto;
}

/* Endpoints */
.endpoint-item {
    background: white;
    border-radius: 0.75rem;
    margin-bottom: 1rem;
    overflow: hidden;
    box-shadow: var(--card-shadow);
}

.endpoint-header {
    padding: 1.25rem;
    display: flex;
    align-items: center;
    gap: 1.5rem;
    cursor: pointer;
    user-select: none;
}

.toggle-icon {
    margin-left: auto;
    transition: transform 0.3s ease;
    color: #94a3b8;
}

.method {
    padding: 0.25rem 0.75rem;
    border-radius: 0.25rem;
    font-weight: 700;
    font-size: 0.8rem;
}

.method.post { background: #dcfce7; color: #166534; }

.path {
    font-family: 'Fira Code', monospace;
    font-weight: 600;
}

.desc {
    color: #64748b;
}

.endpoint-details {
    padding: 0 1.25rem 1.5rem;
}

.endpoint-details h4 {
    color: var(--primary-color);
    margin: 1.5rem 0 0.5rem;
    font-size: 1rem;
}

.endpoint-details p {
    color: #64748b;
    margin-bottom: 0.5rem;
}

.endpoint-details code {
    color: var(--primary-color);
}

/* Tables */
.table-wrap {
    overflow-x: auto;
    margin: 1rem 0;
}

.api-page table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.85rem;
}

.api-page th, .api-page td {
    text-align: left;
    padding: 0.75rem 1rem;
    border-bottom: 1px solid #e2e8f0;
}

.api-page th {
    background: #f8fafc;
    color: var(--secondary-color);
    font-weight: 600;
}

.api-page td {
    color: #64748b;
}

.api-page td:first-child {
    color: var(--text-dark);
    font-family: 'Fira Code', monospace;
    white-space: nowrap;
}

/* Response Section */
.response-section {
    background: white;
    border-radius: 0.75rem;
    padding: 2rem;
    margin-top: 2rem;
    box-shadow: var(--card-shadow);
}

.response-section h3 {
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
    color: var(--secondary-color);
}

.response-section > p {
    color: #64748b;
}

/* Footer */
.api-footer {
    background: var(--secondary-color);
    color: white;
    padding: 3rem 0;
    text-align: center;
}

/* Buttons (overrides) */
.api-page .btn {
    padding: 0.75rem 1.5rem;
    border-radius: 50px;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.api-page .btn-primary {
    background: var(--primary-color);
    color: white;
}

.api-page .btn-primary:hover {
    background: #006666;
    transform: translateY(-3px);
    box-shadow: 0 10px 20px rgba(0, 128, 128, 0.3);
}

.api-page .btn-secondary {
    background: transparent;
    color: white;
    border: 2px solid white;
}

.api-page .btn-secondary:hover {
    background: white;
    color: var(--secondary-color);
}

/* Mobile */
@media (max-width: 768px) {
    .api-hero h1 {
        font-size: 2.5rem;
    }
    .api-hero .hero-actions {
        flex-direction: column;
        align-items: center;
    }
}
