/**
 * SendLogForm - Unified send logging styles
 *
 * Design:
 * - Dark theme (#1a1a2e background context)
 * - Green accent (#B9FF66) for sent state
 * - Yellow/gold accent (#ffc800) for flash
 * - Purple accent (#9747ff) for feel buttons
 *
 * Phase 6 - Boulder Points Send Flow
 */

/* ============================================
   Container
   ============================================ */

.send-log-form {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 16px;
  width: 100%;
}

.send-log-form--disabled {
  opacity: 0.6;
  pointer-events: none;
}

/* ============================================
   Main Row - Send Button Area
   ============================================ */

.send-log-form__main-row {
  min-height: 48px;
  display: flex;
  align-items: center;
}

.send-log-form__centered {
  width: 100%;
  display: flex;
  justify-content: center;
}

.send-log-form__split {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
}

/* ============================================
   Send Button (Before Send) - Subtle Outline Style
   NOT green - save green for "Sent!" state
   ============================================ */

.send-log-form__send-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 48px;
  border-radius: 28px;
  border: 2px solid rgba(255, 255, 255, 0.3);
  background: transparent;
  color: rgba(255, 255, 255, 0.8);
  font-weight: 600;
  font-size: 16px;
  cursor: pointer;
  transition: all 0.2s ease;
  -webkit-tap-highlight-color: transparent;
}

.send-log-form__send-btn:hover:not(:disabled) {
  border-color: rgba(255, 255, 255, 0.5);
  background: rgba(255, 255, 255, 0.05);
  transform: scale(1.02);
}

.send-log-form__send-btn:active:not(:disabled) {
  transform: scale(0.98);
}

.send-log-form__send-icon {
  font-size: 14px;
}

/* ============================================
   Sent Button (After Send) - Filled Style
   ============================================ */

.send-log-form__sent-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 24px;
  border-radius: 24px;
  border: none;
  background: #B9FF66;
  color: #1a1a2e;
  font-weight: 600;
  font-size: 15px;
  cursor: pointer;
  transition: all 0.2s ease;
  -webkit-tap-highlight-color: transparent;
}

.send-log-form__sent-btn:hover:not(:disabled) {
  background: #a8e85c;
}

.send-log-form__sent-btn:active:not(:disabled) {
  transform: scale(0.98);
}

.send-log-form__sent-icon {
  font-size: 12px;
}

/* ============================================
   Right Group (Attempts Badge + Flash)
   ============================================ */

.send-log-form__right-group {
  display: flex;
  align-items: center;
  gap: 10px;
}

/* Attempts Badge - Shows only when > 1 */
.send-log-form__attempts-badge {
  padding: 6px 12px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 16px;
  color: rgba(255, 255, 255, 0.85);
  font-size: 14px;
  font-weight: 600;
}

/* ========================================
   Flash Button - Bulletproof Mobile Fix
   ======================================== */

.send-log-form__flash-btn {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  font-size: 18px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;

  /* Mobile touch fixes */
  -webkit-tap-highlight-color: transparent;
  -webkit-touch-callout: none;
  -webkit-user-select: none;
  user-select: none;
  touch-action: manipulation;

  /* Remove default focus outline */
  outline: none !important;

  /* Transition for smooth color change */
  transition: color 0.15s ease, background-color 0.15s ease, border-color 0.15s ease;
}

/* INACTIVE STATE - Default gray */
.send-log-form__flash-btn:not(.send-log-form__flash-btn--active) {
  border: 2px solid rgba(255, 255, 255, 0.2) !important;
  background: rgba(255, 255, 255, 0.05) !important;
  color: rgba(255, 255, 255, 0.4) !important;
}

/* INACTIVE + any pseudo-state - STILL gray (critical for mobile) */
.send-log-form__flash-btn:not(.send-log-form__flash-btn--active):hover,
.send-log-form__flash-btn:not(.send-log-form__flash-btn--active):focus,
.send-log-form__flash-btn:not(.send-log-form__flash-btn--active):active,
.send-log-form__flash-btn:not(.send-log-form__flash-btn--active):focus-visible,
.send-log-form__flash-btn:not(.send-log-form__flash-btn--active):focus-within {
  border: 2px solid rgba(255, 255, 255, 0.3) !important;
  background: rgba(255, 255, 255, 0.08) !important;
  color: rgba(255, 255, 255, 0.5) !important;
  outline: none !important;
  box-shadow: none !important;
}

/* ACTIVE STATE - Yellow/Gold */
.send-log-form__flash-btn--active {
  background: rgba(255, 200, 0, 0.15) !important;
  border: 2px solid #ffc800 !important;
  color: #ffc800 !important;
}

/* ACTIVE + any pseudo-state - STILL yellow */
.send-log-form__flash-btn--active:hover,
.send-log-form__flash-btn--active:focus,
.send-log-form__flash-btn--active:active,
.send-log-form__flash-btn--active:focus-visible,
.send-log-form__flash-btn--active:focus-within {
  background: rgba(255, 200, 0, 0.25) !important;
  border: 2px solid #ffc800 !important;
  color: #ffc800 !important;
  outline: none !important;
  box-shadow: none !important;
}

/* ============================================
   Details Toggle
   ============================================ */

.send-log-form__details-toggle {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 10px;
  background: none;
  border: none;
  color: rgba(255, 255, 255, 0.5);
  font-size: 13px;
  cursor: pointer;
  transition: color 0.2s;
  width: 100%;
  -webkit-tap-highlight-color: transparent;
}

.send-log-form__details-toggle:hover:not(:disabled) {
  color: rgba(255, 255, 255, 0.8);
}

.send-log-form__details-toggle svg {
  font-size: 10px;
}

/* ============================================
   Details Section (Collapsible)
   ============================================ */

.send-log-form__details {
  overflow: hidden;
}

.send-log-form__details-content {
  /* padding: 16px; */
  /* background: rgba(255, 255, 255, 0.05); */
  border-radius: 12px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

/* Row Layout */
.send-log-form__row {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.send-log-form__row--column {
  flex-direction: column;
  align-items: flex-start;
  gap: 8px;
}

.send-log-form__label {
  color: rgba(255, 255, 255, 0.6);
  font-size: 14px;
  font-weight: 500;
}

/* ============================================
   Attempts Control
   ============================================ */

.send-log-form__attempts-control {
  display: flex;
  align-items: center;
  gap: 16px;
}

.send-log-form__attempts-btn {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.2);
  background: rgba(255, 255, 255, 0.05);
  color: white;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
  -webkit-tap-highlight-color: transparent;
}

.send-log-form__attempts-btn:hover:not(:disabled) {
  background: rgba(255, 255, 255, 0.15);
  border-color: rgba(255, 255, 255, 0.4);
}

.send-log-form__attempts-btn:disabled {
  opacity: 0.3;
  cursor: not-allowed;
}

.send-log-form__attempts-btn svg {
  font-size: 12px;
}

.send-log-form__attempts-value {
  font-size: 20px;
  font-weight: 600;
  min-width: 40px;
  text-align: center;
  color: white;
}

/* ============================================
   Rating Stars
   ============================================ */

.send-log-form__rating {
  display: flex;
  gap: 4px;
}

.send-log-form__star {
  background: none;
  border: none;
  color: rgba(255, 255, 255, 0.25);
  font-size: 22px;
  cursor: pointer;
  padding: 4px;
  transition: all 0.15s ease;
  -webkit-tap-highlight-color: transparent;
}

.send-log-form__star:hover:not(:disabled) {
  color: rgba(255, 200, 0, 0.6);
  transform: scale(1.1);
}

.send-log-form__star--active {
  color: #ffc800;
}

/* ============================================
   Feel Buttons
   ============================================ */

.send-log-form__feel {
  display: flex;
  gap: 8px;
}

.send-log-form__feel-btn {
  padding: 8px 16px;
  border-radius: 20px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  background: rgba(255, 255, 255, 0.05);
  color: rgba(255, 255, 255, 0.7);
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
  -webkit-tap-highlight-color: transparent;
}

.send-log-form__feel-btn:hover:not(:disabled) {
  background: rgba(255, 255, 255, 0.12);
  border-color: rgba(255, 255, 255, 0.35);
}

.send-log-form__feel-btn--active {
  background: #9747ff;
  border-color: #9747ff;
  color: white;
}

.send-log-form__feel-btn--active:hover:not(:disabled) {
  background: #8a3ef0;
}

/* ============================================
   Comment Textarea
   ============================================ */

.send-log-form__comment {
  width: 100%;
  padding: 12px;
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.15);
  background: rgba(255, 255, 255, 0.05);
  color: white;
  font-size: 14px;
  font-family: inherit;
  resize: none;
  transition: border-color 0.2s;
}

.send-log-form__comment:focus {
  outline: none;
  border-color: rgba(185, 255, 102, 0.5);
}

.send-log-form__comment::placeholder {
  color: rgba(255, 255, 255, 0.3);
}

.send-log-form__comment-count {
  align-self: flex-end;
  font-size: 11px;
  color: rgba(255, 255, 255, 0.35);
}

/* ============================================
   Save Status
   ============================================ */

.send-log-form__status {
  text-align: right;
  font-size: 12px;
  padding-top: 8px;
  transition: color 0.2s;
}

.send-log-form__status--saving {
  color: rgba(255, 255, 255, 0.5);
}

.send-log-form__status--saved {
  color: #B9FF66;
}

.send-log-form__status--error {
  color: #ef4444;
}

/* ============================================
   Mobile Adjustments
   ============================================ */

.send-log-form--mobile {
  padding: 12px;
}

.send-log-form--mobile .send-log-form__send-btn {
  padding: 12px 40px;
  font-size: 15px;
}

.send-log-form--mobile .send-log-form__sent-btn {
  padding: 10px 20px;
  font-size: 14px;
}

.send-log-form--mobile .send-log-form__flash-btn {
  width: 40px;
  height: 40px;
  font-size: 16px;
}

.send-log-form--mobile .send-log-form__details-content {
  padding: 12px;
  gap: 14px;
}

.send-log-form--mobile .send-log-form__feel-btn {
  padding: 6px 12px;
  font-size: 12px;
}

.send-log-form--mobile .send-log-form__star {
  font-size: 20px;
}

.send-log-form--mobile .send-log-form__attempts-value {
  font-size: 18px;
}
