/* ==========================================================================
   TAMOOH - Community & Hackathons Styles
   ========================================================================== */

.community-hero {
  position: relative;
  padding: 8rem 0 4.5rem;
  background: radial-gradient(circle at 50% 25%, rgba(0, 242, 254, 0.1) 0%, transparent 60%),
              radial-gradient(circle at 80% 50%, rgba(112, 0, 255, 0.1) 0%, transparent 55%),
              var(--bg-primary);
  text-align: center;
  overflow: hidden;
}

.community-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.5rem 1.3rem;
  background: rgba(0, 242, 254, 0.08);
  border: 1px solid rgba(0, 242, 254, 0.35);
  border-radius: 999px;
  color: #00f2fe;
  font-size: 0.9rem;
  font-weight: 700;
  margin-bottom: 1.5rem;
  box-shadow: 0 0 25px rgba(0, 242, 254, 0.2);
}

.community-hero h1 {
  font-size: clamp(2.2rem, 4.5vw, 3.6rem);
  font-weight: 900;
  line-height: 1.25;
  margin-bottom: 1.2rem;
  color: var(--text-primary);
}

[data-theme="dark"] .community-hero h1 {
  color: #ffffff;
}

.community-hero h1 span {
  background: linear-gradient(135deg, #00f2fe 0%, #a855f7 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.community-hero p {
  max-width: 780px;
  margin: 0 auto 2.5rem;
  font-size: 1.15rem;
  color: var(--text-secondary);
  line-height: 1.8;
}

.btn-community-primary {
  background: linear-gradient(135deg, #00f2fe 0%, #7000ff 100%);
  color: #ffffff;
  font-weight: 800;
  border: none;
  border-radius: 50px;
  padding: 0.95rem 2.2rem;
  font-size: 1.05rem;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.7rem;
  transition: all 0.3s ease;
  box-shadow: 0 4px 20px rgba(0, 242, 254, 0.35);
}

.btn-community-primary:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 30px rgba(112, 0, 255, 0.5);
  filter: brightness(1.1);
}

/* Hackathons Section */
.hackathons-section {
  padding: 5rem 0;
  position: relative;
}

.hackathons-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
  gap: 2.5rem;
  margin-top: 3.5rem;
}

.hackathon-card {
  background: rgba(15, 23, 42, 0.65);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 24px;
  padding: 2.5rem;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  backdrop-filter: blur(18px);
  transition: all 0.4s ease;
  position: relative;
  overflow: hidden;
  text-align: right;
}

.hackathon-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, #00f2fe, #7000ff);
}

.hackathon-card:hover {
  transform: translateY(-6px);
  border-color: rgba(0, 242, 254, 0.4);
  box-shadow: 0 25px 50px -10px rgba(0, 0, 0, 0.6),
              0 0 30px rgba(0, 242, 254, 0.2);
}

.hackathon-status-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1.5rem;
}

.live-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: rgba(239, 68, 68, 0.15);
  color: #ef4444;
  border: 1px solid rgba(239, 68, 68, 0.3);
  padding: 0.35rem 0.85rem;
  border-radius: 50px;
  font-size: 0.82rem;
  font-weight: 800;
}

.live-pulse-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #ef4444;
  box-shadow: 0 0 10px #ef4444;
  animation: pulse 1.5s infinite;
}

.prize-pool-tag {
  background: rgba(245, 158, 11, 0.15);
  color: #f59e0b;
  border: 1px solid rgba(245, 158, 11, 0.3);
  padding: 0.35rem 0.85rem;
  border-radius: 50px;
  font-size: 0.9rem;
  font-weight: 800;
}

.hackathon-card h3 {
  font-size: 1.45rem;
  color: var(--text-primary);
  font-weight: 800;
  line-height: 1.4;
  margin-bottom: 0.8rem;
}

[data-theme="dark"] .hackathon-card h3 {
  color: #ffffff;
}

.hackathon-card p {
  color: #94a3b8;
  font-size: 0.95rem;
  line-height: 1.7;
  margin-bottom: 1.8rem;
}

/* Countdown Box */
.countdown-box {
  display: flex;
  justify-content: center;
  gap: 1rem;
  background: rgba(10, 14, 23, 0.6);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 16px;
  padding: 1.2rem;
  margin-bottom: 1.8rem;
}

.countdown-unit {
  display: flex;
  flex-direction: column;
  align-items: center;
  min-width: 55px;
}

.countdown-num {
  font-size: 1.6rem;
  font-weight: 900;
  color: #00f2fe;
  font-family: var(--font-latin);
}

.countdown-label {
  font-size: 0.72rem;
  color: #64748b;
  margin-top: 0.2rem;
}

.btn-register-hackathon {
  width: 100%;
  background: linear-gradient(135deg, #00f2fe, #0072ff);
  color: #050b14;
  font-weight: 800;
  border: none;
  border-radius: 50px;
  padding: 0.85rem;
  font-size: 1rem;
  cursor: pointer;
  transition: all 0.3s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
}

.btn-register-hackathon:hover {
  filter: brightness(1.1);
  transform: translateY(-2px);
  box-shadow: 0 5px 20px rgba(0, 242, 254, 0.4);
}

/* Community Channels */
.channels-section {
  padding: 5rem 0;
  background: rgba(10, 14, 23, 0.6);
  border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.channels-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 2rem;
  margin-top: 3.5rem;
}

.channel-card {
  background: var(--card-bg);
  border: 1px solid var(--border-color);
  border-radius: 20px;
  padding: 2.2rem;
  text-align: center;
  transition: all 0.3s ease;
  backdrop-filter: blur(14px);
  box-shadow: var(--shadow-sm);
}

[data-theme="dark"] .channel-card {
  background: rgba(15, 23, 42, 0.5);
  border-color: rgba(255, 255, 255, 0.08);
}

.channel-card:hover {
  transform: translateY(-5px);
  border-color: rgba(0, 242, 254, 0.3);
  box-shadow: 0 15px 35px -10px rgba(0, 0, 0, 0.5);
}

.channel-icon {
  width: 70px;
  height: 70px;
  border-radius: 20px;
  margin: 0 auto 1.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2.2rem;
}

.channel-card.discord .channel-icon {
  background: rgba(88, 101, 242, 0.15);
  color: #5865F2;
  border: 1px solid rgba(88, 101, 242, 0.3);
}

.channel-card.discord .btn-join-channel:hover {
  background: #5865F2;
  color: #ffffff;
  border-color: #5865F2;
}

.channel-card.linkedin .channel-icon {
  background: rgba(10, 102, 194, 0.15);
  color: #0a66c2;
  border: 1px solid rgba(10, 102, 194, 0.3);
}

.channel-card.linkedin .btn-join-channel:hover {
  background: #0a66c2;
  color: #ffffff;
  border-color: #0a66c2;
}

.channel-card.facebook .channel-icon {
  background: rgba(24, 119, 242, 0.15);
  color: #1877f2;
  border: 1px solid rgba(24, 119, 242, 0.3);
}

.channel-card.facebook .btn-join-channel:hover {
  background: #1877f2;
  color: #ffffff;
  border-color: #1877f2;
}

.channel-card.telegram .channel-icon {
  background: rgba(0, 136, 204, 0.15);
  color: #0088cc;
  border: 1px solid rgba(0, 136, 204, 0.3);
}

.channel-card.meetup .channel-icon {
  background: rgba(237, 28, 64, 0.15);
  color: #ed1c40;
  border: 1px solid rgba(237, 28, 64, 0.3);
}

/* Event Card Image Banner */
.hackathon-card {
  overflow: hidden;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.hackathon-card-image {
  width: calc(100% + 4.4rem);
  margin: -2.2rem -2.2rem 1.4rem -2.2rem;
  height: 175px;
  background-size: cover;
  background-position: center;
  position: relative;
  overflow: hidden;
  transition: transform 0.4s ease;
}

.hackathon-card:hover .hackathon-card-image {
  transform: scale(1.03);
}

.hackathon-card-image::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(15, 23, 42, 0.1) 0%, rgba(15, 23, 42, 0.9) 100%);
}

.channel-card h4 {
  font-size: 1.3rem;
  color: var(--text-primary);
  font-weight: 800;
  margin-bottom: 0.5rem;
}

[data-theme="dark"] .channel-card h4 {
  color: #ffffff;
}

.channel-card p {
  color: #94a3b8;
  font-size: 0.92rem;
  line-height: 1.65;
  margin-bottom: 1.5rem;
}

.btn-join-channel {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.65rem 1.4rem;
  border-radius: 50px;
  font-weight: 700;
  font-size: 0.9rem;
  text-decoration: none;
  background: var(--bg-secondary);
  color: var(--text-primary);
  border: 1px solid var(--border-color);
  transition: all 0.3s ease;
}

[data-theme="dark"] .btn-join-channel {
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(255, 255, 255, 0.12);
  color: #ffffff;
}

.btn-join-channel:hover {
  background: #00f2fe;
  color: #050b14;
  border-color: #00f2fe;
}

/* Modals */
.comm-modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(5, 11, 20, 0.88);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  z-index: 99999;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
  animation: modalFadeIn 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes modalFadeIn {
  from { opacity: 0; transform: scale(0.96); }
  to { opacity: 1; transform: scale(1); }
}

.comm-modal-container {
  background: #0c1322;
  background: linear-gradient(165deg, rgba(17, 24, 39, 0.98) 0%, rgba(10, 15, 29, 0.98) 100%);
  border: 1.5px solid rgba(0, 242, 254, 0.35);
  border-radius: 24px;
  max-width: 620px;
  width: 100%;
  padding: 2.2rem;
  position: relative;
  box-shadow: 0 25px 60px -15px rgba(0, 0, 0, 0.8), 0 0 35px rgba(0, 242, 254, 0.15);
  max-height: 90vh;
  overflow-y: auto;
  color: #ffffff;
  box-sizing: border-box;
}

.comm-modal-container::-webkit-scrollbar {
  width: 6px;
}
.comm-modal-container::-webkit-scrollbar-track {
  background: rgba(255, 255, 255, 0.03);
  border-radius: 10px;
}
.comm-modal-container::-webkit-scrollbar-thumb {
  background: rgba(0, 242, 254, 0.3);
  border-radius: 10px;
}

.comm-modal-close {
  position: absolute;
  top: 1.2rem;
  left: 1.2rem;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: #94a3b8;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  cursor: pointer;
  font-size: 1.1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.25s ease;
  z-index: 5;
}

.comm-modal-close:hover {
  background: #ef4444;
  border-color: #ef4444;
  color: #ffffff;
  transform: rotate(90deg);
}

.comm-modal-container h3 {
  font-size: 1.45rem;
  font-weight: 800;
  color: #ffffff;
  margin-top: 0;
  margin-bottom: 0.5rem;
  display: flex;
  align-items: center;
  gap: 0.6rem;
  line-height: 1.4;
}

.comm-modal-container h3 i {
  color: #00f2fe;
}

.comm-modal-container p {
  color: #94a3b8;
  font-size: 0.92rem;
  line-height: 1.6;
  margin-bottom: 1.4rem;
}

/* User Status Banners inside modal */
.member-detected-banner {
  background: linear-gradient(135deg, rgba(16, 185, 129, 0.15), rgba(0, 242, 254, 0.1));
  border: 1px solid rgba(16, 185, 129, 0.4);
  border-radius: 14px;
  padding: 0.85rem 1.1rem;
  display: flex;
  align-items: center;
  gap: 0.8rem;
  margin-bottom: 1.4rem;
}

.member-detected-banner .banner-icon {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background: rgba(16, 185, 129, 0.25);
  color: #10b981;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  flex-shrink: 0;
}

.member-detected-banner .banner-info {
  flex: 1;
}

.member-detected-banner .banner-title {
  color: #10b981;
  font-weight: 700;
  font-size: 0.88rem;
  margin-bottom: 0.15rem;
}

.member-detected-banner .banner-text {
  color: #cbd5e1;
  font-size: 0.8rem;
  margin: 0;
  line-height: 1.4;
}

.guest-detected-banner {
  background: rgba(255, 255, 255, 0.04);
  border: 1px dashed rgba(255, 255, 255, 0.15);
  border-radius: 12px;
  padding: 0.75rem 1rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.8rem;
  margin-bottom: 1.4rem;
}

.guest-detected-banner p {
  margin: 0;
  font-size: 0.82rem;
  color: #94a3b8;
}

.guest-detected-banner a {
  color: #00f2fe;
  font-size: 0.82rem;
  font-weight: 700;
  text-decoration: underline;
  white-space: nowrap;
}

/* Registration Type Selector (Individual vs Team) */
.reg-type-selector {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.75rem;
  margin-bottom: 1.3rem;
  background: rgba(255, 255, 255, 0.04);
  padding: 0.35rem;
  border-radius: 14px;
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.reg-type-pill {
  border: 1px solid transparent;
  background: transparent;
  color: #94a3b8;
  padding: 0.7rem 1rem;
  border-radius: 10px;
  cursor: pointer;
  font-family: inherit;
  font-size: 0.9rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  transition: all 0.25s ease;
}

.reg-type-pill.active {
  background: rgba(0, 242, 254, 0.15);
  border-color: rgba(0, 242, 254, 0.4);
  color: #00f2fe;
  box-shadow: 0 4px 12px rgba(0, 242, 254, 0.1);
}

.reg-type-pill:hover:not(.active) {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.06);
}

/* Form Groups & Inputs */
.modal-form-group {
  margin-bottom: 1.15rem;
  text-align: right;
  width: 100%;
  box-sizing: border-box;
}

.modal-form-group label {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  font-size: 0.88rem;
  color: #cbd5e1;
  font-weight: 700;
  margin-bottom: 0.45rem;
}

.modal-form-group label i {
  color: #00f2fe;
  font-size: 0.85rem;
}

.modal-input-wrapper {
  position: relative;
  width: 100%;
  display: block;
}

.modal-input-wrapper .input-icon {
  position: absolute;
  right: 1rem;
  top: 50%;
  transform: translateY(-50%);
  color: #64748b;
  font-size: 0.95rem;
  pointer-events: none;
  transition: color 0.25s ease;
}

.modal-form-group input,
.modal-form-group textarea,
.modal-form-group select {
  width: 100%;
  background: rgba(255, 255, 255, 0.05);
  border: 1.5px solid rgba(255, 255, 255, 0.12);
  border-radius: 12px;
  padding: 0.82rem 1.1rem;
  color: #ffffff !important;
  font-family: inherit;
  font-size: 0.92rem;
  outline: none;
  transition: all 0.25s ease;
  box-sizing: border-box;
  display: block;
}

.modal-input-wrapper input,
.modal-input-wrapper select {
  padding-right: 2.85rem;
}

.modal-form-group select {
  appearance: none;
  -webkit-appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%2300f2fe'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M19 9l-7 7-7-7'%3E%3C/path%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: left 1rem center;
  background-size: 1.1rem;
  cursor: pointer;
}

.modal-form-group select option {
  background: #0f172a;
  color: #ffffff;
  padding: 0.5rem;
}

.modal-form-group input::placeholder,
.modal-form-group textarea::placeholder {
  color: #64748b;
  font-size: 0.88rem;
}

.modal-form-group input:focus,
.modal-form-group textarea:focus,
.modal-form-group select:focus {
  border-color: #00f2fe;
  background: rgba(15, 23, 42, 0.95);
  box-shadow: 0 0 16px rgba(0, 242, 254, 0.25);
}

.modal-input-wrapper:focus-within .input-icon {
  color: #00f2fe;
}

/* Modal Form 2-Column Grid */
.modal-grid-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.85rem;
}

@media (max-width: 576px) {
  .modal-grid-2 {
    grid-template-columns: 1fr;
  }
}

/* Terms Checkbox */
.modal-checkbox-group {
  display: flex;
  align-items: flex-start;
  gap: 0.6rem;
  margin: 1.1rem 0;
  text-align: right;
}

.modal-checkbox-group input[type="checkbox"] {
  width: 18px;
  height: 18px;
  accent-color: #00f2fe;
  margin-top: 0.15rem;
  cursor: pointer;
  flex-shrink: 0;
}

.modal-checkbox-group label {
  font-size: 0.82rem;
  color: #94a3b8;
  cursor: pointer;
  line-height: 1.5;
  margin-bottom: 0;
}

/* Submit Action Button */
.btn-submit-proposal {
  width: 100%;
  background: linear-gradient(135deg, #00f2fe, #0072ff);
  color: #050b14;
  font-weight: 800;
  padding: 0.95rem 1.5rem;
  border: none;
  border-radius: 50px;
  font-size: 1rem;
  font-family: inherit;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.65rem;
  transition: all 0.3s ease;
  box-shadow: 0 8px 25px rgba(0, 242, 254, 0.3);
  margin-top: 0.8rem;
}

.btn-submit-proposal:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 30px rgba(0, 242, 254, 0.45);
  filter: brightness(1.08);
}

.btn-submit-proposal:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  transform: none;
}

/* Success Card inside Modal */
.modal-success-state {
  text-align: center;
  padding: 1rem 0.5rem;
}

.modal-success-icon {
  width: 76px;
  height: 76px;
  border-radius: 50%;
  background: linear-gradient(135deg, rgba(16, 185, 129, 0.2), rgba(0, 242, 254, 0.2));
  border: 2px solid #10b981;
  color: #10b981;
  font-size: 2.3rem;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 1.4rem auto;
  box-shadow: 0 0 30px rgba(16, 185, 129, 0.35);
  animation: pulseSuccess 2s infinite;
}

@keyframes pulseSuccess {
  0% { transform: scale(1); }
  50% { transform: scale(1.06); }
  100% { transform: scale(1); }
}

.modal-success-code {
  background: rgba(255, 255, 255, 0.05);
  border: 1.5px dashed rgba(0, 242, 254, 0.4);
  border-radius: 12px;
  padding: 0.85rem 1.2rem;
  margin: 1.2rem auto;
  display: inline-block;
  color: #00f2fe;
  font-size: 1.15rem;
  font-weight: 800;
  letter-spacing: 1px;
}

.modal-success-actions {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  margin-top: 1.5rem;
}
