/* Footer tidy-up (17 Oct, owner approved; compacted twice the same day because the first passes were too tall).
   Loaded by includes/footer.php right before <footer>, after every other stylesheet.
   "footer " prefix beats the older footer rules in base/footer.css, bba/footer.css and pages/mba.css without !important.
   Desktop: 5 exam columns + one info row (Know Us / Tools / Contact / Centres), 14px links.
   Phones: every group is an accordion (<details>), 44px tap targets. */

footer .footer-inner{max-width:1240px}

/* "On this page" row (only on pages that pass $footer_course_title) */
footer .footer-onpage{display:flex;flex-wrap:wrap;align-items:center;gap:4px 28px;border-top:1px solid var(--edge);padding:18px 0}
footer .footer-onpage .footer-course-col-title{margin:0}
footer .footer-onpage .footer-course-links{flex-direction:row;flex-wrap:wrap;gap:0 26px}

/* Exam link groups: 5 columns */
footer .footer-course-grid{display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:28px 28px;border-top:1px solid var(--edge);padding-top:28px;margin-bottom:24px}
footer .footer-onpage + .footer-course-grid{margin-top:0}
footer .footer-col{display:flex;flex-direction:column;gap:22px;min-width:0}
footer .footer-acc summary{display:block;list-style:none;cursor:default}
footer .footer-acc summary::-webkit-details-marker{display:none}
footer .footer-course-col-title,
footer .footer-4col-title{font-size:12px;font-weight:800;letter-spacing:.09em;text-transform:uppercase;color:#fff;margin-bottom:12px}
footer .footer-acc summary.footer-course-col-title,
footer .footer-acc summary.footer-4col-title{margin-bottom:10px}
footer .footer-course-links{display:flex;flex-direction:column;gap:0}
footer .footer-course-links a,
footer .footer-4col-links a{font-size:14px;line-height:1.4;min-height:28px}

/* Coaching Locations: one slim strip, 13px links */
footer .footer-locations{border-top:1px solid var(--edge);padding:16px 0 12px}
footer .footer-locations .footer-course-col-title{margin-bottom:6px}
footer .footer-locations .footer-course-links{flex-direction:row;flex-wrap:wrap;gap:0 14px}
footer .footer-locations .footer-course-links a{font-size:13px;min-height:26px}

/* Guide link + small "PYQ" link on one line inside the exam columns (no extra height) */
footer .footer-pair{display:flex;align-items:center;gap:10px;min-width:0}
footer .footer-pair a + a{font-size:11.5px;font-weight:700;letter-spacing:.04em;color:var(--ember2);padding:1px 7px;border:1px solid var(--edge);border-radius:100px;min-height:0;line-height:1.5}
footer .footer-pair a + a:hover{border-color:var(--ember2)}

/* Know Us / Tools / Contact / Centres */
footer .footer-4col-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:24px 28px;border-top:1px solid var(--edge);padding-top:28px;margin-bottom:22px}
footer .footer-4col-links{gap:0}
footer .footer-contact-item{font-size:14px;line-height:1.55;margin-bottom:8px}
footer .footer-contact-note{font-size:12.5px;color:var(--dim);margin-top:-4px}

/* Bottom bar: copyright | social | developer */
footer .footer-bottom{border-top:1px solid var(--edge);padding-top:18px;display:flex;flex-wrap:wrap;align-items:center;justify-content:space-between;gap:12px 24px}
footer .footer-blog-social{display:flex;gap:10px;margin:0}
footer .footer-blog-social a{width:34px;height:34px;font-size:12px;font-weight:700}

@media(max-width:960px){
  footer .footer-course-grid{grid-template-columns:repeat(3,minmax(0,1fr))}
}
@media(max-width:820px){
  footer .footer-4col-grid{grid-template-columns:repeat(2,minmax(0,1fr))}
}

/* Phones: accordion groups, one column, 44px tap targets */
@media(max-width:700px){
  footer{padding:32px 0 20px}
  footer .footer-inner{padding:0 20px}
  footer .footer-onpage{padding:14px 0}
  footer .footer-onpage .footer-course-col-title{width:100%;margin-bottom:4px}
  footer .footer-onpage .footer-course-links{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:0 16px;width:100%}
  footer .footer-course-grid,
  footer .footer-4col-grid{grid-template-columns:1fr;gap:0;padding-top:0;margin-bottom:0;border-top:1px solid var(--edge)}
  footer .footer-col{gap:0}
  footer .footer-locations{padding:0}
  footer .footer-acc{border-bottom:1px solid var(--edge)}
  footer .footer-acc summary,
  footer .footer-acc summary.footer-course-col-title,
  footer .footer-acc summary.footer-4col-title{display:flex;align-items:center;justify-content:space-between;min-height:48px;margin:0;cursor:pointer}
  footer .footer-acc summary::after{content:"";width:8px;height:8px;border-right:2px solid var(--muted);border-bottom:2px solid var(--muted);transform:rotate(45deg);transition:transform .2s;margin-right:4px;flex:none}
  footer .footer-acc[open] summary::after{transform:rotate(-135deg)}
  footer .footer-acc .footer-course-links,
  footer .footer-acc .footer-4col-links{padding-bottom:10px}
  footer .footer-acc .footer-contact-item:last-child{padding-bottom:10px}
  footer .footer-locations .footer-course-links{flex-direction:column;gap:0}
  footer .footer-course-links a,
  footer .footer-4col-links a,
  footer .footer-contact-item a{min-height:44px}
  footer .footer-bottom{flex-direction:column;align-items:flex-start;gap:14px;border-top:0;padding-top:20px}}

/* 30 Oct 2026 spacing pass (owner: footer too tight). Same links, same fonts and colours, same structure; only: more air between groups and links,
   MBA list in two inner columns so no column is much taller than its neighbours, Study Abroad moved under SSC (balance), and Coaching Locations
   as an even grid (5 x 2 on desktop, 2 columns on tablet) instead of a wrapped row with a ragged last line. Tablet / desktop only: phones keep the accordion above. */
@media(min-width:701px){
  footer{padding:56px 0 28px}
  footer .footer-course-grid{gap:40px 40px;padding-top:36px;margin-bottom:34px}
  footer .footer-col{gap:32px}
  footer .footer-course-col-title,
  footer .footer-4col-title{margin-bottom:16px}
  footer .footer-acc summary.footer-course-col-title,
  footer .footer-acc summary.footer-4col-title{margin-bottom:14px}
  footer .footer-course-links a,
  footer .footer-4col-links a{min-height:32px;line-height:1.45}
  footer .footer-pair{min-height:32px}
  footer .footer-locations{padding:30px 0 28px}
  footer .footer-locations .footer-course-links{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:2px 36px}
  footer .footer-locations .footer-course-links a{font-size:13.5px;min-height:34px}
  footer .footer-4col-grid{gap:30px 40px;padding-top:34px;margin-bottom:30px}
  footer .footer-contact-item{margin-bottom:10px;line-height:1.65}
  footer .footer-bottom{padding-top:24px;gap:14px 24px}
}
@media(min-width:701px) and (max-width:1099px){
  footer .footer-course-links a,footer .footer-4col-links a,footer .footer-pair{min-height:28px}
  footer .footer-locations .footer-course-links a{min-height:30px}
  footer .footer-course-grid{gap:30px 32px;padding-top:30px;margin-bottom:26px}
  footer .footer-col{gap:24px}
  footer .footer-locations{padding:24px 0 22px}
  footer .footer-4col-grid{gap:24px 32px;padding-top:28px;margin-bottom:24px}
  footer .footer-course-grid{grid-template-columns:repeat(3,minmax(0,1fr))}
  footer .footer-col:first-child{grid-column:span 2}
  footer .footer-col:first-child .footer-course-links{display:grid;grid-template-columns:1fr 1fr;column-gap:28px}
}
@media(min-width:1100px){
  footer .footer-course-grid{grid-template-columns:1.9fr 1fr 1fr 1.1fr 1.1fr;gap:40px 36px}
  footer .footer-col:first-child .footer-course-links{display:grid;grid-template-columns:1fr 1fr;column-gap:24px}
  footer .footer-locations .footer-course-links{grid-template-columns:repeat(5,minmax(0,1fr));gap:2px 18px}
  footer .footer-locations .footer-course-links a{font-size:13px}
}
