:root {
    --primary: #f68220;
    --primary-light: #f89a4d;
    --text: #e2e8f0;
    --text-secondary: #94a3b8;
    --bg: #0f172a;
    --bg-secondary: #1e293b;
    --bg-tertiary: #334155;
    --success: #10b981;
    --warning: #f59e0b;
    --danger: #ef4444;
    --border: #334155;
}

[data-theme="light"] {
    --primary: #f68220;
    --primary-light: #f89a4d;
    --text: #1e293b;
    --text-secondary: #64748b;
    --bg: #f8fafc;
    --bg-secondary: #e2e8f0;
    --bg-tertiary: #f1f5f9;
    --border: #cbd5e1;
}

* {
    margin: 0;
    /*padding: 0;*/
    box-sizing: border-box;
}

body {
    font-family: 'Quicksand', 'Roboto', sans-serif;
    font-size: 1rem;
    background-color: var(--bg);
    color: var(--text);
    height: 100vh;
    display: flex;
    flex-direction: column;
    transition: all 0.3s ease;
}

.container {
    display: flex;
    flex: 1;
    overflow: hidden;
}

/* Scrollbar styling */
::-webkit-scrollbar {
    width: 5px; 
}

::-webkit-scrollbar-track {
    background: var(--bg-secondary); 
}

::-webkit-scrollbar-thumb {
    background: var(--primary-light); 
    border-radius: 6px; 
}

    ::-webkit-scrollbar-thumb:hover {
        background: var(--primary); 
    }

/* Sidebar */
.sidebar {
    width: 300px;
    background-color: var(--bg-secondary);
    border-right: 1px solid var(--border);
    padding: 1rem;
    display: flex;
    flex-direction: column;
    transition: all 0.3s ease;
    overflow-y: auto;
}

.sidebar-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--border);
}

.logo {
    font-weight: 700;
    font-size: 1rem;
    color: var(--primary-light);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

    .logo i {
        font-size: 1.5rem;
    }

.history-list {
    flex: 1;
    overflow-y: auto;
}

.history-item {
    padding: 0.75rem;
    border-radius: 0.5rem;
    margin-bottom: 0.5rem;
    cursor: pointer;
    transition: all 0.2s ease;
    background-color: var(--bg-tertiary);
    position: relative;
}

    .history-item:hover {
        background-color: var(--primary-light);
        color: white;
    }

    .history-item.active {
        background-color: var(--primary);
        color: white;
    }

.history-user {
    font-weight: 600;
    font-size: 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

    .history-user i {
        font-size: 1rem;
        color: var(--text-secondary);
    }

.history-item.active .history-user i {
    color: rgba(255, 255, 255, 0.7);
}

.history-prompt {
    font-size: 1rem;
    display: -webkit-box;
    -webkit-line-clamp: 5;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: normal;
    margin-top: 0.25rem;
    color: var(--text-secondary);
    word-break: break-word;
}

.history-item.active .history-prompt {
    color: rgba(255, 255, 255, 0.8);
}

.history-time {
    font-size: 1rem;
    color: var(--text-secondary);
    /*position: absolute;*/
    top: 0.75rem;
    right: 0.75rem;
    margin-top: 0;
    text-align: right;
    z-index: 1;
}

.history-item.active .history-time {
    color: rgba(255, 255, 255, 0.6);
}

/* Main Content */
.main-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

/* Chat Area */
.chat-area {
    flex: 1;
    overflow-y: auto;
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.message {
    /*             max-width: 1100px;
            max-width: 800px;
            width: 100%; */
    /*             margin: 0 auto; */
}

.user-message {
    /* align-self: flex-end; */
    background-color: var(--primary);
    color: white;
    padding: 1rem;
    border-radius: 1rem 1rem 0 1rem;
}

.ai-message {
    /* align-self: flex-start; */
    background-color: var(--bg-secondary);
    padding: 1rem;
    border-radius: 1rem 1rem 1rem 0;
    border: 1px solid var(--border);
}

.message-header {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0.5rem;
}

    .message-header i {
        font-size: 1rem;
    }

.user-message .message-header i {
    color: rgba(255, 255, 255, 0.8);
}

.ai-message .message-header i {
    color: var(--primary-light);
}

.message-user {
    font-weight: 600;
    font-size: 1rem;
}

.message-time {
    font-size: 1rem;
    color: var(--text-secondary);
    margin-left: auto;
}

.user-message .message-time {
    color: rgba(255, 255, 255, 0.6);
}

.message-content {
    line-height: 1.6;
}

/* Prompt Analysis */
.prompt-analysis {
    background-color: var(--bg-secondary);
    border: 1px solid var(--border);
    border-radius: 1.25rem;
    padding: 1rem;
    /*             margin: 0 auto;
            max-width: 800px;
            width: 100%; */
}

.analysis-header {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 1rem;
    color: var(--primary-light);
}

.analysis-title {
    font-weight: 600;
}

.analysis-section {
    margin-bottom: 1rem;
}

.analysis-actions {
    display: flex;
    gap: 0.5rem;
    margin-top: 0.5rem;
    margin-left: 0.5rem;
}

.analysis-action-btn {
    background: var(--bg-tertiary);
    color: var(--text-secondary);
    border: none;
    border-radius: 0.5rem;
    padding: 0.5rem 0.8rem;
    font-size: 1rem;
    cursor: pointer;
    transition: background 0.2s, color 0.2s;
    display: flex;
    align-items: center;
    gap: 0.3rem;
}

    .analysis-action-btn:hover {
        background: var(--primary-light);
        color: #fff;
    }

.section-title {
    font-size: 1rem;
    font-weight: 500;
    margin-bottom: 0.5rem;
    color: var(--text-secondary);
}

.decomposed-prompt {
    background-color: var(--bg-tertiary);
    padding: 0.75rem;
    border-radius: 0.5rem;
    margin-bottom: 0.5rem;
}

.prompt-part {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 0.25rem;
}

    .prompt-part:last-child {
        margin-bottom: 0;
    }

.part-label {
    font-weight: 500;
    font-size: 1rem;
    color: var(--primary-light);
    min-width: 80px;
}

.part-content {
    font-size: 1rem;
    flex: 1;
}

.security-alert {
    /*display: flex;*/
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem;
    border-radius: 0.5rem;
    font-size: 1rem;
    margin-top: 0.5rem;
}

    .security-alert.warning {
        background-color: rgba(245, 158, 11, 0.1);
        color: var(--warning);
        border: 1px solid rgba(245, 158, 11, 0.3);
    }

    .security-alert.danger {
        background-color: rgba(239, 68, 68, 0.1);
        color: var(--danger);
        border: 1px solid rgba(239, 68, 68, 0.3);
    }

/* Input Area */
.input-area {
    padding: 1rem;
/*    border-top: 1px solid var(--border);
    background-color: var(--bg-secondary);*/
}

.input-container {
    max-width: 1100px;
    width: 100%;
    margin: 0 auto;
    position: relative;
}

.prompt-input {
    width: 100%;
    min-height: 90px;
    max-height: 350px;
    padding: 1rem 4rem 1rem 1rem;
    border-radius: 1rem;
    border: 1px solid var(--border);
    background-color: var(--bg-tertiary);
    color: var(--text);
    font-family: 'Roboto', sans-serif;
    font-size: 1.1rem;
    resize: none;
    outline: none;
    transition: all 0.2s ease;
}

    .prompt-input:focus {
        border-color: var(--primary-light);
        box-shadow: 0 0 0 2px rgba(246, 130, 32, 0.2);
    }

.send-button {
    position: absolute;
    right: 1rem;
    bottom: 2rem;
    background-color: var(--primary);
    color: white;
    border: none;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s ease;
}

    .send-button:hover {
        background-color: var(--primary-light);
        transform: scale(1.05);
    }

    .send-button:active {
        transform: scale(0.95);
    }

/* Settings */
.settings-panel {
    position: fixed;
    top: 0;
    right: -350px;
    width: 350px;
    height: 100%;
    background-color: var(--bg-secondary);
    border-left: 1px solid var(--border);
    padding: 1.5rem;
    transition: all 0.3s ease;
    z-index: 100;
    overflow-y: auto;
}

    .settings-panel.open {
        right: 0;
    }

.settings-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--border);
}

.settings-title {
    font-weight: 600;
    font-size: 1rem;
}

.close-settings {
    background: none;
    border: none;
    color: var(--text-secondary);
    font-size: 1.5rem;
    cursor: pointer;
    transition: all 0.2s ease;
}

    .close-settings:hover {
        color: var(--text);
    }

.setting-group {
    margin-bottom: 1.5rem;
}

.setting-title {
    font-weight: 600;
    margin-bottom: 0.75rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

    .setting-title i {
        color: var(--primary-light);
    }

.theme-toggle {
    display: flex;
    background-color: var(--bg-tertiary);
    border-radius: 0.5rem;
    padding: 0.25rem;
}

.theme-option {
    flex: 1;
    padding: 0.5rem;
    text-align: center;
    border-radius: 0.25rem;
    cursor: pointer;
    transition: all 0.2s ease;
}

    .theme-option.active {
        background-color: var(--primary);
        color: white;
    }

.toggle-switch {
    position: relative;
    display: inline-block;
    width: 50px;
    height: 24px;
}

    .toggle-switch input {
        opacity: 0;
        width: 0;
        height: 0;
    }

.slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: var(--bg-tertiary);
    transition: .4s;
    border-radius: 24px;
}

    .slider:before {
        position: absolute;
        content: "";
        height: 16px;
        width: 16px;
        left: 4px;
        bottom: 4px;
        background-color: white;
        transition: .4s;
        border-radius: 50%;
    }

input:checked + .slider {
    background-color: var(--primary);
}

    input:checked + .slider:before {
        transform: translateX(26px);
    }

.toggle-label {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1rem;
}

.toggle-text {
    flex: 1;
    font-size: 0.875rem;
}

.custom-select {
    width: 100%;
    padding: 0.6rem;
    border: 2px solid var(--primary-light);
    border-radius: 0.5rem;
    background-color: var(--bg-secondary);
    color: var(--text);
    font-size: 1rem;
    font-weight: 500;
    transition: border-color 0.3s, box-shadow 0.3s;
    appearance: none;
    cursor: pointer;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
}

    .custom-select:focus {
        border-color: var(--primary);
        box-shadow: 0 0 0 3px rgba(246, 130, 32, 0.3);
        outline: none;
    }

    .custom-select option {
        background-color: var(--bg-tertiary);
        color: var(--text);
        font-size: 1rem;
        padding: 0.5rem;
        transition: background-color 0.2s, color 0.2s;
    }

        .custom-select option:hover {
            background-color: var(--primary-light);
            color: #fff;
        }

        .custom-select option:checked {
            background-color: var(--primary);
            color: #fff;
        }

/* Top Bar */
.top-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 1.5rem;
    border-bottom: 1px solid var(--border);
    background-color: var(--bg-secondary);
}

.chat-title {
    font-weight: 600;
}

.action-buttons {
    display: flex;
    gap: 0.5rem;
}

.action-button {
    background-color: var(--bg-tertiary);
    border: none;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    color: var(--text);
    transition: all 0.2s ease;
}

    .action-button:hover {
        background-color: var(--primary);
        color: white;
    }

.typing-indicator {
    display: flex;
    gap: 0.25rem;
    padding: 0.5rem 0;
}

.typing-dot {
    width: 8px;
    height: 8px;
    background-color: var(--text-secondary);
    border-radius: 50%;
    animation: pulse 1.5s infinite ease-in-out;
}

    .typing-dot:nth-child(2) {
        animation-delay: 0.2s;
    }

    .typing-dot:nth-child(3) {
        animation-delay: 0.4s;
    }

@media (max-width: 900px) {
    .container     .main-content {
        flex: 1 1 auto;
        min-height: 0;
        display: flex;
        flex-direction: column;
    }

    .sidebar {
        position: fixed;
        left: -100vw;
        top: 0;
        height: 100vh;
        z-index: 200;
        width: 80vw;
        max-width: 320px;
        min-width: 0;
        border-right: none;
        border-bottom: 1px solid var(--border);
        flex-direction: column;
        padding: 1rem 0.5rem 1rem 0.5rem;
        transition: left 0.3s;
        box-shadow: 2px 0 16px rgba(0,0,0,0.12);
        background-color: var(--bg-secondary);
        overflow-y: auto;
    }

        .sidebar.open {
            left: 0;
        }

    .sidebar-backdrop {
        display: block;
        position: fixed;
        z-index: 199;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        background: rgba(0,0,0,0.25);
    }

    .main-content {
        padding: 0;
        min-width: 0;
    }

    .chat-area {
        padding: 0.5rem;
        gap: 1rem;
        overflow-y: auto;
        flex: 1 1 auto;
        min-height: 0;
        max-height: none;
    }

    .prompt-analysis,
    .message {
        padding: 0.75rem;
        font-size: 0.98rem;
    }

    .input-area {
        padding: 0.5rem;
    }

    .input-container {
        max-width: 100%;
        margin: 0;
    }

    .prompt-input {
        min-height: 60px;
        font-size: 1rem;
        padding-right: 3.2rem;
    }

    .send-button {
        right: 0.5rem;
        width: 32px;
        height: 32px;
    }

    .settings-panel {
        width: 100vw;
        right: -100vw;
        padding: 1rem;
        max-width: 100vw;
    }

        .settings-panel.open {
            right: 0;
        }

    .top-bar {
        flex-direction: row;
        gap: 0.5rem;
        padding: 0.5rem 0.5rem;
    }

    .logo {
        font-size: 0.95rem;
    }

    .action-buttons {
        gap: 0.3rem;
    }

    #menu-button {
        display: inline-flex !important;
    }

    body.sidebar-open {
        overflow: hidden;
    }
}

@media (min-width: 901px) {
    #menu-button {
        display: inline-flex !important;
    }

    .sidebar-backdrop {
        display: none !important;
    }

    .sidebar {
        position: static;
        left: 0;
        width: 280px;
        height: auto;
        box-shadow: none;
        transition: left 0.3s;
    }
        .sidebar.closed {
            left: -280px;
            position: fixed;
            top: 0;
            height: 100vh;
            z-index: 200;
            box-shadow: 2px 0 16px rgba(0,0,0,0.12);
            width: 0;
            padding: 0;
            overflow: hidden;
        }
}

.message-content {
    line-height: 1.6;
    /*padding: 1rem;*/
    word-break: break-word;
    overflow-wrap: break-word;
    max-width: 100%;
}

.analysis-action-btn.active {
    background: #f68220;
    color: #fff;
    box-shadow: inset 0 2px 6px rgba(0,0,0,0.10);
}

.gemini-response {
    background-color: var(--bg-tertiary);
    padding: 0.75rem;
    border-radius: 0.5rem;
    margin-bottom: 0.5rem;
    overflow-x: auto;
    width: 100%;
}

    .gemini-response pre {
        background: #181c23;
        color: #e2e8f0;
        font-family: 'Fira Mono', 'Consolas', 'Menlo', monospace;
        font-size: 1em;
        padding: 1em 1.2em;
        border-radius: 8px;
        border: 1px solid #23272e;
        margin: 0.5em 0;
        overflow-x: auto;
        box-shadow: 0 2px 8px rgba(0,0,0,0.08);
        line-height: 1.7;
        display: block;
        width: 100%;
        max-width: 100%;
        white-space: pre;
        word-break: break-word;
    }

    .gemini-response code {
        background: #23272e;
        color: #f68220;
        font-family: 'Fira Mono', 'Consolas', 'Menlo', monospace;
        font-size: 1em;
        padding: 3px 8px;
        border-radius: 6px;
        border: 1px solid #3b4252;
        word-break: break-all;
        box-shadow: 0 1px 4px rgba(0,0,0,0.07);
        display: inline;
    }
    .gemini-response table {
        white-space: pre;
        word-break: break-word;
        overflow-x: auto;
        max-width: 100%;
        width: 100%;
        display: table;
        border-collapse: collapse;
        margin: 1em 0;
        font-size: 1em;
        background: none;
        box-shadow: none;
        color: var(--text);
        table-layout: auto;
    }

    .gemini-response th,
    .gemini-response td {
        padding: 0.75em 1em;
        text-align: left;
        border-bottom: 1px solid var(--border);
        background: none;
        color: var(--text);
    }

    .gemini-response th {
        font-weight: 600;
        color: var(--primary);
        border-bottom: 2px solid var(--border);
    }

    .gemini-response tr:last-child td {
        border-bottom: none;
    }

    .gemini-response tbody tr:hover {
        background: var(--bg-secondary);
        color: var(--text);
        transition: background 0.2s, color 0.2s;
    }

.main-loading-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    width: 100%;
    height: 100%;
    background: transparent;
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

.main-content.loading .chat-area,
.main-content.loading .input-area {
    display: none !important;
}

.rotating-m {
    font-size: 8rem;
    font-weight: bold;
    color: var(--primary);
    transform-style: preserve-3d;
    animation: rotate 3s infinite linear;
}

@keyframes rotate {
    0% {
        transform: rotateY(0deg);
    }

    100% {
        transform: rotateY(360deg);
    }
}

/* DataTable için özel tasarım */
#adminPromptTable.dataTable {
    background: var(--bg-secondary);
    color: var(--text);
    border-radius: 0.75rem;
    overflow: hidden;
    box-shadow: 0 2px 12px rgba(0,0,0,0.04);
    width: 100%;
}

    #adminPromptTable.dataTable th,
    #adminPromptTable.dataTable td {
        background: none;
        color: var(--text);
        border-bottom: 1px solid var(--border);
        padding: 0.75em 1em;
        font-size: 1em;
    }

    #adminPromptTable.dataTable th {
        background: var(--bg-tertiary);
        color: var(--primary);
        font-weight: 600;
        border-bottom: 2px solid var(--border);
    }

    #adminPromptTable.dataTable tbody tr:hover {
        background: var(--primary-light);
        color: #fff;
        transition: background 0.2s, color 0.2s;
    }

    #adminPromptTable.dataTable tr:last-child td {
        border-bottom: none;
    }

#adminPromptTable_wrapper .dataTables_filter input,
#adminPromptTable_wrapper .dataTables_length select {
    background: var(--bg-tertiary);
    color: var(--text);
    border: 1px solid var(--border);
    border-radius: 0.5rem;
    padding: 0.3em 0.7em;
    margin-left: 0.5em;
}

#adminPromptTable_wrapper .dataTables_paginate .paginate_button {
    background: var(--bg-tertiary);
    color: var(--text-secondary) !important;
    border: none;
    border-radius: 0.5rem;
    margin: 0 0.1em;
    padding: 0.4em 0.8em;
    transition: background 0.2s, color 0.2s;
}

    #adminPromptTable_wrapper .dataTables_paginate .paginate_button.current,
    #adminPromptTable_wrapper .dataTables_paginate .paginate_button:hover {
        background: var(--primary);
        color: #fff !important;
    }

#adminPromptTable_wrapper .dataTables_info {
    color: var(--text-secondary);
    margin-top: 0.5em;
}

#adminPromptTable_wrapper .dataTables_length label,
#adminPromptTable_wrapper .dataTables_filter label {
    color: var(--text-secondary);
    font-size: 1em;
}

.security-alert.success {
    background: #e6f9ed;
    color: #15803d;
    border: 1px solid #10b981;
    padding: 8px 12px;
    border-radius: 6px;
    display: flex;
    align-items: center;
    gap: 8px;
    margin-top: 8px;
    font-weight: 500;
}

    .security-alert.success i {
        color: #10b981;
    }

.custom-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.6rem 1.2rem;
    border-radius: 0.5rem;
    font-size: 1rem;
    font-weight: 500;
    border: none;
    cursor: pointer;
    transition: background 0.2s, color 0.2s;
}

.custom-btn-primary {
    background: var(--primary);
    color: #fff;
}

    .custom-btn-primary:hover {
        background: var(--primary-light);
        color: #fff;
    }

.custom-btn-secondary {
    background: var(--bg-tertiary);
    color: var(--primary);
    border: 1px solid var(--primary);
}

    .custom-btn-secondary:hover {
        background: var(--primary-light);
        color: #fff;
    }

.entity-container {
    border-radius: 10px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
    padding: 12px 8px 8px 8px;
    margin: 12px 0;
    max-width: 100%;
    overflow-x: auto;
}

.entity-table {
    width: 100%;
    border-collapse: collapse;
    min-width: 320px;
    font-size: 0.97rem;
}

    .entity-table th,
    .entity-table td {
        padding: 6px 10px;
        text-align: left;
        border-bottom: 1px solid #ececec;
        white-space: nowrap;
    }

    .entity-table th {
        background: #f7f7fa;
        font-weight: 600;
        color: #333;
        border-bottom: 2px solid #ececec;
    }

    .entity-table tr:last-child td {
        border-bottom: none;
    }

.model-table th, .model-table td {
    white-space: normal !important;
    word-break: break-word;
    vertical-align: top;
}


@media (max-width: 600px) {
    .entity-container {
        padding: 8px 2px 4px 2px;
        overflow-x: auto;
    }

    .entity-table {
        min-width: 600px;
        width: 100%;
    }

    .entity-table th,
    .entity-table td {
        padding: 7px 6px;
        font-size: 0.93rem;
    }
}

a {
    text-decoration: none;
}


/* Admin Card Tasarımı */

.main-content-admin {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 20px;
    overflow-y: auto;
}

.card-container {
    display: flex;
    flex-direction: column; 
    align-items: center; 
    gap: 20px; 
    margin-top: 20px; 
    width: 100%;
}

.card {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto; 
    background: var(--bg-secondary);
    border-radius: 12px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    padding: 24px;
    color: var(--text);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}
    .card h2 {
        text-align: center;
        margin-bottom: 16px;
        color: var(--primary-light);
        font-size: 1.5rem;
        font-weight: 600;
    }

.card-content {
    font-size: 1rem;
    line-height: 1.6;
    color: var(--text-secondary);
}

.details-table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 24px;
}

    .details-table th, .details-table td {
        padding: 10px 8px;
        border-bottom: 1px solid #f0f0f0;
        text-align: left;
    }

    .details-table th {
        width: 220px;
        color: #6c757d;
        font-weight: 600;
        background: #f8fafc;
    }

.entity-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 8px;
}

    .entity-table th, .entity-table td {
        padding: 8px 6px;
        border-bottom: 1px solid #e9ecef;
    }

    .entity-table th {
        background: #f1f3f6;
        color: #495057;
    }

.back-btn {
    display: inline-block;
    margin-bottom: 18px;
    color: #495057;
    text-decoration: none;
    font-weight: 500;
}

    .back-btn i {
        margin-right: 6px;
    }

@media (max-width: 600px) {
    .card {
        padding: 12px 4px;
    }

    .details-table th, .details-table td {
        font-size: 0.98em;
    }
}

/*Login*/
.login-body {
    min-height: 100vh;
    margin: 0;
    background: var(--bg);
    color: var(--text);
    font-family: 'Quicksand', 'Roboto', sans-serif;
    display: flex;
    flex-direction: column;
    min-width: 100vw;
}

.login-main {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 100%;
}

.login-title {
    text-align: center;
    color: var(--primary);
    font-size: 1.8rem;
    margin-bottom: 1rem;
    font-weight: 700;
}

.login-container {
    background: var(--bg-secondary);
    padding: 2rem 1.5rem;
    border-radius: 10px;
    box-shadow: 0 2px 12px rgba(0,0,0,0.07);
    width: 100%;
    max-width: 340px;
    display: flex;
    flex-direction: column;
    align-items: center;
}

    .login-container h2 {
        margin-bottom: 1.2rem;
        color: var(--primary-light);
        font-size: 1.4rem;
        font-weight: 600;
    }

.login-form {
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
}

    .login-form label {
        align-self: flex-start;
        margin-bottom: 0.2rem;
        color: var(--text-secondary);
        font-size: 1rem;
    }

    .login-form input[type="text"],
    .login-form input[type="password"] {
        width: 100%;
        padding: 0.5rem;
        margin-bottom: 1rem;
        border: 1px solid #ccc;
        border-radius: 5px;
        font-size: 1rem;
        background: var(--bg-tertiary);
        color: var(--text);
    }

    .login-form button {
        width: 100%;
        padding: 0.6rem;
        background: #f68220;
        color: #fff;
        border: none;
        border-radius: 5px;
        font-size: 1.05rem;
        font-weight: 500;
        cursor: pointer;
        transition: background 0.2s;
    }

        .login-form button:hover {
            background: var(--primary-light);
        }

    .login-form .error-message {
        color: var(--danger);
        text-align: center;
        margin-top: 0.5rem;
        min-height: 1.2em;
    }

.terms-row {
    margin-bottom: 1rem;
    align-self: flex-start;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.terms-link {
    color: var(--primary-light);
    text-decoration: underline;
    cursor: pointer;
    margin-left: 4px;
}

.modal {
    display: none;
    position: fixed;
    z-index: 9999;
    left: 0;
    top: 0;
    width: 100vw;
    height: 100vh;
    overflow: auto;
    background-color: rgba(0,0,0,0.4);
}

.modal-content {
    background-color: var(--bg-secondary);
    color: var(--text);
    margin: 10% auto;
    padding: 2rem;
    border-radius: 8px;
    width: 90%;
    max-width: 900px;
    box-shadow: 0 2px 12px rgba(0,0,0,0.15);
    position: relative;
}

.close {
    color: var(--text-secondary);
    position: absolute;
    right: 1rem;
    top: 1rem;
    font-size: 1.5rem;
    font-weight: bold;
    cursor: pointer;
    transition: color 0.2s;
}

    .close:hover {
        color: var(--primary-light);
    }

.project-info {
    margin-top: 2rem;
    text-align: center;
    color: var(--text-secondary);
    font-size: 0.95rem;
}

.login-footer {
    width: 100vw;
    text-align: center;
    padding: 0.5rem 0;
    color: var(--text);
    font-size: 1rem;
    z-index: 10000;
    position: fixed;
    left: 0;
    bottom: 0;
}

/* Sidebar Navigation Links */
.nav-links {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    list-style-type: none;
    padding: 0; /* Remove default padding */
    margin: 0; /* Remove default margin */
}

    .nav-links a {
        display: flex;
        align-items: center;
        gap: 0.5rem;
        padding: 0.75rem 1rem;
        border-radius: 0.5rem;
        background-color: var(--bg-tertiary);
        color: var(--text-secondary);
        text-decoration: none;
        font-size: 1rem;
        font-weight: 500;
        transition: background-color 0.3s, color 0.3s;
    }

        .nav-links a:hover {
            background-color: var(--primary-light);
            color: #fff;
        }