/* Organic Mr.Teamwork Add-ons - Shared Popups Styles */

/* Overlay */
.omtw-popup-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(15, 23, 18, 0.75);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 999999;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
  padding: 16px;
  box-sizing: border-box;
}

.omtw-popup-overlay.is-open {
  opacity: 1;
  visibility: visible;
}

/* Card Chrome */
.omtw-popup-card {
  background: #ffffff;
  border-radius: 16px;
  width: 100%;
  max-width: 780px;
  box-shadow: 0 25px 60px rgba(0, 0, 0, 0.35);
  overflow: hidden;
  transform: translateY(24px) scale(0.98);
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  position: relative;
  max-height: 90vh;
  display: flex;
  flex-direction: column;
}

.omtw-popup-overlay.is-open .omtw-popup-card {
  transform: translateY(0) scale(1);
}

/* Header Strip */
.omtw-popup-header {
  background: #1F3D2B;
  color: #ffffff;
  padding: 20px 28px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  position: relative;
}

.omtw-popup-header-meta {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.omtw-popup-badge {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: #94B48A;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 6px;
}

.omtw-popup-title {
  font-family: 'Fraunces', Georgia, serif;
  font-size: 24px;
  font-weight: 700;
  color: #ffffff;
  margin: 0;
  line-height: 1.25;
}

.omtw-popup-close {
  background: rgba(255, 255, 255, 0.12);
  border: none;
  color: #ffffff;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 18px;
  transition: background 0.2s ease, transform 0.2s ease;
  flex-shrink: 0;
}

.omtw-popup-close:hover {
  background: rgba(255, 255, 255, 0.25);
  transform: rotate(90deg);
}

/* Body Content */
.omtw-popup-body {
  padding: 28px;
  overflow-y: auto;
  flex: 1;
}

/* Grid Layout for Forms */
.omtw-popup-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px 20px;
}

.omtw-popup-full {
  grid-column: span 2;
}

.omtw-field-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.omtw-field-label {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.6px;
  color: #2D3748;
}

.omtw-field-label span.req {
  color: #C97C4B;
  margin-left: 2px;
}

.omtw-field-input,
.omtw-field-select,
.omtw-field-textarea {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid #E2E8F0;
  border-radius: 8px;
  font-size: 14px;
  font-family: 'Inter', sans-serif;
  background: #F8FAFC;
  color: #1F2937;
  transition: border-color 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
  box-sizing: border-box;
}

.omtw-field-input:focus,
.omtw-field-select:focus,
.omtw-field-textarea:focus {
  outline: none;
  border-color: #7C9473;
  background: #ffffff;
  box-shadow: 0 0 0 3px rgba(124, 148, 115, 0.2);
}

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

/* Modal Footer */
.omtw-popup-footer {
  padding: 16px 28px;
  border-top: 1px solid #E2E8F0;
  background: #FAF7F0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.omtw-popup-guarantee {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  color: #4A5568;
  font-weight: 500;
}

.omtw-popup-actions {
  display: flex;
  align-items: center;
  gap: 16px;
}

.omtw-btn-cancel {
  background: none;
  border: none;
  color: #4A5568;
  font-weight: 600;
  font-size: 14px;
  cursor: pointer;
  padding: 8px 12px;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.omtw-btn-cancel:hover {
  color: #1A2E1E;
}

.omtw-btn-submit {
  background: #1F3D2B;
  color: #ffffff;
  border: none;
  padding: 12px 24px;
  border-radius: 99px;
  font-weight: 700;
  font-size: 14px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  transition: background 0.2s ease, transform 0.2s ease;
}

.omtw-btn-submit i,
.omtw-btn-submit svg,
.omtw-btn-cancel i,
.omtw-btn-cancel svg,
.omtw-popup-close i,
.omtw-popup-close svg,
.omtw-popup-badge i,
.omtw-popup-badge svg,
.omtw-popup-guarantee i,
.omtw-popup-guarantee svg {
  width: 1em;
  height: 1em;
  font-size: 16px;
  vertical-align: middle;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  fill: currentColor;
  flex-shrink: 0;
}

.omtw-btn-submit:hover {
  background: #14281B;
  transform: translateY(-1px);
}

/* Dossier Modal Layout */
.omtw-dossier-layout {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 24px;
}

.omtw-dossier-image-box {
  width: 100%;
  aspect-ratio: 1 / 1;
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid #E2E8F0;
  margin-bottom: 16px;
}

.omtw-dossier-image-box img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.omtw-dossier-specs-box {
  background: #F8FAFC;
  border: 1px solid #E2E8F0;
  border-radius: 10px;
  padding: 14px;
  font-size: 13px;
}

.omtw-dossier-spec-row {
  display: flex;
  justify-content: space-between;
  padding: 6px 0;
  border-bottom: 1px dashed #E2E8F0;
}

.omtw-dossier-spec-row:last-child {
  border-bottom: none;
}

.omtw-dossier-spec-label {
  color: #718096;
  font-weight: 500;
}

.omtw-dossier-spec-val {
  color: #1A2E1E;
  font-weight: 700;
  text-align: right;
}

.omtw-dossier-botanical-meta {
  font-size: 13px;
  color: #4A5568;
  margin-bottom: 16px;
}

.omtw-dossier-siddha-box {
  background: #F0F4F0;
  border-left: 4px solid #7C9473;
  padding: 14px;
  border-radius: 0 8px 8px 0;
  margin-bottom: 20px;
}

.omtw-dossier-siddha-title {
  font-weight: 700;
  color: #1F3D2B;
  font-size: 14px;
  margin-bottom: 4px;
}

.omtw-dossier-siddha-text {
  font-size: 13px;
  color: #334155;
  line-height: 1.5;
}

.omtw-dossier-section-title {
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.6px;
  color: #1A2E1E;
  margin-top: 16px;
  margin-bottom: 8px;
}

.omtw-dossier-benefits-list {
  list-style: none;
  padding: 0;
  margin: 0 0 16px 0;
}

.omtw-dossier-benefits-list li {
  font-size: 13px;
  color: #334155;
  padding: 4px 0 4px 22px;
  position: relative;
}

.omtw-dossier-benefits-list li::before {
  content: "✓";
  position: absolute;
  left: 0;
  color: #7C9473;
  font-weight: bold;
}

.omtw-pills-wrap {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 16px;
}

.omtw-pill {
  background: #E2E8F0;
  color: #2D3748;
  font-size: 12px;
  font-weight: 600;
  padding: 4px 10px;
  border-radius: 20px;
}

.omtw-pill-accent {
  background: #FAF5FF;
  color: #6B21A8;
  border: 1px solid #E9D5FF;
}

.omtw-response-msg {
  padding: 12px 16px;
  border-radius: 8px;
  font-size: 14px;
  margin-top: 16px;
  display: none;
}

.omtw-response-msg.success {
  display: block;
  background: #DEF7EC;
  color: #03543F;
  border: 1px solid #BCF0DA;
}

.omtw-response-msg.error {
  display: block;
  background: #FDE8E8;
  color: #9B1C1C;
  border: 1px solid #FBD5D5;
}

/* Responsive Breakpoints */
@media (max-width: 768px) {
  .omtw-popup-grid {
    grid-template-columns: 1fr;
  }

  .omtw-popup-full {
    grid-column: span 1;
  }

  .omtw-dossier-layout {
    grid-template-columns: 1fr;
  }

  .omtw-popup-card {
    max-height: 95vh;
  }

  .omtw-popup-footer {
    flex-direction: column;
    align-items: stretch;
    text-align: center;
  }

  .omtw-popup-actions {
    flex-direction: column-reverse;
  }

  .omtw-btn-submit {
    justify-content: center;
    width: 100%;
  }
}
