html {
  font-size: 14px;
}

@media (min-width: 768px) {
  html {
    font-size: 16px;
  }
}

.btn:focus, .btn:active:focus, .btn-link.nav-link:focus, .form-control:focus, .form-check-input:focus {
  box-shadow: 0 0 0 0.1rem white, 0 0 0 0.25rem #258cfb;
}

html {
  position: relative;
  min-height: 100%;
}

body {
  margin-bottom: 60px;
}

.unselectable {
    -webkit-user-select: none;
    -webkit-touch-callout: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;
    color: #cc0000;
}


/* Styling the content to be printed */
#printable {
    width: 100%;
    padding: 20px;
    border: 1px solid #ddd;
    background-color: #f9f9f9;
    max-width: 1024px;
    margin: auto;
    page-break-before: auto;
    page-break-after: auto;
    page-break-inside: avoid;
}

/* Print specific styles */
@media print {
    body {
        width: 100%;
        height: auto;
    }

    #printable {
        width: 100%;
        height: auto;
        max-width: 100%;
        page-break-before: auto;
        page-break-after: auto;
        page-break-inside: avoid;
    }

    .no-print {
        display: none;
    }
}

.loader {
    display: none;
    position: fixed;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(255, 255, 255, 0.7); /* semi-transparent white */
    z-index: 9999; /* higher z-index to overlay everything */
}

/* Styles to hide main content initially */
.hidden {
    display: none;
}

.loading {
    position: fixed;
    z-index: 999;
    top: 0;
    left: 0;
    bottom: 0;
    right: 0;
    margin: auto;
    display: none;
    background: radial-gradient(rgba(20, 20, 20,.8), rgba(0, 0, 0, .8));
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-family: Arial, sans-serif;
}

/* Absolute Center Spinner */
/*.loading {
    position: fixed;
    z-index: 999;
    height: 2em;
    width: 2em;
    overflow: show;
    margin: auto;
    top: 0;
    left: 0;
    bottom: 0;
    right: 0;*/
    /*display:none;*/
/*}*/

/* Transparent Overlay */
/*.loading:before {
    content: '';
    display: block;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(rgba(20, 20, 20,.8), rgba(0, 0, 0,.8));
    background: -webkit-radial-gradient(rgba(20, 20, 20,.8), rgba(0, 0, 0,.8));
}*/

/* :not(:required) hides these rules from IE9 and below */
/*.loading:not(:required) {*/
    /* hide "loading..." text */
    /*font: 0/0 a;
    color: transparent;
    text-shadow: none;
    background-color: transparent;
    border: 0;
}

.loading:not(:required):after {
    content: '';
    display: block;
    font-size: 10px;
    width: 1em;
    height: 1em;
    margin-top: -0.5em;
    -webkit-animation: spinner 150ms infinite linear;
    -moz-animation: spinner 150ms infinite linear;
    -ms-animation: spinner 150ms infinite linear;
    -o-animation: spinner 150ms infinite linear;
    animation: spinner 150ms infinite linear;
    border-radius: 0.5em;
    -webkit-box-shadow: rgba(255,255,255, 0.75) 1.5em 0 0 0, rgba(255,255,255, 0.75) 1.1em 1.1em 0 0, rgba(255,255,255, 0.75) 0 1.5em 0 0, rgba(255,255,255, 0.75) -1.1em 1.1em 0 0, rgba(255,255,255, 0.75) -1.5em 0 0 0, rgba(255,255,255, 0.75) -1.1em -1.1em 0 0, rgba(255,255,255, 0.75) 0 -1.5em 0 0, rgba(255,255,255, 0.75) 1.1em -1.1em 0 0;
    box-shadow: rgba(255,255,255, 0.75) 1.5em 0 0 0, rgba(255,255,255, 0.75) 1.1em 1.1em 0 0, rgba(255,255,255, 0.75) 0 1.5em 0 0, rgba(255,255,255, 0.75) -1.1em 1.1em 0 0, rgba(255,255,255, 0.75) -1.5em 0 0 0, rgba(255,255,255, 0.75) -1.1em -1.1em 0 0, rgba(255,255,255, 0.75) 0 -1.5em 0 0, rgba(255,255,255, 0.75) 1.1em -1.1em 0 0;
}*/

/* Animation */

@-webkit-keyframes spinner {
    0% {
        -webkit-transform: rotate(0deg);
        -moz-transform: rotate(0deg);
        -ms-transform: rotate(0deg);
        -o-transform: rotate(0deg);
        transform: rotate(0deg);
    }

    100% {
        -webkit-transform: rotate(360deg);
        -moz-transform: rotate(360deg);
        -ms-transform: rotate(360deg);
        -o-transform: rotate(360deg);
        transform: rotate(360deg);
    }
}

@-moz-keyframes spinner {
    0% {
        -webkit-transform: rotate(0deg);
        -moz-transform: rotate(0deg);
        -ms-transform: rotate(0deg);
        -o-transform: rotate(0deg);
        transform: rotate(0deg);
    }

    100% {
        -webkit-transform: rotate(360deg);
        -moz-transform: rotate(360deg);
        -ms-transform: rotate(360deg);
        -o-transform: rotate(360deg);
        transform: rotate(360deg);
    }
}

@-o-keyframes spinner {
    0% {
        -webkit-transform: rotate(0deg);
        -moz-transform: rotate(0deg);
        -ms-transform: rotate(0deg);
        -o-transform: rotate(0deg);
        transform: rotate(0deg);
    }

    100% {
        -webkit-transform: rotate(360deg);
        -moz-transform: rotate(360deg);
        -ms-transform: rotate(360deg);
        -o-transform: rotate(360deg);
        transform: rotate(360deg);
    }
}

@keyframes spinner {
    0% {
        -webkit-transform: rotate(0deg);
        -moz-transform: rotate(0deg);
        -ms-transform: rotate(0deg);
        -o-transform: rotate(0deg);
        transform: rotate(0deg);
    }

    100% {
        -webkit-transform: rotate(360deg);
        -moz-transform: rotate(360deg);
        -ms-transform: rotate(360deg);
        -o-transform: rotate(360deg);
        transform: rotate(360deg);
    }
}

.spinner-logo {
    width: 124px;
    height: 96px;
    animation: spin 1.2s linear infinite;
}

@keyframes spin {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}

.scale-logo {
    width: 124px;
    height: 96px;
    animation: scalePulse 1s ease-in-out infinite;
}

@keyframes scalePulse {
    0%, 100% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.2);
    }
}

.spin-scale-logo {
    width: 124px;
    height: 96px;
    animation: spinScale 1.2s linear infinite;
}

@keyframes spinScale {
    0% {
        transform: rotate(0deg) scale(1);
    }

    25% {
        transform: rotate(90deg) scale(1.25);
    }

    50% {
        transform: rotate(180deg) scale(1.5);
    }

    75% {
        transform: rotate(270deg) scale(1.25);
    }

    100% {
        transform: rotate(360deg) scale(1);
    }
}
.loader-text {
  margin-top: 1em;
  font-size: 1.2em;
}

.loader-text .dot-1,
.loader-text .dot-2,
.loader-text .dot-3 {
  animation: blink 1.4s infinite;
  opacity: 0;
}

.loader-text .dot-1 {
  animation-delay: 0s;
}

.loader-text .dot-2 {
  animation-delay: 0.2s;
}

.loader-text .dot-3 {
  animation-delay: 0.4s;
}

@keyframes blink {
  0%, 80%, 100% {
    opacity: 0;
  }
  40% {
    opacity: 1;
  }
}

.loader-content {
    text-align: center;
}

#virtualAssistantContainer {
    position: fixed;
    bottom: 24px;
    right: 24px;
    z-index: 1000;
}

.fab {
    position: fixed;
    bottom: 30px;
    right: 30px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border: none;
    color: white;
    border-radius: 50%;
    width: 60px;
    height: 60px;
    font-size: 24px;
    cursor: pointer;
    z-index: 1000;
    box-shadow: 0 8px 25px rgba(102, 126, 234, 0.4);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    align-items: center;
    justify-content: center;
}

.fab:hover {
    transform: scale(1.1);
    box-shadow: 0 12px 35px rgba(102, 126, 234, 0.6);
}

.fab.hide { 
    opacity: 0; 
    pointer-events: none; 
    transform: scale(0.8);
}

.assistant-window {
    position: fixed;
    bottom: 100px;
    right: 30px;
    width: 380px;
    background: #fff;
    border-radius: 20px;
    box-shadow: 0 20px 60px rgba(0,0,0,0.15);
    z-index: 1100;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    max-height: 80vh;
    height: 520px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(10px);
}

.assistant-window.pinned {
    top: 0;
    right: 0;
    bottom: 0;
    width: 420px;
    max-width: 100vw;
    border-radius: 14px;
    height: 100vh;
    max-height: 100vh;
    box-shadow: -4px 0 30px rgba(0,0,0,0.15);
    border-left: 1px solid rgba(0,0,0,0.1);
}

.assistant-header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 18px 20px;
    font-weight: 600;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 1.1em;
    letter-spacing: 0.5px;
    position: relative;
    overflow: hidden;
}

.assistant-header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(45deg, rgba(255,255,255,0.1) 0%, transparent 50%, rgba(255,255,255,0.1) 100%);
    animation: shimmer 3s infinite;
}

.assistant-header button {
    background: rgba(255, 255, 255, 0.2);
    border: none;
    color: white;
    border-radius: 50%;
    width: 32px;
    height: 32px;
    cursor: pointer;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    backdrop-filter: blur(10px);
}

.assistant-header button:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: scale(1.1);
}

.assistant-body {
    flex: 1;
    padding: 20px 16px 16px 16px;
    overflow-y: auto;
    background: linear-gradient(180deg, #f8fafc 0%, #f1f5f9 100%);
    display: flex;
    flex-direction: column;
    gap: 12px;
    scroll-behavior: smooth;
}

.assistant-body::-webkit-scrollbar {
    width: 6px;
}

.assistant-body::-webkit-scrollbar-track {
    background: transparent;
}

.assistant-body::-webkit-scrollbar-thumb {
    background: rgba(102, 126, 234, 0.3);
    border-radius: 3px;
}

.assistant-body::-webkit-scrollbar-thumb:hover {
    background: rgba(102, 126, 234, 0.5);
}

.assistant-input {
    display: flex;
    padding: 16px 16px 16px 16px;
    border-top: 1px solid rgba(0,0,0,0.08);
    background: #fff;
    gap: 10px;
    position: relative;
}

.assistant-input::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent 0%, rgba(102, 126, 234, 0.2) 50%, transparent 100%);
}

.assistant-input input {
    flex: 1;
    padding: 12px 18px;
    border: 2px solid #e2e8f0;
    border-radius: 25px;
    font-size: 1em;
    background: #f8fafc;
    outline: none;
    transition: all 0.3s;
    font-family: inherit;
}

.assistant-input input:focus {
    border-color: #667eea;
    background: #fff;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.assistant-input button {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border: none;
    color: white;
    border-radius: 50%;
    width: 44px;
    height: 44px;
    font-size: 1.2em;
    cursor: pointer;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.3);
}

.assistant-input button:hover:not(:disabled) {
    transform: scale(1.05);
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.4);
}

.assistant-input button:disabled {
    background: #cbd5e1;
    cursor: not-allowed;
    opacity: 0.7;
    box-shadow: none;
}

/* Chat bubbles */
.assistant-message {
    display: flex;
    align-items: flex-end;
    margin-bottom: 4px;
    animation: fadeInUp 0.3s ease-out;
}

.assistant-message.user {
    justify-content: flex-end;
}

.assistant-message.assistant {
    justify-content: flex-start;
}

.assistant-message .bubble {
    max-width: 80%;
    padding: 12px 18px;
    border-radius: 20px;
    font-size: 0.95em;
    line-height: 1.5;
    box-shadow: 0 2px 12px rgba(0,0,0,0.08);
    position: relative;
    word-break: break-word;
    transition: all 0.3s;
    font-family: inherit;
}

.assistant-message.user .bubble {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: #fff;
    border-bottom-right-radius: 6px;
    margin-left: auto;
    margin-right: 0;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.3);
}

.assistant-message.assistant .bubble {
    background: #fff;
    color: #334155;
    border-bottom-left-radius: 6px;
    margin-right: auto;
    margin-left: 0;
    border: 1px solid rgba(0,0,0,0.08);
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
}

.assistant-message.assistant .bubble:hover {
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

/* Typing indicator */
.typing-dot {
    font-weight: 600;
    color: #667eea;
}

.dot {
    animation: blink 1.4s infinite;
    opacity: 0.6;
    font-weight: bold;
}

.dot:nth-child(2) { animation-delay: 0.2s; }
.dot:nth-child(3) { animation-delay: 0.4s; }

@keyframes blink {
    0%, 100% { opacity: 0.3; }
    50% { opacity: 1; }
}

@keyframes shimmer {
    0% { transform: translateX(-100%); }
    100% { transform: translateX(100%); }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Hide class */
.d-none { display: none !important; }

/* Squeeze body when pinned */
.body-assistant-pinned {
    transition: margin-right 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    margin-right: 420px;
}

@media (max-width: 768px) {
    .assistant-window, .assistant-window.pinned { 
        width: 100vw; 
        max-width: 100vw; 
        right: 0;
        border-radius: 0;
    }
    .body-assistant-pinned { 
        margin-right: 0; 
    }
    .fab {
        bottom: 20px;
        right: 20px;
        width: 55px;
        height: 55px;
    }
}

@media (max-width: 480px) {
    .assistant-window {
        bottom: 80px;
        height: calc(100vh - 100px);
        max-height: calc(100vh - 100px);
    }
    .assistant-body {
        padding: 16px 12px 12px 12px;
    }
    .assistant-input {
        padding: 12px 12px 12px 12px;
    }
    .assistant-message .bubble {
        max-width: 90%;
        padding: 10px 14px;
        font-size: 0.9em;
    }
    .fab {
        width: 50px;
        height: 50px;
        font-size: 20px;
    }
}

/* Data Table Styles for Assistant */
.table-container {
    max-width: 100%;
    overflow-x: auto;
    margin: 8px 0;
    border-radius: 8px;
    background: #fff;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.data-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.85em;
    background: #fff;
    border-radius: 8px;
    overflow: hidden;
}

.data-table thead {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.data-table th {
    padding: 12px 8px;
    text-align: left;
    font-weight: 600;
    font-size: 0.9em;
    border: none;
    white-space: nowrap;
}

.data-table tbody tr {
    border-bottom: 1px solid #f0f0f0;
    transition: background-color 0.2s;
}

.data-table tbody tr:hover {
    background-color: #f8f9fa;
}

.data-table tbody tr:nth-child(even) {
    background-color: #fafbfc;
}

.data-table tbody tr:nth-child(even):hover {
    background-color: #f0f2f5;
}

.data-table td {
    padding: 10px 8px;
    border: none;
    vertical-align: top;
    word-break: break-word;
    max-width: 200px;
    overflow: hidden;
    text-overflow: ellipsis;
}

.data-table td:first-child {
    font-weight: 500;
    color: #667eea;
}

/* Mobile responsive table */
@media (max-width: 768px) {
    .data-table {
        font-size: 0.75em;
    }
    
    .data-table th,
    .data-table td {
        padding: 8px 6px;
    }
    
    .data-table td {
        max-width: 120px;
    }
}

@media (max-width: 480px) {
    .table-container {
        margin: 6px 0;
    }
    
    .data-table {
        font-size: 0.7em;
    }
    
    .data-table th,
    .data-table td {
        padding: 6px 4px;
    }
    
    .data-table td {
        max-width: 80px;
    }
}

/* Download Container Styles */
.download-container {
    display: flex;
    align-items: center;
    gap: 12px;
    background: linear-gradient(135deg, #f8fafc 0%, #e2e8f0 100%);
    border: 2px solid #e2e8f0;
    border-radius: 12px;
    padding: 16px;
    margin: 8px 0;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}

.download-container:hover {
    border-color: #667eea;
    box-shadow: 0 4px 16px rgba(102, 126, 234, 0.15);
    transform: translateY(-1px);
}

.download-icon {
    font-size: 2em;
    flex-shrink: 0;
}

.download-content {
    flex: 1;
    min-width: 0;
}

.download-title {
    font-weight: 600;
    color: #334155;
    font-size: 0.95em;
    margin-bottom: 4px;
}

.download-filename {
    color: #64748b;
    font-size: 0.85em;
    margin-bottom: 8px;
    word-break: break-all;
}

.download-button {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    text-decoration: none;
    padding: 8px 16px;
    border-radius: 8px;
    font-size: 0.9em;
    font-weight: 500;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(102, 126, 234, 0.3);
}

.download-button:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.4);
    color: white;
    text-decoration: none;
}

.download-button:active {
    transform: translateY(0);
}

/* Mobile responsive download container */
@media (max-width: 768px) {
    .download-container {
        flex-direction: column;
        text-align: center;
        gap: 8px;
        padding: 12px;
    }
    
    .download-icon {
        font-size: 1.5em;
    }
    
    .download-button {
        width: 100%;
        justify-content: center;
    }
}

@media (max-width: 480px) {
    .download-container {
        padding: 10px;
        margin: 6px 0;
    }
    
    .download-title {
        font-size: 0.9em;
    }
    
    .download-filename {
        font-size: 0.8em;
    }
    
    .download-button {
        font-size: 0.85em;
        padding: 6px 12px;
    }
}

/* Chart Container Styles */
.chart-container {
    background: #fff;
    border: 2px solid #e2e8f0;
    border-radius: 12px;
    overflow: hidden;
    margin: 8px 0;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    transition: all 0.3s ease;
}

.chart-container:hover {
    border-color: #667eea;
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.15);
}

.chart-header {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 16px;
    background: linear-gradient(135deg, #f8fafc 0%, #e2e8f0 100%);
    border-bottom: 1px solid #e2e8f0;
}

.chart-icon {
    font-size: 1.2em;
}

.chart-title {
    font-weight: 600;
    color: #334155;
    font-size: 0.95em;
}

.chart-frame-container {
    position: relative;
    width: 100%;
    height: 400px;
    background: #f8fafc;
}

.chart-iframe {
    width: 100%;
    height: 100%;
    border: none;
    background: #fff;
}

.chart-footer {
    padding: 8px 16px;
    background: #f8fafc;
    border-top: 1px solid #e2e8f0;
    text-align: center;
}

.chart-link {
    color: #667eea;
    text-decoration: none;
    font-size: 0.85em;
    font-weight: 500;
    transition: color 0.2s ease;
}

.chart-link:hover {
    color: #764ba2;
    text-decoration: underline;
}

/* Mobile responsive chart container */
@media (max-width: 768px) {
    .chart-frame-container {
        height: 300px;
    }
    
    .chart-header {
        padding: 10px 12px;
    }
    
    .chart-footer {
        padding: 6px 12px;
    }
}

@media (max-width: 480px) {
    .chart-container {
        margin: 6px 0;
        border-radius: 8px;
    }
    
    .chart-frame-container {
        height: 250px;
    }
    
    .chart-header {
        padding: 8px 10px;
    }
    
    .chart-title {
        font-size: 0.9em;
    }
    
    .chart-footer {
        padding: 4px 10px;
    }
    
    .chart-link {
        font-size: 0.8em;
    }
}

/* Chart Loading and Error States */
.chart-loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%;
    background: #f8fafc;
    color: #64748b;
    font-size: 0.9em;
    gap: 12px;
}

.loading-spinner {
    width: 24px;
    height: 24px;
    border: 2px solid #e2e8f0;
    border-top: 2px solid #667eea;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.chart-error {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%;
    background: #fef2f2;
    color: #dc2626;
    text-align: center;
    gap: 8px;
}

.error-icon {
    font-size: 2em;
}

.error-text {
    font-weight: 600;
    font-size: 1em;
}

.error-subtext {
    font-size: 0.85em;
    color: #7f1d1d;
}

.chart-iframe {
    display: block;
}

/* Chart Preview Container Styles */
.chart-preview-container {
    background: transparent;
    border: none;
    border-radius: 0;
    overflow: hidden;
    margin: 8px 0;
    box-shadow: none;
    transition: none;
    width: 100%;
}

.chart-preview-container:hover {
    border-color: transparent;
    box-shadow: none;
}

.chart-preview-header {
    display: none;
}

.chart-preview-body {
    padding: 0 !important;
    margin: 0 !important;
    text-align: center;
    min-height: auto;
}

.chart-preview-description {
    color: #64748b;
    font-size: 0.85em;
    margin-bottom: 8px;
    line-height: 1.4;
}

.chart-preview-actions {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
}

.chart-preview-note {
    font-size: 0.75em;
    color: #64748b;
    background: #f1f5f9;
    padding: 6px 10px;
    border-radius: 6px;
    border-left: 3px solid #667eea;
    max-width: 250px;
    text-align: center;
    line-height: 1.3;
}

/* Chart Loading and Embedded Styles */
.chart-loading-spinner {
    width: 24px;
    height: 24px;
    border: 2px solid #e2e8f0;
    border-top: 2px solid #667eea;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto;
}

.chart-embedded-container {
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.chart-embedded-iframe {
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.chart-preview-footer {
    text-align: center;
    padding: 8px 0;
}

.chart-preview-link {
    color: #667eea;
    text-decoration: none;
    font-size: 0.85em;
    font-weight: 500;
    transition: color 0.2s ease;
}

.chart-preview-link:hover {
    color: #764ba2;
    text-decoration: underline;
}

.chart-error-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    padding: 20px;
    text-align: center;
}

.chart-error-icon {
    font-size: 2.5em;
}

.chart-error-text {
    font-weight: 600;
    color: #dc2626;
    font-size: 1em;
}

.chart-error-subtext {
    color: #7f1d1d;
    font-size: 0.9em;
    line-height: 1.4;
}

/* Mobile responsive chart preview */
@media (max-width: 768px) {
    .chart-preview-header {
        padding: 12px;
    }
    
    .chart-preview-body {
        padding: 16px;
    }
    
    .chart-preview-button {
        width: 100%;
        justify-content: center;
    }
    
    .chart-preview-note {
        max-width: 100%;
        font-size: 0.75em;
    }
}

@media (max-width: 480px) {
    .chart-preview-container {
        margin: 6px 0;
        border-radius: 8px;
    }
    
    .chart-preview-header {
        padding: 10px;
    }
    
    .chart-preview-title {
        font-size: 0.9em;
    }
    
    .chart-preview-body {
        padding: 12px;
    }
    
    .chart-preview-description {
        font-size: 0.85em;
    }
    
    .chart-preview-button {
        font-size: 0.9em;
        padding: 10px 20px;
    }
}

.chart-preview-body iframe.chart-embedded-iframe,
.chart-preview-body img {
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0;
    margin: 0;
    border-radius: 8px;
    border: 1px solid #e2e8f0;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
    background: #fff;
    display: block;
    padding: 0;
}