/* Custom Global Interface Ecosystem Styles for SEO Tool Dashboard Setup */
.kot-dashboard-wrapper {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    color: #1e293b;
    background-color: #f8fafc;
    padding: 25px;
    border-radius: 12px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.02);
    margin: 20px 0;
}

/* Light / Dark Mode adaptive adjustments */
@media (prefers-color-scheme: dark) {
    .kot-dashboard-wrapper { background-color: #111827; color: #f3f4f6; }
    .kot-card { background: #1f2937 !important; border-color: #374151 !important; color: #f3f4f6 !important;}
    .kot-table th { background: #374151 !important; color: #f3f4f6 !important;}
    .kot-table td { border-bottom-color: #374151 !important; color: #d1d5db !important;}
    .kot-input-group input, .kot-input-group select { background-color: #374151 !important; color: #fff !important; border-color: #4b5563 !important; }
}

/* Form Design Settings */
.kot-search-box {
    background: #ffffff;
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05);
    margin-bottom: 25px;
}
.kot-input-row {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    align-items: center;
}
.kot-input-group {
    position: relative;
    display: flex;
    align-items: center;
    flex: 1;
    min-width: 180px;
}
.flex-grow { flex: 2; min-width: 260px; }
.kot-field-icon {
    position: absolute;
    left: 14px;
    color: #94a3b8;
    font-size: 16px;
    pointer-events: none;
}
.kot-input-group input, .kot-input-group select {
    width: 100%;
    padding: 12px 12px 12px 40px !important;
    border: 1px solid #cbd5e1;
    border-radius: 8px;
    font-size: 15px;
    outline: none;
    transition: all 0.2s ease;
}
.kot-input-group input:focus, .kot-input-group select:focus {
    border-color: #3b82f6;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.15);
}

/* Gradient Buttons */
.kot-btn-submit {
    background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%);
    color: white !important;
    border: none;
    padding: 13px 28px;
    font-size: 15px;
    font-weight: 600;
    border-radius: 8px;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    transition: transform 0.1s ease, opacity 0.2s ease;
}
.kot-btn-submit:hover { opacity: 0.95; transform: translateY(-1px); }
.kot-btn-secondary {
    background: #e2e8f0;
    color: #475569;
    border: none;
    padding: 13px 18px;
    border-radius: 8px;
    cursor: pointer;
}

/* Loader Mechanism Styles */
#kot-loader {
    text-align: center;
    padding: 50px 20px;
}
.kot-spinner {
    width: 50px;
    height: 50px;
    border: 5px solid #e2e8f0;
    border-top-color: #2563eb;
    border-radius: 50%;
    animation: kot-spin 1s infinite linear;
    margin: 0 auto 15px;
}
@keyframes kot-spin { 0% { transform: rotate(0deg); } 100% { transform: rotate(360deg); } }

/* Toolbar Layout */
.kot-toolbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    flex-wrap: wrap;
    gap: 15px;
}
.kot-tool-btn {
    background: #fff;
    border: 1px solid #cbd5e1;
    padding: 8px 16px;
    font-size: 13px;
    border-radius: 6px;
    cursor: pointer;
    margin-left: 5px;
    font-weight: 500;
}
.kot-tool-btn:hover { background: #f8fafc; border-color: #94a3b8; }
.kot-history-tags span {
    background: #e0f2fe;
    color: #0369a1;
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 12px;
    margin-right: 8px;
    cursor: pointer;
    display: inline-block;
}

/* Layout Management Columns System Grid styling rules */
.kot-grid-4 { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 20px; margin-bottom: 25px; }
.kot-grid-2 { display: grid; grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); gap: 20px; margin-bottom: 25px; }

.kot-card {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    padding: 20px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.02);
    position: relative;
    margin-bottom: 20px;
}
.kot-card h3 { margin-top: 0; margin-bottom: 20px; font-size: 16px; font-weight: 600; display: flex; align-items: center; gap: 8px; }
.kot-card-header { display: flex; justify-content: space-between; color: #64748b; font-size: 13px; font-weight: 500; }
.kot-metric-val { font-size: 28px; font-weight: 700; margin: 12px 0 6px; color: #0f172a; }
.kot-card-footer { font-size: 12px; color: #94a3b8; }

/* Progress elements decoration metrics */
.kot-progress-bar { background: #e2e8f0; border-radius: 10px; height: 8px; overflow: hidden; margin-top: 10px; }
.kot-progress-fill { background: linear-gradient(90deg, #4ade80, #f87171); width: 0%; height: 100%; transition: width 0.8s ease; }
.kot-intent-badge { background: #f5f3ff; color: #6d28d9; padding: 6px 14px; border-radius: 6px; font-weight: bold; font-size: 14px; display: inline-block; }

.kot-metric-row { display: flex; justify-content: space-between; padding: 10px 0; border-bottom: 1px dashed #e2e8f0; font-size: 14px; }
.kot-rec-box { background: #f0fdf4; border-left: 4px solid #16a34a; padding: 15px; border-radius: 4px; color: #166534; font-size: 14px; line-height: 1.5; }

/* Dashboard Responsive Interactive Tabs elements */
.kot-tabs { display: flex; gap: 10px; border-bottom: 2px solid #e2e8f0; margin-bottom: 20px; }
.kot-tab-btn { background: none; border: none; padding: 10px 20px; cursor: pointer; font-size: 14px; font-weight: 500; color: #64748b; position: relative; top: 2px; }
.kot-tab-btn.active { color: #2563eb; border-bottom: 2px solid #2563eb; font-weight: 600; }
.kot-tab-panel { display: none; }
.kot-tab-panel.active { display: block; }

/* Data Dashboard Reporting Tables Setup */
.kot-table { width: 100%; border-collapse: collapse; text-align: left; font-size: 14px; }
.kot-table th { background: #f8fafc; padding: 12px; font-weight: 600; color: #475569; border-bottom: 2px solid #e2e8f0; }
.kot-table td { padding: 12px; border-bottom: 1px solid #e2e8f0; vertical-align: top; }
.kot-serp-title { font-weight: 600; color: #1a0dab; text-decoration: none; font-size: 15px; display: block; margin-bottom: 3px; }
.kot-serp-url { color: #006621; font-size: 12px; display: block; margin-bottom: 4px; word-break: break-all; }
.kot-serp-desc { color: #545454; font-size: 13px; line-height: 1.4; }

.kot-hidden { display: none !important; }
.kot-alert { padding: 15px; border-radius: 8px; margin-bottom: 20px; font-size: 14px; }
.kot-alert-danger { background: #fef2f2; border: 1px solid #fee2e2; color: #991b1b; }

.kot-chart-canvas-container { position: relative; height: 260px; width: 100%; }

/* Mobile Device Optimizations */
@media(max-width: 768px) {
    .kot-input-row { flex-direction: column; align-items: stretch; }
    .kot-input-group { width: 100%; }
    .kot-toolbar { flex-direction: column; align-items: flex-start; }
    .kot-actions { width: 100%; display: flex; justify-content: space-between; }
    .kot-tool-btn { margin-left: 0; flex: 1; text-align: center; padding: 8px 4px; font-size: 11px; }
}