/* =============================================================================
   Curriculum v2 — Scoped Stylesheet
   All selectors scoped under .cv2 to avoid conflicts with wiki prose styles.

   Referenced by wiki pages via:
     <link rel="stylesheet" href="/api/css/curriculum-v2">

   Editable in the wiki UI at: /wiki/css/curriculum-v2/edit
   ============================================================================= */

@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:wght@400;600;700&family=Source+Sans+Pro:wght@300;400;600;700&display=swap');

/* --- Base / Reset --- */
.cv2 { max-width: 1100px; margin: 0 auto; padding: 0 30px; font-family: 'Source Sans Pro', sans-serif; color: #f5f5f5; line-height: 1.7; font-size: 16px; }
.cv2, .cv2 * { box-sizing: border-box; }
.cv2 p { color: #e0e0e0; line-height: 1.7; margin-bottom: 12px; }
.cv2 a { color: #d4af37 !important; text-decoration: none !important; }
.cv2 a:hover { color: #f0d060 !important; text-decoration: underline !important; }

/* --- Headings --- */
.cv2 h1 { font-family: 'Playfair Display', serif; font-size: 2.6em; font-weight: 700; color: #f5f5f5; margin: 0 0 8px 0; padding: 0; border: none; letter-spacing: 1px; }
.cv2 h2 { font-family: 'Playfair Display', serif; font-size: 1.8em; color: #f5f5f5; margin: 40px 0 20px 0; padding-bottom: 12px; border-bottom: 2px solid #8B0000; }
.cv2 h3 { font-family: 'Playfair Display', serif; font-size: 1.4em; color: #d4af37; margin: 25px 0 15px 0; }
.cv2 h4 { font-size: 1.15em; color: #d4af37; margin: 20px 0 12px 0; font-weight: 600; }

/* --- Subtitle / Tagline --- */
.cv2 .subtitle { font-size: 1.2em; color: #d4af37; font-weight: 300; letter-spacing: 3px; text-transform: uppercase; margin: 0; }
.cv2 .tagline { color: #b0b0b0; margin-top: 10px; font-style: italic; }

/* --- Lists --- */
.cv2 ul, .cv2 ol { margin: 10px 0 10px 20px; padding: 0; }
.cv2 li { margin: 6px 0; color: #b0b0b0; line-height: 1.6; }
.cv2 li strong { color: #f5f5f5; }

/* --- Module Headers (module pages) --- */
.cv2 .module-header { background: linear-gradient(90deg, #8B0000, transparent); padding: 20px 30px; margin: 60px 0 30px 0; border-radius: 5px; }
.cv2 .module-header h2 { margin: 0; padding: 0; border: none; font-size: 1.8em; }

/* --- Cards --- */
.cv2 .card { background: #242424; border-radius: 8px; padding: 25px; margin: 20px 0; border-left: 4px solid #8B0000; box-shadow: 0 4px 15px rgba(0,0,0,0.3); }

/* --- Class Cards (module pages) --- */
.cv2 .class-card { background: #242424; border-radius: 8px; padding: 30px; margin: 30px 0; border: 1px solid #3a3a3a; }
.cv2 .class-header { display: flex; justify-content: space-between; align-items: flex-start; flex-wrap: wrap; margin-bottom: 20px; padding-bottom: 15px; border-bottom: 1px solid #3a3a3a; }
.cv2 .class-title { font-family: 'Playfair Display', serif; font-size: 1.5em; color: #f5f5f5; }
.cv2 .class-meta { color: #b0b0b0; font-size: 0.95em; }
.cv2 .class-meta span { margin-right: 20px; }

/* --- Level Badges --- */
.cv2 .level-badge { display: inline-block; padding: 4px 12px; border-radius: 20px; font-size: 0.85em; font-weight: 600; text-transform: uppercase; letter-spacing: 1px; }
.cv2 .level-beginner { background: #2d5a27; color: #90EE90; }
.cv2 .level-intermediate { background: #5a4a27; color: #FFD700; }
.cv2 .level-advanced { background: #5a2727; color: #FF6B6B; }

/* --- Tables (generic) --- */
.cv2 table { width: 100%; border-collapse: collapse; margin: 20px 0; font-size: 0.95em; }
.cv2 th { background: #0d0d0d; color: #d4af37; padding: 14px 15px; text-align: left; font-weight: 600; text-transform: uppercase; font-size: 0.8em; letter-spacing: 1px; }
.cv2 td { padding: 12px 15px; border-bottom: 1px solid #3a3a3a; color: #e0e0e0; }
.cv2 tr:hover td { background: rgba(139, 0, 0, 0.08); }

/* --- Data Table (class alias) --- */
.cv2 table.data-table { width: 100%; border-collapse: collapse; margin: 20px 0; font-size: 0.95em; }
.cv2 table.data-table th { background: #0d0d0d; color: #d4af37; padding: 14px 15px; text-align: left; font-weight: 600; text-transform: uppercase; font-size: 0.8em; letter-spacing: 1px; }
.cv2 table.data-table td { padding: 12px 15px; border-bottom: 1px solid #3a3a3a; color: #e0e0e0; }
.cv2 table.data-table tr:hover td { background: rgba(139, 0, 0, 0.08); }

/* --- Stats Table (index page) --- */
.cv2 .stats-table { width: 100%; border-collapse: collapse; margin: 25px 0 30px 0; background: #242424; border-radius: 8px; overflow: hidden; }
.cv2 .stats-table td { text-align: center; padding: 18px 12px; border-right: 1px solid #3a3a3a; }
.cv2 .stats-table td:last-child { border-right: none; }
.cv2 .stats-table tr:first-child td { border-top: 3px solid #8B0000; }
.cv2 .stats-number { font-family: 'Playfair Display', serif; font-size: 2em; color: #d4af37; line-height: 1; display: block; }
.cv2 .stats-label { color: #b0b0b0; font-size: 0.85em; display: block; margin-top: 6px; }

/* --- Philosophy Box --- */
.cv2 .philosophy-box { background: linear-gradient(135deg, #242424, #0d0d0d); border: 2px solid #d4af37; border-radius: 10px; padding: 30px; margin: 25px 0; text-align: center; }
.cv2 .philosophy-box h3 { color: #d4af37; margin: 0 0 12px 0; }
.cv2 .philosophy-box p { font-size: 1.1em; color: #e0e0e0; max-width: 800px; margin: 0 auto; }

/* --- Nav Index (index page) --- */
.cv2 .nav-index { background: #242424; border-radius: 10px; padding: 30px; margin: 30px 0; border: 1px solid #3a3a3a; }
.cv2 .nav-index h2 { margin: 0 0 20px 0; padding: 0; border: none; font-size: 1.5em; color: #d4af37; }
.cv2 .nav-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 16px; }
.cv2 .nav-module { background: #0d0d0d; border-radius: 8px; padding: 18px; border-left: 4px solid #8B0000; }
.cv2 .nav-module h3 { margin: 0 0 10px 0; font-size: 1.05em; padding: 0; }
.cv2 .nav-module h3 a { color: #d4af37 !important; text-decoration: none !important; }
.cv2 .nav-module h3 a:hover { color: #f0d060 !important; text-decoration: underline !important; }
.cv2 .nav-module ul { margin: 0; padding: 0; list-style: none; }
.cv2 .nav-module li { margin: 5px 0; font-size: 0.9em; }
.cv2 .nav-module li a { color: #b0b0b0 !important; text-decoration: none !important; }
.cv2 .nav-module li a:hover { color: #ffffff !important; text-decoration: underline !important; }

/* --- Warning Box --- */
.cv2 .warning-box { background: rgba(139, 0, 0, 0.2); border-left: 4px solid #C41E3A; padding: 20px; margin: 20px 0; border-radius: 0 8px 8px 0; }
.cv2 .warning-box::before { content: "\26A0\FE0F "; }

/* --- Activity Block --- */
.cv2 .activity { background: rgba(212, 175, 55, 0.1); border-left: 4px solid #d4af37; padding: 12px 20px; margin: 15px 0; border-radius: 0 8px 8px 0; }

/* --- Breadcrumb (module pages) --- */
.cv2 .breadcrumb { padding: 15px 0; margin-bottom: 20px; font-size: 0.9em; }
.cv2 .breadcrumb a { color: #d4af37 !important; text-decoration: none !important; }
.cv2 .breadcrumb a:hover { color: #C41E3A !important; }
.cv2 .breadcrumb span { color: #b0b0b0; margin: 0 8px; }

/* --- Safety Grid (index page) --- */
.cv2 .safety-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 15px; margin: 20px 0; }
.cv2 .safety-danger { background: #242424; border-radius: 8px; padding: 20px; border-left: 4px solid #cc3333; }
.cv2 .safety-safe { background: #242424; border-radius: 8px; padding: 20px; border-left: 4px solid #4a7c4e; }
.cv2 .safety-danger h4 { color: #cc3333; margin: 0 0 12px 0; }
.cv2 .safety-safe h4 { color: #4a7c4e; margin: 0 0 12px 0; }
.cv2 .safety-danger ul, .cv2 .safety-safe ul { margin: 0; padding: 0 0 0 18px; }

/* --- Emergency card variant --- */
.cv2 .card-emergency { border-left-color: #cc3333; }
.cv2 .card-emergency h4 { color: #cc3333; margin: 0 0 12px 0; }
.cv2 .card-emergency ul { columns: 2; margin: 0; padding: 0 0 0 18px; }

/* --- Videos card variant --- */
.cv2 .card-videos h4 { color: #d4af37; margin: 0 0 12px 0; }
.cv2 .card-videos .note { margin-top: 12px; color: #888; font-style: italic; font-size: 0.9em; }

/* --- Checklist --- */
.cv2 .checklist { list-style: none; margin: 0; }
.cv2 .checklist li { padding: 8px 0 8px 30px; position: relative; border-bottom: 1px solid #3a3a3a; color: #b0b0b0; font-size: 0.95em; }
.cv2 .checklist li:last-child { border-bottom: none; }
.cv2 .checklist li::before { content: "\2610"; position: absolute; left: 0; color: #C41E3A; font-size: 1.1em; }

/* --- Quick Links --- */
.cv2 .quick-links { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 20px; padding-top: 20px; border-top: 1px solid #3a3a3a; }
.cv2 .quick-links a { background: #8B0000 !important; color: white !important; padding: 8px 16px; border-radius: 20px; text-decoration: none !important; font-size: 0.9em; transition: background 0.2s; }
.cv2 .quick-links a:hover { background: #C41E3A !important; }

/* --- Footer (both pages) --- */
.cv2 .cv2-footer { background: #0d0d0d; padding: 25px; text-align: center; margin-top: 50px; border-top: 3px solid #8B0000; border-radius: 0 0 8px 8px; }
.cv2 .cv2-footer p { color: #b0b0b0; font-size: 0.9em; margin: 4px 0; }
.cv2 .cv2-footer a { color: #d4af37 !important; text-decoration: none !important; }
.cv2 .cv2-footer a:hover { color: #C41E3A !important; }
.cv2 footer { background: #0d0d0d; padding: 25px; text-align: center; margin-top: 50px; border-top: 3px solid #8B0000; border-radius: 0 0 8px 8px; }
.cv2 footer p { color: #b0b0b0; font-size: 0.9em; margin: 4px 0; }
.cv2 footer a { color: #d4af37 !important; text-decoration: none !important; }
.cv2 footer a:hover { color: #C41E3A !important; }

/* --- Kink brand logos --- */
.cv2 .kink-brand-header { text-align: center; margin-bottom: 20px; }
.cv2 .kink-brand-header .kink-stacked { max-height: 72px; width: auto; display: block; margin: 0 auto 20px auto; }
.cv2 .kink-module-brand { display: flex; align-items: center; justify-content: center; gap: 20px; flex-wrap: wrap; margin-bottom: 16px; }
.cv2 .kink-module-brand .kink-logomark { height: 48px; width: auto; }
.cv2 .kink-module-brand .kink-side { height: 36px; width: auto; max-width: 200px; }
.cv2 .cv2-footer .kink-logomark-footer { height: 32px; width: auto; opacity: 0.7; vertical-align: middle; margin-right: 8px; }

/* --- Header (module pages use <header>) --- */
.cv2 header { background: linear-gradient(135deg, #0d0d0d, #1a1a1a); border-bottom: 3px solid #8B0000; padding: 40px 0; text-align: center; margin-bottom: 30px; border-radius: 8px 8px 0 0; }

/* --- Responsive --- */
@media (max-width: 768px) {
  .cv2 h1 { font-size: 1.8em; }
  .cv2 { padding: 0 15px; }
  .cv2 .nav-grid { grid-template-columns: 1fr; }
  .cv2 .stats-table td { padding: 12px 6px; }
  .cv2 .stats-number { font-size: 1.4em; }
  .cv2 .safety-grid { grid-template-columns: 1fr; }
  .cv2 .card-emergency ul { columns: 1; }
}

@media print {
  .cv2 { color: black; }
  .cv2 .card, .cv2 table { background: #f9f9f9; border: 1px solid #ccc; }
}
