/**
Theme Name: Pratham Child
Author: Mukesh K
Author URI: http://missionpratham.com/author/mukesh/
Description: Child theme for Mission Pratham website—custom Study Material layouts, ACF UI & advanced styling.
Version: 1.0.0
Text Domain: pratham-child
Template: astra
*/

/* --------------------------------------------
   SINGLE STUDY MATERIAL PAGE (sm- classes)
---------------------------------------------*/

/* Main wrapper */
.sm-wrapper {
    max-width: 980px;
    margin: 0 auto;
    padding: 24px 16px 60px;
    font-family: system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
}

/* ================= META STRIP ================= */

.sm-meta-strip {
    display: flex;
    flex-wrap: wrap;
    gap: 10px 18px;
    padding: 12px 18px;
    margin: 12px 0 18px;
    border-radius: 12px;
    background: #f8fafc;
    align-items: center;
}

/* Each meta item (Subject / Class pill) */
.sm-meta-item {
    display: inline-flex;
    align-items: center;
    gap: 8px;                /* icon ↔ text */
    padding: 6px 10px;
    background: #f3f4f6;
    border: 0.5px solid #e5e7eb;
    border-radius: 8px;
    color: #374151;
    font-size: 0.95rem;
    width: fit-content;
    box-sizing: border-box;
}

/* Icon */
.sm-meta-icon img,
.sm-meta-icon svg {
    width: 16px;
    height: 16px;
    display: inline-block;
    object-fit: contain;
    flex-shrink: 0;
}

/* Label + value */
.sm-meta-label {
    margin: 0;
    font-weight: 600;
    color: #4b5563;
    line-height: 1;
}

.sm-meta-value {
    margin-left: 4px;        /* “Subject:” & value ke beech chhota gap */
    font-weight: 700;
    color: #111827;
    line-height: 1;
}

/* Optional colored variants (agar PHP me class add karo) */
.sm-meta-item.subject { color: #0ea5a4; }
.sm-meta-item.class   { color: #1d4ed8; }

/* ================= CARDS / CONTENT ================= */

.sm-card {
    background:#f9fafb;
    border-radius:14px;
    padding:20px 22px;
    margin-bottom:18px;
}

.sm-card-title {
    font-size:1.15rem;
    font-weight:700;
    margin-bottom:10px;
    color:#111827;
}

.sm-card-body {
    font-size:0.96rem;
    color:#111827;
}

/* ================= VIDEO ================= */

.sm-video-inner {
    position:relative;
    padding-bottom:56.25%;
    height:0;
    overflow:hidden;
    border-radius:12px;
    background:#000;
    margin-bottom:12px;
}

.sm-video-inner iframe {
    position:absolute;
    inset:0;
    width:100%;
    height:100%;
    border:0;
}

/* ================= PDF PREVIEW (old iframe style – plugin ke pehle) ================= */

.sm-pdf-preview {
    border-radius:12px;
    overflow:hidden;
    background:#e5e7eb;
    height:480px;
    max-height:65vh;
}

.sm-pdf-preview iframe {
    width:100%;
    height:100%;
    border:0;
}

/* ================= DOWNLOAD SECTION LAYOUT ================= */

.sm-card-download {
    display:flex;
    align-items:center;
    justify-content:space-between;
    gap:16px;
}

.sm-file-label {
    font-size:0.85rem;
    color:#6b7280;
}

.sm-file-name  {
    font-size:1rem;
    font-weight:600;
    color:#111827;
}

/* ================= CHAPTER LIST ================= */

.sm-chapter-list {
    list-style:none;
    padding:0;
    margin:0;
}

.sm-chapter-list li {
    margin-bottom:8px;
}

.sm-chapter-list a {
    color:#2563eb;
    text-decoration:none;
}

.sm-chapter-list a:hover {
    text-decoration:underline;
}

/* ================= FAQ ================= */

.sm-faq-list {
    display:flex;
    flex-direction:column;
    gap:8px;
}

.sm-faq-item {
    border-radius:10px;
    border:1px solid #e5e7eb;
    padding:10px 12px;
    background:#fff;
}

.sm-faq-item[open] {
    background:#f9fafb;
}

.sm-faq-question {
    cursor:pointer;
    font-weight:600;
}

.sm-faq-answer {
    margin-top:8px;
    color:#374151;
}

/* ================= COURSES ================= */

.sm-course-grid {
    display:grid;
    grid-template-columns:repeat(3,1fr);
    gap:14px;
}

.sm-course-card {
    background:#fff;
    border:1px solid #e5e7eb;
    padding:10px;
    border-radius:12px;
    display:flex;
    flex-direction:column;
    gap:8px;
}

.sm-course-thumb img {
    width:100%;
    border-radius:8px;
    display:block;
}

.sm-course-title {
    font-size:0.95rem;
    font-weight:600;
    margin:0;
}

.sm-course-excerpt {
    font-size:0.85rem;
    color:#4b5563;
    flex:1;
}

.sm-btn-course {
    background:#2563eb;
    color:#fff;
    padding:8px 12px;
    border-radius:8px;
    text-decoration:none;
}

/* ================= RESPONSIVE ================= */

@media (max-width: 768px) {
    .sm-wrapper       { padding:16px 12px 40px; }
    .sm-card-download { flex-direction:column; align-items:flex-start; gap:8px; }
    .sm-course-grid   { grid-template-columns:1fr; }
}

@media (max-width: 720px) {
    .sm-meta-strip { gap:8px; padding:10px; }
    .sm-page-title { font-size: 22px; }
}

/* ================= MIXED TITLE (for cards etc.) ================= */

.mixed-title {
    font-family: "DM Sans", Arial, sans-serif;
}

.mixed-title .hindi {
    font-family: "Anek Devanagari", sans-serif;
}

/* ================= BREADCRUMBS ================= */

.sm-breadcrumbs {
    font-size: 0.95rem;
    color: #6b7280;
    margin-top: 8px;
}

.sm-breadcrumbs a {
    color: #2563eb;
    text-decoration:none;
}

.sm-breadcrumbs a:hover {
    text-decoration: underline;
}

/* ================= DOWNLOAD BUTTON (single page) ================= */

.sm-btn {
    display:inline-flex;
    align-items:center;
    justify-content:center;
    gap:8px;
    padding: 10px 18px;
    border-radius: 10px;
    font-weight:600;
    text-decoration:none;
    border: 1px solid rgba(0,0,0,0.06);
    transition: background-color .18s ease, color .18s ease,
                transform .12s ease, box-shadow .18s ease;
}

/* default state: blue button, white text */
.sm-btn-download {
    background: #1d4ed8;
    color: #ffffff;
    box-shadow: 0 8px 20px rgba(29,78,216,0.12);
}

/* icon inside download button – SVG uses currentColor */
.sm-download-icon {
    width: 18px;
    height: 18px;
    display: inline-block;
    flex-shrink: 0;
    fill: currentColor;
}

/* hover: yellow bg, blue text, icon follows same blue */
.sm-btn-download:hover,
.sm-btn-download:focus {
    background: #facc15 !important;
    color: #1d4ed8 !important;
    transform: translateY(-2px);
    box-shadow: 0 10px 26px rgba(250,204,21,0.18);
}

/* FILE INFO section */
.sm-file-info {
    display:flex;
    align-items:center;
    gap:10px;
}

/* ================= FONT OVERRIDES ================= */

/* Full single study material page = Anek Devanagari */
.single-study_material .sm-wrapper,
.single-study_material .sm-wrapper * {
    font-family: "Anek Devanagari", sans-serif !important;
}

/* BUT: Subject / Class meta pills = DM Sans (clean, compact) */
.single-study_material .sm-meta-item,
.single-study_material .sm-meta-item * {
    font-family: "DM Sans", sans-serif !important;
}
/* ✅ Download button font = DM Sans */
.single-study_material .sm-btn-download,
.single-study_material .sm-btn-download * {
    font-family: "DM Sans", sans-serif !important;
}