/* Shared stylesheet for Cordova to React Native tutorial chapters */
:root {
  --react: #087ea4;
  --react-cyan: #61DAFB;
  --react-dark: #005670;
  --react-light: rgba(97, 218, 251, 0.08);
  --cordova: #E8A838;
  --cordova-light: rgba(232, 168, 56, 0.08);
}

/* Layout */
.tutorial-layout { display: grid; grid-template-columns: 260px 1fr; gap: 0; min-height: calc(100vh - 72px); }
@media (max-width: 991px) { .tutorial-layout { grid-template-columns: 1fr; } }

/* Sidebar */
.tutorial-sidebar { background: #f8fafc; border-right: 1px solid #e2e8f0; padding: 28px 0; position: sticky; top: 72px; height: calc(100vh - 72px); overflow-y: auto; }
@media (max-width: 991px) { .tutorial-sidebar { position: static; height: auto; border-right: none; border-bottom: 1px solid #e2e8f0; padding: 16px 0; } }
.sidebar-title { font-size: 0.72rem; font-weight: 800; color: #94a3b8; text-transform: uppercase; letter-spacing: 0.08em; padding: 0 20px 12px; }
.sidebar-link { display: flex; align-items: center; gap: 12px; padding: 10px 20px; font-size: 0.85rem; font-weight: 500; color: #64748b; text-decoration: none; border-left: 3px solid transparent; transition: all 0.15s; }
.sidebar-link:hover { color: var(--react); background: var(--react-light); text-decoration: none; }
.sidebar-link.active { color: var(--react); font-weight: 700; border-left-color: var(--react); background: var(--react-light); }
.sidebar-link.done { color: #16a34a; }
.sidebar-ch-num { width: 24px; height: 24px; border-radius: 6px; background: #e2e8f0; color: #64748b; display: flex; align-items: center; justify-content: center; font-size: 0.72rem; font-weight: 800; flex-shrink: 0; }
.sidebar-link.active .sidebar-ch-num { background: var(--react); color: white; }
.sidebar-link.done .sidebar-ch-num { background: #dcfce7; color: #16a34a; }

/* Content */
.tutorial-content { padding: 40px 48px; max-width: 900px; }
@media (max-width: 767px) { .tutorial-content { padding: 24px 16px; } }

/* Code comparison grid */
.compare-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
@media (max-width: 767px) { .compare-grid { grid-template-columns: 1fr; } }
.code-panel { border-radius: 12px; overflow: hidden; }
.code-panel-header { padding: 10px 16px; font-size: 0.78rem; font-weight: 700; display: flex; align-items: center; gap: 8px; }
.cordova-header { background: #1a1a1a; color: #E8A838; }
.rn-header { background: #1a1a1a; color: #61DAFB; }
.code-panel pre[class*="language-"] { margin: 0; border-radius: 0; font-size: 0.82rem; }

/* Callout boxes */
.callout { border-radius: 12px; padding: 16px 20px; margin: 20px 0; }
.callout-rn { background: var(--react-light); border-left: 4px solid var(--react); }
.callout-tip { background: #f0fdf4; border-left: 4px solid #22c55e; }
.callout-warning { background: #fff7ed; border-left: 4px solid #f97316; }
.callout-cordova { background: var(--cordova-light); border-left: 4px solid var(--cordova); }
.callout-title { font-weight: 700; font-size: 0.85rem; margin-bottom: 4px; }

/* Chapter navigation */
.chapter-nav { border-top: 1px solid #e2e8f0; margin-top: 48px; padding-top: 24px; display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.nav-btn { display: flex; align-items: center; gap: 10px; padding: 14px 20px; border-radius: 12px; border: 2px solid #e2e8f0; text-decoration: none; color: #1e293b; font-weight: 600; font-size: 0.88rem; transition: all 0.2s; }
.nav-btn:hover { border-color: var(--react); color: var(--react); text-decoration: none; }
.nav-btn-next { background: var(--react); border-color: var(--react); color: white; }
.nav-btn-next:hover { background: var(--react-dark); border-color: var(--react-dark); color: white; }

/* Comparison table */
.compare-table th { font-weight: 700; font-size: 0.82rem; }
.compare-table .cordova-col { background: var(--cordova-light); }
.compare-table .rn-col { background: var(--react-light); }

/* Mark done button */
.done-btn { background: none; border: 2px solid #e2e8f0; border-radius: 50rem; padding: 8px 20px; font-size: 0.85rem; font-weight: 600; cursor: pointer; transition: all 0.2s; color: #64748b; }
.done-btn.marked { background: #dcfce7; border-color: #22c55e; color: #16a34a; }
.done-btn:hover:not(.marked) { border-color: #22c55e; color: #16a34a; }

/* Inline code */
code:not([class]) { background: #f1f5f9; padding: 2px 6px; border-radius: 4px; font-size: 0.85em; color: var(--react); font-family: 'JetBrains Mono', monospace; }

/* Badge pills */
.tech-badge { display: inline-flex; align-items: center; gap: 5px; padding: 4px 12px; border-radius: 50rem; font-size: 0.78rem; font-weight: 700; }
.badge-cordova { background: var(--cordova-light); color: #92400e; border: 1px solid rgba(232,168,56,0.3); }
.badge-rn { background: var(--react-light); color: #0369a1; border: 1px solid rgba(97,218,251,0.4); }
