:root {
    --primary: #2ecc71;
    --primary-dark: #27ae60;
    --primary-light: rgba(46,204,113,.15);
    --text: #2d3748;
    --text-muted: #718096;
    --bg: #f5f7fa;
    --bg-white: #ffffff;
    --border: #e2e8f0;
    --radius: 8px;
    --shadow: 0 2px 10px rgba(0,0,0,.08);
    --header-h: 56px;
    --container-w: 1280px;
    --gap: 24px;
}

*, *::before, *::after { box-sizing: border-box; }
body {
    margin: 0;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    font-size: 16px;
    line-height: 1.6;
    color: var(--text);
    background: var(--bg);
}
a { color: var(--primary); text-decoration: none; }
a:hover { text-decoration: underline; }
h1, h2, h3, h4, h5, h6 {color:#10b981; margin: 0 0 0.6em; line-height: 1.3; }
p { margin: 0 0 1em; }
em, i { font-style: normal; }

/* ================================
   Header
   ================================ */
.site-header {
    background: var(--bg-white);
    border-bottom: 1px solid var(--border);
    box-shadow: var(--shadow);
    position: sticky;
    top: 0;
    z-index: 100;
}
.header-inner {
    max-width: var(--container-w);
    margin: 0 auto;
    padding: 0 var(--gap);
    height: var(--header-h);
    display: flex;
    align-items: center;
    gap: 8px;
}
.site-logo {
    flex-shrink: 0;
    width: 160px;
    height: 50px;
    background-image: url('logo.png');
    background-size: contain;
    background-repeat: no-repeat;
    background-position: left center;
}
.site-logo a {
    display: block;
    width: 100%;
    height: 100%;
    font-size: 0;
    overflow: hidden;
}

.language-switcher {position: relative;cursor: pointer;height:44px;line-height:44px;color: #10b981;font-size:20px;min-width:40px;}

.language-switcher ul{ width:260px;margin:0;padding:0;position:absolute;right:0;left:auto;top: calc(100% - 10px);box-shadow:0 2px 5px rgba(0,0,0,0.1);}
.language-switcher ul{display: none;}
.language-switcher:hover ul{display:block;position:absolute; z-index:1001;}
.language-switcher ul li{float:left;width:130px;height:38px;line-height:38px; list-style:none;overflow:hidden;margin:0px;letter-spacing:1px;margin-right:-1px;margin-bottom:-1px;border-bottom:1px solid #e0e0e0}
.language-switcher ul li a:link,.language-switcher ul li a:visited{ border-radius: 2px; font-size:13px;display:block; text-align:center; border:1px solid #e0e0e0;text-decoration:none;color:#000000;background:#f0f0f0; }
.language-switcher ul li a:hover,.language-switcher ul li a:active{background-color: var(--primary);color:#ffffff;}

.note{color:#555555;background-color:#ffffee;border:1px solid #e0e0e0;margin-bottom:9px;text-align:left;line-height:28px;word-wrap:break-word;word-break:break-all;padding:8px;font-size:15px;overflow:hidden;position:relative; border-radius: var(--radius);}
.note i{font-weight: bold;color:#22c55e;}
.note b{color:#7777ff;}
.note em{color:#ff5500;}
.note a:link,.note a:visited {text-decoration: underline;COLOR: #22c55e;text-decoration-style: dashed; text-underline-offset: 3px; }
.note a:hover{color:#ff5500;} 

/* Main Nav */
.menu-toggle {
    display: none;
    background: none;
    border: none;
    font-size: 1.5rem;
    color: var(--text);
    cursor: pointer;
    padding: 4px 8px;
    flex-shrink: 0;
}
.nav-main {
    display: flex;
    gap: 4px;
    flex: 1;
    overflow-x: auto;
    -ms-overflow-style: none;
    scrollbar-width: none;
}
.nav-main::-webkit-scrollbar { display: none; }
.nav-main a {
    padding: 6px 14px;
    border-radius: 6px;
    background: var(--primary-light);
    color: #333;
    font-size: 0.95rem;
    white-space: nowrap;
    transition: background .15s, color .15s;
}
.nav-main a:hover,
.nav-main a.active {
    background: var(--primary);
    color: #fff;
    text-decoration: none;
}
.nav-main a.goto {
    background: #FF783C;
    color: #fff;
    border-radius: var(--radius);
}
.nav-main a.goto:hover {
    background: #2ecc71;
    text-decoration: none;
}

/* ================================
   Container
   ================================ */
.site-container {
    max-width: var(--container-w);
    margin: 0 auto;
    padding: var(--gap);
}
main {
    background: var(--bg-white);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    padding: var(--gap);
    min-height: 400px;
}
.path { font-size: 0.85rem; color: var(--text-muted); margin-bottom: 12px; white-space: nowrap;overflow: hidden;text-overflow: ellipsis;}
.path a { color: var(--text-muted); }
.path a:hover { color: var(--primary); }
/* Article Images */
.article-img {
    max-width: 100%;
    border-radius: var(--radius);
    display: block;
    margin: 0 auto 10px;
}

/* ================================
   Footer
   ================================ */
.site-footer { text-align: center;background: var(--bg-white);border-top: 1px solid var(--border);margin-top: 40px;padding: 15px}
.site-footer a:link,.site-footer a:visited {color:#666666;text-decoration:none;}
.site-footer a:hover{color:#000000;text-decoration: underline} 
/* ================================
   Friend Links
   ================================ */
.friend-links { border: 1px solid var(--border); border-radius: var(--radius);
    list-style: none;
    padding: 10px;
    margin: 15px 0 1em;
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}
.friend-links li { margin: 0; }
.friend-links a {
    color: #666;
    font-size: 0.875rem;
}
.friend-links a::after { content:"↗"; color:#999999;}
/* ================================
   Lightbox
   ================================ */
.img-overlay {
    position: fixed; inset: 0; z-index: 999;
    background: rgba(0,0,0,.85);
    display: flex; align-items: center; justify-content: center;
}
.img-overlay-img {
    max-width: 90%; max-height: 90%;
    border-radius: 8px; cursor: default;
}
.img-overlay-close {
    position: fixed; top: 16px; right: 24px;
    font-size: 2.5rem; color: #fff;
    background: none; border: none; cursor: pointer;
    line-height: 1;
}
.img-overlay-close:hover { opacity: .7; }

/* ================================
   Popup Overlay
   ================================ */
#opendiv {
    display: none;
    position: fixed; inset: 0; z-index: 1000;
    background: rgba(0,0,0,.5);
    align-items: center;
    justify-content: center;
    flex-direction: column;
    gap: 12px;
}
#divcontent {
    background: #fff;
    border-radius: 8px;
    padding: 24px;
    max-width: 90%;
    max-height: 90%;
    width: auto;
    height: auto;
    overflow-y: auto;
    box-shadow: 0 4px 20px rgba(0,0,0,.2);
}
.popup-close {
    background: none; border: none;
    font-size: 1.2rem; cursor: pointer;
    color: #fff;
    line-height: 1;
}
.popup-close:hover { opacity: .7; }
.copyright::after { font-size:11px;color:#999;content:" Powered by NoDB-Webbase & jSpreadsheet & ECharts"; }
/* ================================
   Responsive
   ================================ */
/* ================================
   Chart App Styles
   ================================ */
.chart-app {
  display: flex;
  flex-direction: column;
  gap: 24px;
}
.chart-section {
  background: var(--bg-white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
}
.section-header { margin-bottom: 16px; }
.section-header h2 { margin: 0 0 4px; font-size: 1.25rem; }
.section-header p { margin: 0; color: var(--text-muted); font-size: 0.9rem; }
.toolbar { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 12px; }
.btn {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 8px 16px; border: none; border-radius: var(--radius);
  font-size: 0.9rem; cursor: pointer; transition: opacity .15s;
}
.btn:hover { opacity: .85; }
.btn-primary { background: var(--primary); color: #fff; }
.btn-outline { background: transparent; color: var(--text); border: 1px solid var(--border); }
.btn-outline:hover { background: var(--primary-light); }
.btn-dark { background: #333; color: #fff; }
.btn-dark:hover { background: #555; }
.btn-danger { color: #e74c3c; border-color: #e74c3c; }
.btn-danger:hover { background: #fde8e8; }

#spreadsheet { width: 100%; overflow-x: auto; margin-bottom: 8px; }
#spreadsheet .jexcel { width: 100%; }
#spreadsheet .jexcel td { min-width: 120px; padding: 8px 6px; white-space: nowrap; }
#spreadsheet .jexcel thead td { padding: 8px 6px; }
#spreadsheet .jexcel thead tr,
#spreadsheet .jexcel tbody tr { height: 36px; }
.chart-controls {
  display: flex; gap: 12px; margin-bottom: 12px;
}
.control-left { flex: 0 0 40%; }
.control-right { flex: 1; display: flex; gap: 12px; }
.control-right .control-row { flex: 1; }
.control-row { display: flex; flex-direction: column; gap: 4px; }
.control-row label { font-size: 0.8rem; color: var(--text-muted); font-weight: 500; }
.control-row select,
.control-row input[type="text"],
.control-row input[type="number"] {
  padding: 6px 10px; border: 1px solid var(--border); border-radius: var(--radius);
  font-size: 0.9rem; background: var(--bg-white); color: var(--text);
}
.control-row select[multiple] { min-height: 80px; max-width: 200px; }
.control-row select[multiple] option { max-width: 180px; overflow: hidden; text-overflow: ellipsis; }
#chartContainer { border: 1px solid var(--border); border-radius: var(--radius); padding: 12px; background: #fafbfc; }
#echart { width: 100%; aspect-ratio: 16 / 9; max-height: 800px; }
#echart.echart-dualring,
#echart.echart-radar,
#echart.echart-funnel { aspect-ratio: 8 / 9; }
.chart-actions { display: flex; align-items: center; gap: 8px; margin-bottom: 12px; }
.chart-arrow { font-size: 20px; padding: 0 4px; }
.chart-status { font-size: 0.95rem; color: #10b981; margin-left: 12px; }
.download-toolbar { display: flex; gap: 8px; flex-wrap: wrap; }

.chart-types-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
  gap: 12px; margin-bottom: 24px;
}
.chart-type-card {
  display: flex; flex-direction: column; align-items: center; gap: 6px;
  padding: 12px; border: 1px solid var(--border); border-radius: var(--radius);
  cursor: default; transition: border-color .15s;
}
.chart-type-card:hover { border-color: var(--primary); }
.chart-type-card span { font-size: 0.8rem; color: var(--text-muted); }
.chart-icon {
  width: 40px; height: 40px; background: var(--primary-light);
  border-radius: 6px; position: relative;
}
.chart-icon::after {
  content: ''; position: absolute; inset: 6px;
  border: 2px solid var(--primary); border-radius: 2px;
}
.chart-icon-spline::after { border: none; border-top: 3px solid var(--primary); border-radius: 0; top: 50%; left: 10%; right: 10%; }
.chart-icon-line::after { border: none; border-top: 2px solid var(--primary); border-radius: 0; top: 50%; left: 10%; right: 10%; }
.chart-icon-column::after { border: none; background: var(--primary); inset: 8px 20px 4px; }
.chart-icon-bar::after { border: none; background: var(--primary); inset: 10px 4px 10px 20px; }
.chart-icon-pie::after { border-radius: 50%; background: conic-gradient(var(--primary) 0% 40%, var(--primary-light) 40% 100%); }
.chart-icon-area::after { border: none; background: var(--primary-light); border-top: 2px solid var(--primary); top: 30%; left: 10%; right: 10%; bottom: 10%; }
.chart-icon-scatter::after { border: none; }
.chart-icon-scatter::before {
  content: '..'; position: absolute; font-size: 20px; font-weight: bold;
  color: var(--primary); letter-spacing: 8px; top: 50%; left: 50%; transform: translate(-50%, -50%);
}

.chart-icon-dualring::after { border: none; border-radius: 50%; background: conic-gradient(var(--primary) 0% 25%, var(--primary-light) 25% 50%, var(--primary) 50% 75%, var(--primary-light) 75% 100%); }
.chart-icon-dualring::before { content: ''; position: absolute; inset: 12px; border-radius: 50%; background: var(--bg-white); z-index: 1; }

.chart-icon-radar::after { border: none; clip-path: polygon(50% 0%, 100% 25%, 100% 75%, 50% 100%, 0% 75%, 0% 25%); background: var(--primary-light); }
.chart-icon-radar::before { content: ''; position: absolute; width: 1px; height: 16px; background: var(--primary); top: 7px; left: 19px; }
.chart-icon-radar div { content: ''; position: absolute; width: 16px; height: 1px; background: var(--primary); top: 19px; left: 7px; }

.chart-icon-heatmap::after { border: none; background: var(--primary-light); inset: 6px; }
.chart-icon-heatmap::before { content: ''; position: absolute; width: 7px; height: 7px; border-radius: 1px; background: var(--primary); top: 9px; left: 9px; box-shadow: 11px 0 0 var(--primary), 0 11px 0 var(--primary), 11px 11px 0 var(--primary); }

.chart-icon-funnel::after { border: none; background: var(--primary); clip-path: polygon(25% 0%, 75% 0%, 100% 100%, 0% 100%); inset: 6px; }

.chart-type-list { display: flex; flex-direction: column; gap: 10px; }
.chart-type-row { display: flex; align-items: center; gap: 16px; padding: 12px 16px; border: 1px solid var(--border); border-radius: var(--radius); transition: border-color .15s; }
.chart-type-row:hover { border-color: var(--primary); }
.chart-type-icon-name { display: flex; flex-direction: column; align-items: center; gap: 4px; min-width: 90px; flex-shrink: 0; }
.chart-type-icon-name span { font-size: 0.8rem; color: var(--text-muted); white-space: nowrap; }
.chart-type-desc { font-size: 0.85rem; color: #333333; line-height: 1.5; }
.toolbar-hint { font-size: 0.75rem; color: #10b981; margin-left: auto; align-self: center; }

.faq-section h3 { margin-bottom: 12px;margin-top: 12px; }
.faq-item { border: 1px solid var(--border); border-radius: var(--radius); margin-bottom: 8px; }
.faq-q {
  padding: 10px 14px; cursor: pointer; font-weight: 500; font-size: 0.9rem;
  position: relative; user-select: none;
}
.faq-q::after { content: '+'; position: absolute; right: 14px; top: 50%; transform: translateY(-50%); font-size: 1.1rem; color: var(--text-muted); }
.faq-a {
  padding: 0 14px; max-height: 0; overflow: hidden; transition: max-height .2s, padding .2s;
  font-size: 0.85rem; color: var(--text-muted); border-top: 0 solid var(--border);
}
.faq-a.open { padding: 10px 14px; max-height: 200px; border-top-width: 1px; }

/* ================================
   share
   ================================ */
.share{display: flex;gap:6px;color:#666666;justify-content: flex-end;line-height:22px;font-size: 14px;margin-top:3px;margin-bottom:10px; float: right;}
.share span {color:#000000;}

.cbuttonf {position: relative;padding: 5px;font-size: 14px;color: #fff;background-color: #1877F2;border: none;border-radius: 5px;cursor: pointer;transition: background-color 0.3s;display: flex;align-items: center;}
.cbuttonf:after {content: "Facebook";}
.cbuttonf:hover {background-color:var(--primary);}

.cbuttont {position: relative;padding: 5px;font-size: 14px;color: #fff;background-color: #000000;border: none;border-radius: 5px;cursor: pointer;transition: background-color 0.3s;display: flex;align-items: center;}
.cbuttont:after {content: "Twitter(X)";}
.cbuttont:hover {background-color: var(--primary);}

.cbuttonr {position: relative;padding: 5px;font-size: 14px;color: #fff;background-color:#FF4500;border: none;border-radius: 5px;cursor: pointer;transition: background-color 0.3s;display: flex;align-items: center;}
.cbuttonr:after {content: "Reddit";}
.cbuttonr:hover {background-color: var(--primary);}

.cbuttonl {position: relative;padding: 5px;font-size: 14px;color: #fff;background-color:#0077B5;border: none;border-radius: 5px;cursor: pointer;transition: background-color 0.3s;display: flex;align-items: center;}
.cbuttonl:after {content: "LinkedIn";}
.cbuttonl:hover {background-color: var(--primary);}


#top_div{ position:fixed; bottom:50px; right:10px; display:none;width:50px;height:53px;z-index:20;  } 

@media (max-width: 768px) {
.path::before { padding:8px;background-color: #ffff00;font-size:16px;color:#ff0033;content:" All features are available on PC only."; }
    .menu-toggle { display: block; }
    .nav-main {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        flex-direction: column;
        background: var(--bg-white);
        border-top: 1px solid var(--border);
        padding: 8px var(--gap);
        z-index: 100;
        flex: none;
    }
    .nav-main.active { display: flex; }
    .nav-main a {
        padding: 10px 0;
        border-bottom: 1px solid var(--border);
        border-radius: 0;
    }
    .nav-main a:last-child { border-bottom: none; }
    .nav-main a.active { color: var(--primary); font-weight: 600; }
    .nav-main a.goto {
        background: #FF783C;
        color: #fff;
        padding: 10px 14px;
        border-radius: var(--radius);
        margin-bottom: 4px;
        border-bottom: none;
    }
.language-switcher {margin-left: auto;}
    .site-container { padding: 16px; }
    main { padding: 16px; }
    .header-inner {
        position: relative;
        justify-content: normal;
    }
    .site-logo {
        position: absolute;
        left: 50%;
        transform: translateX(-50%);
        width: 140px;
    }
    #divcontent { padding: 16px; max-width: 95%; }

    .chart-controls { flex-direction: column; }
    .control-right { flex-direction: column; }
}
.jexcel_about { display: none; }
.jexcel > tbody > tr > td.editor {
  overflow: hidden !important;
  position: relative;
}
.jexcel .editor > input,
.jexcel .editor > textarea {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  padding: 8px 6px;
  box-sizing: border-box;
  resize: none;
}
.jexcel > tbody > tr > td > textarea {
  padding-top: 0 !important;
}
