/* DESN2003 Course Website - Architecture School Aesthetic */

:root {
  --ink: #1a1a1a;
  --ink-light: #4a4a4a;
  --accent: #e07b39;
  --bg-warm: #f7f5f2;
  --bg-card: #ffffff;
  --border: #e5e2dd;
  --page-max-width: 1800px;
  --page-gutter: clamp(1rem, 3vw, 3rem);

  /* Override Quarto width variables */
  --bs-body-width: 100% !important;
}

/* Base */
body {
  background-color: var(--bg-warm);
  -webkit-font-smoothing: antialiased;
}

/* Remove default quarto container constraints for hero */
.page-layout-article .page-columns {
  max-width: 100%;
}

/* Title block - bold architectural statement */
#title-block-header {
  background: #e07b39;
  color: var(--ink);
  padding: 4rem 2rem 3rem;
  margin: 0;
  margin-left: calc(-50vw + 50%);
  margin-right: calc(-50vw + 50%);
  width: 100vw;
  text-align: center;
}

#title-block-header.quarto-title-block {
  margin-bottom: 0;
}

#title-block-header .title {
  font-size: 3rem;
  font-weight: 700;
  letter-spacing: -0.03em;
  margin-bottom: 0.5rem;
  color: var(--ink);
}

#title-block-header .subtitle {
  font-size: 1.1rem;
  font-weight: 400;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  opacity: 0.8;
  color: var(--ink);
}

/* Hero image - full bleed */
.quarto-figure,
main > p:first-of-type {
  margin: 0 -1rem;
  padding: 0;
}

main > p:first-of-type img,
.quarto-figure img {
  width: 100vw;
  max-width: none;
  height: 45vh;
  object-fit: cover;
  display: block;
  margin-left: 50%;
  transform: translateX(-50%);
}

/* Intro text */
main > p:nth-of-type(2) {
  max-width: 100%;
  margin: 3rem auto;
  padding: 0 2rem;
  font-size: 1.25rem;
  line-height: 1.7;
  color: var(--ink-light);
  text-align: center;
}

/* Force Quarto containers to use the available viewport width */
body,
body.nav-fixed,
#quarto-content,
#quarto-content.quarto-container,
.quarto-container,
.page-columns,
.page-rows-contents {
  max-width: 100% !important;
  width: 100% !important;
  margin: 0 auto !important;
  padding-left: 0 !important;
  padding-right: 0 !important;
  box-sizing: border-box;
}

/* Responsive page container that expands with the viewport */
main,
main.content,
main.column-page,
.column-page,
.column-body,
.column-screen-inset,
.page-layout-full main,
.page-layout-full main.content,
.page-layout-full .column-page,
.page-layout-full .column-body {
  max-width: none !important;
  width: min(var(--page-max-width), calc(100vw - (2 * var(--page-gutter)))) !important;
  margin: 0 auto !important;
  padding-left: 0 !important;
  padding-right: 0 !important;
  box-sizing: border-box;
}

/* Tables should use available width */
table {
  width: 100%;
}

/* Callouts should use available width */
.callout {
  max-width: 100% !important;
}

/* Section headings */
h2 {
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--ink);
  margin-top: 3rem;
  margin-bottom: 1.5rem;
  padding-bottom: 1rem;
  border-bottom: 2px solid var(--ink);
}

/* Weekly notes as cards grid */
main > ul {
  list-style: none;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1.25rem;
  margin-bottom: 3rem;
}

main > ul > li {
  background: var(--bg-card);
  border: 1px solid var(--border);
  padding: 1.5rem;
  transition: all 0.2s ease;
  position: relative;
}

main > ul > li:hover {
  border-color: var(--ink);
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(0,0,0,0.08);
}

main > ul > li > a:first-child {
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--ink);
  text-decoration: none;
  display: block;
  margin-bottom: 0.75rem;
}

main > ul > li > a:first-child::before {
  content: "";
  display: block;
  width: 24px;
  height: 3px;
  background: var(--accent);
  margin-bottom: 0.75rem;
}

main > ul > li > a:first-child:hover {
  color: var(--accent);
}

/* Nested resources */
main ul ul {
  margin: 0;
  padding: 0;
  list-style: none;
}

main ul ul li {
  padding: 0.35rem 0;
  border-top: 1px solid var(--border);
}

main ul ul li:first-child {
  margin-top: 0.5rem;
  padding-top: 0.75rem;
}

main ul ul a {
  font-size: 0.85rem;
  color: var(--ink-light);
  text-decoration: none;
}

main ul ul a:hover {
  color: var(--accent);
}

/* Time & Location section */
main > p:last-of-type,
main > p:nth-last-of-type(2),
main > p:nth-last-of-type(3) {
  font-size: 1rem;
  color: var(--ink);
}

main > p strong {
  font-weight: 600;
  color: var(--ink);
}

/* Info block styling */
#time-location + p,
#time-location ~ p {
  background: var(--bg-card);
  border-left: 3px solid var(--accent);
  padding: 1rem 1.5rem;
  margin: 0.5rem 0;
  max-width: 400px;
}

/* Navbar - minimal but present */
.navbar {
  background: var(--bg-warm) !important;
  border-bottom: 1px solid var(--border);
  padding: 1rem 2rem;
}

.navbar-brand {
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--ink) !important;
}

.nav-link {
  color: var(--ink-light) !important;
  font-size: 0.9rem;
}

.nav-link:hover {
  color: var(--ink) !important;
}

/* Footer */
.nav-footer {
  background: var(--ink);
  color: rgba(255,255,255,0.6);
  padding: 2rem;
  text-align: center;
  font-size: 0.85rem;
}

/* Hide TOC on homepage for cleaner look */
#quarto-sidebar,
#TOC {
  display: none;
}

/* Links */
a {
  color: var(--accent);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

/* ==========================================
   Article Pages (Assessment, Writing Samples)
   ========================================== */

/* Add breathing room after header on article pages */
.page-layout-full #title-block-header.quarto-title-block {
  margin-bottom: 3rem;
}

/* Article pages inherit the global responsive width; add vertical breathing room */
.page-layout-full main,
.page-layout-full main.content,
.page-layout-full .column-page {
  padding-bottom: 4rem !important;
}

/* Article headings - slightly larger for readability */
.page-layout-full main h2 {
  font-size: 0.9rem;
  margin-top: 3.5rem;
}

.page-layout-full main h3 {
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--ink);
  margin-top: 2rem;
  margin-bottom: 1rem;
}

/* Blockquotes for sample text */
.page-layout-full blockquote {
  background: var(--bg-card);
  border-left: 3px solid var(--accent);
  margin: 1.5rem 0;
  padding: 1.5rem 2rem;
  font-size: 0.95rem;
  line-height: 1.8;
  color: var(--ink-light);
}

.page-layout-full blockquote h4 {
  font-size: 1rem;
  font-weight: 600;
  color: var(--ink);
  margin-top: 1.5rem;
  margin-bottom: 0.75rem;
}

.page-layout-full blockquote h4:first-child {
  margin-top: 0;
}

/* Custom HTML blocks in assessment page */
.course-info {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  margin: 2rem 0;
}

.course-info-item {
  background: var(--bg-card);
  border: 1px solid var(--border);
  padding: 1.25rem 1.5rem;
  flex: 1 1 140px;
  min-width: 140px;
  text-align: center;
}

.course-info-label {
  display: block;
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--ink-light);
  margin-bottom: 0.5rem;
}

.course-info-value {
  display: block;
  font-size: 1.75rem;
  font-weight: 700;
  color: var(--accent);
}

/* Document progression diagram */
.doc-progression {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  margin: 2rem 0;
}

.doc-step {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 1.25rem 1.5rem;
  background: var(--bg-card);
  border-top: 3px solid var(--accent);
  min-width: 130px;
}

.doc-label {
  display: block;
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--accent);
  font-weight: 700;
  margin-bottom: 0.35rem;
}

.doc-name {
  display: block;
  font-size: 0.875rem;
  color: var(--ink);
  font-weight: 500;
}

.doc-arrow {
  font-size: 1.5rem;
  color: var(--ink-light);
  font-weight: 300;
}

/* Two-column layout for professional discovery */
.two-col {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.5rem;
  margin: 2rem 0;
}

.info-block {
  background: var(--bg-card);
  border: 1px solid var(--border);
  padding: 1.5rem;
}

.info-block h3 {
  font-size: 1rem;
  margin-top: 0;
  margin-bottom: 0.75rem;
  color: var(--ink);
}

.info-block p {
  margin: 0;
  font-size: 0.9rem;
  color: var(--ink-light);
  line-height: 1.6;
}

/* Tables in article pages */
.page-layout-full table {
  width: 100%;
  border-collapse: collapse;
  margin: 1.5rem 0;
  font-size: 0.9rem;
}

.page-layout-full table th,
.page-layout-full table td {
  padding: 0.75rem 1rem;
  border: 1px solid var(--border);
  text-align: left;
}

.page-layout-full table th {
  background: var(--bg-card);
  font-weight: 600;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--ink);
}

.page-layout-full table td {
  background: var(--bg-warm);
}

/* Muted text helper */
.text-muted {
  color: var(--ink-light);
  font-size: 0.9rem;
}

.uppercase {
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

/* Responsive */
@media (max-width: 768px) {
  #title-block-header .title {
    font-size: 2rem;
  }

  main > p:first-of-type img,
  .quarto-figure img {
    height: 35vh;
  }

  main > ul {
    grid-template-columns: 1fr;
  }

  main {
    padding: 0 0 3rem;
  }

  /* Article pages responsive */
  .page-layout-full main {
    padding-bottom: 3rem !important;
  }

  .page-layout-full #title-block-header.quarto-title-block {
    margin-bottom: 2rem;
  }

  .page-layout-full blockquote {
    padding: 1rem 1.25rem;
    margin-left: 0;
    margin-right: 0;
  }

  .course-info-item {
    flex: 1 1 100%;
  }

  .doc-progression {
    flex-direction: column;
    gap: 0.5rem;
  }

  .doc-step {
    min-width: 200px;
    width: 100%;
    max-width: 280px;
  }

  .doc-arrow {
    transform: rotate(90deg);
  }
}
