/*
 * This is a manifest file that'll be compiled into application.css.
 *
 * With Propshaft, assets are served efficiently without preprocessing steps. You can still include
 * application-wide styles in this file, but keep in mind that CSS precedence will follow the standard
 * cascading order, meaning styles declared later in the document or manifest will override earlier ones,
 * depending on specificity.
 *
 * Consider organizing styles into separate files for maintainability.
 */

body.hotwire-native .d-hotwire-native-none {
  display: none !important;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  line-height: 1.5;
}

main {
  max-width: 48rem;
  margin: 0 auto;
  padding: 1.5rem 1rem;
}

header {
  background: #0f172a;
  padding: 0.75rem 1rem;
}

header nav {
  max-width: 48rem;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

header nav > a {
  color: #fff;
  font-weight: 700;
  font-size: 1.1rem;
  text-decoration: none;
}

header .nav-links {
  display: flex;
  align-items: center;
  gap: 1rem;
}

header .nav-links a {
  color: #cbd5e1;
}

header form {
  margin: 0;
}

header button {
  background: none;
  border: none;
  color: #fca5a5;
  padding: 0;
  font-size: 1rem;
}

h1, h2, h3 {
  color: inherit;
}

a {
  color: inherit;
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

.flash {
  padding: 0.75rem 1rem;
  margin: 0;
}

.flash-notice {
  background: transparent;
  color: #166534;
}

.flash-alert {
  background: transparent;
  color: #991b1b;
}

button, input[type="submit"] {
  cursor: pointer;
}

.feed-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.btn {
  display: inline-block;
  background: #2563eb;
  color: #fff;
  padding: 0.4rem 0.8rem;
  border-radius: 6px;
  font-weight: 600;
}

.btn:hover {
  text-decoration: none;
  background: #1d4ed8;
}

.btn-secondary {
  display: inline-block;
  background: transparent;
  color: #2563eb;
  padding: 0.4rem 0.8rem;
  border-radius: 6px;
  border: 1px solid #bfdbfe;
  font-weight: 600;
}

.btn-secondary:hover {
  background: transparent;
  color: #1d4ed8;
  text-decoration: none;
}

.post-filters {
  display: flex;
  gap: 0.5rem;
  margin: 1rem 0;
}

.post-filters a {
  padding: 0.25rem 0.6rem;
  border: 1px solid #cbd5e1;
  border-radius: 999px;
  color: #475569;
  font-size: 0.85rem;
}

.post-filters a.active {
  background: #e0e7ff;
  border-color: #6366f1;
  color: #3730a3;
}

.post {
  background: transparent;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  padding: 1rem 1.25rem;
  margin-bottom: 1rem;
}

.post-meta, .comment-meta {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-size: 0.85rem;
  color: #64748b;
}

.badge {
  text-transform: capitalize;
  font-size: 0.7rem;
  padding: 0.1rem 0.5rem;
  border-radius: 999px;
  font-weight: 700;
}

.badge-question { background: transparent; color: #1e40af; }
.badge-file { background: transparent; color: #166534; }
.badge-general { background: transparent; color: #334155; }

.post-title {
  margin: 0.5rem 0;
}

.post-title a {
  color: #0f172a;
}

.post-body {
  color: #334155;
  margin-bottom: 0.75rem;
}

.post-attachment a {
  font-weight: 600;
}

.post-footer {
  display: flex;
  gap: 1rem;
  font-size: 0.85rem;
  color: #64748b;
  border-top: 1px solid #f1f5f9;
  padding-top: 0.5rem;
}

.post-actions, .comment-actions {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-top: 0.5rem;
}

.post-actions form, .comment-actions form {
  margin: 0;
}

.post-actions button, .comment-actions button {
  background: none;
  border: none;
  color: #dc2626;
  padding: 0;
  font-size: 0.85rem;
}

.vote-buttons {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin: 0.5rem 0;
}

.vote-buttons form {
  margin: 0;
}

.vote-buttons button {
  background: transparent;
  border: 1px solid #cbd5e1;
  border-radius: 6px;
  padding: 0.1rem 0.5rem;
  color: #334155;
}

.vote-score {
  font-weight: 700;
  color: #0f172a;
}

.comments {
  margin-top: 2rem;
}

.comment {
  background: transparent;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  padding: 0.75rem 1rem;
  margin-bottom: 0.75rem;
}

.comment-body {
  margin: 0.25rem 0;
}

.field {
  margin-bottom: 1rem;
}

.field label {
  display: block;
  font-weight: 600;
  margin-bottom: 0.25rem;
}

.field input[type="text"], .field input[type="email"], .field input[type="password"],
.field select, .field textarea {
  width: 100%;
  padding: 0.5rem;
  border: 1px solid #cbd5e1;
  border-radius: 6px;
  font-size: 1rem;
}

.actions input[type="submit"] {
  background: #2563eb;
  color: #fff;
  border: none;
  padding: 0.5rem 1.25rem;
  border-radius: 6px;
  font-size: 1rem;
  font-weight: 600;
}

.errors {
  background: transparent;
  border: 1px solid #fecaca;
  color: #991b1b;
  border-radius: 6px;
  padding: 0.75rem 1rem;
  margin-bottom: 1rem;
}

.empty {
  color: #64748b;
  text-align: center;
  padding: 2rem 0;
}

trix-editor {
  border: 1px solid #cbd5e1;
  border-radius: 6px;
  min-height: 8rem;
}

.subject-list {
  list-style: none;
  padding: 0;
}

.subject-list li {
  background: transparent;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  padding: 0.75rem 1rem;
  margin-bottom: 0.5rem;
  display: flex;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
}

.subject-code {
  font-size: 1.1rem;
  font-weight: 800;
  color: inherit;
}

.subject-name {
  flex: 1;
}

.subject-counts {
  color: #64748b;
  font-size: 0.85rem;
}

.subject-section {
  margin: 1.5rem 0;
}

.resource-list {
  list-style: none;
  padding: 0;
}

.resource-list li {
  display: flex;
  gap: 0.75rem;
  align-items: baseline;
  background: transparent;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  padding: 0.6rem 1rem;
  margin-bottom: 0.4rem;
  flex-wrap: wrap;
}

.resource-list small {
  color: #64748b;
}

.admin-table {
  width: 100%;
  border-collapse: collapse;
  background: transparent;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  overflow: hidden;
}

.admin-table th, .admin-table td {
  text-align: left;
  padding: 0.6rem 0.9rem;
  border-bottom: 1px solid #f1f5f9;
  vertical-align: top;
}

.admin-table th {
  background: transparent;
  color: #475569;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.03em;
}

.admin-table .row-actions {
  display: flex;
  gap: 0.75rem;
  align-items: center;
  flex-wrap: wrap;
  font-size: 0.9rem;
}

.admin-table .row-actions form {
  margin: 0;
}

.admin-table .row-actions button {
  background: none;
  border: none;
  color: #dc2626;
  padding: 0;
  font-size: 0.9rem;
}

.badge-draft, .badge-formatting { background: transparent; color: #854d0e; }
.badge-ready { background: transparent; color: #166534; }
.badge-failed { background: transparent; color: #991b1b; }
.badge-active { background: transparent; color: #166534; }
.badge-suspended { background: transparent; color: #991b1b; }
.badge-upcoming { background: transparent; color: #1e40af; }
.badge-live { background: transparent; color: #166534; }
.badge-completed { background: transparent; color: #475569; }
.badge-cancelled { background: transparent; color: #991b1b; }
.badge-pending { background: transparent; color: #854d0e; }
.badge-paid { background: transparent; color: #166534; }

.room-details {
  margin: 1rem 0;
  padding: 1rem 1.25rem;
  border: 1px solid #bbf7d0;
  background: transparent;
  border-radius: 8px;
}

.room-details h3 {
  margin-top: 0;
}

.room-details code {
  font-size: 1.05rem;
  font-weight: 600;
  color: #14532d;
  background: transparent;
  padding: 0.15rem 0.5rem;
  border-radius: 4px;
}

.room-details-locked {
  border-color: #e2e8f0;
  background: transparent;
}

.room-details-locked code {
  color: #334155;
  background: transparent;
}

.place-form {
  display: flex;
  align-items: center;
  gap: 0.35rem;
}

.place-select {
  width: 4.5rem;
}

.btn-small {
  padding: 0.25rem 0.6rem;
  font-size: 0.8rem;
}

.leaderboard {
  list-style: none;
  margin: 0;
  padding: 0;
}

.leaderboard li {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.5rem 0.75rem;
  border-bottom: 1px solid #e2e8f0;
}

.leaderboard-place {
  font-weight: 600;
  min-width: 2.5rem;
}

.leaderboard-name {
  flex: 1;
}

.leaderboard-prize {
  font-weight: 600;
  color: #166534;
}

.leaderboard-1 .leaderboard-place { color: #b45309; }
.leaderboard-2 .leaderboard-place { color: #64748b; }
.leaderboard-3 .leaderboard-place { color: #b45309; }

.quote {
  margin: 0 0 1rem;
  padding: 1rem 1.25rem;
  border-left: 4px solid #cbd5e1;
  background: transparent;
  border-radius: 0 8px 8px 0;
}

.quote p {
  margin: 0;
  font-size: 1.05rem;
  line-height: 1.6;
}

.quote footer {
  margin-top: 0.5rem;
  color: #64748b;
  font-size: 0.9rem;
}

.quote-featured {
  border-left-color: #b45309;
  background: transparent7ed;
}

.quote-featured p {
  font-size: 1.2rem;
  font-weight: 500;
}

.tournament-card {
  background: transparent;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  padding: 0.9rem 1.25rem;
  margin-bottom: 0.75rem;
}

.tournament-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.tournament-head h3 {
  margin: 0;
}

.tournament-head h3 a {
  color: #0f172a;
}

.tournament-stats {
  color: #64748b;
}

.tournament-stats strong {
  color: #0f172a;
}

.tournament-stats .slots {
  margin-left: 0.5rem;
}

.announcement-banner {
  background: #1d4ed8;
  color: #fff;
  text-align: center;
  padding: 0.5rem 1rem;
  font-weight: 600;
  font-size: 0.95rem;
}

.announcement-banner a {
  color: #fff;
  text-decoration: underline;
}

.admin-nav {
  max-width: 48rem;
  margin: 0 auto;
  padding: 0.75rem 1rem 0;
  display: flex;
  gap: 1.25rem;
  font-weight: 600;
  flex-wrap: wrap;
}

.admin-nav a {
  color: #475569;
  border-bottom: 2px solid transparent;
  padding-bottom: 0.25rem;
}

.admin-nav a:hover {
  color: #2563eb;
  border-bottom-color: #2563eb;
  text-decoration: none;
}

.page-hero {
  background: #1e1e2e;
  color: #fff;
  border-radius: 12px;
  padding: 2rem 1.5rem;
  margin-bottom: 1.5rem;
}

.page-hero h1 {
  color: #fff;
  margin-top: 0;
}

.page-hero p {
  color: #cbd5e1;
  margin-bottom: 0;
}

.roadmap-grid, .pricing-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 1rem;
}

.roadmap-card, .pricing-card {
  background: transparent;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  padding: 1.25rem;
}

.roadmap-card h2, .pricing-card h2 {
  margin-top: 0;
  color: #0f172a;
}

.muted {
  color: #64748b;
}

.roadmap-phases {
  margin: 0.75rem 0 0;
  padding-left: 1.25rem;
}

.roadmap-phases li {
  margin-bottom: 0.4rem;
}

.pricing-amount {
  font-size: 1.75rem;
  font-weight: 800;
  color: #2563eb;
  margin: 0.75rem 0 0.25rem;
}

.video-embed {
  position: relative;
  aspect-ratio: 16 / 9;
  background: #0f172a;
  border-radius: 10px;
  overflow: hidden;
  margin-bottom: 1rem;
}

.video-embed iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
}

.lecture-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.lecture-list li {
  background: transparent;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  padding: 0.6rem 0.9rem;
  margin-bottom: 0.6rem;
  display: flex;
  align-items: baseline;
  gap: 0.6rem;
  flex-wrap: wrap;
}

.lecture-list li small {
  width: 100%;
  color: #64748b;
}

.lecture-label {
  font-weight: 700;
  color: #2563eb;
  white-space: nowrap;
}

.notification-bell {
  display: inline-flex;
  align-items: center;
  position: relative;
  color: #cbd5e1;
}

.notification-bell:hover {
  text-decoration: none;
  color: #fff;
}

.notification-icon {
  width: 1.25rem;
  height: 1.25rem;
}

.notification-badge {
  position: absolute;
  top: -0.4rem;
  right: -0.6rem;
  background: #dc2626;
  color: #fff;
  font-size: 0.65rem;
  font-weight: 700;
  min-width: 1rem;
  height: 1rem;
  padding: 0 0.2rem;
  border-radius: 999px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.notification-badge:empty, .notification-badge[style*="display: none"] {
  display: none;
}

.notification-item {
  background: transparent;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  padding: 0.75rem 1rem;
  margin-bottom: 0.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.notification-unread {
  background: transparent;
  border-color: #bfdbfe;
}

.notification-link {
  flex: 1;
  color: #0f172a;
}

.notification-link:hover {
  text-decoration: none;
}

.notification-message {
  margin: 0;
}

.notification-time {
  color: #64748b;
}

.whatsapp-float {
  position: fixed;
  right: 1.25rem;
  bottom: 1.25rem;
  width: 3.25rem;
  height: 3.25rem;
  background: #25d366;
  color: #fff;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
  z-index: 50;
}

.whatsapp-float:hover {
  background: #1fb557;
  color: #fff;
  text-decoration: none;
  transform: scale(1.05);
}

.whatsapp-icon {
  width: 1.75rem;
  height: 1.75rem;
}
