커뮤니티 - 스타일 변경

This commit is contained in:
현성필
2025-11-05 17:13:09 +09:00
parent edb40d4a0f
commit 5168347f11
16 changed files with 4583 additions and 439 deletions
@@ -0,0 +1,351 @@
// -----------------------------------------------------------------------------
// Accordion Component - FAQ and Collapsible Sections
// -----------------------------------------------------------------------------
// FAQ Accordion
.faq-accordion {
background: $white;
border-radius: $border-radius-lg;
box-shadow: $shadow-sm;
overflow: hidden;
.faq-item {
border-bottom: 1px solid $border-gray;
transition: $transition-base;
&:last-child {
border-bottom: none;
}
&.active {
background: rgba($primary-blue, 0.02);
.faq-question {
color: $primary-blue;
&::before {
background: $gradient-primary;
}
.faq-icon {
transform: rotate(180deg);
color: $primary-blue;
}
}
}
}
.faq-question {
display: flex;
align-items: center;
justify-content: space-between;
padding: $spacing-lg $spacing-xl;
font-size: $font-size-base;
font-weight: $font-weight-medium;
color: $text-dark;
cursor: pointer;
transition: $transition-base;
position: relative;
gap: $spacing-md;
@media (max-width: $breakpoint-sm) {
padding: $spacing-md $spacing-lg;
font-size: $font-size-sm;
}
&::before {
content: 'Q';
position: absolute;
left: $spacing-xl;
top: 50%;
transform: translateY(-50%);
width: 32px;
height: 32px;
display: flex;
align-items: center;
justify-content: center;
background: $light-bg;
color: $primary-blue;
border-radius: $border-radius-circle;
font-size: $font-size-sm;
font-weight: $font-weight-bold;
transition: $transition-base;
@media (max-width: $breakpoint-sm) {
width: 28px;
height: 28px;
font-size: $font-size-xs;
}
}
&:hover {
background: rgba($primary-blue, 0.03);
color: $primary-blue;
}
.faq-question-text {
flex: 1;
padding-left: 48px;
line-height: $line-height-normal;
@media (max-width: $breakpoint-sm) {
padding-left: 40px;
}
}
.faq-icon {
flex-shrink: 0;
font-size: 20px;
color: $text-gray;
transition: $transition-base;
@media (max-width: $breakpoint-sm) {
font-size: 18px;
}
}
}
.faq-answer {
display: none;
padding: 0 $spacing-xl $spacing-lg;
margin-left: 48px;
margin-right: $spacing-xl;
position: relative;
@media (max-width: $breakpoint-sm) {
padding: 0 $spacing-lg $spacing-md;
margin-left: 40px;
margin-right: $spacing-lg;
}
&::before {
content: 'A';
position: absolute;
left: -48px;
top: 8px;
width: 32px;
height: 32px;
display: flex;
align-items: center;
justify-content: center;
background: $gradient-primary;
color: $white;
border-radius: $border-radius-circle;
font-size: $font-size-sm;
font-weight: $font-weight-bold;
@media (max-width: $breakpoint-sm) {
left: -40px;
width: 28px;
height: 28px;
font-size: $font-size-xs;
}
}
&.show {
display: block;
animation: slideDown 0.3s ease;
}
.faq-answer-content {
padding: $spacing-md 0;
font-size: $font-size-sm;
color: $text-gray;
line-height: $line-height-loose;
@media (max-width: $breakpoint-sm) {
font-size: $font-size-xs;
padding: $spacing-sm 0;
}
// Content formatting
p {
margin-bottom: $spacing-md;
&:last-child {
margin-bottom: 0;
}
}
ul, ol {
margin: $spacing-sm 0;
padding-left: $spacing-lg;
}
li {
margin-bottom: $spacing-xs;
}
a {
color: $primary-blue;
text-decoration: underline;
&:hover {
color: $secondary-blue;
}
}
code {
background: $gray-bg;
padding: 2px 6px;
border-radius: $border-radius-sm;
font-family: $font-family-mono;
font-size: 0.9em;
color: $primary-blue;
}
pre {
background: $gray-bg;
border: 1px solid $border-gray;
border-radius: $border-radius-md;
padding: $spacing-md;
overflow-x: auto;
margin: $spacing-md 0;
code {
background: transparent;
padding: 0;
color: $text-dark;
}
}
}
}
}
// FAQ Page specific styles
.faq-page {
min-height: calc(100vh - 140px);
background: $gray-bg;
padding: $spacing-3xl $spacing-lg;
@media (max-width: $breakpoint-sm) {
padding: $spacing-2xl $spacing-md;
}
}
.faq-container {
max-width: $container-max-width;
margin: 0 auto;
}
.faq-header {
margin-bottom: $spacing-3xl;
@media (max-width: $breakpoint-sm) {
margin-bottom: $spacing-2xl;
}
.page-title {
font-size: $font-size-3xl;
font-weight: $font-weight-bold;
color: $text-dark;
margin-bottom: $spacing-md;
background: $gradient-primary;
-webkit-background-clip: text;
-webkit-text-fill-color: transparent;
background-clip: text;
@media (max-width: $breakpoint-sm) {
font-size: $font-size-2xl;
}
}
.page-description {
font-size: $font-size-base;
color: $text-gray;
line-height: $line-height-normal;
@media (max-width: $breakpoint-sm) {
font-size: $font-size-sm;
}
}
}
// Slide down animation
@keyframes slideDown {
from {
opacity: 0;
transform: translateY(-10px);
}
to {
opacity: 1;
transform: translateY(0);
}
}
// Generic accordion (for reuse)
.accordion {
background: $white;
border-radius: $border-radius-lg;
box-shadow: $shadow-sm;
overflow: hidden;
.accordion-item {
border-bottom: 1px solid $border-gray;
&:last-child {
border-bottom: none;
}
&.active {
.accordion-header {
background: rgba($primary-blue, 0.03);
color: $primary-blue;
.accordion-icon {
transform: rotate(180deg);
}
}
}
}
.accordion-header {
display: flex;
align-items: center;
justify-content: space-between;
padding: $spacing-lg $spacing-xl;
font-size: $font-size-base;
font-weight: $font-weight-medium;
color: $text-dark;
cursor: pointer;
transition: $transition-base;
@media (max-width: $breakpoint-sm) {
padding: $spacing-md $spacing-lg;
font-size: $font-size-sm;
}
&:hover {
background: rgba($primary-blue, 0.02);
}
.accordion-title {
flex: 1;
}
.accordion-icon {
flex-shrink: 0;
font-size: 20px;
color: $text-gray;
transition: $transition-base;
}
}
.accordion-content {
display: none;
padding: $spacing-lg $spacing-xl;
font-size: $font-size-sm;
color: $text-gray;
line-height: $line-height-normal;
border-top: 1px solid $border-gray;
@media (max-width: $breakpoint-sm) {
padding: $spacing-md $spacing-lg;
}
&.show {
display: block;
animation: slideDown 0.3s ease;
}
}
}
@@ -0,0 +1,361 @@
// -----------------------------------------------------------------------------
// Table Component Styles - Reusable table designs
// -----------------------------------------------------------------------------
// Base table styles
.data-table {
width: 100%;
background: $white;
border-radius: $border-radius-lg;
overflow: hidden;
box-shadow: $shadow-sm;
// Table wrapper for responsive scrolling
&-wrapper {
overflow-x: auto;
margin-bottom: $spacing-xl;
@media (max-width: $breakpoint-sm) {
border-radius: $border-radius-lg;
box-shadow: $shadow-sm;
}
}
table {
width: 100%;
border-collapse: collapse;
thead {
background: $light-bg;
tr {
border-bottom: 2px solid $border-gray;
}
th {
padding: $spacing-md $spacing-lg;
text-align: left;
font-size: $font-size-sm;
font-weight: $font-weight-semibold;
color: $text-dark;
white-space: nowrap;
@media (max-width: $breakpoint-sm) {
padding: $spacing-sm $spacing-md;
font-size: $font-size-xs;
}
}
}
tbody {
tr {
border-bottom: 1px solid $border-gray;
transition: $transition-base;
&:last-child {
border-bottom: none;
}
&:hover {
background-color: rgba($primary-blue, 0.02);
}
}
td {
padding: $spacing-md $spacing-lg;
font-size: $font-size-sm;
color: $text-gray;
@media (max-width: $breakpoint-sm) {
padding: $spacing-sm $spacing-md;
font-size: $font-size-xs;
}
a {
color: $text-dark;
text-decoration: none;
transition: $transition-base;
&:hover {
color: $primary-blue;
}
}
}
}
}
}
// Notice board table (list view with columns)
.notice-table {
width: 100%;
background: $white;
border-radius: $border-radius-lg;
overflow: hidden;
box-shadow: $shadow-sm;
&-wrapper {
overflow-x: auto;
@media (max-width: $breakpoint-sm) {
border-radius: 0;
box-shadow: none;
}
}
// Table header
.table-header {
display: grid;
grid-template-columns: 80px 1fr 120px;
gap: $spacing-md;
padding: $spacing-md $spacing-lg;
background: $light-bg;
border-bottom: 2px solid $border-gray;
font-size: $font-size-sm;
font-weight: $font-weight-semibold;
color: $text-dark;
@media (max-width: $breakpoint-md) {
grid-template-columns: 60px 1fr 100px;
padding: $spacing-sm $spacing-md;
font-size: $font-size-xs;
}
@media (max-width: $breakpoint-sm) {
display: none; // Hide header on mobile
}
.col-num {
text-align: center;
}
.col-title {
text-align: left;
}
.col-date {
text-align: center;
}
}
// Table rows
.table-row {
display: grid;
grid-template-columns: 80px 1fr 120px;
gap: $spacing-md;
padding: $spacing-lg;
border-bottom: 1px solid $border-gray;
transition: $transition-base;
cursor: pointer;
@media (max-width: $breakpoint-md) {
grid-template-columns: 60px 1fr 100px;
padding: $spacing-md;
}
@media (max-width: $breakpoint-sm) {
grid-template-columns: 1fr;
gap: $spacing-sm;
padding: $spacing-md;
}
&:last-child {
border-bottom: none;
}
&:hover {
background-color: rgba($primary-blue, 0.02);
}
.col-num {
display: flex;
align-items: center;
justify-content: center;
font-size: $font-size-sm;
color: $text-gray;
font-weight: $font-weight-medium;
@media (max-width: $breakpoint-sm) {
display: none;
}
}
.col-title {
display: flex;
align-items: center;
font-size: $font-size-base;
color: $text-dark;
font-weight: $font-weight-medium;
@media (max-width: $breakpoint-sm) {
font-size: $font-size-sm;
}
a {
color: inherit;
text-decoration: none;
display: flex;
align-items: center;
gap: $spacing-sm;
transition: $transition-base;
&:hover {
color: $primary-blue;
}
}
.file-icon {
display: inline-flex;
align-items: center;
margin-left: $spacing-sm;
opacity: 0.6;
img {
width: 16px;
height: 16px;
}
}
}
.col-date {
display: flex;
align-items: center;
justify-content: center;
font-size: $font-size-sm;
color: $text-light;
@media (max-width: $breakpoint-sm) {
justify-content: flex-start;
font-size: $font-size-xs;
padding-top: $spacing-xs;
}
}
}
// Mobile label for date
@media (max-width: $breakpoint-sm) {
.table-row .col-date::before {
content: '등록일: ';
color: $text-gray;
margin-right: $spacing-xs;
}
}
}
// Empty state for tables
.table-empty {
padding: $spacing-5xl $spacing-lg;
text-align: center;
background: $white;
border-radius: $border-radius-lg;
.empty-icon {
margin-bottom: $spacing-lg;
img {
max-width: 200px;
opacity: 0.7;
@media (max-width: $breakpoint-sm) {
max-width: 150px;
}
}
}
.empty-text {
font-size: $font-size-base;
color: $text-gray;
@media (max-width: $breakpoint-sm) {
font-size: $font-size-sm;
}
}
}
// Search and filter section for tables
.table-controls {
display: flex;
justify-content: space-between;
align-items: center;
margin-bottom: $spacing-xl;
gap: $spacing-lg;
@media (max-width: $breakpoint-sm) {
flex-direction: column;
align-items: stretch;
gap: $spacing-md;
}
.total-count {
font-size: $font-size-sm;
color: $text-gray;
strong {
color: $primary-blue;
font-weight: $font-weight-semibold;
}
@media (max-width: $breakpoint-sm) {
order: 2;
text-align: center;
}
}
.search-box {
display: flex;
gap: $spacing-sm;
@media (max-width: $breakpoint-sm) {
order: 1;
}
input {
flex: 1;
min-width: 250px;
padding: $spacing-sm $spacing-md;
border: 1px solid $border-gray;
border-radius: $border-radius-md;
font-size: $font-size-sm;
transition: $transition-base;
@media (max-width: $breakpoint-sm) {
min-width: auto;
}
&:focus {
outline: none;
border-color: $primary-blue;
box-shadow: 0 0 0 3px rgba($primary-blue, 0.1);
}
&::placeholder {
color: $text-light;
}
}
button {
padding: $spacing-sm $spacing-lg;
background: $gradient-primary;
color: $white;
border: none;
border-radius: $border-radius-md;
font-size: $font-size-sm;
font-weight: $font-weight-medium;
cursor: pointer;
transition: $transition-base;
white-space: nowrap;
&:hover {
transform: translateY(-2px);
box-shadow: $shadow-md;
}
&:active {
transform: translateY(0);
}
i {
margin-right: $spacing-xs;
}
}
}
}