:root {
  --primary-color: #007bff;
  --secondary-color: #6c757d;
  --success-color: #28a745;
  --warning-color: #ffc107;
  --danger-color: #dc3545;
  --light-bg: #f8f9fa;
  --white: #fff;
  --text-dark: #333;
  --text-light: #6c757d;
  --border-radius: 12px;
  --shadow: 0 4px 20px rgba(0,0,0,0.1);
  --transition: all 0.3s ease;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
}

.page-wrapper {
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
  padding: 20px;
  color: var(--text-dark);
  line-height: 1.6;
}

.main-container {
  max-width: 900px;
  margin: auto;
  background: var(--white);
  padding: 30px;
  border-radius: var(--border-radius);
  box-shadow: var(--shadow);
}

.main-title {
  text-align: center;
  color: var(--primary-color);
  margin-bottom: 30px;
  font-size: 28px;
  font-weight: 300;
  letter-spacing: 1px;
}

.textarea-wrapper { 
  position: relative; 
  margin-bottom: 20px;
}

.highlight-layer, .input-textarea {
  font-family: inherit;
  font-size: 16px;
  line-height: 1.6;
  letter-spacing: 0;
  white-space: pre-wrap;
  word-wrap: break-word;
  overflow-wrap: break-word;
}

.highlight-layer {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  color: transparent;
  padding: 16px;
  pointer-events: none;
  border-radius: var(--border-radius);
  border: 2px solid #e9ecef;
}

.input-textarea {
  width: 100%;
  height: 280px;
  padding: 16px;
  border: 2px solid #e9ecef;
  border-radius: var(--border-radius);
  background: var(--white);
  resize: vertical;
  outline: none;
  transition: var(--transition);
  box-shadow: inset 0 2px 4px rgba(0,0,0,0.05);
}

.input-textarea:focus {
  border-color: var(--primary-color);
  box-shadow: 0 0 0 0.2rem rgba(0,123,255,.25);
}

.wrong-word { 
  text-decoration: underline wavy var(--danger-color); 
  position: relative;
  cursor: help;
}

.wrong-word:hover::after {
  content: attr(data-tooltip);
  position: absolute;
  bottom: 100%;
  left: 50%;
  transform: translateX(-50%);
  background: var(--danger-color);
  color: var(--white);
  padding: 4px 8px;
  border-radius: 4px;
  font-size: 12px;
  white-space: nowrap;
  z-index: 10;
  margin-bottom: 2px;
}

.button-controls { 
  margin: 20px 0;
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  justify-content: center;
}

.btn {
  padding: 12px 20px;
  background: var(--primary-color);
  border: 0;
  color: var(--white);
  border-radius: 8px;
  cursor: pointer;
  font-size: 14px;
  font-weight: 500;
  display: flex;
  align-items: center;
  gap: 8px;
  transition: var(--transition);
  box-shadow: 0 2px 8px rgba(0,123,255,0.2);
}

.btn:hover {
  background: #0056b3;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0,123,255,0.3);
}

.btn:active {
  transform: translateY(0);
}

.stats-display { 
  margin: 20px 0;
  font-size: 18px;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 15px;
  flex-wrap: wrap;
  justify-content: center;
  background: var(--light-bg);
  padding: 15px;
  border-radius: var(--border-radius);
}

.stats-item {
  display: flex;
  align-items: center;
  gap: 5px;
  color: var(--text-light);
}

.stats-item strong {
  color: var(--text-dark);
}

.progress-circle {
  width: 70px;
  height: 70px;
  border-radius: 50%;
  background: conic-gradient(var(--primary-color) 0deg, var(--primary-color) 0deg, #e9ecef 0deg);
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  flex-shrink: 0;
  box-shadow: var(--shadow);
  transition: var(--transition);
}

.progress-circle::after {
  content: attr(data-percent);
  background: var(--white);
  width: 50px;
  height: 50px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  color: var(--primary-color);
  font-weight: bold;
  z-index: 2;
  box-shadow: 0 0 0 3px var(--white);
  border: 2px solid #f8f9fa;
}

.progress-circle.low { 
  box-shadow: 0 4px 20px rgba(40,167,69,0.3); 
  --primary-color: var(--success-color);
}

.progress-circle.low::after { color: var(--success-color); }

.progress-circle.medium { 
  box-shadow: 0 4px 20px rgba(255,193,7,0.3); 
  --primary-color: var(--warning-color);
}

.progress-circle.medium::after { color: var(--warning-color); }

.progress-circle.high { 
  box-shadow: 0 4px 20px rgba(220,53,69,0.3); 
  --primary-color: var(--danger-color);
}

.progress-circle.high::after { color: var(--danger-color); }

.suggestions-box { 
  margin-top: 20px;
  background: var(--light-bg);
  padding: 20px;
  border-radius: var(--border-radius);
  max-height: 200px;
  overflow-y: auto;
  border: 1px solid #e9ecef;
  box-shadow: inset 0 2px 4px rgba(0,0,0,0.05);
}

.suggestions-box.empty {
  text-align: center;
  color: var(--text-light);
  font-style: italic;
}

.suggestions-box div { 
  margin-bottom: 12px; 
  padding: 12px; 
  background: var(--white); 
  border-radius: 8px; 
  border-left: 4px solid var(--primary-color);
  box-shadow: 0 2px 4px rgba(0,0,0,0.05);
  transition: var(--transition);
}

.suggestions-box div:hover {
  transform: translateX(2px);
  box-shadow: 0 4px 8px rgba(0,0,0,0.1);
}

.suggestions-box strong { 
  color: var(--danger-color); 
  margin-right: 10px; 
  font-size: 16px;
}

.sug {
  display: inline-block;
  padding: 6px 12px;
  margin: 4px;
  background: #e3f2fd;
  border: 1px solid #bbdefb;
  border-radius: 20px;
  cursor: pointer;
  color: var(--primary-color);
  font-size: 14px;
  font-weight: 500;
  transition: var(--transition);
  box-shadow: 0 1px 3px rgba(0,123,255,0.1);
}

.sug:hover {
  background: #bbdefb;
  color: #0056b3;
  transform: translateY(-1px) scale(1.05);
  box-shadow: 0 3px 6px rgba(0,123,255,0.2);
}

.loading-indicator {
  display: inline-block;
  width: 24px;
  height: 24px;
  border: 3px solid #f3f3f3;
  border-top: 3px solid var(--primary-color);
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

.usage-guide {
  margin-top: 30px;
  padding: 20px;
  background: var(--light-bg);
  border-radius: var(--border-radius);
  border-left: 4px solid var(--primary-color);
}

.usage-guide h3 {
  color: var(--primary-color);
  margin-bottom: 15px;
  font-size: 20px;
  font-weight: 500;
}

.usage-guide p {
  color: var(--text-dark);
  margin-bottom: 10px;
  line-height: 1.7;
}

.usage-guide ul {
  color: var(--text-light);
  padding-left: 20px;
}

.usage-guide li {
  margin-bottom: 8px;
  color: var(--text-dark);
}

@media (max-width: 768px) {
  .main-container {
    padding: 20px;
    margin: 10px;
  }
  
  .button-controls {
    justify-content: center;
  }
  
  .btn {
    padding: 10px 16px;
    font-size: 13px;
  }
  
  .stats-display {
    font-size: 16px;
    gap: 10px;
  }
  
  .progress-circle {
    width: 60px;
    height: 60px;
  }
  
  .progress-circle::after {
    width: 40px;
    height: 40px;
    font-size: 14px;
  }
  
  .input-textarea {
    height: 200px;
    font-size: 14px;
  }
  
  .usage-guide {
    padding: 15px;
  }
}
  .spc99_container {
            font-family: 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
            line-height: 1.8;
            color: #333;
            max-width: 900px;
            margin: 20px auto;
            padding: 40px;
            border: 1px solid #eee;
            border-radius: 15px;
            background-color: #ffffff;
            box-shadow: 0 10px 30px rgba(0,0,0,0.05);
        }
        .spc99_h1 {
            color: #1a237e;
            font-size: 32px;
            text-align: center;
            margin-bottom: 25px;
            font-weight: 800;
        }
        .spc99_intro_p {
            font-size: 1.1em;
            margin-bottom: 20px;
        }
        .spc99_h2 {
            color: #0d47a1;
            font-size: 24px;
            margin-top: 35px;
            margin-bottom: 15px;
            border-left: 6px solid #2196f3;
            padding-left: 15px;
        }
        .spc99_feature_list, .spc99_step_list, .spc99_user_list {
            list-style: none;
            padding: 0;
        }
        .spc99_feature_list li, .spc99_step_list li, .spc99_user_list li {
            background: #f8f9fa;
            margin-bottom: 15px;
            padding: 20px;
            border-radius: 10px;
            border: 1px solid #eceff1;
        }
        .spc99_feature_list li strong, .spc99_step_list li strong, .spc99_user_list li strong {
            color: #1565c0;
            display: block;
            font-size: 1.1em;
            margin-bottom: 5px;
        }
        .spc99_red_highlight {
            color: #d32f2f;
            font-weight: bold;
            text-decoration: underline;
        }
        .spc99_faq_section {
            background: #e3f2fd;
            padding: 25px;
            border-radius: 12px;
            margin-top: 40px;
        }
        .spc99_faq_item {
            margin-bottom: 20px;
            border-bottom: 1px solid #bbdefb;
            padding-bottom: 10px;
        }
        .spc99_faq_q {
            font-weight: bold;
            color: #0d47a1;
            font-size: 1.1em;
        }
        .spc99_faq_a {
            margin-top: 5px;
            color: #444;
        }
        .spc99_footer_cta {
            text-align: center;
            margin-top: 40px;
            padding: 30px;
            background: linear-gradient(135deg, #1e3c72 0%, #2a5298 100%);
            color: white;
            border-radius: 12px;
            font-size: 1.2em;
        }