/* Data Dictionary Container Width Constraints */
.data-dict-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Responsive width adjustments */
@media (max-width: 1280px) {
    .data-dict-container {
        max-width: 95%;
    }
}

@media (max-width: 768px) {
    .data-dict-container {
        max-width: 100%;
        padding: 0 16px;
    }
}

@media (max-width: 480px) {
    .data-dict-container {
        padding: 0 12px;
    }
}

/* Data Dictionary Table Styling */
.data-table {
    width: 100%;
    border-collapse: collapse;
    background: white;
    font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
    margin: 0 !important;
    border-radius: 0 !important;
    table-layout: fixed;
}

/* Standardized column widths across all data dictionary tables */
.data-table .col-name,
.data-table .col-name-cell {
    width: 18%;
}

.data-table .col-desc,
.data-table .col-desc-cell {
    width: 34%;
}

.data-table .col-type,
.data-table .col-type-cell {
    width: 14%;
}

.data-table .col-format,
.data-table .col-format-cell {
    width: 34%;
}

/* Table description styling in header */
.table-description {
    color: black;
    font-size: 13px;
    margin-top: 8px;
    margin-bottom: 4px;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

/* Secondary badge styling - yellow color */
.table-badge.secondary {
    background: #fff7cc !important;
    color: #000000 !important;
    border: 1px solid #daa520 !important;
}

/* All table badges should have black text */
.table-badge {
    color: #000000 !important;
}

/* Add underline to section titles */
.data-dict-container .section-card-title {
    border-bottom: none !important;
    padding-bottom: 8px !important;
    padding-right: 28px !important;
    width: 100% !important;
    position: relative !important;
    display: flex;
    align-items: center;
}

.data-dict-container .section-card-title .table-badge {
    margin-left: auto;
    display: inline-flex !important;
    align-items: center;
    align-self: center;
    line-height: 1;
    margin-top: 0;
    margin-bottom: 0;
}

/* Primary badge styling - keep green fill, add dark green border */
.data-dict-container .section-card-title .table-badge:not(.secondary) {
    border: 1px solid #166534 !important;
}

/* Remove card padding and make it behave like section-card */
.data-dict-container .card {
    padding: 0 !important;
}

/* Adjust header layout for description */
.data-dict-container .section-card-header {
    flex-direction: column;
    align-items: flex-start;
    position: relative;
    padding: 20px 24px 16px 24px;
    border-bottom: none !important;
}

.data-dict-container .section-card-header::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: #e9ecef;
}

/* Override collapsible tab styling */
.data-dict-container .collapsible-tab .section-card-header {
    padding: 20px 24px 16px 24px !important;
    flex-direction: column !important;
    align-items: flex-start !important;
    width: 100% !important;
    box-sizing: border-box !important;
}

/* Override any table height constraints */
.data-dict-container .table-container,
.data-dict-container .table-wrapper,
.data-dict-container .data-table {
    max-height: none !important;
    height: auto !important;
}

/* Fix spacing between header border and message-box */
.data-dict-container .section-card-header .message-box {
    margin-top: 0px !important;
    width: 100%;
    box-sizing: border-box;
}

.data-dict-container .section-card-header i {
    position: absolute;
    top: 16px;
    right: 20px;
}

/* Remove ALL padding/margins around table containers */
.data-dict-container .table-container {
    padding: 0 !important;
    margin: 0 !important;
}

.data-dict-container .table-wrapper {
    margin: 0 !important;
    border-radius: 0 !important;
    padding: 0 !important;
    border: none !important;
    box-shadow: none !important;
}

.data-dict-container .section-card-content {
    padding: 0 !important;
    margin: 0 !important;
}

/* Ensure card body has no padding for tables */
.data-dict-container .card .section-card-body {
    padding: 0 !important;
}

/* Override any inherited margins/padding */
.data-dict-container .collapsible-tab .section-card-content {
    padding: 0 !important;
    margin: 0 !important;
}

.data-dict-container .collapsible-tab .section-card-content > * {
    margin: 0 !important;
}

/* Ensure table takes full width with no gaps */
.data-dict-container .data-table {
    width: 100% !important;
    margin: 0 !important;
    border-collapse: collapse !important;
    border-spacing: 0 !important;
}

.data-table th {
    background: #f8f9fa;
    color: #495057;
    font-weight: 600;
    padding: 12px 16px;
    text-align: left;
    border-bottom: 2px solid #dee2e6;
    font-size: 14px;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

.data-table td {
    padding: 12px 16px;
    border-bottom: 1px solid #e9ecef;
    vertical-align: top;
    font-size: 13px;
    line-height: 1.4;
}

.data-table tbody tr:hover {
    background-color: #f8f9fa;
}

/* Column name cells - code style without left border */
.col-name-cell {
    font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace !important;
    font-weight: 600;
    color: #0969da;
    background: #f6f8fa;
    font-size: 14px;
}

/* Description cells */
.col-desc-cell {
    color: black;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

/* Data type text style (plain, no pill/bubble) */
.type-badge {
    display: inline;
    padding: 0;
    border: none;
    border-radius: 0;
    background: transparent;
    color: inherit;
    font-size: 13px;
    font-weight: 400;
    text-transform: none;
    letter-spacing: normal;
    font-family: inherit;
}

/* Keep type variants neutral to match vintage data dictionary */
.type-badge.string {
    background: transparent;
    color: inherit;
    border: none;
}

.type-badge.integer {
    background: transparent;
    color: inherit;
    border: none;
}

.type-badge.datetime {
    background: transparent;
    color: inherit;
    border: none;
}

.type-badge.binary {
    background: transparent;
    color: inherit;
    border: none;
}

/* Format cell styling */
.col-format-cell {
    font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
}

.col-format-cell code {
    background: #f6f8fa;
    color: #d73a49;
    padding: 2px 6px;
    border-radius: 6px;
    font-size: 12px;
    border: 1px solid #e1e4e8;
    font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
    white-space: normal;
    overflow-wrap: anywhere;
    word-break: break-word;
}

/* Options list styling - capsule style */
.options-list {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin: 4px 0;
}

.options-list .option {
    display: inline-block;
    background: #f1f3f4;
    color: #3c4043;
    padding: 4px 10px;
    border-radius: 16px;
    font-size: 11px;
    font-weight: 500;
    border: 1px solid #dadce0;
    font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
    transition: all 0.2s ease;
}

.options-list .option:hover {
    background: #e8eaed;
    border-color: #5f6368;
    transform: translateY(-1px);
}