<template>
  <div class="section-wrapper">
    <div class="section-header">
      <div class="section-title">{{ title }}</div>
      <div class="section-header-right">
        <slot name="header-right"></slot>
      </div>
    </div>
    <div class="section-body">
      <slot></slot>
    </div>
  </div>
</template>

<script>
export default {
  name: 'SectionTitle',
  props: {
    title: {
      type: String,
      default: ''
    }
  }
}
</script>

<style lang="scss" scoped>
.section-wrapper {
  background: rgba(45, 42, 85, 0.9);
  border-radius: 24rpx;
  padding: 32rpx;
  margin-bottom: 32rpx;
  box-shadow: 0 8rpx 30rpx rgba(0, 0, 0, 0.2);
}

.section-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 24rpx;
}

.section-title {
  font-size: 28rpx;
  font-weight: 500;
  color: #A78BFA;
}



.section-header-right {
  font-size: 24rpx;
  color: rgba(255, 255, 255, 0.5);
}
</style>