/**
 * Golcam Home Layout - Modern Two Column Design
 * Mobile-first approach with responsive adjustments
 */

/* ===== CSS RESET & GLOBAL VARIABLES ===== */
:root {
  /* Color palette */
  --primary-color: #1e5799;
  --primary-dark: #173e6d;
  --primary-light: #2c75c5;
  --secondary-color: #e74c3c;
  --accent-color: #f39c12;
  --text-color: #FFF;
  --text-light: #666;
  --text-muted: #999;
  --bg-color: #f5f7fa;
  --card-bg: #fff;
  --border-color: #eee;
  
  /* Layout variables */
  --container-padding: 15px;
  --border-radius: 10px;
  --card-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
  --animation-speed: 0.3s;
}

/* ===== BASE STYLING ===== */
body {
  font-family: 'Roboto', Arial, sans-serif;
  background-color: var(--bg-color);
  color: var(--text-color);
  line-height: 1.5;
  margin: 0;
  padding: 0;
}

*, *:before, *:after {
  box-sizing: border-box;
}

img {
  max-width: 100%;
  height: auto;
}

a {
  color: var(--primary-color);
  text-decoration: none;
  transition: color var(--animation-speed) ease;
}

a:hover {
  color: var(--primary-dark);
}

h1, h2, h3, h4, h5, h6 {
  margin-top: 0;
}

/* ===== CONTAINER LAYOUT ===== */
.gc-container {
  width: 100%;
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 var(--container-padding);
}

/* Main two-column layout - mobile first approach */
.gc-layout {
  display: flex;
  flex-direction: column; /* Default for mobile: stack vertically */
  gap: 20px;
  margin: 20px 0;
}

.gc-main {
  flex: 1;
  min-width: 0; /* Prevents flex child from overflowing */
}

.gc-sidebar {
  width: 100%;
}

/* Larger screens: side-by-side */
@media (min-width: 992px) {
  .gc-layout {
    flex-direction: row;
    gap: 30px;
  }
  
  .gc-main {
    flex: 7; /* 70% of the space */
  }
  
  .gc-sidebar {
    flex: 3; /* 30% of the space */
    min-width: 0;
  }
}

/* ===== HEADER BANNER / WELCOME SECTION ===== */
.gc-banner {
  position: relative;
  width: 100%;
  background: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
  border-radius: var(--border-radius);
  overflow: hidden;
  color: white;
  margin-bottom: 20px;
}

.gc-welcome {
  padding: 40px 20px;
  text-align: center;
  position: relative;
  z-index: 2;
}

.gc-welcome h1 {
  font-size: 1.8rem;
  margin-bottom: 15px;
  font-weight: 700;
}

.gc-welcome p {
  font-size: 1rem;
  margin-bottom: 20px;
  opacity: 0.9;
}

.gc-banner::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: url('/images/pattern.png') repeat;
  opacity: 0.1;
  z-index: 1;
}

.gc-welcome-buttons {
  display: flex;
  flex-direction: column;
  gap: 10px;
  max-width: 300px;
  margin: 0 auto;
}

/* For tablet and up screens */
@media (min-width: 768px) {
  .gc-welcome {
    padding: 60px 30px;
  }
  
  .gc-welcome h1 {
    font-size: 2.5rem;
  }
  
  .gc-welcome p {
    font-size: 1.2rem;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
  }
  
  .gc-welcome-buttons {
    flex-direction: row;
    max-width: 500px;
  }
}

/* ===== BUTTONS ===== */
.gc-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 20px;
  border-radius: 50px;
  font-weight: 600;
  font-size: 0.95rem;
  transition: all var(--animation-speed) ease;
  border: none;
  cursor: pointer;
  flex: 1;
}

.gc-btn i {
  margin-right: 8px;
}

.gc-btn-primary {
  background-color: var(--secondary-color);
  color: white;
}

.gc-btn-primary:hover {
  background-color: #c0392b;
  color: white;
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
}

.gc-btn-secondary {
  background-color: rgba(255, 255, 255, 0.2);
  color: white;
  backdrop-filter: blur(5px);
}

.gc-btn-secondary:hover {
  background-color: rgba(255, 255, 255, 0.3);
  color: white;
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
}

/* ===== USER STATS SECTION ===== */
.gc-user-stats {
  background-color: var(--card-bg);
  border-radius: var(--border-radius);
  box-shadow: var(--card-shadow);
  margin-bottom: 20px;
  overflow: hidden;
}

.gc-stats-header {
  display: flex;
  align-items: center;
  padding: 15px 20px;
  background: linear-gradient(90deg, var(--primary-color), var(--primary-light));
  color: white;
}

.gc-stats-header i {
  margin-right: 10px;
  font-size: 1.2rem;
}

.gc-stats-header h2 {
  margin: 0;
  font-size: 1.1rem;
  font-weight: 600;
}

.gc-stats-content {
  padding: 20px;
}

.gc-user-profile {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  margin-bottom: 20px;
}

.gc-avatar-wrapper {
  position: relative;
  margin-bottom: 15px;
}

.gc-avatar {
  width: 100px;
  height: 100px;
  border-radius: 50%;
  object-fit: cover;
  border: 3px solid var(--primary-color);
}

.gc-badge {
  position: absolute;
  bottom: 0;
  right: 0;
  width: 40px;
  height: 40px;
  background-color: white;
  border-radius: 50%;
  padding: 2px;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}

.gc-user-info {
  margin-bottom: 15px;
}

.gc-user-name {
  font-size: 1.2rem;
  font-weight: 600;
  margin: 0 0 5px;
}

.gc-user-position {
  color: var(--text-light);
  margin: 0 0 5px;
}

.gc-user-value {
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--primary-color);
}

.gc-stats-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 15px;
}

.gc-stat-item {
  background-color: #f8f9fa;
  border-radius: 8px;
  padding: 15px;
  text-align: center;
  transition: transform var(--animation-speed) ease, box-shadow var(--animation-speed) ease;
}

.gc-stat-item:hover {
  transform: translateY(-3px);
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.gc-stat-icon {
  font-size: 1.5rem;
  color: var(--primary-color);
  margin-bottom: 10px;
}

.gc-stat-value {
  font-size: 1.2rem;
  font-weight: 700;
  margin-bottom: 5px;
}

.gc-stat-label {
  font-size: 0.9rem;
  color: var(--text-muted);
}

@media (min-width: 768px) {
  .gc-user-profile {
    flex-direction: row;
    text-align: left;
  }
  
  .gc-avatar-wrapper {
    margin-right: 20px;
    margin-bottom: 0;
  }
  
  .gc-stats-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

/* ===== SEARCH BOX ===== */
.gc-search {
  background-color: var(--card-bg);
  border-radius: var(--border-radius);
  box-shadow: var(--card-shadow);
  margin-bottom: 20px;
  overflow: hidden;
}

.gc-search-form {
  padding: 20px;
}

/* Responsive grid layout for search form */
.gc-search-form-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 15px;
}

/* Field containers with icons */
.gc-field-select,
.gc-date-picker {
  position: relative;
}

.gc-field-label {
  display: block;
  margin-bottom: 8px;
  font-weight: 600;
  color: var(--primary-color);
  font-size: 0.9rem;
}

.gc-field-icon {
  position: absolute;
  left: 12px;
  top: 38px;
  color: var(--primary-color);
  z-index: 1;
}

/* Style for select and input fields */
.gc-form-control {
  width: 100%;
  padding: 12px 12px 12px 35px;
  border: 1px solid var(--border-color);
  border-radius: 8px;
  font-size: 1rem;
  transition: all var(--animation-speed) ease;
  background-color: var(--card-bg);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.gc-form-control:focus {
  outline: none;
  border-color: var(--primary-color);
  box-shadow: 0 0 0 3px rgba(30, 87, 153, 0.1);
  transform: translateY(-2px);
}

/* Search button styling */
.gc-search-btn {
  width: 100%;
  padding: 12px 20px;
  background: linear-gradient(to right, var(--primary-color), var(--primary-light));
  color: white;
  border: none;
  border-radius: 8px;
  font-weight: 600;
  cursor: pointer;
  transition: all var(--animation-speed) ease;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.gc-search-btn:hover {
  background: linear-gradient(to right, var(--primary-light), var(--primary-color));
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
}

.gc-search-btn:active {
  transform: translateY(0);
}

/* Tablet layout */
@media (min-width: 768px) {
  .gc-search-form-grid {
    grid-template-columns: 1fr 1fr;
  }
  
  .gc-search-actions {
    grid-column: span 2;
  }
}

/* Desktop layout - all in one row */
@media (min-width: 992px) {
  .gc-search-form-grid {
    grid-template-columns: 1fr 1fr auto;
    align-items: flex-end;
  }
  
  .gc-search-actions {
    grid-column: auto;
  }
  
  .gc-search-btn {
    height: 100%;
    min-height: 45px;
    white-space: nowrap;
  }
}

/* Mobile optimizations */
@media (max-width: 576px) {
  .gc-search-form {
    padding: 15px;
  }
  
  .gc-field-label {
    font-size: 0.85rem;
  }
  
  .gc-form-control {
    padding: 10px 10px 10px 35px;
    font-size: 0.95rem;
  }
  
  .gc-field-icon {
    top: 36px;
  }
  
  .gc-search-btn .btn-text {
    display: none;
  }
  
  .gc-search-btn {
    padding: 10px;
  }
  
  .gc-search-btn i {
    margin-right: 0;
    font-size: 1.2rem;
  }
}

/* ===== CARD COMPONENTS ===== */
.gc-card {
  background-color: var(--card-bg);
  border-radius: var(--border-radius);
  box-shadow: var(--card-shadow);
  margin-bottom: 20px;
  overflow: hidden;
  transition: transform var(--animation-speed) ease, box-shadow var(--animation-speed) ease;
}

.gc-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 15px rgba(0, 0, 0, 0.1);
}

.gc-card-header {
  display: flex;
  align-items: center;
  padding: 15px 20px;
  background: linear-gradient(90deg, var(--primary-color), var(--primary-light));
  color: white;
}

.gc-card-header i {
  margin-right: 10px;
  font-size: 1.2rem;
  display: inline-block;
  vertical-align: middle;
}

.gc-card-header h2 {
  margin: 0;
  font-size: 1.1rem;
  font-weight: 600;
  display: inline-block;
  vertical-align: middle;
}

.gc-card-content {
  padding: 20px;
}

/* ===== VIDEO GRID ===== */
.gc-video-grid {
  display: grid;
  grid-template-columns: 1fr; /* Mobile: 1 column */
  gap: 20px;
}

@media (min-width: 576px) {
  .gc-video-grid {
    grid-template-columns: repeat(2, 1fr); /* Tablet: 2 columns */
  }
}

@media (min-width: 992px) {
  .gc-video-grid {
    grid-template-columns: repeat(3, 1fr); /* Desktop: 3 columns */
  }
}

/* ===== VIDEO CARD ===== */
.gc-video-card {
  background-color: var(--card-bg);
  border-radius: var(--border-radius);
  overflow: hidden;
  box-shadow: var(--card-shadow);
  transition: transform var(--animation-speed) ease, box-shadow var(--animation-speed) ease;
  display: flex;
  flex-direction: column;
  height: 100%;
}

.gc-video-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 15px rgba(0, 0, 0, 0.1);
}

.gc-video-thumb {
  position: relative;
  aspect-ratio: 16/9;
  overflow: hidden;
  background-color: #f0f0f0;
}

.gc-video-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.gc-video-card:hover .gc-video-thumb img {
  transform: scale(1.05);
}

.gc-video-thumb .gc-tag {
  position: absolute;
  top: 10px;
  left: 10px;
  padding: 5px 10px;
  border-radius: 20px;
  font-size: 0.8rem;
  background-color: rgba(30, 87, 153, 0.8);
  color: white;
  z-index: 1;
}

.gc-video-thumb .gc-category {
  position: absolute;
  top: 10px;
  right: 10px;
  padding: 5px 10px;
  border-radius: 20px;
  font-size: 0.8rem;
  background-color: rgba(231, 76, 60, 0.8);
  color: white;
  z-index: 1;
}

.gc-video-thumb .gc-play-button {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%) scale(0.9);
  width: 60px;
  height: 60px;
  background-color: rgba(0, 0, 0, 0.6);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: all var(--animation-speed) ease;
}

.gc-video-thumb .gc-play-button::after {
  content: '';
  display: block;
  width: 0;
  height: 0;
  border-top: 15px solid transparent;
  border-bottom: 15px solid transparent;
  border-left: 25px solid white;
  margin-left: 5px;
}

.gc-video-card:hover .gc-play-button {
  opacity: 1;
  transform: translate(-50%, -50%) scale(1);
}

.gc-video-info {
  padding: 15px;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.gc-video-title {
  font-weight: 600;
  margin: 0 0 10px;
  line-height: 1.4;
}

.gc-video-title a {
  color: var(--text-color);
}

.gc-video-title a:hover {
  color: var(--primary-color);
}

.gc-video-meta {
  margin-top: auto;
  display: flex;
  justify-content: space-between;
  padding-top: 10px;
  border-top: 1px solid var(--border-color);
  font-size: 0.85rem;
  color: var(--text-muted);
}

.gc-video-author a {
  color: var(--primary-color);
  font-weight: 500;
}

.gc-video-views i {
  margin-right: 5px;
}
section.gc-widget {
  background-color: var(--card-bg);
  border-radius: var(--border-radius);
  box-shadow: var(--card-shadow);
  margin-bottom: 20px;
  overflow: hidden;
  padding: 0px 0px 3px 0px;
}
/* ===== SIDEBAR WIDGETS ===== */
.gc-widget-header {
  display: flex;
  align-items: center;
  padding: 15px 20px;
  background: linear-gradient(135deg, #4995ff, #111827, #4995ff);
  background-size: 300% 300%;
  animation: gradientFlow 2s ease infinite;
  color: white;
}

@keyframes gradientFlow {
  0% {
      background-position: 0% 50%;
  }
  50% {
      background-position: 100% 50%;
  }
  100% {
      background-position: 0% 50%;
  }
}


.gc-widget-header {
  display: flex;
  align-items: center;
  padding: 15px 20px;
  background: linear-gradient(90deg, var(--primary-color), var(--primary-light));
  border-radius: 10px 10px 0px 0px;
  height: 41px;
  font-size: 15px !important;
  color: #FFF !important;
}

.gc-widget-header i {
  margin-right: 10px;
  font-size: 1.2rem;
  display: inline-block;
  vertical-align: middle;
}

.gc-widget-header h2 {
  margin: 0;
  font-size: 1.1rem;
  font-weight: 600;
  display: inline-block;
  vertical-align: middle;
}

.gc-widget-content {
  padding: 20px;
}

/* Stats Counter Widget */
.gc-stats-counter {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 15px;
}

.gc-counter-item {
  background-color: #f8f9fa;
  border-radius: 8px;
  padding: 15px;
  text-align: center;
  transition: transform var(--animation-speed) ease, box-shadow var(--animation-speed) ease;
}

.gc-counter-item:hover {
  transform: translateY(-3px);
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.gc-counter-icon {
  font-size: 1.5rem;
  color: var(--primary-color);
  margin-bottom: 10px;
}

.gc-counter-value {
  font-size: 1.2rem;
  font-weight: 700;
  margin-bottom: 5px;
}

.gc-counter-label {
  font-size: 0.9rem;
  color: var(--text-muted);
}

/* Top Players Widget */
.gc-player-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.gc-player-item {
  display: flex;
  align-items: center;
  padding: 12px 0;
  border-bottom: 1px solid var(--border-color);
}

.gc-player-item:last-child {
  border-bottom: none;
}

.gc-player-rank {
  font-weight: 700;
  width: 30px;
  height: 30px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background-color: #f0f0f0;
  margin-right: 12px;
  font-size: 0.9rem;
}

.gc-player-item:nth-child(1) .gc-player-rank {
  background-color: #ffd700;
  color: #333;
}

.gc-player-item:nth-child(2) .gc-player-rank {
  background-color: #c0c0c0;
  color: #333;
}

.gc-player-item:nth-child(3) .gc-player-rank {
  background-color: #cd7f32;
  color: white;
}

.gc-player-avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  object-fit: cover;
  margin-right: 12px;
}

.gc-player-info {
  flex: 1;
}

.gc-player-name {
  font-weight: 600;
  margin: 0 0 3px;
  font-size: 0.95rem;
}

.gc-player-stats {
  font-size: 0.85rem;
  color: var(--text-muted);
}

.gc-player-score {
  font-weight: 700;
  color: var(--primary-color);
}

/* ===== UTILITY CLASSES ===== */
/* Fix specifico per l'icona fa-film che ha problemi di allineamento */
.gc-card-header i.fas.fa-film,
.gc-widget-header i.fas.fa-film {
  display: inline-block !important;
  vertical-align: middle !important;
  margin-right: 10px !important;
}

.gc-text-center {
  text-align: center;
}

.gc-mt-0 {
  margin-top: 0;
}

.gc-mb-0 {
  margin-bottom: 0;
}

.gc-p-0 {
  padding: 0;
}

/* ===== ANIMATION CLASSES ===== */
.gc-fade-in {
  animation: fadeIn 0.5s ease-out forwards;
}

.gc-slide-up {
  animation: slideUp 0.5s ease-out forwards;
}

/* Fix per evitare che l'animazione disturbi l'allineamento dell'icona fa-film */
i.fas.fa-film.gc-slide-up {
  display: inline-block !important;
  vertical-align: middle !important;
  float: none !important;
  position: relative !important;
}

.gc-scale-in {
  animation: scaleIn 0.5s ease-out forwards;
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes slideUp {
  from { 
    opacity: 0;
    transform: translateY(20px);
  }
  to { 
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes scaleIn {
  from { 
    opacity: 0;
    transform: scale(0.9);
  }
  to { 
    opacity: 1;
    transform: scale(1);
  }
}
