Files
myprojplanet_vite/src/components/CMyRecCard/CMyRecCard.scss

508 lines
9.0 KiB
SCSS
Raw Normal View History

// ========================================
// VARIABILI
// ========================================
$primary-color: #1976d2;
$positive-color: #21ba45;
$negative-color: #c10015;
$grey-color: #666;
$grey-light: #999;
$border-radius: 10px;
$border-radius-sm: 6px;
$transition-speed: 0.3s;
$shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.06);
$shadow-md: 0 2px 6px rgba(0, 0, 0, 0.08);
$shadow-hover: 0 4px 12px rgba(0, 0, 0, 0.12);
$mobile-breakpoint: 768px;
// ========================================
// WRAPPER CARD - ALTERNATING COLORS
// ========================================
.rec-card-wrapper {
margin: 3px auto;
padding: 0;
width: 100%; // Aggiungi questa riga
@media (max-width: $mobile-breakpoint) {
margin: 2px auto;
}
&.is-even {
.modern-rec-card {
background: linear-gradient(135deg, rgba(49, 154, 239, 0.08) 0%, rgba(25, 118, 210, 0.03) 100%);
border-color: rgba(66, 165, 245, 0.12);
}
}
&.is-odd {
.modern-rec-card {
background: linear-gradient(135deg, rgba(38, 197, 218, 0.08) 0%, rgba(0, 150, 136, 0.03) 100%);
border-color: rgba(38, 198, 218, 0.12);
}
}
}
// ========================================
// CARD EVENTO (Calendar View)
// ========================================
.event-card {
display: flex;
gap: 6px;
margin-bottom: 6px;
background: white;
border-radius: $border-radius;
overflow: hidden;
box-shadow: $shadow-md;
transition: box-shadow $transition-speed ease;
&:hover {
box-shadow: $shadow-hover;
}
@media (max-width: $mobile-breakpoint) {
gap: 5px;
margin-bottom: 5px;
}
}
.event-date-column {
flex: 0 0 70px;
background: linear-gradient(135deg, $primary-color, #42a5f5);
padding: 6px 3px;
display: flex;
align-items: center;
justify-content: center;
@media (max-width: $mobile-breakpoint) {
flex: 0 0 65px;
padding: 5px 2px;
}
}
.date-stack {
display: flex;
flex-direction: column;
align-items: center;
gap: 2px;
color: white;
text-align: center;
}
.day-of-week {
font-size: 0.625rem;
font-weight: 600;
text-transform: uppercase;
letter-spacing: 0.5px;
opacity: 0.9;
@media (max-width: $mobile-breakpoint) {
font-size: 0.5625rem;
}
}
.day-number {
font-size: 1.875rem;
font-weight: 700;
line-height: 1;
margin: 3px 0;
@media (max-width: $mobile-breakpoint) {
font-size: 1.625rem;
margin: 2px 0;
}
}
.month-name {
font-size: 0.8125rem;
font-weight: 600;
text-transform: uppercase;
letter-spacing: 0.5px;
@media (max-width: $mobile-breakpoint) {
font-size: 0.75rem;
}
}
.time-start,
.time-end {
font-size: 0.6875rem;
font-weight: 500;
padding: 2px 5px;
background: rgba(255, 255, 255, 0.2);
border-radius: 4px;
margin-top: 2px;
@media (max-width: $mobile-breakpoint) {
font-size: 0.625rem;
padding: 1px 4px;
}
}
.date-separator {
font-size: 0.9375rem;
margin: 3px 0;
opacity: 0.8;
@media (max-width: $mobile-breakpoint) {
font-size: 0.875rem;
margin: 2px 0;
}
}
.user-avatar {
margin-top: 6px;
border: 2px solid rgba(255, 255, 255, 0.3);
box-shadow: $shadow-sm;
@media (max-width: $mobile-breakpoint) {
margin-top: 5px;
width: 36px !important;
height: 36px !important;
}
}
.event-image-container {
flex: 1;
position: relative;
overflow: hidden;
// L'altezza viene gestita dinamicamente dal Vue
}
.event-image {
width: 100%;
height: 100%;
cursor: pointer;
transition: transform $transition-speed ease;
&:hover {
transform: scale(1.03);
}
:deep(.q-img__image) {
object-fit: cover;
}
}
// ========================================
// CARD RECORD PRINCIPALE
// ========================================
.modern-rec-card {
background: white;
border: 1px solid rgba(0, 0, 0, 0.08);
border-radius: $border-radius;
box-shadow: $shadow-sm;
padding: 6px;
transition: all $transition-speed ease;
margin-bottom: 3px;
position: relative;
overflow: hidden;
&:hover {
box-shadow: $shadow-md;
transform: translateY(-1px);
}
@media (max-width: $mobile-breakpoint) {
padding: 5px;
margin-bottom: 2px;
}
}
// ========================================
// AVATAR SECTION
// ========================================
.avatar-section {
position: relative;
padding: 0 !important;
margin-right: 6px;
@media (max-width: $mobile-breakpoint) {
margin-right: 5px;
}
}
.type-badge {
position: absolute;
top: -3px;
left: -3px;
z-index: 1;
font-size: 0.625rem;
padding: 2px 5px;
border-radius: 4px;
font-weight: 600;
@media (max-width: $mobile-breakpoint) {
font-size: 0.5625rem;
padding: 1px 4px;
}
}
.record-avatar {
box-shadow: $shadow-sm;
border: 2px solid rgba(0, 0, 0, 0.05);
@media (max-width: $mobile-breakpoint) {
width: 48px !important;
height: 48px !important;
}
:deep(.q-img) {
border-radius: 50%;
}
}
// ========================================
// CONTENT SECTION
// ========================================
.content-section {
padding: 0 6px 0 0 !important;
min-width: 0;
@media (max-width: $mobile-breakpoint) {
padding: 0 5px 0 0 !important;
}
}
.tags-row {
display: flex;
flex-wrap: wrap;
gap: 3px;
margin-bottom: 3px;
align-items: center;
@media (max-width: $mobile-breakpoint) {
gap: 2px;
margin-bottom: 2px;
}
}
.tag-chip {
height: 19px;
font-size: 0.6875rem;
padding: 0 5px;
border-radius: 4px;
box-shadow: none;
font-weight: 500;
&.subsector {
background: linear-gradient(135deg, $positive-color, #26a69a);
color: white;
}
&.sector {
background: linear-gradient(135deg, $primary-color, #42a5f5);
color: white;
}
@media (max-width: $mobile-breakpoint) {
height: 17px;
font-size: 0.625rem;
padding: 0 4px;
}
:deep(.q-chip__content) {
padding: 0;
}
}
.status-badge {
font-size: 0.6875rem;
padding: 2px 5px;
border-radius: 4px;
display: inline-flex;
align-items: center;
gap: 3px;
@media (max-width: $mobile-breakpoint) {
font-size: 0.625rem;
padding: 2px 4px;
gap: 2px;
}
}
.description-text {
font-size: 0.9375rem;
color: #333;
line-height: 1.4;
margin: 3px 0;
word-break: break-word;
&.event-title {
font-weight: 600;
color: #1a1a1a;
}
@media (max-width: $mobile-breakpoint) {
font-size: 0.875rem;
margin: 2px 0;
}
}
.user-stats-row {
display: flex;
justify-content: space-between;
align-items: center;
margin: 3px 0;
font-size: 0.8125rem;
color: $grey-color;
@media (max-width: $mobile-breakpoint) {
font-size: 0.75rem;
margin: 2px 0;
}
}
.user-name {
font-weight: 600;
font-style: italic;
color: #333;
margin-right: 6px;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
@media (max-width: $mobile-breakpoint) {
margin-right: 5px;
}
}
.stats-container {
display: flex;
align-items: center;
gap: 5px;
flex-shrink: 0;
white-space: nowrap;
@media (max-width: $mobile-breakpoint) {
gap: 4px;
}
}
.stat-item {
display: inline-flex;
align-items: center;
gap: 2px;
font-weight: 500;
.q-icon {
vertical-align: middle;
}
}
.attending-badge {
display: inline-flex;
align-items: center;
gap: 3px;
color: $positive-color;
font-weight: 600;
font-size: 0.8125rem;
margin: 3px 0;
padding: 3px 6px;
background: rgba(33, 186, 69, 0.1);
border-radius: 6px;
width: fit-content;
@media (max-width: $mobile-breakpoint) {
font-size: 0.75rem;
margin: 2px 0;
padding: 2px 5px;
gap: 2px;
}
}
.cities-text {
font-size: 0.8125rem;
color: $grey-light;
text-align: right;
margin-top: 2px;
overflow: hidden;
text-overflow: ellipsis;
@media (max-width: $mobile-breakpoint) {
font-size: 0.75rem;
}
}
// ========================================
// ACTIONS SECTION
// ========================================
.actions-section {
padding: 0 !important;
align-self: flex-start;
margin-left: 3px;
@media (max-width: $mobile-breakpoint) {
margin-left: 2px;
}
}
.action-menu-btn {
width: 30px;
height: 30px;
color: $grey-color;
transition: all $transition-speed ease;
&:hover {
background: rgba(0, 0, 0, 0.05);
color: $primary-color;
}
@media (max-width: $mobile-breakpoint) {
width: 28px;
height: 28px;
}
}
// ========================================
// LEGACY SUPPORT
// ========================================
.myflex {
display: flex;
flex: 1;
}
.text_user_city {
text-overflow: ellipsis;
white-space: wrap;
overflow: hidden;
font-size: 0.8125rem;
color: $grey-color;
}
.cardrec {
border: 1px solid rgba(0, 0, 0, 0.08);
box-shadow: $shadow-sm;
border-radius: $border-radius;
padding: 6px;
background-color: white;
margin: 3px;
@media (min-width: 500px) {
margin: 2px;
padding: 5px;
}
}
.text_title {
color: $primary-color;
}
.event_date {
font-style: italic;
font-size: 0.8125rem;
}
// ========================================
// SEPARATOR
// ========================================
.q-separator {
margin: 3px 0;
opacity: 0.5;
@media (max-width: $mobile-breakpoint) {
margin: 2px 0;
}
}