/* ═══════════════════════════════════════════════
   CLICK2INTERIOR — Popup Form Styles
   File: assets/css/popup_form.css
   ═══════════════════════════════════════════════ */

/* ── Trigger Button (floating) ── */
.popup-trigger-btn {
  position: fixed;
  bottom: 32px;
  right: 32px;
  z-index: 900;
  display: flex;
  align-items: center;
  gap: 10px;
  background: var(--ink, #1a1209);
  color: #f5efe6;
  border: none;
  padding: 14px 22px;
  font-family: 'Cormorant Garamond', 'Playfair Display', Georgia, serif;
  font-size: 15px;
  font-weight: 600;
  letter-spacing: 0.04em;
  cursor: pointer;
  clip-path: polygon(0 0, calc(100% - 12px) 0, 100% 12px, 100% 100%, 12px 100%, 0 calc(100% - 12px));
  transition: transform 0.25s ease, box-shadow 0.25s ease;
  box-shadow: 0 8px 32px rgba(26,18,9,0.28);
}
.popup-trigger-btn:hover {
  transform: translateY(-3px);
  box-shadow: 0 14px 40px rgba(26,18,9,0.38);
}
.popup-trigger-btn svg {
  width: 18px;
  height: 18px;
  stroke: #c9a96e;
  fill: none;
  stroke-width: 1.8;
}
.popup-trigger-btn .ptb-dot {
  width: 8px; height: 8px;
  border-radius: 50%;
  background: #c9a96e;
  animation: ptbPulse 2s infinite;
}
@keyframes ptbPulse {
  0%,100% { box-shadow: 0 0 0 0 rgba(201,169,110,0.6); }
  50%      { box-shadow: 0 0 0 7px rgba(201,169,110,0); }
}

/* ── Overlay ── */
.pf-overlay {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.4s ease;
}
.pf-overlay.active {
  opacity: 1;
  pointer-events: all;
}
.pf-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(15, 10, 5, 0.72);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
}

/* ── Modal Shell ── */
.pf-modal {
  position: relative;
  z-index: 2;
  width: 100%;
  max-width: 920px;
  min-height: 540px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  background: #faf6f0;
  overflow: hidden;
  transform: translateY(40px) scale(0.97);
  transition: transform 0.45s cubic-bezier(0.22, 1, 0.36, 1);
  box-shadow: 0 40px 120px rgba(15,10,5,0.5), 0 0 0 1px rgba(201,169,110,0.15);
}
.pf-overlay.active .pf-modal {
  transform: translateY(0) scale(1);
}

/* ── Left Panel (Visual) ── */
.pf-left {
  position: relative;
  overflow: hidden;
  background: #1a1209;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 0;
}
.pf-left-bg {
  position: absolute;
  inset: 0;
  background-image: url('https://images.unsplash.com/photo-1616486338812-3dadae4b4ace?w=800&q=80');
  background-size: cover;
  background-position: center;
  opacity: 0.55;
  transform: scale(1.05);
  transition: transform 6s ease;
}
.pf-overlay.active .pf-left-bg {
  transform: scale(1);
}
.pf-left-grad {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    160deg,
    rgba(26,18,9,0.1) 0%,
    rgba(26,18,9,0.35) 40%,
    rgba(26,18,9,0.92) 100%
  );
}
.pf-left-content {
  position: relative;
  z-index: 2;
  padding: 36px 32px;
}
.pf-left-tag {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(201,169,110,0.18);
  border: 1px solid rgba(201,169,110,0.35);
  color: #c9a96e;
  font-size: 11px;
  font-family: 'DM Sans', sans-serif;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding: 6px 14px;
  margin-bottom: 18px;
}
.pf-left-tag span {
  width: 6px; height: 6px;
  border-radius: 50%;
  background: #c9a96e;
}
.pf-left h2 {
  font-family: 'Cormorant Garamond', 'Playfair Display', Georgia, serif;
  font-size: clamp(26px, 3vw, 34px);
  font-weight: 600;
  color: #f5efe6;
  line-height: 1.22;
  margin: 0 0 14px;
}
.pf-left h2 em {
  font-style: italic;
  color: #c9a96e;
}
.pf-left p {
  font-family: 'DM Sans', sans-serif;
  font-size: 13.5px;
  color: rgba(245,239,230,0.72);
  line-height: 1.65;
  margin: 0 0 24px;
}
.pf-trust {
  display: flex;
  gap: 20px;
}
.pf-trust-item {
  text-align: center;
}
.pf-trust-item strong {
  display: block;
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-size: 22px;
  font-weight: 700;
  color: #c9a96e;
  line-height: 1;
}
.pf-trust-item span {
  font-family: 'DM Sans', sans-serif;
  font-size: 11px;
  color: rgba(245,239,230,0.55);
  letter-spacing: 0.06em;
}
.pf-left-deco {
  position: absolute;
  top: 24px;
  right: 24px;
  width: 64px;
  height: 64px;
  border: 1px solid rgba(201,169,110,0.25);
  border-radius: 50%;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: center;
}
.pf-left-deco svg {
  width: 28px; height: 28px;
  stroke: #c9a96e;
  fill: none;
  stroke-width: 1.2;
}
.pf-left-lines {
  position: absolute;
  top: 0; left: 0;
  width: 100%; height: 100%;
  z-index: 1;
  overflow: hidden;
  pointer-events: none;
}
.pf-left-lines::before,
.pf-left-lines::after {
  content: '';
  position: absolute;
  border: 1px solid rgba(201,169,110,0.08);
  border-radius: 50%;
}
.pf-left-lines::before {
  width: 280px; height: 280px;
  top: -60px; right: -80px;
}
.pf-left-lines::after {
  width: 180px; height: 180px;
  top: 0; right: -20px;
}

/* ── Right Panel (Form) ── */
.pf-right {
  position: relative;
  display: flex;
  flex-direction: column;
  padding: 40px 36px 36px;
  background: #faf6f0;
  overflow-y: auto;
}
.pf-close {
  position: absolute;
  top: 18px; right: 18px;
  width: 36px; height: 36px;
  border: 1px solid rgba(26,18,9,0.12);
  background: transparent;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s, border-color 0.2s;
}
.pf-close:hover { background: #1a1209; border-color: #1a1209; }
.pf-close:hover svg { stroke: #f5efe6; }
.pf-close svg { width: 16px; height: 16px; stroke: #1a1209; fill: none; stroke-width: 2; }

.pf-form-header { margin-bottom: 28px; padding-right: 30px; }
.pf-form-header p {
  font-family: 'DM Sans', sans-serif;
  font-size: 11.5px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #c9a96e;
  margin: 0 0 8px;
}
.pf-form-header h3 {
  font-family: 'Cormorant Garamond', 'Playfair Display', Georgia, serif;
  font-size: 26px;
  font-weight: 600;
  color: #1a1209;
  line-height: 1.2;
  margin: 0;
}

/* ── Field Groups ── */
.pf-field {
  position: relative;
  margin-bottom: 20px;
}
.pf-field label {
  display: block;
  font-family: 'DM Sans', sans-serif;
  font-size: 11.5px;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #6b5a44;
  margin-bottom: 7px;
}
.pf-field label .req {
  color: #c9a96e;
  margin-left: 2px;
}
.pf-field input,
.pf-field textarea {
  width: 100%;
  background: #fff;
  border: 1.5px solid rgba(26,18,9,0.12);
  font-family: 'DM Sans', sans-serif;
  font-size: 14px;
  color: #1a1209;
  padding: 12px 16px;
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
  box-sizing: border-box;
  appearance: none;
}
.pf-field textarea {
  resize: none;
  height: 90px;
  line-height: 1.55;
}
.pf-field input:focus,
.pf-field textarea:focus {
  border-color: #c9a96e;
  box-shadow: 0 0 0 3px rgba(201,169,110,0.12);
}
.pf-field input.error,
.pf-field textarea.error,
.pf-phone-wrap.error .pf-phone-input {
  border-color: #d94f38;
  box-shadow: 0 0 0 3px rgba(217,79,56,0.10);
}
.pf-field input.valid,
.pf-field textarea.valid,
.pf-phone-wrap.valid .pf-phone-input {
  border-color: #5a9a6f;
  box-shadow: 0 0 0 3px rgba(90,154,111,0.10);
}
.pf-err-msg {
  display: none;
  font-family: 'DM Sans', sans-serif;
  font-size: 11.5px;
  color: #d94f38;
  margin-top: 5px;
  align-items: center;
  gap: 5px;
}
.pf-err-msg.show { display: flex; }
.pf-err-msg svg { width: 12px; height: 12px; stroke: #d94f38; fill: none; stroke-width: 2.5; flex-shrink: 0; }

/* ── Phone Field ── */
.pf-phone-wrap {
  display: flex;
  border: 1.5px solid rgba(26,18,9,0.12);
  background: #fff;
  transition: border-color 0.2s, box-shadow 0.2s;
  position: relative;
}
.pf-phone-wrap:focus-within {
  border-color: #c9a96e;
  box-shadow: 0 0 0 3px rgba(201,169,110,0.12);
}
.pf-phone-wrap.error {
  border-color: #d94f38;
  box-shadow: 0 0 0 3px rgba(217,79,56,0.10);
}
.pf-phone-wrap.valid {
  border-color: #5a9a6f;
  box-shadow: 0 0 0 3px rgba(90,154,111,0.10);
}

/* Country Selector */
.pf-country-btn {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 0 12px 0 14px;
  border: none;
  border-right: 1.5px solid rgba(26,18,9,0.10);
  background: #f5f0e8;
  cursor: pointer;
  white-space: nowrap;
  font-family: 'DM Sans', sans-serif;
  font-size: 13px;
  color: #1a1209;
  min-width: 100px;
  height: 44px;
  transition: background 0.15s;
}
.pf-country-btn:hover { background: #ede7da; }
.pf-country-btn .cb-flag { font-size: 18px; line-height: 1; }
.pf-country-btn .cb-code { font-size: 13px; font-weight: 500; color: #1a1209; }
.pf-country-btn .cb-caret {
  width: 12px; height: 12px;
  stroke: #6b5a44; fill: none;
  stroke-width: 2.5;
  margin-left: 2px;
  transition: transform 0.2s;
}
.pf-country-btn.open .cb-caret { transform: rotate(180deg); }

/* Phone Input */
.pf-phone-input {
  flex: 1;
  border: none !important;
  box-shadow: none !important;
  padding: 12px 14px !important;
  background: transparent;
  margin: 0 !important;
}
.pf-phone-input:focus { box-shadow: none !important; border: none !important; }

/* Country Dropdown */
.pf-country-dropdown {
  position: absolute;
  top: calc(100% + 4px);
  left: 0;
  width: 320px;
  background: #fff;
  border: 1.5px solid rgba(26,18,9,0.12);
  box-shadow: 0 16px 48px rgba(26,18,9,0.16);
  z-index: 999;
  display: none;
  flex-direction: column;
  max-height: 300px;
}
.pf-country-dropdown.open { display: flex; }
.pf-cd-search {
  padding: 10px 12px;
  border-bottom: 1px solid rgba(26,18,9,0.08);
  flex-shrink: 0;
}
.pf-cd-search input {
  width: 100%;
  border: 1px solid rgba(26,18,9,0.12);
  padding: 8px 12px;
  font-family: 'DM Sans', sans-serif;
  font-size: 13px;
  outline: none;
  background: #faf6f0;
  color: #1a1209;
  box-sizing: border-box;
}
.pf-cd-search input:focus { border-color: #c9a96e; }
.pf-cd-list {
  overflow-y: auto;
  flex: 1;
}
.pf-cd-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  cursor: pointer;
  font-family: 'DM Sans', sans-serif;
  font-size: 13px;
  color: #1a1209;
  transition: background 0.12s;
}
.pf-cd-item:hover { background: #f5f0e8; }
.pf-cd-item.selected { background: rgba(201,169,110,0.12); }
.pf-cd-item .cd-flag { font-size: 18px; line-height: 1; }
.pf-cd-item .cd-name { flex: 1; }
.pf-cd-item .cd-code { color: #6b5a44; font-size: 12px; }
.pf-cd-empty {
  padding: 20px;
  text-align: center;
  font-family: 'DM Sans', sans-serif;
  font-size: 13px;
  color: #6b5a44;
  display: none;
}
.pf-cd-empty.show { display: block; }

/* ── Submit Button ── */
.pf-submit {
  width: 100%;
  background: #1a1209;
  color: #f5efe6;
  border: none;
  padding: 15px 24px;
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-size: 16px;
  font-weight: 600;
  letter-spacing: 0.06em;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin-top: 6px;
  clip-path: polygon(0 0, calc(100% - 10px) 0, 100% 10px, 100% 100%, 10px 100%, 0 calc(100% - 10px));
  transition: background 0.25s, transform 0.2s;
  position: relative;
  overflow: hidden;
}
.pf-submit::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, transparent, rgba(201,169,110,0.15), transparent);
  transform: translateX(-100%);
  transition: transform 0.5s ease;
}
.pf-submit:hover { background: #2e1f0a; }
.pf-submit:hover::before { transform: translateX(100%); }
.pf-submit:active { transform: scale(0.98); }
.pf-submit svg { width: 16px; height: 16px; stroke: #c9a96e; fill: none; stroke-width: 2; }
.pf-submit .pf-spinner {
  display: none;
  width: 16px; height: 16px;
  border: 2px solid rgba(245,239,230,0.3);
  border-top-color: #f5efe6;
  border-radius: 50%;
  animation: pfSpin 0.7s linear infinite;
}
.pf-submit.loading .pf-spinner { display: block; }
.pf-submit.loading .pf-submit-text,
.pf-submit.loading svg { opacity: 0; }
@keyframes pfSpin { to { transform: rotate(360deg); } }

/* ── Success State ── */
.pf-success {
  display: none;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 40px 20px;
  height: 100%;
}
.pf-success.show { display: flex; }
.pf-success-icon {
  width: 72px; height: 72px;
  border: 2px solid #c9a96e;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 20px;
  animation: pfSuccessPop 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}
@keyframes pfSuccessPop { from { transform: scale(0.5); opacity: 0; } to { transform: scale(1); opacity: 1; } }
.pf-success-icon svg { width: 32px; height: 32px; stroke: #c9a96e; fill: none; stroke-width: 2; }
.pf-success h4 {
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-size: 24px;
  font-weight: 600;
  color: #1a1209;
  margin: 0 0 10px;
}
.pf-success p {
  font-family: 'DM Sans', sans-serif;
  font-size: 13.5px;
  color: #6b5a44;
  line-height: 1.6;
  max-width: 260px;
}

/* ── Privacy Note ── */
.pf-privacy {
  display: flex;
  align-items: center;
  gap: 7px;
  margin-top: 12px;
  font-family: 'DM Sans', sans-serif;
  font-size: 11px;
  color: #9e8a72;
}
.pf-privacy svg { width: 12px; height: 12px; stroke: #9e8a72; fill: none; stroke-width: 2; flex-shrink: 0; }

/* ── Decorative Corner ── */
.pf-corner {
  position: absolute;
  bottom: 0; right: 0;
  width: 60px; height: 60px;
  overflow: hidden;
  pointer-events: none;
}
.pf-corner::before {
  content: '';
  position: absolute;
  bottom: -1px; right: -1px;
  width: 0; height: 0;
  border-style: solid;
  border-width: 0 0 60px 60px;
  border-color: transparent transparent rgba(201,169,110,0.15) transparent;
}

/* ── Responsive ── */
@media (max-width: 680px) {
  .pf-modal {
    grid-template-columns: 1fr;
    max-width: 420px;
    min-height: auto;
  }
  .pf-left {
    min-height: 200px;
  }
  .pf-left-content { padding: 24px; }
  .pf-left h2 { font-size: 22px; }
  .pf-right { padding: 28px 24px 28px; }
  .pf-country-dropdown { width: 280px; }
  .popup-trigger-btn { bottom: 20px; right: 20px; padding: 12px 18px; font-size: 14px; }
}