:root {
    --primary: #6366f1;
    --primary-hover: #4f46e5;
    --bg-main: #f8fafc;
    --bg-card: #ffffff;
    --text-main: #1e293b;
    --text-muted: #64748b;
    --border-color: #e2e8f0;
    --radius: 12px;
    --shadow: 0 4px 6px -1px rgb(0 0 0 / .1), 0 2px 4px -2px rgb(0 0 0 / .1);
    --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / .1), 0 4px 6px -4px rgb(0 0 0 / .1);
    --danger: #ef4444;
    --success: #10b981
}

#otk-admin-app {
    font-family: Inter, system-ui, -apple-system, sans-serif;
    color: var(--text-main);
    background-color: var(--bg-main);
    min-height: 100vh;
    padding: 2rem;
    box-sizing: border-box;
    display: flex;
    flex-direction: column
}

.otk-container {
    max-width: 1400px;
    margin: 0 auto;
    width: 100%;
    flex: 1
}

.otk-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem
}

.otk-title {
    font-size: 1.875rem;
    font-weight: 700;
    color: #0f172a
}

.otk-card {
    background: var(--bg-card);
    border-radius: var(--radius);
    border: 1px solid var(--border-color);
    box-shadow: var(--shadow);
    overflow: hidden;
    transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
    position: relative
}

.otk-card h2 {
    color: #fff;
}

.otk-card.selected {
    border-color: var(--primary);
    background: #f5f7ff
}

.otk-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: .5rem;
    background-color: var(--primary);
    color: #fff;
    padding: .625rem 1.25rem;
    border-radius: 8px;
    font-weight: 600;
    border: none;
    cursor: pointer;
    transition: background-color .2s;
    font-size: .875rem
}

.otk-btn-secondary {
    background-color: #f1f5f9;
    color: #475569
}

.otk-btn-danger {
    background-color: #fef2f2;
    color: var(--danger);
    border: 1px solid #fee2e2
}

.otk-sidebar {
    width: 240px;
    flex-shrink: 0;
    background: white;
    border-radius: var(--radius);
    border: 1px solid var(--border-color);
    padding: 1.25rem;
    height: fit-content;
    position: sticky;
    top: 1rem
}

.otk-sidebar-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem
}

.otk-sidebar-title {
    font-weight: 700;
    font-size: .8rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: .05em
}

.otk-add-folder-btn {
    background: none;
    border: none;
    cursor: pointer;
    color: var(--primary);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 4px;
    border-radius: 4px;
    transition: all .2s
}

.otk-add-folder-btn:hover {
    background: #eef2ff
}

.otk-sidebar-item {
    display: flex;
    align-items: center;
    gap: .75rem;
    padding: .625rem .875rem;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 500;
    color: var(--text-muted);
    transition: all .2s;
    font-size: .9rem
}

.otk-sidebar-item:hover {
    background: #f1f5f9;
    color: var(--text-main)
}

.otk-sidebar-item.active {
    background: #eef2ff;
    color: var(--primary)
}

.otk-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1.25rem
}

.otk-category-header {
    background: #f8fafc;
    padding: .75rem 1.25rem;
    border-radius: 8px;
    margin-bottom: 1.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-left: 4px solid var(--primary)
}

.otk-modal-overlay {
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    background: rgba(15, 23, 42, .75);
    -webkit-backdrop-filter: blur(4px);
    backdrop-filter: blur(4px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 5000
}

.otk-input {
    width: 100%;
    padding: .75rem 1rem;
    border-radius: 8px;
    border: 1px solid var(--border-color);
    font-family: inherit;
    box-sizing: border-box
}

.otk-empty-folder {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 4rem 2rem;
    background: white;
    border: 2px dashed var(--border-color);
    border-radius: var(--radius);
    color: var(--text-muted);
    text-align: center
}

.otk-feature-row {
    display: flex;
    gap: 1.5rem;
    align-items: flex-start;
    padding: 1.5rem;
    border-bottom: 1px solid var(--border-color)
}

.otk-feature-row:last-child {
    border-bottom: none
}

.otk-feature-icon {
    flex-shrink: 0;
    width: 48px;
    height: 48px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #eef2ff;
    color: var(--primary)
}

.otk-selection-bar {
    position: fixed;
    bottom: 2rem;
    left: 50%;
    transform: translate(-50%);
    background: #1e293b;
    color: #fff;
    padding: .75rem 1.5rem;
    border-radius: 9999px;
    display: flex;
    align-items: center;
    gap: 1.5rem;
    box-shadow: 0 20px 25px -5px #0000001a;
    z-index: 100
}

.otk-badge {
    padding: .25rem .625rem;
    border-radius: 9999px;
    font-size: .75rem;
    font-weight: 500
}

.badge-success {
    background: #dcfce7;
    color: #166534
}

.otk-footer {
    margin-top: 4rem;
    padding: 2rem 0;
    border-top: 1px solid var(--border-color);
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 3rem;
    opacity: .8;
    transition: opacity .3s
}

.otk-footer:hover {
    opacity: 1
}

.otk-footer-brand {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: .5rem;
    text-decoration: none;
    color: var(--text-muted);
    font-size: .8rem;
    font-weight: 500
}

.otk-footer-logo {
    height: 32px;
    width: auto;
    filter: grayscale(1);
    transition: filter .3s
}

.otk-footer-brand:hover .otk-footer-logo {
    filter: grayscale(0)
}

.animate-fade-in {
    animation: fadeIn .4s ease-out forwards
}

@keyframes fadeIn {
    0% {
        opacity: 0;
        transform: translateY(10px)
    }

    to {
        opacity: 1;
        transform: translateY(0)
    }
}

.animate-spin {
    animation: spin 1s linear infinite
}

@keyframes spin {
    0% {
        transform: rotate(0)
    }

    to {
        transform: rotate(360deg)
    }
}