/* Nano AI Proactive Hero Component Styles
 * Matching Figma designs exactly
 * 
 * IMPORTANT: After making changes to this file, run `npm run minify` to regenerate minified CSS
 */

:root {
    --nano-bg-white: #FFFFFF;
    --nano-text-primary: #111827;
    --nano-text-secondary: #6B7280;
    --nano-text-tertiary: #9CA3AF;
    --nano-blue: #4D8EF3;
    --nano-blue-light: #E8F2FF;
    --nano-blue-dark: #286bcd;
    --nano-button-dark: #1F2937;
    --nano-border-light: #EDEFF3;
    --nano-border-medium: #E5E5E5;
    --nano-divider: #F0F0F0;
    --nano-critical-bg: #FEE2E2;
    --nano-critical-text: #DC2626;
    --nano-success: #10B981;
    --nano-input-bg: #F5F5F5;
    --nano-header-bg: #F8F9FA;
}

/* Main Container */
.nano-proactive-hero {
    width: 100%;
    max-width: 500px;
    margin: 0 auto;
}

/* Chat Window */
.nano-chat-window {
    background: var(--nano-bg-white);
    border-radius: 12px;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    height: 600px;
    border: 1px solid var(--nano-border-medium);
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
}

/* Chat Header */
.nano-chat-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 20px;
    background: var(--nano-header-bg);
    border-bottom: 1px solid var(--nano-divider);
    flex-shrink: 0;
}

.nano-chat-header-left {
    display: flex;
    align-items: center;
    gap: 8px;
}

.nano-chat-title {
    font-size: 14px;
    font-weight: 400;
    color: var(--nano-text-primary);
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
}

.nano-chat-header-right {
    display: flex;
    align-items: center;
    gap: 8px;
}

.nano-window-control {
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: none;
    background: transparent;
    cursor: pointer;
    border-radius: 4px;
    transition: background-color 0.2s ease;
    padding: 0;
}

.nano-window-control:hover {
    background-color: rgba(0, 0, 0, 0.05);
}

.nano-window-control svg {
    display: block;
}

/* Chat Content Area */
.nano-chat-content {
    flex: 1;
    overflow-y: auto;
    overflow-x: hidden;
    padding: 20px;
    background: var(--nano-bg-white);
    position: relative;
}

.nano-chat-content::-webkit-scrollbar {
    width: 6px;
}

.nano-chat-content::-webkit-scrollbar-track {
    background: transparent;
}

.nano-chat-content::-webkit-scrollbar-thumb {
    background: var(--nano-border-light);
    border-radius: 3px;
}

.nano-chat-content::-webkit-scrollbar-thumb:hover {
    background: var(--nano-text-secondary);
}

/* Nano Action Card Container */
.nano-action-card-container {
    width: 100%;
}

/* Nano Action Card */
.nano-action-card {
    background: var(--nano-bg-white);
    border-radius: 16px;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    padding: 20px;
    border: 1px solid var(--nano-border-light);
}

/* Action Card Header */
.nano-action-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 16px;
}

.nano-action-title {
    font-size: 18px;
    font-weight: 700;
    color: var(--nano-text-primary);
    margin: 0;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
}

.nano-action-close {
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: none;
    background: transparent;
    cursor: pointer;
    border-radius: 4px;
    transition: background-color 0.2s ease;
    padding: 0;
}

.nano-action-close:hover {
    background-color: rgba(0, 0, 0, 0.05);
}

.nano-action-close svg {
    display: block;
}

/* Visual Section */
.nano-action-visual {
    margin-bottom: 16px;
    min-height: 120px;
}

/* Shift Cards Carousel */
.nano-shift-cards-carousel {
    display: flex;
    gap: 12px;
    overflow-x: auto;
    overflow-y: hidden;
    padding-bottom: 4px;
    scrollbar-width: thin;
    scrollbar-color: var(--nano-border-light) transparent;
}

.nano-shift-cards-carousel::-webkit-scrollbar {
    height: 4px;
}

.nano-shift-cards-carousel::-webkit-scrollbar-track {
    background: transparent;
}

.nano-shift-cards-carousel::-webkit-scrollbar-thumb {
    background: var(--nano-border-light);
    border-radius: 2px;
}

.nano-shift-card {
    flex-shrink: 0;
    width: 150px;
    min-height: 100px;
    background: var(--nano-border-light);
    border-radius: 12px;
    position: relative;
    overflow: hidden;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.nano-shift-card-active {
    background: var(--nano-bg-white);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.nano-shift-card-top-bar {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: var(--nano-blue);
}

.nano-shift-card-content {
    padding: 12px 16px;
    display: flex;
    flex-direction: column;
    height: 100%;
}

.nano-shift-card-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 8px;
}

.nano-shift-time {
    font-size: 14px;
    font-weight: 400;
    color: var(--nano-text-primary);
}

.nano-shift-ratio {
    font-size: 12px;
    font-weight: 400;
    color: var(--nano-text-secondary);
}

.nano-shift-card-body {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    flex: 1;
}

.nano-shift-name {
    font-size: 14px;
    font-weight: 400;
    color: var(--nano-text-primary);
}

.nano-shift-duration {
    font-size: 12px;
    font-weight: 400;
    color: var(--nano-text-secondary);
    background: var(--nano-border-light);
    padding: 4px 8px;
    border-radius: 6px;
}

/* Percentage Cards */
.nano-percentage-cards {
    display: flex;
    align-items: center;
    gap: 16px;
    justify-content: center;
    position: relative;
}

.nano-percentage-card {
    width: 120px;
    height: 100px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.nano-percentage-current {
    background: var(--nano-critical-bg);
    color: var(--nano-critical-text);
}

.nano-percentage-suggested {
    background: var(--nano-button-dark);
    color: var(--nano-bg-white);
}

.nano-percentage-value {
    font-size: 32px;
    font-weight: 700;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
}

.nano-percentage-hint {
    position: absolute;
    top: -24px;
    right: 0;
    font-size: 12px;
    color: var(--nano-text-secondary);
    border: 1px dashed var(--nano-border-medium);
    padding: 4px 8px;
    border-radius: 4px;
    background: var(--nano-bg-white);
}

/* Grid Visualization */
.nano-grid-visualization {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.nano-grid-row {
    display: flex;
    gap: 8px;
}

.nano-grid-cell {
    flex: 1;
    aspect-ratio: 1;
    background: var(--nano-border-light);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 40px;
}

.nano-grid-cell-highlighted {
    background: var(--nano-button-dark);
    color: var(--nano-bg-white);
    font-weight: 600;
    font-size: 14px;
}

/* Chart Visualization */
.nano-chart-visualization {
    width: 100%;
    height: 120px;
    padding: 8px;
}

.nano-chart-svg {
    width: 100%;
    height: 100%;
}

.nano-chart-bar-highlighted {
    animation: pulse-highlight 2s ease-in-out infinite;
}

@keyframes pulse-highlight {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.7;
    }
}

/* Content Section */
.nano-action-content {
    margin-bottom: 16px;
}

.nano-scenario-title {
    font-size: 16px;
    font-weight: 700;
    color: var(--nano-text-primary);
    margin: 0 0 8px 0;
    line-height: 1.3;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
}

.nano-scenario-description {
    font-size: 14px;
    font-weight: 400;
    color: var(--nano-text-primary);
    margin: 0;
    line-height: 1.6;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
}

/* Action Footer */
.nano-action-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-top: 16px;
    border-top: 1px solid var(--nano-border-light);
}

.nano-action-icons {
    display: flex;
    gap: 8px;
}

.nano-action-icon-btn {
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: none;
    background: transparent;
    cursor: pointer;
    border-radius: 4px;
    transition: background-color 0.2s ease;
    padding: 0;
}

.nano-action-icon-btn:hover {
    background-color: rgba(0, 0, 0, 0.05);
}

.nano-action-icon-btn svg {
    display: block;
}

/* CTA Button */
.nano-action-cta {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 20px;
    background: var(--nano-button-dark);
    color: var(--nano-bg-white);
    border: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    cursor: pointer;
    transition: background-color 0.2s ease, transform 0.1s ease;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
}

.nano-action-cta:hover {
    background-color: #111827;
    transform: translateY(-1px);
}

.nano-action-cta:active {
    transform: translateY(0);
}

.nano-cta-icon {
    display: flex;
    align-items: center;
}

.nano-cta-icon svg {
    display: block;
}

.nano-cta-text {
    white-space: nowrap;
}

.nano-cta-star {
    display: flex;
    align-items: center;
    margin-left: 4px;
}

.nano-cta-star svg {
    display: block;
    width: 14px;
    height: 14px;
}

/* Chat Input Area */
.nano-chat-input-area {
    padding: 16px 20px;
    background: var(--nano-bg-white);
    border-top: 1px solid var(--nano-divider);
    flex-shrink: 0;
}

.nano-chat-input-container {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 12px;
}

.nano-input-icon-btn {
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: none;
    background: transparent;
    cursor: pointer;
    border-radius: 4px;
    transition: background-color 0.2s ease;
    padding: 0;
    flex-shrink: 0;
}

.nano-input-icon-btn:hover {
    background-color: rgba(0, 0, 0, 0.05);
}

.nano-input-icon-btn svg {
    display: block;
}

.nano-chat-input {
    flex: 1;
    height: 44px;
    padding: 12px 20px;
    background: var(--nano-input-bg);
    border: 1px solid var(--nano-border-medium);
    border-radius: 24px;
    font-size: 14px;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    color: var(--nano-text-primary);
    outline: none;
}

.nano-chat-input::placeholder {
    color: var(--nano-text-tertiary);
}

.nano-input-send-btn {
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: none;
    background: var(--nano-border-light);
    cursor: pointer;
    border-radius: 50%;
    transition: background-color 0.2s ease;
    padding: 0;
    flex-shrink: 0;
}

.nano-input-send-btn:hover {
    background-color: var(--nano-text-secondary);
}

.nano-input-send-btn svg {
    display: block;
    stroke: var(--nano-bg-white);
}

/* Quick Action Buttons */
.nano-quick-actions {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

.nano-quick-action-btn {
    flex: 1;
    min-width: 120px;
    height: 44px;
    padding: 12px 16px;
    background: var(--nano-input-bg);
    border: 1px solid var(--nano-border-medium);
    border-radius: 8px;
    font-size: 14px;
    font-weight: 400;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    color: var(--nano-text-primary);
    cursor: pointer;
    transition: background-color 0.2s ease, border-color 0.2s ease;
    text-align: center;
}

.nano-quick-action-btn:hover {
    background-color: var(--nano-border-light);
    border-color: var(--nano-text-secondary);
}

/* Responsive Design */
@media (max-width: 640px) {
    .nano-chat-window {
        height: 450px;
        border-radius: 12px;
    }
    
    .nano-chat-header {
        padding: 12px 16px;
    }
    
    .nano-chat-content {
        padding: 12px;
    }
    
    .nano-action-card {
        padding: 16px;
    }
    
    .nano-shift-card {
        width: 120px;
        min-height: 80px;
    }
    
    .nano-scenario-title {
        font-size: 15px;
    }
    
    .nano-scenario-description {
        font-size: 13px;
    }
    
    .nano-chat-input-area {
        padding: 12px 16px;
    }
    
    .nano-quick-actions {
        flex-direction: column;
    }
    
    .nano-quick-action-btn {
        width: 100%;
        min-width: auto;
    }
}

@media (min-width: 641px) and (max-width: 1024px) {
    .nano-chat-window {
        height: 550px;
    }
    
    .nano-shift-card {
        width: 130px;
    }
}

/* Reduced Motion Support */
@media (prefers-reduced-motion: reduce) {
    .nano-action-card-container *,
    .nano-shift-card,
    .nano-action-cta,
    .nano-action-icon-btn,
    .nano-window-control {
        transition: none !important;
        animation: none !important;
    }
    
    .nano-chart-bar-highlighted {
        animation: none !important;
    }
}

/* Accessibility */
.nano-proactive-hero:focus-within {
    outline: 2px solid var(--nano-blue);
    outline-offset: 2px;
}

.nano-action-cta:focus-visible,
.nano-action-icon-btn:focus-visible,
.nano-action-close:focus-visible {
    outline: 2px solid var(--nano-blue);
    outline-offset: 2px;
}

/* Print Styles */
@media print {
    .nano-proactive-hero {
        break-inside: avoid;
    }
    
    .nano-chat-window {
        box-shadow: none;
        border: 1px solid #ddd;
    }
    
    .nano-action-cta,
    .nano-action-icon-btn,
    .nano-window-control {
        display: none;
    }
}
