/* ABDC Integrated Dashboard Styles - V4 */
:root {
    --abdc-blue: #011150;
    --abdc-blue-light: #0a1e6e;
    --abdc-yellow: #fcd111;
    --abdc-yellow-hover: #fbbf24;
    --abdc-bg-light: #f4f7fa;
    --abdc-white: #ffffff;
    --abdc-text: #2d3748;
    --abdc-text-muted: #718096;
    --abdc-border: #e2e8f0;
    --abdc-success: #48bb78;
    --abdc-danger: #f56565;
}

.abdc-panel-container {
    display: flex;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0,0,0,0.08);
    border: 1px solid var(--abdc-border);
    min-height: 85vh;
    background: var(--abdc-white);
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
}

/* Sidebar */
.abdc-panel-sidebar {
    width: 280px;
    background: var(--abdc-blue);
    padding: 2.5rem 1.5rem;
    display: flex;
    flex-direction: column;
    color: var(--abdc-white);
}

.abdc-sidebar-logo {
    text-align: center;
    margin-bottom: 2.5rem;
}

.abdc-sidebar-logo img {
    max-width: 160px;
}

.abdc-user-info {
    display: flex;
    align-items: center;
    padding: 15px;
    background: rgba(255,255,255,0.07);
    border-radius: 12px;
    margin-bottom: 2rem;
}

.abdc-user-avatar {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    margin-right: 15px;
    border: 2px solid var(--abdc-yellow);
    object-fit: cover;
}

.abdc-user-meta strong {
    font-size: 15px;
    display: block;
    margin-bottom: 2px;
}

.abdc-user-meta small {
    font-size: 12px;
    opacity: 0.7;
}

.abdc-sidebar-divider {
    border: 0;
    border-top: 1px solid rgba(255,255,255,0.1);
    margin: 0 0 2rem 0;
}

.abdc-tab-link {
    width: 100%;
    background: transparent;
    border: none;
    color: var(--abdc-white);
    padding: 14px 18px;
    text-align: left;
    font-size: 15px;
    font-weight: 600;
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.3s;
    margin-bottom: 8px;
    display: flex;
    align-items: center;
}

.abdc-tab-link:hover {
    background: rgba(255,255,255,0.1);
}

.abdc-tab-link.active {
    background: var(--abdc-yellow);
    color: var(--abdc-blue);
}

.abdc-logout-button {
    margin-top: auto;
    background: rgba(255,255,255,0.1);
    color: var(--abdc-white);
    text-align: center;
    padding: 12px;
    border-radius: 10px;
    text-decoration: none;
    font-weight: bold;
    transition: all 0.3s;
}

.abdc-logout-button:hover {
    background: var(--abdc-danger);
    color: white;
}

/* Content Area */
.abdc-panel-content {
    flex-grow: 1;
    padding: 3rem;
    background: var(--abdc-bg-light);
    overflow-y: auto;
}

.abdc-panel-tab {
    display: none;
}

.abdc-panel-tab.active {
    display: block;
    animation: fadeIn 0.5s ease;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(15px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Vouchers Tab Specific */
.abdc-vouchers-header {
    margin-bottom: 35px;
}

.abdc-vouchers-header h2 {
    font-size: 28px;
    color: var(--abdc-blue);
    margin-bottom: 8px;
}

.abdc-stats-grid {
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    gap: 30px;
    margin-bottom: 40px;
}

.abdc-stat-card {
    background: var(--abdc-white);
    padding: 25px;
    border-radius: 16px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.03);
}

.abdc-card-header h3 {
    font-size: 18px;
    margin-bottom: 20px;
    color: var(--abdc-blue);
    font-weight: 700;
}

/* Chart Modern */
.abdc-chart-wrapper {
    display: flex;
    align-items: center;
    gap: 30px;
}

.abdc-chart-container-modern {
    position: relative;
    width: 180px;
    height: 180px;
}

.abdc-chart-center-modern {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
}

.abdc-chart-percent {
    display: block;
    font-size: 32px;
    font-weight: 800;
    color: var(--abdc-blue);
    line-height: 1;
}

.abdc-chart-label {
    font-size: 12px;
    color: var(--abdc-text-muted);
    text-transform: uppercase;
    letter-spacing: 1px;
}

.abdc-chart-legend {
    flex-grow: 1;
}

.legend-item {
    display: flex;
    align-items: center;
    margin-bottom: 12px;
}

.legend-item .dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    margin-right: 12px;
}

.dot.used { background: #e91e63; }
.dot.available { background: #3498db; }

.legend-total {
    margin-top: 20px;
    padding-top: 15px;
    border-top: 1px solid var(--abdc-border);
    font-size: 14px;
}

/* Generate Card */
.abdc-input-group-modern {
    display: flex;
    flex-direction: column;
    gap: 15px;
    margin: 20px 0;
}

.input-with-icon {
    position: relative;
    display: flex;
    align-items: center;
}

.input-with-icon .icon {
    position: absolute;
    left: 15px;
    color: var(--abdc-text-muted);
    font-weight: bold;
}

.input-with-icon input {
    width: 100%;
    padding: 14px 14px 14px 40px;
    border: 2px solid var(--abdc-border);
    border-radius: 12px;
    font-size: 15px;
    transition: border-color 0.3s;
}

.input-with-icon input:focus {
    border-color: var(--abdc-blue);
    outline: none;
}

.abdc-btn-primary-modern {
    background: var(--abdc-blue);
    color: white;
    border: none;
    padding: 14px;
    border-radius: 12px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s;
}

.abdc-btn-primary-modern:hover {
    background: var(--abdc-blue-light);
    transform: translateY(-2px);
}

.abdc-limit-info {
    margin-top: 20px;
}

.limit-bar-container {
    height: 6px;
    background: #edf2f7;
    border-radius: 3px;
    margin-bottom: 8px;
    overflow: hidden;
}

.limit-bar-fill {
    height: 100%;
    background: var(--abdc-yellow);
    border-radius: 3px;
}

/* Table Modern */
.abdc-table-section {
    background: var(--abdc-white);
    border-radius: 16px;
    padding: 25px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.03);
}

.abdc-table-modern {
    width: 100%;
    border-collapse: collapse;
}

.abdc-table-modern th {
    text-align: left;
    padding: 15px;
    border-bottom: 2px solid var(--abdc-border);
    color: var(--abdc-text-muted);
    font-size: 13px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.abdc-table-modern td {
    padding: 18px 15px;
    border-bottom: 1px solid var(--abdc-border);
    font-size: 15px;
}

.abdc-code-tag {
    background: #f7fafc;
    padding: 6px 12px;
    border-radius: 6px;
    font-family: monospace;
    font-weight: 700;
    color: var(--abdc-blue);
    border: 1px solid var(--abdc-border);
}

.abdc-domain-tag {
    color: var(--abdc-text-muted);
    font-weight: 500;
}

.abdc-status-pill {
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 700;
}

.pill-available { background: #e6fffa; color: #2c7a7b; }
.pill-used { background: #fff5f5; color: #c53030; }

/* Courses Tab Modern */
.abdc-courses-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 30px;
}

.abdc-course-card-modern {
    background: var(--abdc-white);
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 10px 25px rgba(0,0,0,0.05);
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
    border: 1px solid var(--abdc-border);
}

.abdc-course-card-modern:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(0,0,0,0.1);
}

.abdc-course-thumb {
    position: relative;
    height: 180px;
}

.abdc-course-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.abdc-course-badge {
    position: absolute;
    top: 15px;
    right: 15px;
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 800;
    text-transform: uppercase;
    color: #fff;
    box-shadow: 0 4px 10px rgba(0,0,0,0.2);
}

.abdc-course-badge.status-concluido { background: var(--abdc-success); }
.abdc-course-badge.status-em-andamento { background: #f6ad55; }
.abdc-course-badge.status-nao-iniciado { background: #a0aec0; }

.abdc-course-body {
    padding: 25px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.abdc-course-body h4 {
    margin: 0 0 20px 0;
    font-size: 19px;
    line-height: 1.4;
    color: var(--abdc-blue);
    font-weight: 700;
    min-height: 54px;
}

.abdc-progress-container {
    margin-bottom: 25px;
}

.abdc-progress-info {
    display: flex;
    justify-content: space-between;
    font-size: 13px;
    margin-bottom: 10px;
    font-weight: 600;
    color: var(--abdc-text-muted);
}

.abdc-progress-bar {
    height: 10px;
    background: #edf2f7;
    border-radius: 5px;
    overflow: hidden;
}

.abdc-progress-fill {
    height: 100%;
    background: var(--abdc-yellow);
    border-radius: 5px;
    transition: width 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

.abdc-btn-course {
    display: block;
    text-align: center;
    background: var(--abdc-blue);
    color: #fff;
    padding: 14px;
    border-radius: 12px;
    text-decoration: none;
    font-weight: 700;
    font-size: 15px;
    transition: all 0.3s;
    margin-top: auto;
}

.abdc-btn-course:hover {
    background: var(--abdc-blue-light);
    color: #fff;
    box-shadow: 0 5px 15px rgba(1, 17, 80, 0.3);
}

/* Responsive */
@media (max-width: 1024px) {
    .abdc-stats-grid { grid-template-columns: 1fr; }
}

@media (max-width: 768px) {
    .abdc-panel-container { flex-direction: column; }
    .abdc-panel-sidebar { width: 100%; padding: 1.5rem; }
    .abdc-tabs-nav { display: flex; overflow-x: auto; gap: 10px; padding-bottom: 10px; }
    .abdc-tab-link { white-space: nowrap; width: auto; padding: 10px 15px; }
    .abdc-panel-content { padding: 1.5rem; }
}
