@import url('e61e21aec67c4d2398cd116d36785bc3.css');

* {
  box-sizing: border-box;
}

html, body {
  height: 100%;
  margin: 0;
  padding: 0;
  overflow: hidden;
  background-color: #000;
  color: #fff;
  font-family: 'Russo One', sans-serif;
  user-select: none;
}

.container {
  width: 100%;
  height: 100%;
  position: relative;
}

.loading-init {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  background-color: #000;
  z-index: 1000;
  transition: opacity 0.5s;
}

.loading-init__header {
  font-size: 2.5em;
  margin-bottom: 20px;
  color: #fff;
}

.loading-init__status {
  font-size: 1.2em;
  color: #888;
}

.stage-container {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}

.canvas-container {
  width: 100%;
  height: 100%;
  position: absolute;
  top: 0;
  left: 0;
}

canvas {
  display: block;
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
}

.text-launch-container {
  position: absolute;
  bottom: 40px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  align-items: center;
  gap: 8px;
  z-index: 100;
  padding: 6px 6px 6px 20px;
  background: rgba(10, 10, 10, 0.4);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 100px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.2);
  transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  flex-wrap: nowrap;
  display:none
}

.text-launch-container:hover, .text-launch-container:focus-within {
  background: rgba(20, 20, 20, 0.6);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.3);
  border-color: rgba(255, 255, 255, 0.15);
}

.text-launch-input {
  background: transparent;
  border: none;
  color: #fff;
  font-family: 'Russo One', sans-serif;
  font-size: 16px;
  width: 180px;
  outline: none;
  letter-spacing: 1px;
}

.text-launch-input::placeholder {
  color: rgba(255, 255, 255, 0.4);
  transition: color 0.3s;
}

.text-launch-input:focus::placeholder {
  color: rgba(255, 255, 255, 0.2);
}

.text-launch-btn {
  background: #fff;
  color: #000;
  border: none;
  padding: 8px 20px;
  border-radius: 100px;
  font-family: 'Russo One', sans-serif;
  font-size: 14px;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  white-space: nowrap;
}

.text-launch-btn:hover:not(:disabled) {
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(255, 255, 255, 0.2);
}

.text-launch-btn:active:not(:disabled) {
  transform: translateY(1px);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.text-launch-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  background: rgba(255, 255, 255, 0.05);
  border-color: transparent;
}

/* Mobile responsive adjustments */
@media (max-width: 640px) {
  .text-launch-container {
    bottom: 20px;
    width: 90%;
    max-width: 360px;
    padding: 4px 4px 4px 16px;
  }
  
  .text-launch-input {
    width: 100%;
    font-size: 14px;
  }
  
  .text-launch-btn {
    padding: 8px 16px;
    font-size: 13px;
  }
  
  .menu__inner-wrap {
    padding: 60px 20px 20px 20px;
  }
  
  .close-menu-btn {
    top: 15px;
    right: 15px;
  }
}

.controls {
  position: absolute;
  top: 20px;
  right: 20px;
  display: flex;
  flex-direction: column;
  gap: 15px;
  z-index: 100;
  transition: opacity 0.3s;
  display:none
}

.btn {
  width: 50px;
  height: 50px;
  border-radius: 50%;
  background-color: rgba(255, 255, 255, 0.1);
  display: flex;
  justify-content: center;
  align-items: center;
  cursor: pointer;
  transition: background-color 0.2s;
  backdrop-filter: blur(5px);
}

.btn:hover {
  background-color: rgba(255, 255, 255, 0.25);
}

.btn svg {
  pointer-events: none;
}

.menu {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.85);
  z-index: 200;
  display: flex;
  justify-content: center;
  align-items: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s;
}

.menu.open {
  opacity: 1;
  pointer-events: auto;
}

.menu.hide {
  display: none;
}

.menu__inner-wrap {
  width: 90%;
  max-width: 500px;
  background-color: #111;
  padding: 40px;
  border-radius: 10px;
  position: relative;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
  max-height: 90vh;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}

.close-menu-btn {
  position: absolute;
  top: 20px;
  right: 20px;
  width: 40px;
  height: 40px;
}

.menu__header {
  font-size: 2em;
  margin-bottom: 10px;
  color: #fff;
}

.menu__subheader {
  font-size: 1em;
  margin-bottom: 30px;
  color: #888;
}

form {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.form-option {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.form-option label {
  font-size: 1.1em;
  color: #ccc;
}

select {
  background-color: #222;
  color: #fff;
  border: 1px solid #444;
  padding: 8px 12px;
  border-radius: 5px;
  font-family: inherit;
  font-size: 1em;
  outline: none;
}

input[type="checkbox"] {
  width: 20px;
  height: 20px;
}

.credits {
  margin-top: 40px;
  text-align: center;
  color: #666;
  font-size: 0.8em;
  width: 100%;
}

.file-input-wrapper {
  display: flex;
  gap: 10px;
}

.btn-file-upload, .btn-file-reset {
  background-color: #333;
  color: #fff;
  border: 1px solid #555;
  padding: 8px 12px;
  border-radius: 5px;
  cursor: pointer;
  font-family: inherit;
  font-size: 0.9em;
  transition: background-color 0.2s;
}

.btn-file-upload:hover, .btn-file-reset:hover {
  background-color: #444;
}

.btn-file-reset {
  background-color: #522;
  border-color: #733;
}

.btn-file-reset:hover {
  background-color: #633;
}

/* Screenshot mode: Hide all UI elements */
.screenshot-mode .controls,
.screenshot-mode .text-launch-container,
.screenshot-mode .menu,
.screenshot-mode .help-modal,
.screenshot-mode .loading-init,
.recording-mode .controls,
.recording-mode .text-launch-container,
.recording-mode .menu,
.recording-mode .help-modal,
.recording-mode .loading-init {
  display: none !important;
}

.record-btn.recording svg {
  fill: #ff0043;
}

.recording-status {
  position: absolute;
  top: 20px;
  right: 20px;
  display: flex;
  align-items: center;
  gap: 15px;
  z-index: 1000;
  display: none;
}

.recording-mode .recording-status {
  display: flex;
}

.recording-timer {
  color: white;
  font-family: 'Russo One', sans-serif;
  font-size: 20px;
  text-shadow: 0 1px 2px rgba(0,0,0,0.5);
  letter-spacing: 1px;
}

.stop-record-btn {
  background: rgba(255, 0, 67, 0.9);
  width: 44px;
  height: 44px;
  border-radius: 50%;
  display: flex;
  justify-content: center;
  align-items: center;
  cursor: pointer;
  transition: transform 0.2s;
}

.stop-record-btn:hover {
  transform: scale(1.1);
  background: #ff0043;
}

.stop-record-btn svg {
  width: 20px;
  height: 20px;
}

/* Share Modal Styles */
.share-modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 2000;
  display: flex;
  justify-content: center;
  align-items: center;
  opacity: 1;
  pointer-events: auto;
  transition: opacity 0.3s;
}

.share-modal.hide {
  opacity: 0;
  pointer-events: none;
}

.share-modal__overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.85);
  backdrop-filter: blur(5px);
}

.share-modal__inner {
  width: 95%;
  max-width: 800px;
  background-color: #1a1a1a;
  border-radius: 16px;
  position: relative;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.6);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border: 1px solid rgba(255, 215, 0, 0.2);
  max-height: 90vh;
}

.share-modal__header {
  padding: 15px;
  text-align: center;
  font-size: 1.2em;
  color: #FFD700;
  background: linear-gradient(to bottom, #2a2a2a, #1a1a1a);
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  flex-shrink: 0;
}

.close-share-btn {
  position: absolute;
  top: 10px;
  right: 10px;
  width: 32px;
  height: 32px;
  z-index: 10;
  background-color: rgba(255, 255, 255, 0.1);
}

.share-modal__content {
  padding: 20px;
  overflow-y: hidden; /* Handle scrolling in children */
  display: flex;
  flex-direction: row;
  gap: 20px;
  height: 100%;
}

.share-modal__preview {
  flex: 0 0 45%;
  background-color: #000;
  border-radius: 8px;
  overflow: hidden;
  display: flex;
  justify-content: center;
  align-items: center;
  border: 1px solid #333;
  /* Aspect ratio constraint or max-height */
  max-height: 100%;
}

.share-preview-img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
}

.share-modal__controls {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 15px;
  overflow-y: auto;
}

.share-tabs {
  display: flex;
  gap: 10px;
  margin-bottom: 10px;
}

.share-tab {
  flex: 1;
  padding: 10px;
  background-color: #333;
  border: none;
  border-radius: 8px;
  color: #888;
  cursor: pointer;
  font-family: inherit;
  font-weight: bold;
  transition: all 0.2s;
  white-space: nowrap; /* Prevent wrapping */
  font-size: 1em;
}

.share-tab.active {
  background-color: #FFD700;
  color: #000;
  box-shadow: 0 0 10px rgba(255, 215, 0, 0.3);
}

.share-panel {
  display: none;
  flex-direction: column;
  gap: 15px;
  flex: 1;
}

.share-panel.active {
  display: flex;
}

/* Fortune Panel */
.fortune-display-container {
  flex: 1;
  background-color: #222;
  border-radius: 8px;
  display: flex;
  justify-content: center;
  align-items: center;
  border: 1px dashed #444;
  min-height: 120px;
}

.fortune-display {
  font-size: 2em;
  color: #FFD700;
  text-align: center;
  font-weight: bold;
}

.custom-message-input {
  width: 100%;
  height: 100px;
  background-color: #222;
  border: 1px solid #444;
  border-radius: 8px;
  padding: 12px;
  color: #fff;
  font-family: inherit;
  resize: none;
  font-size: 1em;
}

.custom-message-input:focus {
  outline: none;
  border-color: #FFD700;
}

.btn-draw-fortune, .btn-generate-poster {
  width: 100%;
  padding: 12px;
  border: none;
  border-radius: 50px;
  font-family: inherit;
  font-size: 1em;
  cursor: pointer;
  font-weight: bold;
  transition: transform 0.1s, opacity 0.2s;
  white-space: nowrap; /* Prevent wrapping */
}

.btn-draw-fortune {
  background: linear-gradient(135deg, #ff4d4d, #b30000);
  color: white;
  box-shadow: 0 4px 15px rgba(255, 0, 0, 0.3);
}

.btn-generate-poster {
  background: linear-gradient(135deg, #FFD700, #FFA500);
  color: #000;
  margin-top: 10px;
  box-shadow: 0 4px 15px rgba(255, 215, 0, 0.3);
}

.btn-draw-fortune:hover, .btn-generate-poster:hover {
  opacity: 0.9;
  transform: translateY(-2px);
}

.btn-draw-fortune:active, .btn-generate-poster:active {
  transform: translateY(0);
}

/* Immersive Mode Logic */
.controls.hide,
.text-launch-container.hide {
  opacity: 0;
  pointer-events: none;
  visibility: hidden;
  transition: opacity 0.5s ease-in-out;
}

/* Toast Notification */
.toast-container {
  position: fixed;
  top: 20%;
  left: 50%;
  transform: translateX(-50%);
  background-color: rgba(0, 0, 0, 0.8);
  color: #fff;
  padding: 12px 24px;
  border-radius: 50px;
  font-size: 14px;
  z-index: 3000;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.3s ease;
  text-align: center;
  border: 1px solid rgba(255, 255, 255, 0.15);
  backdrop-filter: blur(4px);
  box-shadow: 0 4px 12px rgba(0,0,0,0.3);
  max-width: 90%;
}

.toast-container.show {
  opacity: 1;
}

/* Mobile responsive adjustments for Share Modal */
@media (max-width: 768px) {
  .share-modal__inner {
    flex-direction: column;
    height: auto;
    max-height: 90vh;
  }
  
  .share-modal__content {
    flex-direction: column;
    padding: 15px;
    gap: 15px;
    overflow-y: auto;
  }
  
  .share-modal__preview {
    flex: 0 0 auto;
    width: 100%;
    height: 240px; /* Reduced height for mobile preview to fit screen */
    margin-bottom: 0;
  }
  
  .share-modal__controls {
    flex: 0 0 auto;
    gap: 10px; /* Reduced gap */
  }
  
  .share-tab {
    font-size: 0.9em;
    padding: 8px 5px;
  }
  
  .btn-draw-fortune, .btn-generate-poster {
    font-size: 0.95em;
    padding: 10px;
    margin-top: 5px; /* Reduced margin */
  }
  
  .fortune-display-container {
    min-height: 80px; /* Reduced min-height */
  }

  .fortune-display {
    font-size: 1.5em;
  }
}
.video-container{
  position: absolute;
  top: 45%;
  left: 45%;
  
}

.video-container video {
	height:30vh;
	mix-blend-mode: screen;
}