/*
Theme Name: Next One Creators
Theme URI: https://nextonecreators.com
Author: Next One Creators
Author URI: https://nextonecreators.com
Description: Premium, minimal, highly interactive Coming Soon theme for NEXT ONE CREATORS. Features an original creator runner mini-game, smooth interactive red glow cursor effect, and integrated "Next One Leads" WordPress admin dashboard with CSV export.
Version: 1.0.0
Requires at least: 5.8
Tested up to: 6.7
Requires PHP: 7.4
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: next-one-creators
Tags: coming-soon, minimal, custom-logo, entertainment, creator-economy, interactive, responsive
*/

/* ==========================================================================
   NEXT ONE CREATORS - COMING SOON THEME STYLES
   Visual Style: Minimal, White background, Soft Red accents, Modern Typography
   ========================================================================== */

:root {
  --bg-color: #FFFFFF;
  --bg-soft-red: #FFF5F5;
  --bg-subtle: #FAFAFA;
  --primary-red: #E50914;
  --primary-red-hover: #C50610;
  --electric-red: #FF2E36;
  --accent-soft: rgba(229, 9, 20, 0.06);
  --accent-glow: rgba(229, 9, 20, 0.22);
  --border-subtle: rgba(229, 9, 20, 0.12);
  --border-light: #F1F1F5;

  --text-primary: #0F172A;
  --text-secondary: #475569;
  --text-muted: #94A3B8;

  --font-family: 'Plus Jakarta Sans', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 20px;
  --radius-full: 9999px;

  --transition-smooth: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  --transition-fast: all 0.15s ease-out;
}

/* Reset & Box Sizing */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html, body {
  width: 100%;
  min-height: 100vh;
  background-color: var(--bg-color);
  color: var(--text-primary);
  font-family: var(--font-family);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
  position: relative;
}

/* Subtle Atmospheric Red Aura (Ultra Minimal) */
body::before {
  content: '';
  position: fixed;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 100vw;
  height: 50vh;
  max-width: 1200px;
  background: radial-gradient(ellipse 70% 60% at 50% -10%, rgba(229, 9, 20, 0.045) 0%, transparent 80%);
  pointer-events: none;
  z-index: 0;
}

/* Subtle Grain / Clean Overlay */
.site-wrapper {
  position: relative;
  z-index: 1;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  padding: 40px 24px 100px;
}

/* ==========================================================================
   HERO / MAIN SCREEN
   ========================================================================== */
.hero-container {
  max-width: 860px;
  width: 100%;
  margin: 0 auto;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

/* Entrance Animations */
@keyframes fadeInUp {
  0% {
    opacity: 0;
    transform: translateY(20px);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes fadeInScale {
  0% {
    opacity: 0;
    transform: scale(0.96);
  }
  100% {
    opacity: 1;
    transform: scale(1);
  }
}

@keyframes pulseGlow {
  0%, 100% {
    box-shadow: 0 0 0 0 rgba(229, 9, 20, 0.2);
  }
  50% {
    box-shadow: 0 0 20px 4px rgba(229, 9, 20, 0.15);
  }
}

/* Secret Project Pill / Status Indicator */
.project-status {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 16px;
  background-color: var(--accent-soft);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-full);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--primary-red);
  margin-bottom: 24px;
  animation: fadeInUp 0.8s cubic-bezier(0.16, 1, 0.3, 1) 0.1s both;
}

.status-dot {
  width: 7px;
  height: 7px;
  background-color: var(--primary-red);
  border-radius: 50%;
  display: inline-block;
  animation: pulseGlow 2.5s infinite;
}

/* Brand Logo / Name */
.brand-identity {
  margin-bottom: 12px;
  animation: fadeInUp 0.9s cubic-bezier(0.16, 1, 0.3, 1) 0.25s both;
}

.brand-logo-img {
  max-height: 52px;
  width: auto;
  display: block;
  margin: 0 auto;
  object-fit: contain;
}

.brand-name {
  font-size: clamp(2.4rem, 6vw, 4.4rem);
  font-weight: 900;
  letter-spacing: -0.035em;
  line-height: 1.05;
  color: var(--text-primary);
  text-transform: uppercase;
}

.brand-name .highlight-red {
  color: var(--primary-red);
}

/* Tagline */
.brand-tagline {
  font-size: clamp(1.25rem, 3vw, 1.85rem);
  font-weight: 600;
  letter-spacing: -0.015em;
  color: var(--text-secondary);
  margin-bottom: 24px;
  animation: fadeInUp 0.9s cubic-bezier(0.16, 1, 0.3, 1) 0.45s both;
}

.brand-tagline .dot {
  color: var(--primary-red);
}

/* Coming Soon Subtle Message */
.coming-soon-message {
  margin-bottom: 36px;
  animation: fadeInUp 0.9s cubic-bezier(0.16, 1, 0.3, 1) 0.65s both;
}

.coming-soon-title {
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 4px;
}

.coming-soon-subtitle {
  font-size: 0.92rem;
  color: var(--text-muted);
  font-weight: 400;
  letter-spacing: 0.01em;
}

/* ==========================================================================
   MINI-GAME CONTAINER ("The Next One Runner")
   ========================================================================== */
.game-wrapper {
  width: 100%;
  max-width: 680px;
  margin: 10px auto 30px;
  animation: fadeInScale 1s cubic-bezier(0.16, 1, 0.3, 1) 0.85s both;
  position: relative;
}

.game-card {
  background: #FFFFFF;
  border: 1px solid rgba(229, 9, 20, 0.1);
  border-radius: var(--radius-lg);
  padding: 16px 20px 20px;
  box-shadow: 0 4px 24px -6px rgba(229, 9, 20, 0.06), 0 1px 3px rgba(0, 0, 0, 0.02);
  transition: var(--transition-smooth);
}

.game-card:hover {
  border-color: rgba(229, 9, 20, 0.2);
  box-shadow: 0 8px 30px -4px rgba(229, 9, 20, 0.09);
}

.game-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
  padding-bottom: 10px;
  border-bottom: 1px dashed var(--border-light);
}

.game-title-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--primary-red);
}

.game-scores {
  display: flex;
  gap: 16px;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-secondary);
  font-variant-numeric: tabular-nums;
}

.game-score-item span {
  color: var(--text-primary);
  font-weight: 700;
}

.game-score-item.score-high span {
  color: var(--primary-red);
}

/* Canvas Area */
.canvas-container {
  width: 100%;
  position: relative;
  border-radius: var(--radius-md);
  overflow: hidden;
  background-color: #FAFAFC;
  cursor: pointer;
}

#runnerCanvas {
  display: block;
  width: 100%;
  height: 180px;
  background: transparent;
  user-select: none;
  -webkit-user-select: none;
}

/* Game Controls Hint */
.game-hint {
  margin-top: 10px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.74rem;
  color: var(--text-muted);
}

.game-key-pill {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.key-badge {
  display: inline-block;
  padding: 1px 6px;
  background: var(--bg-soft-red);
  border: 1px solid var(--border-subtle);
  border-radius: 4px;
  font-size: 0.68rem;
  font-weight: 700;
  color: var(--primary-red);
}

/* ==========================================================================
   FIXED CONTACT US BUTTON
   ========================================================================== */
.fixed-contact-bar {
  position: fixed;
  bottom: 28px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 100;
  animation: fadeInUp 0.8s cubic-bezier(0.16, 1, 0.3, 1) 1.05s both;
}

.btn-contact {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 13px 28px;
  background-color: var(--primary-red);
  color: #FFFFFF;
  border: none;
  border-radius: var(--radius-full);
  font-family: var(--font-family);
  font-size: 0.92rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  cursor: pointer;
  box-shadow: 0 4px 18px rgba(229, 9, 20, 0.28), 0 2px 6px rgba(0, 0, 0, 0.05);
  transition: var(--transition-smooth);
  outline: none;
}

.btn-contact svg {
  width: 17px;
  height: 17px;
  transition: transform 0.25s ease;
}

.btn-contact:hover {
  background-color: var(--electric-red);
  transform: translateY(-2px) scale(1.03);
  box-shadow: 0 8px 24px rgba(229, 9, 20, 0.38), 0 3px 8px rgba(0, 0, 0, 0.08);
}

.btn-contact:hover svg {
  transform: translateX(3px);
}

.btn-contact:active {
  transform: translateY(0) scale(0.98);
}

/* ==========================================================================
   CONTACT US MODAL (Modern Native Dialog + Full-Screen Scroll Wrapper)
   ========================================================================== */
body.modal-open,
body:has(.contact-dialog[open]) {
  overflow: hidden !important;
}

/* Hide fixed contact button when modal is open so it NEVER overlaps */
body.modal-open .fixed-contact-bar,
body:has(.contact-dialog[open]) .fixed-contact-bar {
  display: none !important;
  opacity: 0 !important;
  visibility: hidden !important;
  pointer-events: none !important;
}

/* Full Viewport Dialog Shell */
.contact-dialog {
  position: fixed !important;
  top: 0 !important;
  left: 0 !important;
  right: 0 !important;
  bottom: 0 !important;
  width: 100vw !important;
  height: 100vh !important;
  max-width: 100vw !important;
  max-height: 100vh !important;
  margin: 0 !important;
  padding: 0 !important;
  border: none !important;
  background: transparent !important;
  overflow: hidden !important;
  z-index: 99999 !important;
  outline: none;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease;
}

.contact-dialog[open] {
  opacity: 1;
  pointer-events: auto;
  display: block !important;
}

.contact-dialog::backdrop {
  background: rgba(15, 23, 42, 0.6);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

/* Dedicated Backdrop Layer */
.modal-backdrop-layer {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  background: rgba(15, 23, 42, 0.6);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  z-index: 1;
}

/* Full-Screen Touch-Scroll Wrapper: Guaranteed smooth scrolling on phones and tablets */
.modal-scroll-wrapper {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 2;
  overflow-y: auto !important;
  overflow-x: hidden !important;
  -webkit-overflow-scrolling: touch !important;
  overscroll-behavior-y: contain;
  touch-action: pan-y !important;
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 32px 16px;
  box-sizing: border-box;
}

/* Modal Inner Card */
.modal-content {
  background: #FFFFFF;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-subtle);
  padding: 32px 28px 36px;
  position: relative;
  width: 100%;
  max-width: 520px;
  margin: auto;
  box-sizing: border-box;
  box-shadow: 0 25px 60px -15px rgba(15, 23, 42, 0.3);
  transform: scale(0.96) translateY(12px);
  transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

.contact-dialog[open] .modal-content {
  transform: scale(1) translateY(0);
}

.modal-header {
  margin-bottom: 22px;
  padding-right: 32px;
}

.modal-close-btn {
  position: absolute;
  top: 22px;
  right: 22px;
  width: 34px;
  height: 34px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-soft-red);
  border: 1px solid var(--border-subtle);
  border-radius: 50%;
  color: var(--text-secondary);
  cursor: pointer;
  transition: var(--transition-fast);
}

.modal-close-btn:hover {
  background: var(--primary-red);
  color: #FFFFFF;
  border-color: var(--primary-red);
  transform: rotate(90deg);
}

.modal-title {
  font-size: 1.55rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--text-primary);
  margin-bottom: 6px;
}

.modal-subtitle {
  font-size: 0.88rem;
  color: var(--text-secondary);
}

/* Form Styles */
.contact-form {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
  text-align: left;
}

.form-label {
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--text-primary);
}

.form-label .required {
  color: var(--primary-red);
}

/* Contact Type Selector (Pills) */
.type-selector-group {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
}

.type-pill {
  position: relative;
}

.type-pill input[type="radio"] {
  position: absolute;
  opacity: 0;
  width: 0;
  height: 0;
}

.type-pill label {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 9px 8px;
  background: #FAFAFC;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-sm);
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text-secondary);
  cursor: pointer;
  transition: var(--transition-fast);
  text-align: center;
}

.type-pill input[type="radio"]:checked + label {
  background: var(--bg-soft-red);
  border-color: var(--primary-red);
  color: var(--primary-red);
  font-weight: 700;
}

.type-pill label:hover {
  border-color: rgba(229, 9, 20, 0.4);
}

/* Inputs & Textarea */
.form-input, .form-textarea {
  width: 100%;
  padding: 10px 14px;
  font-family: var(--font-family);
  font-size: 0.9rem;
  color: var(--text-primary);
  background: #FAFAFC;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-sm);
  transition: var(--transition-fast);
  outline: none;
}

.form-input:focus, .form-textarea:focus {
  background: #FFFFFF;
  border-color: var(--primary-red);
  box-shadow: 0 0 0 3px rgba(229, 9, 20, 0.1);
}

.form-textarea {
  min-height: 90px;
  resize: vertical;
}

/* Submit Button */
.btn-submit {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  min-height: 50px;
  padding: 14px 20px;
  background-color: var(--primary-red);
  color: #FFFFFF;
  border: none;
  border-radius: var(--radius-sm);
  font-family: var(--font-family);
  font-size: 0.98rem;
  font-weight: 700;
  cursor: pointer;
  transition: var(--transition-fast);
  margin-top: 10px;
  margin-bottom: 6px;
  position: relative;
  z-index: 5;
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
}

.btn-submit:hover:not(:disabled) {
  background-color: var(--electric-red);
  box-shadow: 0 4px 16px rgba(229, 9, 20, 0.35);
}

.btn-submit:active:not(:disabled) {
  transform: scale(0.99);
}

.btn-submit:disabled {
  opacity: 0.65;
  cursor: not-allowed;
}

.btn-spinner {
  width: 18px;
  height: 18px;
  border: 2px solid rgba(255, 255, 255, 0.3);
  border-top-color: #FFFFFF;
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
  display: none;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

/* Submission Messages */
.form-feedback {
  display: none;
  padding: 14px 16px;
  border-radius: var(--radius-sm);
  font-size: 0.88rem;
  font-weight: 600;
  text-align: center;
  margin-top: 14px;
}

.form-feedback.success {
  display: block;
  background: #F0FDF4;
  border: 1px solid #BBF7D0;
  color: #166534;
}

.form-feedback.error {
  display: block;
  background: #FEF2F2;
  border: 1px solid #FECACA;
  color: #991B1B;
}

/* ==========================================================================
   INTERACTIVE CURSOR EFFECT (Desktop)
   ========================================================================== */
.custom-cursor-dot,
.custom-cursor-glow {
  position: fixed;
  top: 0;
  left: 0;
  border-radius: 50%;
  pointer-events: none;
  z-index: 9999;
  transform: translate(-50%, -50%);
  transition: opacity 0.3s ease;
}

.custom-cursor-dot {
  width: 7px;
  height: 7px;
  background-color: var(--primary-red);
  box-shadow: 0 0 6px rgba(229, 9, 20, 0.6);
}

.custom-cursor-glow {
  width: 44px;
  height: 44px;
  background: radial-gradient(circle, rgba(229, 9, 20, 0.18) 0%, rgba(229, 9, 20, 0.04) 50%, transparent 75%);
  transition: width 0.25s ease, height 0.25s ease, background 0.25s ease;
}

/* Expanded Cursor on Hoverable Elements */
body.cursor-hover .custom-cursor-glow {
  width: 70px;
  height: 70px;
  background: radial-gradient(circle, rgba(229, 9, 20, 0.25) 0%, rgba(229, 9, 20, 0.07) 50%, transparent 75%);
}

body.cursor-hover .custom-cursor-dot {
  transform: translate(-50%, -50%) scale(1.4);
}

/* Mobile Touch Ripple Effect */
.touch-ripple {
  position: fixed;
  border-radius: 50%;
  pointer-events: none;
  z-index: 9998;
  transform: translate(-50%, -50%) scale(0);
  background: radial-gradient(circle, rgba(229, 9, 20, 0.25) 0%, transparent 70%);
  animation: rippleAnimation 0.6s ease-out forwards;
}

@keyframes rippleAnimation {
  0% {
    width: 0;
    height: 0;
    opacity: 0.8;
    transform: translate(-50%, -50%) scale(0.2);
  }
  100% {
    width: 140px;
    height: 140px;
    opacity: 0;
    transform: translate(-50%, -50%) scale(1);
  }
}

/* ==========================================================================
   RESPONSIVE DESIGN (Tablets & Mobile)
   ========================================================================== */
@media (max-width: 768px) {
  .modal-scroll-wrapper {
    align-items: flex-start !important;
    padding: 24px 14px 60px !important;
  }

  .modal-content {
    margin-top: 10px;
    margin-bottom: 40px;
    padding: 26px 20px 32px;
  }
}

@media (max-width: 640px) {
  .site-wrapper {
    padding: 30px 16px 90px;
  }

  .brand-name {
    font-size: 2.2rem;
  }

  .brand-tagline {
    font-size: 1.15rem;
    margin-bottom: 18px;
  }

  .coming-soon-title {
    font-size: 0.96rem;
  }

  .coming-soon-subtitle {
    font-size: 0.84rem;
  }

  .game-card {
    padding: 12px 14px 14px;
    border-radius: var(--radius-md);
  }

  #runnerCanvas {
    height: 150px;
  }

  /* Mobile Modal Touch-Scroll Optimization */
  .modal-scroll-wrapper {
    align-items: flex-start !important;
    padding: 14px 10px max(110px, calc(env(safe-area-inset-bottom, 24px) + 85px)) !important;
  }

  .modal-content {
    margin-top: 4px;
    margin-bottom: 50px;
    padding: 20px 15px 24px;
    border-radius: var(--radius-md);
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.25);
  }

  .modal-header {
    margin-bottom: 16px;
    padding-right: 28px;
  }

  .modal-title {
    font-size: 1.35rem;
  }

  .modal-subtitle {
    font-size: 0.8rem;
  }

  .form-group {
    gap: 4px;
    margin-bottom: 2px;
  }

  .type-selector-group {
    grid-template-columns: repeat(3, 1fr);
    gap: 6px;
  }

  .type-pill label {
    padding: 8px 4px;
    font-size: 0.76rem;
  }

  .form-input, .form-textarea {
    font-size: 16px; /* Prevents auto-zoom on iOS Safari */
    padding: 9px 12px;
  }

  .form-textarea {
    min-height: 70px;
  }

  .btn-submit {
    min-height: 52px;
    font-size: 1rem;
    margin-top: 12px;
    margin-bottom: 10px;
    box-shadow: 0 4px 18px rgba(229, 9, 20, 0.4);
  }

  .btn-contact {
    padding: 11px 22px;
    font-size: 0.88rem;
  }

  .fixed-contact-bar {
    bottom: 20px;
  }
}

/* Hide desktop cursor on touch screens */
@media (pointer: coarse) {
  .custom-cursor-dot,
  .custom-cursor-glow {
    display: none !important;
  }
}
