/* ============================================================
   NOUN CLUB — Instagram-matched theme
   Primary:  #8B1A1A  (deep crimson / maroon)
   Cream:    #F2DEB5  (warm beige)
   Gold:     #C49A35
   Dark bg:  #0D0D0D
   Surface:  #1A1A1A
   Surface2: #222222
   ============================================================ */

@font-face {
    font-family: "JannaLT";
    src: url("alfont_com_Janna-LT-Bold.ttf") format("truetype");
}

/* Apply font to everything EXCEPT Font Awesome icon elements */
*:not(.fa) {
  font-family: "JannaLT" !important;
}

* {
  box-sizing: border-box;
}

body {
  font-family: "JannaLT" !important;
  background: #0D0D0D;
  color: #D8D0C4;
  position: relative;
  direction: rtl;
}

a {
  color: #C49A35;
  transition: 0.4s;
}

a:hover, a:active, a:focus {
  color: #F2DEB5;
  outline: none;
  text-decoration: none;
}

h1, h2, h3, h4, h5, h6 {
  font-family: "JannaLT";
  font-weight: 400;
  margin: 0 0 20px 0;
  padding: 0;
  color: #F2DEB5;
}

/* Back to top */
/* Back to top layout properties */
.back-to-top {
  position: fixed;
  display: none;
  background: #8B1A1A;
  color: #F2DEB5;
  padding: 8px 14px 11px 14px;
  font-size: 16px;
  border-radius: 50%;
  right: 15px;
  bottom: 15px;
  transition: background 0.3s, transform 0.3s;
  box-shadow: 0 2px 12px rgba(139,26,26,0.5);
  z-index: 200;
}

/* Add this rule right below it to protect the icon font */
.back-to-top .fa {
  font-family: 'FontAwesome' !important;
}
.back-to-top:hover {
  background: #6e1414;
  color: #F2DEB5;
  transform: translateY(-3px);
}

/*--------------------------------------------------------------
# Main / Hero
--------------------------------------------------------------*/
#main {
  display: table;
  width: 100%;
  height: 100vh;
  background: url(../img/main-bg.webp) top center fixed;
  background-size: cover;
}

#main .main-logo { margin: 20px; }
#main .main-logo img { max-width: 100%; }

#main .main-container {
  background: rgba(0, 0, 0, 0.82);
  display: table-cell;
  margin: 0;
  padding: 0;
  text-align: center;
  vertical-align: middle;
}

#text {
  color: #F2DEB5;
  font-size: 32px;
  letter-spacing: 2px;
}

#main h2 {
  color: #C49A35;
  margin-bottom: 40px;
}

#main .rotating > .animated { display: inline-block; }

/* Scroll-down chevron */
.btn-scroll-down {
  display: inline-block;
  margin-top: 10px;
  color: rgba(242,222,181,0.5);
  font-size: 22px;
  animation: bounce 2s infinite;
}
.btn-scroll-down:hover { color: #8B1A1A; }


@keyframes bounce {
  0%, 100% { transform: translateY(0); }
  50%       { transform: translateY(8px); }
}

@media (max-width: 768px) {
  #main h2 { font-size: 22px; line-height: 28px; margin-bottom: 25px; }
}

/*--------------------------------------------------------------
# Header
--------------------------------------------------------------*/
#header {
  background: #0D0D0D;
  border-bottom: 1px solid #2a1a1a;
  padding: 15px 0;
  height: auto; /* Changed from fixed 72px to wrap contents naturally */
  min-height: 72px;
  position: relative;
  z-index: 1000;
}

/* Ensure the Bootstrap container acts as a flexbox row */
#header .container {
  display: flex !important;
  justify-content: space-between; /* Pushes Logo to one side, Nav Menu to the other */
  align-items: center;
  flex-direction: row; /* Honors RTL direction natively */
}

#header #logo {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0;
}

#header #logo a {
  display: inline-flex;
  align-items: center;
  text-decoration: none;
}

#header #logo p {
  color: #F2DEB5;
  font-size: 22px;
  margin: 0;
  padding-right: 10px; /* Right-side padding for proper RTL spacing */
}

#header #logo img { max-height: 55px; width: auto; }

@media (max-width: 991px) {
  #header #logo img { max-height: 45px; }
  #header #logo p { display: none; } /* Simpler hide logic */
}

/* Fixed Sticky Header State */
.is-sticky #header {
  position: fixed !important;
  top: 0;
  left: 0;
  right: 0;
  width: 100%;
  background: rgba(13,13,13,0.96) !important;
  box-shadow: 0 2px 14px rgba(139,26,26,0.3);
  z-index: 1000;
  padding: 10px 0; /* Marginally tighter layout while sticky */
}

/*--------------------------------------------------------------
# Header
--------------------------------------------------------------*/
#header {
  background: #0D0D0D;
  border-bottom: 1px solid #2a1a1a;
  padding: 15px 0;
  height: auto; /* Changed from fixed 72px to wrap contents naturally */
  min-height: 72px;
  position: relative;
  z-index: 1000;
}

/* Ensure the Bootstrap container acts as a flexbox row */
#header .container {
  display: flex !important;
  justify-content: space-between; /* Pushes Logo to one side, Nav Menu to the other */
  align-items: center;
  flex-direction: row; /* Honors RTL direction natively */
}

#header #logo {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0;
}

#header #logo a {
  display: inline-flex;
  align-items: center;
  text-decoration: none;
}

#header #logo p {
  color: #F2DEB5;
  font-size: 22px;
  margin: 0;
  padding-right: 10px; /* Right-side padding for proper RTL spacing */
}

#header #logo img { max-height: 55px; width: auto; }

@media (max-width: 991px) {
  #header #logo img { max-height: 45px; }
  #header #logo p { display: none; } /* Simpler hide logic */
}

/* Fixed Sticky Header State */
.is-sticky #header {
  position: fixed !important;
  top: 0;
  left: 0;
  right: 0;
  width: 100%;
  background: rgba(13,13,13,0.96) !important;
  box-shadow: 0 2px 14px rgba(139,26,26,0.3);
  z-index: 1000;
  padding: 10px 0; /* Marginally tighter layout while sticky */
}

/*--------------------------------------------------------------
# Navigation Menu
--------------------------------------------------------------*/
/* Converted the main nav wrapper to a horizontal flexbox row */
.nav-menu {
  display: flex !important;
  flex-direction: row !important;
  direction: rtl;
  align-items: center;
  margin: 0;
  padding: 0;
  list-style: none;
}

.nav-menu *, .nav-menu li { list-style: none; margin: 0; padding: 0; }

.nav-menu li { position: relative; white-space: nowrap; }

/* REMOVED: float: left; (Flexbox completely manages alignment now) */
.nav-menu > li {
  display: inline-block;
}

/* Standard Link Styling */
.nav-menu a {
  display: block;
  padding: 8px 18px;
  color: #D8D0C4;
  font-weight: 300;
  font-size: 20px;
  outline: none;
  text-decoration: none;
  transition: color 0.3s;
}

.nav-menu a:hover,
.nav-menu li:hover > a,
.nav-menu .menu-active > a,
.nav-menu a.active {
  color: #C49A35;
  text-decoration: none;
}

/* Dropdown styling updates (Kept stable for future use) */
.nav-menu ul {
  position: absolute;
  display: none;
  top: 100%;
  right: 0;
  left: auto;
  z-index: 99;
  margin: 4px 0 0 0;
  box-shadow: 0 4px 16px rgba(0,0,0,0.6);
}

.nav-menu li:hover > ul,
.nav-menu li.sfHover > ul { display: block; }
.nav-menu ul ul { top: 0; right: 100%; left: auto; }
.nav-menu ul li { min-width: 180px; background: #1A1A1A; border-top: 1px solid #2a2a2a; }
.nav-menu ul li:first-child { border-top: 0; }
.nav-menu ul li:hover { background: #222; }
.nav-menu ul li a { color: #D8D0C4; }
.nav-menu ul ul { margin: 0; }

/* Mobile Nav Toggle */
#mobile-nav-toggle {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  left: auto;
  z-index: 999;
  margin: 18px 18px 0 0;
  border: 0;
  background: none;
  font-size: 26px;
  display: none;
  transition: all 0.4s;
  outline: none;
  color: #F2DEB5;
}

/* Change your existing mobile media query to this: */
@media (max-width: 768px) {
  .mySlides { 
    aspect-ratio: 4 / 3 !important; /* CHANGED: Gives the container a boxier, taller shape on phones */
  }

  .custom-caption {
    padding: 8px 12px !important;    /* Tightens padding to preserve space */
  }

  .custom-caption h3 {
    font-size: 16px;                 /* Marginally downsizes text on mobile */
  }
}

/* Mobile Nav — slides from right (RTL) */
#mobile-nav {
  position: fixed;
  top: 0;
  padding-top: 55px;
  bottom: 0;
  z-index: 998;
  background: #0D0D0D;
  border-left: 1px solid #2a1a1a;
  right: -270px;
  left: auto;
  width: 270px;
  overflow-y: auto;
  transition: right 0.4s ease;
  direction: rtl;
}

#mobile-nav ul {
  display: flex !important;
  flex-direction: column !important;
}

#mobile-nav ul li { position: relative; }

#mobile-nav ul li a {
  color: #D8D0C4;
  font-size: 20px;
  padding: 14px 20px;
  display: block;
  outline: none;
  border-bottom: 1px solid #1e1e1e;
  transition: color 0.3s, background 0.3s;
}

#mobile-nav ul li a:hover {
  color: #C49A35;
  background: #1a1a1a;
}

body.mobile-nav-active { overflow: hidden; }
body.mobile-nav-active #mobile-nav { right: 0; }

#mobile-body-overly {
  width: 100%;
  height: 100%;
  z-index: 997;
  top: 0;
  left: 0;
  position: fixed;
  background: rgba(0,0,0,0.7);
  display: none;
}

/*--------------------------------------------------------------
# Sections Common
--------------------------------------------------------------*/
.section-padding { padding: 80px 0; }

.section-title {
  font-size: 30px;
  color: #F2DEB5;
  text-transform: uppercase;
  text-align: center;
  font-weight: 700;
  letter-spacing: 1px;
}

.section-description {
  text-align: center;
  margin-bottom: 40px;
  font-size: 20px;
  color: #AAA;
}

.section-title-divider {
  width: 60px;
  height: 3px;
  background: linear-gradient(90deg, #8B1A1A, #C49A35);
  margin: 0 auto 20px auto;
  border-radius: 2px;
}

/*--------------------------------------------------------------
# About Section
--------------------------------------------------------------*/
#about {
  background: #111111;
}

.about-info { text-align: right; }

.about-info p {
  font-size: 20px;
  color: #CCC;
  line-height: 1.9;
  margin-bottom: 30px;
}

.about-text {
  margin-top: 0;
  margin-bottom: 30px;
  line-height: 1.9;
}

.about-text:last-child {
  margin-bottom: 0;
  color: #F2DEB5;
  font-size: 22px;
}

.about-img { text-align: center; }

.about-img img {
  border-radius: 8px;
  max-width: 72%;
  border: 2px solid #2a1a1a;
  box-shadow: 0 6px 25px rgba(139,26,26,0.2);
}

@media (max-width: 768px) {
  .about-img { margin-top: 30px; }
  .about-img img { max-width: 90%; }
}

/*--------------------------------------------------------------
# Stats Bar
--------------------------------------------------------------*/
#stats {
  background: #8B1A1A;
  padding: 35px 0;
  position: relative;
  overflow: hidden;
}

#stats::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  background: linear-gradient(135deg, #8B1A1A 0%, #6e1414 50%, #8B1A1A 100%);
}

.stat-item {
  padding: 10px 20px;
  border-left: 1px solid rgba(242,222,181,0.2);
  position: relative;
  z-index: 1;
}

.stat-item:last-child { border-left: none; }

.stat-number {
  display: block;
  font-size: 40px;
  font-weight: 700;
  color: #F2DEB5;
  line-height: 1;
}

.stat-label {
  display: block;
  font-size: 15px;
  color: rgba(242,222,181,0.75);
  margin-top: 6px;
}

@media (max-width: 768px) {
  .stat-item { border-left: none; border-bottom: 1px solid rgba(242,222,181,0.2); }
  .stat-item:last-child { border-bottom: none; }
}

/*--------------------------------------------------------------
# About2 — Vision / Message / Goals
--------------------------------------------------------------*/
#about2 {
  background: #0D0D0D;
  padding: 80px 0;
}

.vmg-row {
  display: flex;
  flex-wrap: wrap;
  align-items: stretch;
}

.vmg-card {
  margin-bottom: 30px;
  display: flex;
  flex-direction: column;
}

#about2 .picture .pic {
  border-radius: 50%;
  margin: auto;
  overflow: hidden;
  height: 150px;
  width: 150px;
  border: 3px solid #8B1A1A;
  box-shadow: 0 0 0 4px #cb8642f9;
}

#about2 .picture .pic img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

#about2 .picture h4 {
  font-weight: 700;
  color: #F2DEB5;
  margin-top: 14px;
  font-size: 24px;
  text-align: center;
}

#about2 .quote {
  background: #1A1A1A;
  border: 1px solid #2a2a2a;
  padding: 28px 22px;
  margin-top: 15px;
  border-radius: 8px;
  text-align: center;
  flex: 1;
  border-top: 3px solid #8B1A1A;
}

#about2 .quote p {
  font-size: 19px;
  color: #CCC;
  line-height: 1.8;
  margin-bottom: 10px;
}

#about2 .quote p:last-child { margin-bottom: 0; }

/*--------------------------------------------------------------
# Team Section
--------------------------------------------------------------*/
#team {
  background: #111111;
  padding: 80px 0;
}

.team-table-wrap { overflow-x: auto; }

.team-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  font-size: 18px;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 4px 20px rgba(0,0,0,0.4);
}

.team-table tr { transition: background 0.2s; }
.team-table tr:nth-child(even) { background: #1a1a1a; }
.team-table tr:nth-child(odd)  { background: #141414; }
.team-table tr:hover { background: #1f1010; }

.team-table td {
  padding: 14px 22px;
  text-align: center;
  border-bottom: 1px solid #222;
  color: #CCC;
}

.team-table tr:last-child td { border-bottom: none; }

.team-table .name-cell {
  font-weight: 700;
  color: #F2DEB5;
  border-right: 4px solid #8B1A1A;
}

/*--------------------------------------------------------------
/* Interests Section Base
--------------------------------------------------------------*/
#interests {
  background: #0D0D0D;
  padding: 80px 0 60px 0;
}

/* 1. THE TITLE FIX: Centers the header and description perfectly */
#interests .section-title,
#interests .section-header,
#interests h2,
#interests h3 {
  text-align: center !important;
  display: block !important;
  width: 100% !important;
  margin-left: auto !important;
  margin-right: auto !important;
  color: #F2DEB5;
}

#interests .section-description,
#interests p:not(.interest-description) {
  text-align: center !important;
  display: block !important;
  max-width: 600px;
  margin: 0 auto 40px auto !important; /* Creates clean space below description */
  color: #fff;
}

/* 2. THE GRID FIX: Forces side-by-side equal-height boxes on desktop */
@media (min-width: 992px) {
  /* Targets only rows containing the columns */
  #interests .row {
    display: flex !important;
    flex-wrap: wrap !important;
    justify-content: center;
  }

  #interests .row > div[class*="col-"] {
    display: flex !important;
    flex-direction: column !important;
    margin-bottom: 30px;
  }
}

/* 3. THE BOX FIX: Brings back your beautiful cards with identical heights */
.interest-item {
  display: flex !important;
  flex-direction: column !important;
  flex-grow: 1 !important; /* Forces all cards in a row to match height */
  width: 100%;
  text-align: center;
  padding: 28px 20px;
  background: #1A1A1A !important; /* Restores the dark grey background */
  border: 1px solid #2a2a2a;
  border-radius: 8px;
  transition: transform 0.3s, box-shadow 0.3s, border-top-color 0.3s;
  border-top: 3px solid transparent;
  box-sizing: border-box;
}

/* 4. Hover, Typography & Spacing */
.interest-item:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 28px rgba(139,26,26,0.25);
  border-top-color: #8B1A1A;
  border-color: #2a1a1a;
}

.interest-icon {
  font-size: 30px;
  color: #C49A35;
  margin-bottom: 12px;
}

.interest-title {
  font-weight: 700;
  text-transform: uppercase;
  font-size: 20px;
  color: #F2DEB5;
  margin-bottom: 10px;
}

.interest-title a { 
  color: #F2DEB5; 
}

.interest-description {
  line-height: 1.8;
  font-size: 17px;
  color: #999;
  margin: 0;
}
/* Slideshow */
.slideshow-wrap {
  margin-top: 50px;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 6px 30px rgba(139,26,26,0.2);
  border: 1px solid #2a1a1a;
  position: relative;
}

.slideshow-counter {
  position: absolute;
  top: 12px;
  left: 16px;
  background: rgba(139,26,26,0.85);
  color: #F2DEB5;
  padding: 4px 12px;
  border-radius: 20px;
  font-size: 14px;
  z-index: 20;
}

.w3-content { text-align: center; position: relative; }

.mySlides {
  width: 100%;
  aspect-ratio: 16 / 7;
  position: relative;
  overflow: hidden;
  display: none;
  animation: fadeSlide 0.5s ease-in-out;
}

@keyframes fadeSlide {
  from { opacity: 0.3; }
  to   { opacity: 1; }
}

.mySlides img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}

.custom-caption {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  background: rgba(13,5,5,0.82);
  backdrop-filter: blur(5px);
  border-top: 1px solid rgba(196,154,53,0.25);
  color: #F2DEB5 !important;
  padding: 12px 20px !important;
  box-sizing: border-box;
  z-index: 10;
  direction: rtl;
  text-align: right;
}

.custom-caption h3 { font-size: 19px; margin: 0 0 4px 0; color: #F2DEB5; }
.custom-caption p  { font-size: 14px; margin: 0; color: #C49A35; }

.slide-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(139,26,26,0.7) !important;
  color: #F2DEB5 !important;
  border: none;
  padding: 10px 16px;
  font-size: 18px;
  border-radius: 6px !important;
  cursor: pointer;
  z-index: 15;
  transition: background 0.3s;
}

.slide-btn:hover { background: #8B1A1A !important; }
.slide-prev { right: 10px; }
.slide-next { left: 10px; }

.slide-dots {
  display: flex;
  justify-content: center;
  gap: 7px;
  padding: 10px 0;
  background: #111;
}

.slide-dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: rgba(255,255,255,0.15);
  cursor: pointer;
  transition: background 0.3s, transform 0.3s;
  border: none;
  padding: 0;
}

.slide-dot.active {
  background: #C49A35;
  transform: scale(1.35);
}

@media (max-width: 600px) {
  .mySlides { aspect-ratio: 4 / 3; }
}

/*--------------------------------------------------------------
# Achievements Section
--------------------------------------------------------------*/
#achievements {
  background: #111;
  padding: 80px 0;
}

.achievements-grid { margin-top: 10px; }

#achievements .achievements-item {
  background-position: center center;
  background-size: cover;
  background-repeat: no-repeat;
  position: relative;
  height: 230px;
  width: 100%;
  display: table;
  overflow: hidden;
  margin-bottom: 25px;
  cursor: default;
  border-radius: 6px;
  border: 1px solid #2a1a1a;
  box-shadow: 0 3px 14px rgba(0,0,0,0.4);
}

#achievements .achievements-item .details {
  height: 230px;
  background: rgba(139,26,26,0.92);
  display: table-cell;
  vertical-align: middle;
  opacity: 0;
  transition: opacity 0.3s;
  text-align: center;
  padding: 15px;
}

#achievements .achievements-item .details h4 {
  font-size: 19px;
  font-weight: 700;
  color: #F2DEB5;
  transform: translateY(-12px);
  transition: transform 0.3s, opacity 0.3s;
  opacity: 0;
  margin-bottom: 8px;
}

#achievements .achievements-item .details span {
  display: block;
  color: rgba(242,222,181,0.85);
  font-size: 15px;
  transform: translateY(12px);
  transition: transform 0.3s, opacity 0.3s;
  opacity: 0;
  line-height: 1.6;
}

#achievements .achievements-item:hover .details { opacity: 1; }
#achievements .achievements-item:hover .details h4,
#achievements .achievements-item:hover .details span {
  transform: translateY(0);
  opacity: 1;
}

/*--------------------------------------------------------------
# Contact / Registration Section
--------------------------------------------------------------*/
#contact {
  background: #0D0D0D;
  border-top: 1px solid #2a1a1a;
}

#form {
  text-align: center;
  font-size: 20px;
  padding: 20px 0 40px;
  color: #CCC;
}

#form p { line-height: 1.8; color: #CCC; }

.register-btn {
  display: inline-block;
  background: #8B1A1A;
  color: #F2DEB5 !important;
  font-size: 21px;
  padding: 14px 42px;
  border-radius: 6px;
  margin: 18px 0;
  transition: background 0.3s, transform 0.3s;
  box-shadow: 0 4px 18px rgba(139,26,26,0.4);
  border: 1px solid rgba(196,154,53,0.3);
}

.register-btn:hover {
  background: #6e1414;
  transform: translateY(-2px);
  color: #F2DEB5 !important;
}

.register-note {
  font-size: 16px !important;
  color: #666 !important;
  margin-top: 8px;
}

/*--------------------------------------------------------------
# Footer
--------------------------------------------------------------*/
#footer {
  background: #080808;
  border-top: 1px solid #2a1a1a;
  padding: 40px 0 25px;
  color: #CCC;
  text-align: center;
}

.footer-section { margin-bottom: 22px; }

.footer-label {
  font-size: 16px;
  color: #888;
  margin-bottom: 10px;
  letter-spacing: 1px;
}

.social-icons {
  display: flex;
  justify-content: center;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 5px;
}

.social-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: #1a1a1a;
  border: 1px solid #2a2a2a;
  color: #CCC !important;
  font-size: 18px;
  transition: background 0.3s, transform 0.3s, border-color 0.3s;
}

.social-icon:hover {
  background: #8B1A1A;
  border-color: #8B1A1A;
  transform: translateY(-3px);
  color: #F2DEB5 !important;
}

.copyright {
  font-size: 14px;
  color: #555;
  margin-top: 15px;
}

#logo-footer { text-align: center; margin-bottom: 15px; }
#logo-footer img { max-height: 65px; }

/* Gold decorative divider */
.footer-section + .footer-section {
  border-top: 1px solid #1e1e1e;
  padding-top: 18px;
}

