/* ============================================================
   ORNATE BORDER FRAME
   ============================================================ */
.ornate-frame {
  position: relative;
  border: 2px solid var(--gold-dark);
  padding: 40px;
  background: rgba(240,230,208,0.5);
}

/* Double border effect */
.ornate-frame::before {
  content: '';
  position: absolute;
  top: 6px; left: 6px; right: 6px; bottom: 6px;
  border: 1px solid var(--gold-mid);
  pointer-events: none;
}

/* Corner rosettes */
.ornate-frame .corner {
  position: absolute;
  width: 28px;
  height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  color: var(--gold-dark);
  z-index: 2;
}
.ornate-frame .corner::after {
  content: '\2E19'; /* leaf ornament */
  text-shadow: 0 0 4px rgba(201,168,76,0.4);
}
.ornate-frame .corner-tl { top: -4px; left: -4px; }
.ornate-frame .corner-tr { top: -4px; right: -4px; }
.ornate-frame .corner-bl { bottom: -4px; left: -4px; }
.ornate-frame .corner-br { bottom: -4px; right: -4px; }

.ornate-frame-wide {
  padding: 50px 60px;
}

/* ============================================================
   ORNAMENTAL DIVIDERS
   ============================================================ */
.ornament-divider {
  text-align: center;
  margin: 32px 0;
  font-size: 18px;
  color: var(--gold-dark);
  letter-spacing: 6px;
  user-select: none;
}
.ornament-divider::before {
  content: '\2500\2500\2500 \2767 \2E19 \2767 \2500\2500\2500';
}

.ornament-divider-sm {
  text-align: center;
  margin: 20px 0;
  font-size: 14px;
  color: var(--gold-mid);
  user-select: none;
}
.ornament-divider-sm::before {
  content: '\2500\2500 \2726 \2500\2500';
  letter-spacing: 4px;
}

/* ============================================================
   ILLUMINATED CAPITALS
   ============================================================ */
.illuminated-heading {
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 28px;
  color: var(--parchment-light);
  margin-bottom: 8px;
  line-height: 1.3;
}

.page-subtitle {
  font-family: var(--font-body);
  font-size: 15px;
  color: var(--gold-dark);
  opacity: 0.8;
  margin: 0 0 0 0;
  letter-spacing: 0.5px;
  font-style: italic;
}

.illuminated-heading .drop-cap {
  float: left;
  font-family: var(--font-display);
  font-size: 72px;
  line-height: 0.8;
  padding: 4px 12px 4px 0;
  color: var(--gold-dark);
  font-weight: 700;
  position: relative;
  margin-right: 4px;
}

/* Drop cap with decorative frame */
.drop-cap-framed {
  float: left;
  font-family: var(--font-display);
  font-size: 88px;
  line-height: 0.85;
  color: var(--gold-dark);
  font-weight: 900;
  position: relative;
  margin: 0 16px 8px 0;
  width: 100px;
  height: 100px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, var(--deep-blue) 0%, #1a304a 100%);
  border: 3px solid var(--gold-dark);
  box-shadow: inset 0 0 20px rgba(201,168,76,0.15), 0 2px 8px rgba(0,0,0,0.2);
}
.drop-cap-framed::before {
  content: '';
  position: absolute;
  top: 4px; left: 4px; right: 4px; bottom: 4px;
  border: 1px solid var(--gold-mid);
  opacity: 0.6;
}
.drop-cap-framed::after {
  content: '\2766';
  position: absolute;
  bottom: -10px;
  right: -10px;
  font-size: 16px;
  color: var(--gold-dark);
  opacity: 0.7;
}

/* Smaller illuminated cap for entry headings */
.small-illuminated {
  font-family: var(--font-display);
  font-size: 36px;
  color: var(--gold-dark);
  font-weight: 700;
  float: left;
  line-height: 1;
  margin-right: 4px;
  padding: 2px 6px;
  background: var(--deep-blue);
  border: 2px solid var(--gold-dark);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  box-shadow: 0 1px 4px rgba(0,0,0,0.15);
  position: relative;
}
.small-illuminated::before {
  content: '';
  position: absolute;
  top: 2px; left: 2px; right: 2px; bottom: 2px;
  border: 1px solid rgba(201,168,76,0.4);
}

/* ============================================================
   VINE DECORATIONS
   ============================================================ */
.vine-margin {
  position: relative;
  padding-left: 36px;
}
.vine-margin::before {
  content: '\2767\a\2E19\a\2766\a\2767\a\2E19\a\2766\a\2767\a\2E19\a\2766';
  white-space: pre;
  position: absolute;
  left: 4px;
  top: 0;
  font-size: 14px;
  color: var(--gold-dark);
  opacity: 0.35;
  line-height: 2.4;
  letter-spacing: 0;
}

.vine-horizontal {
  display: flex;
  align-items: center;
  gap: 6px;
  color: var(--gold-dark);
  font-size: 12px;
  opacity: 0.5;
  user-select: none;
  margin: 8px 0;
  white-space: nowrap;
  overflow: hidden;
}
.vine-horizontal::before {
  content: '\2767 \2E19 \2766 \2767 \2E19 \2766 \2767 \2E19 \2766 \2767 \2E19 \2766 \2767 \2E19 \2766 \2767 \2E19 \2766 \2767 \2E19 \2766 \2767 \2E19 \2766';
}

/* Gold vine border bottom (used on nav) */
.vine-border-bottom {
  position: relative;
}
.vine-border-bottom::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 12px;
  mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='60' height='12' viewBox='0 0 60 12'%3E%3Cpath d='M0,6 Q10,0 15,6 Q20,12 30,6 Q40,0 45,6 Q50,12 60,6' fill='none' stroke='black' stroke-width='4'/%3E%3C/svg%3E");
  -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='60' height='12' viewBox='0 0 60 12'%3E%3Cpath d='M0,6 Q10,0 15,6 Q20,12 30,6 Q40,0 45,6 Q50,12 60,6' fill='none' stroke='black' stroke-width='4'/%3E%3C/svg%3E");
  mask-repeat: repeat-x;
  -webkit-mask-repeat: repeat-x;
  background: linear-gradient(90deg, var(--gold-dark), var(--gold-mid), var(--gold-dark));
}

/* ============================================================
   MANUSCRIPT BORDER BAND
   ============================================================ */
.ms-band {
  text-align: center;
  padding: 8px 0;
  font-size: 12px;
  color: var(--gold-dark);
  opacity: 0.3;
  user-select: none;
  letter-spacing: 4px;
  overflow: hidden;
  white-space: nowrap;
}
.ms-band::before {
  content: '\2767 \2E19 \2726 \2767 \2E19 \2726 \2767 \2E19 \2726 \2767 \2E19 \2726 \2767 \2E19 \2726 \2767 \2E19 \2726 \2767 \2E19 \2726 \2767 \2E19 \2726';
}

/* ============================================================
   PROJECT TAGS
   ============================================================ */
.project-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.project-tag {
  font-family: var(--font-heading);
  font-size: 11px;
  color: var(--rubric-red);
  border: 1px solid var(--rubric-red);
  padding: 3px 10px;
  letter-spacing: 0.5px;
  font-weight: 600;
  position: relative;
  background: rgba(201,168,76,0.06);
}
.project-tag::before {
  content: '\3014';
  margin-right: 2px;
  opacity: 0.4;
}
.project-tag::after {
  content: '\3015';
  margin-left: 2px;
  opacity: 0.4;
}

/* ============================================================
   INTEREST BADGES
   ============================================================ */
.interest-badge {
  font-family: var(--font-heading);
  font-size: 13px;
  color: var(--deep-blue);
  border: 2px solid var(--gold-dark);
  border-radius: 50px;
  padding: 8px 20px;
  font-weight: 600;
  letter-spacing: 0.5px;
  position: relative;
  background: rgba(240,230,208,0.3);
}
.interest-badge::before {
  content: '';
  position: absolute;
  top: 3px; left: 3px; right: 3px; bottom: 3px;
  border: 1px solid rgba(201,168,76,0.3);
  border-radius: 50px;
  pointer-events: none;
}

/* ============================================================
   MARGIN SPOT ILLUSTRATIONS
   ============================================================ */
.spot-ms {
  position: absolute;
  pointer-events: none;
  user-select: none;
  opacity: 0.1;
  font-size: 28px;
}
.spot-ms.vine { color: var(--forest-green); }
.spot-ms.vine::before { content: '\2766'; }
.spot-ms.floral { color: var(--forest-green); }
.spot-ms.floral::before { content: '\2E19'; }
.spot-ms.leaf { color: var(--forest-green); }
.spot-ms.leaf::before { content: '\2767'; }
.spot-ms.star { color: var(--gold-dark); }
.spot-ms.star::before { content: '\2726'; }

/* ============================================================
   DECORATIVE PAGE CORNERS
   ============================================================ */
.page-corners {
  position: relative;
}
.page-corners::before,
.page-corners::after {
  position: fixed;
  font-size: 40px;
  color: var(--gold-dark);
  opacity: 0.12;
  pointer-events: none;
  z-index: 0;
}
.page-corners::before {
  content: '\2766';
  top: 80px;
  left: 12px;
}
.page-corners::after {
  content: '\2767';
  bottom: 20px;
  right: 16px;
}
