/* industries-management.html — page-specific styles */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    background: linear-gradient(135deg, #0b0e13 0%, #141c28 100%);
    min-height: 100vh;
    color: #c9d2dc;
    line-height: 1.6;
}

.app-container {
    display: flex;
    min-height: 100vh;
}

/* Sidebar with Modern Design */
.sidebar {
    width: 280px;
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(20px);
    border-right: 1px solid rgba(255, 255, 255, 0.1);
    color: white;
    padding: 24px 0;
    box-shadow: 2px 0 25px rgba(0,0,0,0.3);
    transition: all 0.3s ease;
    overflow-y: auto;
    flex-shrink: 0;
    position: fixed;
    height: 100vh;
}

.sidebar.collapsed {
    width: 80px;
}

.logo {
    display: flex;
    align-items: center;
    font-size: 20px;
    font-weight: 600;
    color: white;
    background: linear-gradient(135deg, #ff6b00, #ff9933);
    background-clip: text;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.logo img {
    height: 32px;
}

.logo .material-icons {
    margin-right: 12px;
    font-size: 28px;
}

/* Navigation Items with Modern Styling */
.nav-item {
    display: flex;
    align-items: center;
    padding: 12px 24px;
    cursor: pointer;
    transition: all 0.3s ease;
    border: none;
    background: none;
    color: white;
    width: 100%;
    text-align: left;
    position: relative;
    border-radius: 0 25px 25px 0;
    margin: 4px 0;
}

.nav-item.active {
    background: #26303f;
    border-left: 4px solid #5468f2;
    color: white;
    font-weight: 500;
    box-shadow: 0 4px 20px rgba(84,104,242,0.3);
}

.nav-item .material-icons {
    margin-right: 12px;
    font-size: 20px;
    transition: all 0.3s ease;
}

.nav-text {
    flex: 1;
}

/* Main Content with Modern Styling */
.main-content {
    flex: 1;
    margin-left: 280px;
    display: flex;
    flex-direction: column;
    background: rgba(255,255,255,0.02);
    min-width: 0;
    overflow: hidden;
}

.header {
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    padding: 20px 32px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.1);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.header-left {
    display: flex;
    align-items: center;
}

.header-title {
    font-size: 28px;
    font-weight: 700;
    margin-left: 20px;
    background: linear-gradient(135deg, #ff6b00, #ff9933);
    background-clip: text;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.header-right {
    display: flex;
    align-items: center;
    gap: 20px;
}

@keyframes pulse {
    0% { box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.7); }
    70% { box-shadow: 0 0 0 10px rgba(16, 185, 129, 0); }
    100% { box-shadow: 0 0 0 0 rgba(16, 185, 129, 0); }
}

/* Content Area Styling */
.content {
    padding: 32px;
    flex: 1;
    overflow-y: auto;
    position: relative;
    max-width: calc(100vw - 280px);
    width: 100%;
}

.container {
    max-width: 1600px;
    margin: 0 auto;
}

.main-layout {
    display: grid;
    grid-template-columns: 280px 1fr;
    gap: 24px;
    align-items: start;
}

.sidebar-filters {
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    padding: 24px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.3);
    position: sticky;
    top: 24px;
}

.sidebar-section {
    margin-bottom: 32px;
}

.sidebar-title {
    font-weight: 600;
    font-size: 1.1rem;
    color: #c9d2dc;
    margin-bottom: 16px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.industries-list {
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    padding: 24px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.3);
    max-height: 600px;
    overflow-y: auto;
}

.industries-list h2 {
    color: #c9d2dc;
    margin-bottom: 20px;
    font-size: 1.5rem;
    border-bottom: 2px solid rgba(255, 255, 255, 0.1);
    padding-bottom: 10px;
}

.industry-item {
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 15px;
    margin-bottom: 15px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.industry-item:hover {
    background: rgba(255, 255, 255, 0.1);
    transform: translateY(-2px);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.3);
    border-color: #2b8be6;
}

.industry-item.active {
    background: linear-gradient(135deg, rgba(43,139,230,0.3), rgba(84,104,242,0.3));
    color: white;
    border-color: #2b8be6;
    box-shadow: 0 4px 20px rgba(43,139,230,0.3);
}

.industry-item h3 {
    font-size: 1.1rem;
    margin-bottom: 5px;
    color: #c9d2dc;
}

.industry-item p {
    font-size: 0.9rem;
    opacity: 0.8;
    color: #8c99a8;
}

.add-industry-btn {
    background: linear-gradient(135deg, #2b8be6, #5468f2);
    color: white;
    border: none;
    padding: 12px 20px;
    border-radius: 10px;
    cursor: pointer;
    font-size: 1rem;
    font-weight: 600;
    transition: all 0.3s ease;
    width: 100%;
    margin-top: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.add-industry-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 20px rgba(43,139,230,0.4);
}

.industry-profile {
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    padding: 30px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.3);
}

.profile-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
    padding-bottom: 20px;
    border-bottom: 2px solid rgba(255, 255, 255, 0.1);
}

.profile-header h2 {
    color: #c9d2dc;
    font-size: 1.8rem;
}

.action-buttons {
    display: flex;
    gap: 10px;
}

.btn {
    background: linear-gradient(135deg, #2b8be6, #5468f2);
    color: white;
    border: none;
    padding: 12px 20px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    text-decoration: none;
    font-family: inherit;
}

.btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 20px rgba(43,139,230,0.4);
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.2);
}

.btn-outline {
    background: transparent;
    color: #2b8be6;
    border: 2px solid #2b8be6;
}

.btn-outline:hover {
    background: #2b8be6;
    color: white;
}

.form-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    color: #c9d2dc;
}

.form-group input,
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 12px 16px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 8px;
    font-size: 14px;
    font-family: inherit;
    transition: all 0.3s ease;
    background: rgba(255, 255, 255, 0.05);
    color: #c9d2dc;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
    outline: none;
    border-color: #2b8be6;
    box-shadow: 0 0 0 3px rgba(43,139,230,0.1);
}

.form-group input::placeholder,
.form-group textarea::placeholder {
    color: #8c99a8;
}

.form-group textarea {
    resize: vertical;
    min-height: 100px;
}

.trends-section {
    grid-column: 1 / -1;
}

.trends-list {
    background: #19202b;
    border-radius: 10px;
    padding: 15px;
    margin-top: 10px;
}

.trend-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px;
    background: #171e27;
    border-radius: 8px;
    margin-bottom: 10px;
    border: 1px solid #d8e9fa;
}

.trend-item:last-child {
    margin-bottom: 0;
}

.trend-info {
    flex: 1;
}

.trend-name {
    font-weight: 600;
    color: #9ea7b4;
}

.trend-description {
    font-size: 0.9rem;
    color: #738194;
    margin-top: 2px;
}

.trend-actions {
    display: flex;
    gap: 5px;
}

.btn-small {
    padding: 4px 8px;
    font-size: 0.8rem;
}

.metrics-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 15px;
    margin-top: 20px;
}

.metric-card {
    background: linear-gradient(135deg, #5d71f3, #112cdc);
    color: white;
    padding: 20px;
    border-radius: 15px;
    text-align: center;
}

.metric-value {
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 5px;
}

.metric-label {
    font-size: 0.9rem;
    opacity: 0.9;
}

.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.7);
    z-index: 1000;
    justify-content: center;
    align-items: center;
}

.modal.active {
    display: flex;
}

.modal-content {
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    padding: 24px;
    max-width: 800px;
    max-height: 90vh;
    width: 90%;
    overflow-y: auto;
    box-shadow: 0 4px 20px rgba(0,0,0,0.5);
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 24px;
    padding-bottom: 16px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.modal-title {
    font-size: 1.4rem;
    font-weight: 600;
    color: #c9d2dc;
}

.close {
    background: none;
    border: none;
    cursor: pointer;
    padding: 8px;
    border-radius: 50%;
    color: #8c99a8;
    transition: all 0.3s ease;
}

.close:hover {
    background: rgba(255, 255, 255, 0.1);
    color: #c9d2dc;
}

.empty-state {
    text-align: center;
    padding: 60px 20px;
    color: #738194;
}

.empty-state h3 {
    font-size: 1.5rem;
    margin-bottom: 10px;
    color: #9ea7b4;
}

.empty-state p {
    margin-bottom: 20px;
}

@media (max-width: 1024px) {
    .main-layout {
        grid-template-columns: 1fr;
    }

    .sidebar-filters {
        position: static;
    }

    .content-header {
        flex-direction: column;
        align-items: stretch;
    }
}

@media (max-width: 768px) {
    .content {
        padding: 16px;
    }

    .main-content {
        grid-template-columns: 1fr;
    }

    .form-grid {
        grid-template-columns: 1fr;
    }

    .metrics-grid {
        grid-template-columns: 1fr;
    }

    .header-title {
        font-size: 20px;
    }

    .sidebar {
        width: 80px;
    }

    .sidebar .nav-text {
        display: none;
    }
}

@media print {
    body {
        background: white;
        color: black;
    }

    .sidebar, .header-actions, .upload-area {
        display: none;
    }

    .main-layout {
        grid-template-columns: 1fr;
    }
}

/* Modern Chatbot Styles */
.chatbot-container {
    position: fixed;
    bottom: 32px;
    right: 32px;
    z-index: 1000;
}

.chatbot-trigger {
    width: 72px;
    height: 72px;
    background: linear-gradient(135deg, #2b8be6, #5468f2);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 8px 25px rgba(43,139,230,0.4);
    transition: all 0.3s ease;
    border: none;
    color: white;
    animation: chatbotPulse 3s infinite;
}

.chatbot-trigger:hover {
    transform: scale(1.1);
    box-shadow: 0 12px 35px rgba(43,139,230,0.5);
}

.chatbot-trigger .material-icons {
    font-size: 32px;
}

.chatbot-window {
    position: fixed;
    bottom: 122px;
    right: 32px;
    width: 380px;
    height: calc(100vh - 210px);
    max-height: calc(100vh - 210px);
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(25px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 20px;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.3);
    display: none;
    flex-direction: column;
    overflow: hidden;
    transform: translateY(20px);
    opacity: 0;
    transition: all 0.4s ease;
}

.chatbot-header {
    background: linear-gradient(135deg, #2b8be6, #5468f2);
    color: white;
    padding: 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.chatbot-close:hover {
    background: rgba(255, 255, 255, 0.2);
}

.quick-action {
    padding: 8px 16px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 20px;
    font-size: 12px;
    cursor: pointer;
    transition: all 0.3s ease;
    color: #8c99a8;
}

.quick-action:hover {
    background: rgba(43,139,230,0.2);
    border-color: #2b8be6;
    color: #2b8be6;
}

.chatbot-messages {
    flex: 1;
    padding: 24px;
    overflow-y: auto;
    background: rgba(0, 0, 0, 0.1);
}

.message {
    margin-bottom: 20px;
    animation: messageSlideIn 0.4s ease;
}

.message.user {
    display: flex;
    justify-content: flex-end;
}

.chatbot-input-area {
    padding: 20px;
    background: rgba(0, 0, 0, 0.2);
    backdrop-filter: blur(10px);
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.message.bot .message-content.ai-styled .ai-response {
    line-height: 1.7;
    color: #ffffff;
    font-size: 13px;
}

.quick-action {
    padding: 8px 16px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 20px;
    font-size: 12px;
    cursor: pointer;
    transition: all 0.3s ease;
    color: #f2f5f9;
}

.quick-action:hover {
    background: rgba(43,139,230,0.2);
    border-color: #2b8be6;
    color: #2b8be6;
}

.typing-indicator {
    display: flex;
    align-items: center;
    padding: 16px 20px;
    margin-bottom: 20px;
}

.typing-dots {
    display: flex;
    gap: 6px;
    margin-left: 12px;
}

.typing-dot {
    width: 8px;
    height: 8px;
    background: #8c99a8;
    border-radius: 50%;
    animation: typingDot 1.4s infinite;
}

.typing-dot:nth-child(2) {
    animation-delay: 0.2s;
}

.typing-dot:nth-child(3) {
    animation-delay: 0.4s;
}

@keyframes typingDot {
    0%, 60%, 100% {
        transform: translateY(0);
        opacity: 0.4;
    }
    30% {
        transform: translateY(-12px);
        opacity: 1;
    }
}

.issues-tracker-form {
    flex: 1;
    padding: 24px;
    overflow-y: auto;
    background: rgba(0, 0, 0, 0.1);
    max-height: calc(90vh - 80px);
}

.form-group {
    margin-bottom: 20px;
}

.form-submit:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
}

.form-success {
    text-align: center;
    padding: 40px 20px;
    color: #10b981;
}

.form-success .material-icons {
    font-size: 48px;
    margin-bottom: 16px;
}

.form-success h3 {
    margin-bottom: 8px;
    color: #f2f5f9;
}

.form-success p {
    color: #8c99a8;
    font-size: 14px;
}

.hidden {
    display: none;
}
