/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    line-height: 1.6;
    color: #ffffff;
    background-color: #000000;
    min-height: 100vh;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
    background-color: #000000;
    min-height: 100vh;
}

/* Header */
header {
    text-align: center;
    padding: 40px 0;
    border-bottom: 2px solid #333333;
    margin-bottom: 40px;
}

header .logo {
    max-width: 200px;
    margin-bottom: 20px;
}

header h1 {
    font-size: 2.5em;
    color: #ffffff;
    margin-bottom: 10px;
}

.subtitle {
    font-size: 1.2em;
    color: #cccccc;
}

/* Sections */
section {
    margin-bottom: 50px;
}

section h2 {
    font-size: 2em;
    color: #ffffff;
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 2px solid #333333;
}

section h3 {
    font-size: 1.5em;
    color: #ffffff;
    margin-top: 30px;
    margin-bottom: 15px;
}

section h4 {
    font-size: 1.2em;
    color: #ffffff;
    margin-top: 20px;
    margin-bottom: 10px;
}

section p {
    margin-bottom: 15px;
    color: #cccccc;
}

section ul {
    margin-left: 30px;
    margin-bottom: 20px;
}

section li {
    margin-bottom: 8px;
    color: #cccccc;
}

/* Code Blocks */
code {
    background-color: #1a1a1a;
    padding: 2px 6px;
    border-radius: 3px;
    font-family: 'Courier New', monospace;
    font-size: 0.9em;
    color: #ffffff;
    border: 1px solid #333333;
}

.code-block {
    background-color: #1a1a1a;
    color: #ffffff;
    padding: 20px;
    border-radius: 5px;
    margin: 15px 0;
    overflow-x: auto;
    border: 1px solid #333333;
}

.code-block code {
    background-color: transparent;
    color: #ffffff;
    padding: 0;
    font-size: 0.95em;
    white-space: pre-wrap;
    word-wrap: break-word;
    border: none;
}

/* Endpoints */
.endpoint {
    background-color: #1a1a1a;
    padding: 25px;
    border-radius: 8px;
    margin-bottom: 30px;
    border-left: 4px solid #ffffff;
    border: 1px solid #333333;
}

.method {
    display: inline-block;
    padding: 5px 15px;
    border-radius: 4px;
    font-weight: bold;
    font-size: 0.9em;
    margin-right: 10px;
    margin-bottom: 10px;
}

.method.get {
    background-color: #27ae60;
    color: white;
}

.method.post {
    background-color: #3498db;
    color: white;
}

.url {
    font-family: 'Courier New', monospace;
    font-size: 1.1em;
    color: #ffffff;
    margin: 10px 0;
}

.example {
    margin-top: 20px;
}

/* Models */
.model {
    background-color: #1a1a1a;
    padding: 20px;
    border-radius: 8px;
    margin-bottom: 20px;
    border-left: 4px solid #ffffff;
    border: 1px solid #333333;
}

/* Test Form */
.test-form {
    background-color: #1a1a1a;
    padding: 30px;
    border-radius: 8px;
    margin-top: 20px;
    border: 1px solid #333333;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: bold;
    color: #ffffff;
}

.form-group input,
.form-group select {
    width: 100%;
    padding: 10px;
    border: 1px solid #333333;
    border-radius: 4px;
    font-size: 1em;
    background-color: #000000;
    color: #ffffff;
}

.form-group input:focus,
.form-group select:focus {
    outline: none;
    border-color: #ffffff;
    box-shadow: 0 0 5px rgba(255, 255, 255, 0.3);
}

button[type="submit"] {
    background-color: #ffffff;
    color: #000000;
    padding: 12px 30px;
    border: none;
    border-radius: 4px;
    font-size: 1.1em;
    cursor: pointer;
    transition: background-color 0.3s;
    font-weight: bold;
}

button[type="submit"]:hover {
    background-color: #cccccc;
}

button[type="submit"]:active {
    transform: scale(0.98);
}

button[type="submit"]:disabled {
    opacity: 0.7;
    cursor: not-allowed;
}

/* Loading Spinner */
.spinner {
    border: 3px solid #333333;
    border-top: 3px solid #ffffff;
    border-radius: 50%;
    width: 20px;
    height: 20px;
    animation: spin 1s linear infinite;
    display: inline-block;
    margin-right: 10px;
    vertical-align: middle;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.loading-container {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 20px;
}

/* Full Width Button */
.full-width-button {
    width: 100%;
    background-color: #ffffff;
    color: #000000;
    padding: 20px;
    border: none;
    border-radius: 4px;
    font-size: 1.2em;
    font-weight: bold;
    cursor: pointer;
    transition: background-color 0.3s;
    margin: 30px 0;
    text-decoration: none;
    display: block;
    text-align: center;
}

.full-width-button:hover {
    background-color: #cccccc;
}

.full-width-button:active {
    transform: scale(0.98);
}

/* Loading Spinner */
.spinner {
    border: 3px solid #333333;
    border-top: 3px solid #ffffff;
    border-radius: 50%;
    width: 30px;
    height: 30px;
    animation: spin 1s linear infinite;
    display: inline-block;
    margin-right: 10px;
    vertical-align: middle;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Ensure spinner works in buttons too */
button span[style*="animation"] {
    animation: spin 1s linear infinite !important;
}

.loading-container {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

/* Result Display */
.result {
    margin-top: 20px;
    padding: 20px;
    border-radius: 4px;
    display: none;
    border: 1px solid #333333;
}

.result.success {
    background-color: #1a1a1a;
    border: 1px solid #27ae60;
    color: #27ae60;
    display: block;
}

.result.error {
    background-color: #1a1a1a;
    border: 1px solid #e74c3c;
    color: #e74c3c;
    display: block;
}

.result pre {
    margin-top: 10px;
    white-space: pre-wrap;
    word-wrap: break-word;
    color: #ffffff;
}

/* Example Tabs */
.example-tabs {
    margin-top: 15px;
}

.tab-buttons {
    display: flex;
    gap: 10px;
    margin-bottom: 10px;
    border-bottom: 1px solid #333333;
}

.tab-button {
    background-color: transparent;
    color: #ffffff;
    border: none;
    border-bottom: 2px solid transparent;
    padding: 10px 20px;
    cursor: pointer;
    font-size: 1em;
    font-weight: normal;
    transition: all 0.3s;
}

.tab-button:hover {
    color: #cccccc;
    background-color: #1a1a1a;
}

.tab-button.active {
    color: #ffffff;
    border-bottom-color: #ffffff;
    font-weight: bold;
}

.tab-content {
    display: none;
}

.tab-content.active {
    display: block;
}

/* Footer */
footer {
    text-align: center;
    padding: 30px 0;
    border-top: 2px solid #333333;
    margin-top: 50px;
    color: #cccccc;
}

/* Responsive */
@media (max-width: 768px) {
    .container {
        padding: 15px;
    }

    header h1 {
        font-size: 2em;
    }

    .code-block {
        font-size: 0.85em;
        padding: 15px;
    }
}
