/* Apple-inspired Design System */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, 'SF Pro Display', 'SF Pro Text', Helvetica, Arial, sans-serif;
  line-height: 1.47059;
  font-weight: 400;
  letter-spacing: -0.022em;
  color: #1d1d1f;
  background: #fbfbfd;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

.container {
  max-width: 980px;
  margin: 0 auto;
  padding: 0 22px;
}

/* Header */
.main-header {
  background: rgba(251, 251, 253, 0.8);
  backdrop-filter: saturate(180%) blur(20px);
  border-bottom: 1px solid rgba(0, 0, 0, 0.08);
  padding: 12px 0;
  position: sticky;
  top: 0;
  z-index: 1000;
}

.header-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 20px;
}

.logo-section {
  display: flex;
  align-items: center;
  gap: 16px;
}

.logo-icon {
  font-size: 28px;
  color: #1d1d1f;
  font-weight: 300;
}

.logo-icon-img {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  object-fit: contain;
}

h1 {
  font-size: 28px;
  font-weight: 600;
  color: #1d1d1f;
  letter-spacing: -0.017em;
  margin: 0;
}

.header-badges {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.badge {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 16px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 500;
  color: #1d1d1f;
  background: rgba(0, 0, 0, 0.04);
  border: none;
  letter-spacing: -0.01em;
}

/* Breadcrumb Navigation */
.breadcrumb-nav {
  background: #f5f5f7;
  padding: 12px 0;
  border-bottom: 1px solid #e5e5e7;
}

.breadcrumb {
  display: flex;
  align-items: center;
  list-style: none;
  margin: 0;
  padding: 0;
  font-size: 14px;
  color: #86868b;
}

.breadcrumb-item {
  display: flex;
  align-items: center;
}

.breadcrumb-item:not(:last-child)::after {
  content: "›";
  margin: 0 8px;
  color: #86868b;
  font-size: 16px;
}

.breadcrumb-item a {
  color: #007aff;
  text-decoration: none;
  transition: color 0.2s ease;
}

.breadcrumb-item a:hover {
  color: #0056cc;
  text-decoration: underline;
}

.breadcrumb-item.active span {
  color: #1d1d1f;
  font-weight: 500;
}

/* Main Content */
.main-content {
  padding: 60px 0 80px;
}

/* Hero Section */
.hero-section {
  text-align: center;
  padding: 60px 0 80px;
  background: linear-gradient(135deg, #fbfbfd 0%, #f5f5f7 100%);
  margin-bottom: 80px;
  border-radius: 18px;
}

.hero-title {
  font-size: 56px;
  font-weight: 600;
  color: #1d1d1f;
  letter-spacing: -0.025em;
  margin-bottom: 8px;
  line-height: 1.07143;
}

.hero-subtitle {
  font-size: 28px;
  font-weight: 400;
  color: #1d1d1f;
  letter-spacing: -0.017em;
  margin-bottom: 12px;
  line-height: 1.14286;
}

.hero-description {
  font-size: 21px;
  font-weight: 400;
  color: #86868b;
  letter-spacing: 0.011em;
  line-height: 1.381;
  max-width: 600px;
  margin: 0 auto;
}

/* Cards */
.card {
  background: #fff;
  border-radius: 18px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
  margin-bottom: 40px;
  overflow: hidden;
  transition: all 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.card:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.12);
}

.card-header {
  background: #fff;
  padding: 30px 40px 20px;
  border-bottom: 1px solid rgba(0, 0, 0, 0.06);
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 20px;
}

.card-header h2 {
  font-size: 24px;
  font-weight: 600;
  color: #1d1d1f;
  letter-spacing: -0.017em;
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 0;
  line-height: 1.16667;
}

.card-header i {
  font-size: 20px;
  color: #007aff;
}

.card-body {
  padding: 30px 40px 40px;
}

/* Buttons */
.section-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 24px;
  border: none;
  border-radius: 980px;
  font-size: 17px;
  font-weight: 400;
  letter-spacing: -0.022em;
  text-decoration: none;
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
  white-space: nowrap;
  min-height: 44px;
}

.btn:hover {
  transform: scale(1.02);
}

.btn-primary {
  background: #007aff;
  color: #fff;
}

.btn-primary:hover {
  background: #0051d5;
  box-shadow: 0 4px 16px rgba(0, 122, 255, 0.3);
}

.btn-outline {
  background: transparent;
  color: #007aff;
  border: 1px solid rgba(0, 122, 255, 0.3);
}

.btn-outline:hover {
  background: rgba(0, 122, 255, 0.08);
  border-color: #007aff;
}

/* Instructions */
.input-instructions, .output-info {
  margin-bottom: 24px;
  padding: 20px 24px;
  background: #f5f5f7;
  border-radius: 12px;
  border: none;
}

.instruction {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  color: #86868b;
  font-size: 17px;
  letter-spacing: -0.022em;
  line-height: 1.47059;
}

.instruction i {
  color: #007aff;
  margin-top: 2px;
  font-size: 16px;
}

/* Areas */
.areas {
  position: relative;
  width: 100%;
  height: 400px;
  margin-bottom: 24px;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
  background: #fff;
}

.json textarea,
.json pre,
.csv textarea,
.csv .table,
.json .drop {
  width: 100%;
  height: 100%;
  position: absolute;
  top: 0;
  left: 0;
}

/* Textareas */
.json-textarea, .csv-textarea {
  border: none;
  padding: 24px;
  font-family: 'SF Mono', Monaco, 'Cascadia Code', 'Roboto Mono', Consolas, monospace;
  font-size: 14px;
  line-height: 1.42857;
  resize: none;
  outline: none;
  background: #fff;
  color: #1d1d1f;
  letter-spacing: 0;
}

.json-textarea:focus {
  box-shadow: 0 0 0 4px rgba(0, 122, 255, 0.15);
}

.csv-textarea {
  background: #f5f5f7;
  color: #86868b;
}

/* Code highlighting */
.json pre {
  padding: 24px;
  background: #f5f5f7;
  cursor: pointer;
  overflow: auto;
  font-family: 'SF Mono', Monaco, 'Cascadia Code', 'Roboto Mono', Consolas, monospace;
  font-size: 14px;
  line-height: 1.42857;
  color: #1d1d1f;
  transition: background-color 0.3s ease;
}

.json pre:hover {
  background: #ebebed;
}

/* Drop zone */
.json .drop {
  background: rgba(0, 122, 255, 0.06);
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  color: #007aff;
  font-size: 17px;
  font-weight: 400;
  z-index: 100;
  border: 2px dashed rgba(0, 122, 255, 0.3);
  margin: 20px;
  border-radius: 12px;
  height: calc(100% - 40px);
  width: calc(100% - 40px);
  letter-spacing: -0.022em;
}

.json .drop i {
  font-size: 48px;
  margin-bottom: 16px;
  opacity: 0.8;
}

/* Visibility states */
.json textarea { display: block; }
.json .rendered { display: none; }
.json .drop { display: none; }
.csv .rendered { display: none; }

/* Controls */
.json-controls {
  display: flex;
  gap: 24px;
  margin-bottom: 24px;
  flex-wrap: wrap;
}

.separator-control {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.separator-control label {
  font-weight: 500;
  color: #1d1d1f;
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 17px;
  letter-spacing: -0.022em;
}

.form-select {
  padding: 12px 16px;
  border: 1px solid rgba(0, 0, 0, 0.1);
  border-radius: 8px;
  font-size: 17px;
  background: #fff;
  color: #1d1d1f;
  cursor: pointer;
  font-family: inherit;
  letter-spacing: -0.022em;
  transition: all 0.3s ease;
}

.form-select:focus {
  outline: none;
  border-color: #007aff;
  box-shadow: 0 0 0 4px rgba(0, 122, 255, 0.15);
}

/* Alerts */
.status-messages {
  margin-top: 24px;
}

.alert {
  padding: 16px 20px;
  border-radius: 12px;
  margin-bottom: 16px;
  display: flex;
  align-items: flex-start;
  gap: 12px;
  font-size: 17px;
  letter-spacing: -0.022em;
  line-height: 1.47059;
}

.alert-info {
  background: rgba(0, 122, 255, 0.08);
  color: #1d1d1f;
  border: 1px solid rgba(0, 122, 255, 0.2);
}

.alert-danger {
  background: rgba(255, 59, 48, 0.08);
  color: #1d1d1f;
  border: 1px solid rgba(255, 59, 48, 0.2);
}

.alert a {
  color: #007aff;
  font-weight: 400;
  text-decoration: none;
}

.alert a:hover {
  text-decoration: underline;
}

/* CSV Table */
.table-container {
  overflow-x: auto;
  border-radius: 12px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
  background: #fff;
}

.csv-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 17px;
  background: #fff;
  letter-spacing: -0.022em;
}

.csv-table th,
.csv-table td {
  padding: 16px 20px;
  text-align: left;
  border-bottom: 1px solid rgba(0, 0, 0, 0.06);
  max-width: 200px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  line-height: 1.47059;
}

.csv-table th {
  background: #f5f5f7;
  font-weight: 600;
  color: #1d1d1f;
  border-bottom: 1px solid rgba(0, 0, 0, 0.1);
}

.csv-table tbody tr:hover {
  background: rgba(0, 0, 0, 0.02);
}

/* Features Section */
.features-section {
  margin: 80px 0;
}

.features-title {
  text-align: center;
  font-size: 40px;
  font-weight: 600;
  color: #1d1d1f;
  letter-spacing: -0.022em;
  margin-bottom: 60px;
  line-height: 1.1;
}

.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 40px;
}

.feature-card {
  background: #fff;
  padding: 40px 32px;
  border-radius: 18px;
  text-align: center;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
  transition: all 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.feature-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.12);
}

.feature-icon {
  width: 64px;
  height: 64px;
  margin: 0 auto 24px;
  background: linear-gradient(135deg, #007aff, #5ac8fa);
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 28px;
  color: #fff;
}

.feature-card h3 {
  font-size: 24px;
  font-weight: 600;
  color: #1d1d1f;
  margin-bottom: 12px;
  letter-spacing: -0.017em;
  line-height: 1.16667;
}

.feature-card p {
  color: #86868b;
  font-size: 17px;
  line-height: 1.47059;
  letter-spacing: -0.022em;
}

/* Footer */
.main-footer {
  background: #f5f5f7;
  border-top: 1px solid rgba(0, 0, 0, 0.06);
  padding: 40px 0;
  margin-top: 80px;
}

.footer-content {
  text-align: center;
}

.footer-info p {
  color: #86868b;
  margin-bottom: 12px;
  font-size: 17px;
  letter-spacing: -0.022em;
  line-height: 1.47059;
}

.footer-info a {
  color: #007aff;
  text-decoration: none;
  font-weight: 400;
}

.footer-info a:hover {
  text-decoration: underline;
}

.footer-info i {
  color: #ff3b30;
  margin-right: 6px;
}

/* FAQ Section */
.faq-section {
  margin: 80px 0;
}

.faq-title {
  text-align: center;
  font-size: 40px;
  font-weight: 600;
  color: #1d1d1f;
  letter-spacing: -0.022em;
  margin-bottom: 60px;
  line-height: 1.1;
}

.faq-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
  gap: 30px;
}

.faq-item {
  background: #fff;
  padding: 32px;
  border-radius: 18px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
  transition: all 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.faq-item:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.12);
}

.faq-item h3 {
  font-size: 20px;
  font-weight: 600;
  color: #1d1d1f;
  margin-bottom: 16px;
  letter-spacing: -0.017em;
  line-height: 1.2;
}

.faq-item p {
  color: #86868b;
  font-size: 17px;
  line-height: 1.47059;
  letter-spacing: -0.022em;
  margin: 0;
}

/* Utility classes */
.show-render-all {
  display: none;
}

.console {
  margin-bottom: 10px;
  font-size: 80%;
  display: none;
}

.console.in-use {
  background: #f5f5f7;
}

.console.error {
  color: #ff3b30;
}

/* Responsive Design */
@media (max-width: 1068px) {
  .container {
    padding: 0 22px;
  }
  
  .hero-title {
    font-size: 48px;
  }
  
  .hero-subtitle {
    font-size: 24px;
  }
  
  .hero-description {
    font-size: 19px;
  }
}

@media (max-width: 734px) {
  .container {
    padding: 0 16px;
  }
  
  .main-content {
    padding: 40px 0 60px;
  }
  
  .hero-section {
    padding: 40px 0 60px;
    margin-bottom: 60px;
  }
  
  .hero-title {
    font-size: 32px;
  }
  
  .hero-subtitle {
    font-size: 21px;
  }
  
  .hero-description {
    font-size: 17px;
  }
  
  h1 {
    font-size: 24px;
  }
  
  .header-content {
    flex-direction: column;
    text-align: center;
  }
  
  .card-header {
    flex-direction: column;
    align-items: flex-start;
    padding: 24px 24px 16px;
  }
  
  .card-body {
    padding: 24px;
  }
  
  .section-actions {
    width: 100%;
    justify-content: flex-start;
  }
  
  .areas {
    height: 320px;
  }
  
  .json-controls {
    flex-direction: column;
  }
  
  .features-grid {
    grid-template-columns: 1fr;
    gap: 32px;
  }
  
  .features-title {
    font-size: 32px;
    margin-bottom: 40px;
  }
  
  .feature-card {
    padding: 32px 24px;
  }
  
  .faq-title {
    font-size: 32px;
    margin-bottom: 40px;
  }
  
  .faq-grid {
    grid-template-columns: 1fr;
    gap: 24px;
  }
  
  .faq-item {
    padding: 24px;
  }
  
  .faq-item h3 {
    font-size: 18px;
  }
  
  .faq-item p {
    font-size: 16px;
  }
}

/* How to Use Section */
.how-to-section {
  margin: 80px 0;
}

.how-to-title {
  text-align: center;
  font-size: 40px;
  font-weight: 600;
  color: #1d1d1f;
  letter-spacing: -0.022em;
  margin-bottom: 60px;
  line-height: 1.1;
}

.steps-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 40px;
}

.step-item {
  background: #fff;
  padding: 40px 32px;
  border-radius: 18px;
  text-align: center;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
  transition: all 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
  position: relative;
}

.step-item:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.12);
}

.step-number {
  width: 60px;
  height: 60px;
  margin: 0 auto 24px;
  background: linear-gradient(135deg, #007aff, #5ac8fa);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  font-weight: 600;
  color: #fff;
}

.step-item h3 {
  font-size: 24px;
  font-weight: 600;
  color: #1d1d1f;
  margin-bottom: 16px;
  letter-spacing: -0.017em;
  line-height: 1.16667;
}

.step-item p {
  color: #86868b;
  font-size: 17px;
  line-height: 1.47059;
  letter-spacing: -0.022em;
}

/* Use Cases Section */
.use-cases-section {
  margin: 80px 0;
  background: #f5f5f7;
  padding: 80px 0;
  border-radius: 18px;
}

.use-cases-title {
  text-align: center;
  font-size: 40px;
  font-weight: 600;
  color: #1d1d1f;
  letter-spacing: -0.022em;
  margin-bottom: 60px;
  line-height: 1.1;
}

.use-cases-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 30px;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 40px;
}

.use-case-item {
  background: #fff;
  padding: 32px;
  border-radius: 18px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
  transition: all 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.use-case-item:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.12);
}

.use-case-item h3 {
  font-size: 20px;
  font-weight: 600;
  color: #1d1d1f;
  margin-bottom: 16px;
  letter-spacing: -0.017em;
  line-height: 1.2;
  display: flex;
  align-items: center;
  gap: 12px;
}

.use-case-item h3 i {
  color: #007aff;
  font-size: 18px;
}

.use-case-item p {
  color: #86868b;
  font-size: 17px;
  line-height: 1.47059;
  letter-spacing: -0.022em;
  margin: 0;
}

/* Info Section */
.info-section {
  margin: 80px 0;
  background: #fff;
  padding: 80px 0;
  border-radius: 18px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
}

.info-content {
  max-width: 800px;
  margin: 0 auto;
  padding: 0 40px;
}

.info-content h2 {
  text-align: center;
  font-size: 40px;
  font-weight: 600;
  color: #1d1d1f;
  letter-spacing: -0.022em;
  margin-bottom: 40px;
  line-height: 1.1;
}

.info-text p {
  color: #1d1d1f;
  font-size: 19px;
  line-height: 1.52632;
  letter-spacing: -0.022em;
  margin-bottom: 24px;
}

.info-text p:last-child {
  margin-bottom: 0;
}

.info-text strong {
  font-weight: 600;
  color: #1d1d1f;
}

@media (max-width: 734px) {
  .how-to-title {
    font-size: 32px;
    margin-bottom: 40px;
  }
  
  .steps-grid {
    grid-template-columns: 1fr;
    gap: 30px;
  }
  
  .step-item {
    padding: 32px 24px;
  }
  
  .step-item h3 {
    font-size: 20px;
  }
  
  .step-item p {
    font-size: 16px;
  }
  
  .use-cases-title {
    font-size: 32px;
    margin-bottom: 40px;
  }
  
  .use-cases-grid {
    grid-template-columns: 1fr;
    gap: 24px;
    padding: 0 20px;
  }
  
  .use-case-item {
    padding: 24px;
  }
  
  .use-case-item h3 {
    font-size: 18px;
  }
  
  .use-case-item p {
    font-size: 16px;
  }
  
  .info-content {
    padding: 0 20px;
  }
  
  .info-content h2 {
    font-size: 32px;
    margin-bottom: 30px;
  }
  
  .info-text p {
    font-size: 17px;
  }
}

@media (max-width: 480px) {
  .areas {
    height: 280px;
  }
  
  .json-textarea, .csv-textarea {
    padding: 16px;
    font-size: 14px;
  }
  
  .json pre {
    padding: 16px;
    font-size: 14px;
  }
  
  .btn {
    padding: 10px 20px;
    font-size: 16px;
  }
}

/* Highlight.js override */
.hljs {
  background-color: #f5f5f7 !important;
  padding: 24px !important;
  border-radius: 12px !important;
  font-family: 'SF Mono', Monaco, 'Cascadia Code', 'Roboto Mono', Consolas, monospace !important;
}