/* ==========================================================================
   Hazlnut Clean Dashboard Automated UI Walkthrough Component Styles
   ========================================================================== */

:root {
  --hw-maroon: #561023;
  --hw-cream: #EDE6DC;
  --hw-cream-light: #F7F3EC;
  --hw-green: #194234;
  --hw-coral: #E45558;
  --hw-blue: #B4CEED;
  --hw-pink: #E163C3;
  --hw-chartreuse: #D5C800;
  --hw-border: #D9D0C3;
  --hw-text-dark: #1E1E1E;
  --hw-text-muted: #6B5E52;
  --hw-font-serif: 'Nanum Myeongjo', serif;
  --hw-font-sans: 'Nanum Myeongjo', serif;
  --hw-font-mono: 'DM Mono', monospace;
}

/* MANDATORY UNIVERSAL 0px BORDER RADIUS FOR ALL AUTOMATION UI ELEMENTS */
.hero-walkthrough-container,
.hero-walkthrough-container *,
.hero-walkthrough-container *::before,
.hero-walkthrough-container *::after {
  border-radius: 0px !important;
}

/* Outer Shell Container */
.hero-walkthrough-container {
  position: relative;
  width: 100%;
  max-width: 760px;
  height: 420px;
  margin: 0 auto;
  background: var(--hw-cream);
  border-radius: 0px !important;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.25);
  overflow: hidden;
  font-family: var(--hw-font-serif);
  color: var(--hw-text-dark);
  box-sizing: border-box;
  user-select: none;
}

/* Inner App Layout: Main Preview Canvas + Right Sidepane */
.hw-app-body {
  display: grid;
  grid-template-columns: 1fr 310px;
  height: 420px;
  background: var(--hw-cream);
  overflow: hidden;
}

/* ==========================================================================
   Main Preview Canvas Area (Scrollable Left Canvas)
   ========================================================================== */

.hw-main-preview {
  position: relative;
  padding: 24px 36px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  background-color: var(--hw-cream);
  transition: background-color 0.6s cubic-bezier(0.4, 0, 0.2, 1), color 0.4s ease;
  overflow: hidden !important;
  overflow-y: hidden !important;
  overflow-x: hidden !important;
  height: 100%;
  box-sizing: border-box;
  scrollbar-width: none;
  -ms-overflow-style: none;
}

/* Hide Scrollbar while keeping full scrolling functionality */
.hw-main-preview::-webkit-scrollbar {
  display: none !important;
  width: 0 !important;
  height: 0 !important;
}

.hw-main-preview > div {
  width: 100%;
}

.format-portrait .hw-main-preview {
  padding-left: 36px !important;
  padding-right: 36px !important;
}

.format-landscape .hw-main-preview {
  padding-left: 36px !important;
  padding-right: 36px !important;
}

/* Hero Content Box (Portrait vs Landscape / Full Image Layout) */
.hw-wishlist-hero-card {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 44px;
  width: 100%;
  margin: 0 auto;
  transition: all 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.format-portrait .hw-wishlist-hero-card {
  flex-direction: row;
  align-items: center;
}

.format-landscape .hw-wishlist-hero-card {
  flex-direction: column;
  align-items: center;
  width: 100%;
  gap: 14px;
}

/* Main Cover Photo Container & SVG Mask Treatments */
.hw-cover-image-frame {
  position: relative;
  overflow: hidden;
  flex-shrink: 0;
  transition: all 0.6s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 12px 36px rgba(0, 0, 0, 0.12);
  background: #084434;

  -webkit-mask-size: 100% 100%;
  mask-size: 100% 100%;
  -webkit-mask-repeat: no-repeat;
  mask-repeat: no-repeat;
  -webkit-mask-position: center;
  mask-position: center;
}

/* Portrait Dimensions */
.format-portrait .hw-cover-image-frame {
  width: 240px;
  height: 320px;
}

/* Landscape Dimensions: Non-Full Image Frames have top breathing space */
.format-landscape .hw-cover-image-frame {
  width: 480px;
  max-width: 100%;
  height: 190px;
  margin: 0 auto;
}

/* Full Image Mode: Edge-to-Edge Full Bleed Width & Top Alignment */
.format-landscape .hw-cover-image-frame.frame-full,
.hw-cover-image-frame.frame-full {
  width: calc(100% + 72px) !important;
  margin-left: -36px !important;
  margin-right: -36px !important;
  margin-top: -24px !important;
  max-width: none !important;
  height: 200px !important;
  border-radius: 0 !important;
  box-shadow: none !important;
}

.hw-cover-image-frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 20%;
  display: block;
}

/* Overlay Badge for Full Image Mode ("Click to edit cover photo") */
.hw-cover-overlay-badge {
  display: none !important;
}

/* Production SVG Masks */
.frame-plaque {
  -webkit-mask-image: url("../assets/hero_frames/frame-plaque.svg");
  mask-image: url("../assets/hero_frames/frame-plaque.svg");
}

.frame-cartouche {
  -webkit-mask-image: url("../assets/hero_frames/frame-cartouche.svg");
  mask-image: url("../assets/hero_frames/frame-cartouche.svg");
}

.frame-gem {
  -webkit-mask-image: url("../assets/hero_frames/frame-gem.svg");
  mask-image: url("../assets/hero_frames/frame-gem.svg");
}

.frame-full {
  -webkit-mask-image: none !important;
  mask-image: none !important;
  border-radius: 0 !important;
}

/* Landscape Mask Variances */
.format-landscape .frame-plaque {
  -webkit-mask-image: url("../assets/hero_frames/frame-plaque-landscape.svg");
  mask-image: url("../assets/hero_frames/frame-plaque-landscape.svg");
}

.format-landscape .frame-cartouche {
  -webkit-mask-image: url("../assets/hero_frames/frame-cartouche-landscape.svg");
  mask-image: url("../assets/hero_frames/frame-cartouche-landscape.svg");
}

.format-landscape .frame-gem {
  -webkit-mask-image: url("../assets/hero_frames/frame-gem-landscape.svg");
  mask-image: url("../assets/hero_frames/frame-gem-landscape.svg");
}


/* ==========================================================================
   Exact Production Centered Hero Typography Formation (Tight Vertical Spacing)
   ========================================================================== */

.hw-wishlist-info {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  width: 100%;
  max-width: 480px;
  margin: 0 auto;
  gap: 4px;
  transition: color 0.4s ease;
}

.hw-hero-title-group {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 6px 10px;
  width: 100%;
  text-align: center;
  margin: 0;
  padding: 0;
}

.wedding-page .hw-hero-name,
.hw-hero-name {
  font-family: 'Nanum Myeongjo', serif !important;
  font-size: 36px !important;
  font-weight: 400 !important;
  color: var(--hw-maroon);
  line-height: 1.15 !important;
  letter-spacing: normal !important;
}

.hw-pencil-icon {
  font-size: 15px;
  opacity: 0.65;
  margin-left: 2px;
  vertical-align: middle;
}

.hw-title-ampersand {
  font-family: 'Nanum Myeongjo', serif;
  font-style: italic;
  font-size: 32px;
  font-weight: 400;
  line-height: 1.15;
  color: var(--hw-coral);
  transition: color 0.4s ease;
}

.wedding-page .hw-wishlist-subtitle,
.hw-wishlist-subtitle {
  font-family: 'Nanum Myeongjo', serif !important;
  font-size: 28px !important;
  font-weight: 400 !important;
  color: var(--hw-maroon);
  line-height: 1.2 !important;
  letter-spacing: normal !important;
  text-align: center;
  width: 100%;
  margin: 2px 0 0 0;
  padding: 0;
}

/* Date Rule Divider */
.hw-date-rule {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  margin: 14px auto 10px;
  color: var(--hw-text-muted);
  font-family: var(--hw-font-mono);
  font-size: 11px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.hw-date-rule::before,
.hw-date-rule::after {
  content: '';
  height: 1px;
  width: 24px;
  background: currentColor;
  opacity: 0.4;
}

.hw-wishlist-message {
  font-family: var(--hw-font-serif);
  font-style: italic;
  font-size: 17px;
  line-height: 1.4;
  color: var(--hw-maroon);
  max-width: 420px;
  margin: 0 auto;
  text-align: center;
  opacity: 0.9;
}

/* Dark Theme Text Adjustments */
.theme-dark-bg .hw-hero-name-part,
.theme-dark-bg .hw-wishlist-subtitle,
.theme-dark-bg .hw-wishlist-message {
  color: #EDE6DC;
}

.theme-dark-bg .hw-title-ampersand {
  color: var(--hw-chartreuse);
}

.theme-dark-bg .hw-date-rule {
  color: rgba(237, 230, 220, 0.7);
}

/* ==========================================================================
   Filter Bar & Product Cards Section Below Hero Section
   ========================================================================== */

/* ==========================================================================
   Filter Bar & Product Cards Section Below Hero Section (Reference 2 Precision)
   ========================================================================== */

.hw-products-section-wrapper {
  display: none !important;
  width: 100%;
  margin-top: 24px;
  flex-direction: column;
  gap: 10px;
}

.hw-filter-bar-row {
  display: flex;
  justify-content: flex-end;
  width: 100%;
  margin-bottom: 2px;
}

.hw-sort-dropdown-v2 {
  display: inline-flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 6px 12px;
  background: #FFFFFF;
  border: 1px solid var(--hw-border, #D9D0C3);
  border-radius: 0px !important;
  font-size: 12px;
  font-weight: 600;
  font-family: var(--hw-font-sans, sans-serif);
  color: #561023;
  box-shadow: 4px 4px 0 0 rgba(0, 0, 0, 0.25);
  cursor: pointer;
  width: 135px;
  box-sizing: border-box;
}

.hw-sort-dropdown-v2 .hw-dropdown-arrow {
  font-size: 10px;
  opacity: 0.8;
}

/* Product Cards Grid Row */
.hw-products-preview-grid {
  display: flex;
  align-items: flex-start;
  gap: 20px;
  width: 100%;
}

/* Left Split Actions Column (Add Gift / Add Cash Fund) */
.hw-split-actions-col {
  display: flex;
  flex-direction: column;
  gap: 12px;
  width: 200px;
  flex-shrink: 0;
}

.hw-action-card-half {
  width: 200px;
  height: 72px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 16px;
  border-radius: 0px !important;
  cursor: pointer;
  box-shadow: 6px 6px 0 0 rgba(0, 0, 0, 0.25);
  box-sizing: border-box;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

/* Add Gift Card (Top) */
.hw-add-gift-card {
  background: #FFFFFF;
  color: #561023;
}

.hw-gift-badge {
  width: 40px;
  height: 40px;
  background-color: #EE5959;
  border-radius: 14px !important; /* Squircle icon container from Ref 2 */
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.hw-add-gift-card .hw-action-label {
  font-family: var(--hw-font-sans, sans-serif);
  font-weight: 700;
  font-size: 15px;
  color: #561023;
  margin-left: 10px;
  flex-grow: 1;
}

/* Add Cash Fund Card (Bottom) */
.hw-add-cash-card {
  background: #561023;
  color: #FFFFFF;
}

.hw-action-label-stack {
  display: flex;
  flex-direction: column;
  font-family: var(--hw-font-sans, sans-serif);
  font-weight: 700;
  font-size: 14px;
  line-height: 1.15;
  color: #FFFFFF;
}

.hw-cash-motif {
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

/* Product Card Item */
.hw-product-item-card {
  width: 200px;
  height: 330px;
  background: #FFFFFF;
  border-radius: 0px !important;
  overflow: hidden;
  box-shadow: 6px 6px 0 0 rgba(0, 0, 0, 0.25);
  display: flex;
  flex-direction: column;
  flex-shrink: 0;
}

.hw-product-item-img {
  width: 100%;
  height: 190px;
  object-fit: cover;
  display: block;
  border-radius: 0px !important;
}

.hw-product-item-details {
  padding: 12px 14px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  flex-grow: 1;
  justify-content: space-between;
  box-sizing: border-box;
}

.hw-product-item-title {
  font-family: var(--hw-font-serif, serif);
  font-size: 14px;
  line-height: 1.3;
  color: #561023;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.hw-product-item-price {
  font-family: var(--hw-font-serif, serif);
  font-size: 14px;
  font-weight: 500;
  color: #561023;
}

.hw-product-item-footer {
  display: flex;
  justify-content: flex-end;
  margin-top: 4px;
}

.hw-view-online-btn {
  background: #EDE6DC;
  color: #561023;
  border: none;
  border-radius: 0px !important;
  padding: 4px 10px;
  font-family: var(--hw-font-sans, sans-serif);
  font-size: 11px;
  font-weight: 500;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  cursor: pointer;
  transition: background 0.2s ease;
}

.hw-view-online-btn:hover {
  background: #E2D7C7;
}

/* Exact Hazlnut Production Banner Toast Notification */
.hw-status-toast {
  display: none !important;
}

/* ==========================================================================
   Right Customization Sidepane Panel
   ========================================================================== */

/* ==========================================================================
   Right Customization Sidepane Panel (Reference Image Exact Spacing)
   ========================================================================== */

.hw-side-panel {
  background: #EDE6DC;
  border-left: 1px solid rgba(86, 16, 35, 0.12);
  box-shadow: -10px 0 30px rgba(0, 0, 0, 0.08);
  padding: 20px 20px 16px 20px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  height: 100%;
  box-sizing: border-box;
  position: relative;
  z-index: 20;
  border-radius: 0px !important;
  overflow: hidden;
}

.hw-side-panel-body {
  flex-grow: 1;
  overflow-y: auto;
  padding-right: 0px;
  margin-bottom: 8px;
  scrollbar-width: none;
  -ms-overflow-style: none;
}

.hw-side-panel-body::-webkit-scrollbar {
  display: none !important;
  width: 0 !important;
  height: 0 !important;
}

/* Panel Header Area */
.hw-panel-header {
  display: flex;
  align-items: center;
  gap: 14px;
  padding-bottom: 16px;
  border-bottom: 1px solid #E0D8C6;
  margin-bottom: 16px;
}

.hw-back-btn {
  width: 44px;
  height: 44px;
  background: #561023;
  color: #FFFFFF;
  border: none;
  border-radius: 0px !important;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  cursor: pointer;
  flex-shrink: 0;
}

.hw-panel-subtitle {
  font-size: 10px;
  font-weight: 700;
  font-family: var(--hw-font-mono, monospace);
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: #194234;
  margin-bottom: 2px;
}

.hw-panel-title {
  font-family: 'Nanum Myeongjo', serif;
  font-size: 28px;
  font-weight: 400;
  color: #561023;
  margin: 0;
  line-height: 1.1;
}

.hw-section-title {
  font-family: 'Nanum Myeongjo', serif;
  font-size: 22px;
  font-weight: 400;
  color: #561023;
  margin: 0 0 16px 0;
}

/* Frame Controls & Live Thumbnail */
.hw-frame-controls-row {
  display: grid;
  grid-template-columns: 135px 1fr;
  gap: 16px;
  align-items: flex-start;
}

.hw-thumbnail-column {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  width: 135px;
}

.hw-thumbnail-box {
  width: 135px;
  height: 95px;
  background: #084434;
  overflow: hidden;
  transition: all 0.4s ease;
  box-shadow: 0 4px 10px rgba(0,0,0,0.1);
  border-radius: 0px !important;
  
  -webkit-mask-size: 100% 100%;
  mask-size: 100% 100%;
  -webkit-mask-repeat: no-repeat;
  mask-repeat: no-repeat;
}

.hw-thumbnail-box.frame-full {
  -webkit-mask-image: none !important;
  mask-image: none !important;
  border-radius: 0px !important;
}

.hw-thumbnail-box img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hw-option-group-label {
  font-size: 10px;
  font-weight: 700;
  font-family: var(--hw-font-mono, monospace);
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: #A3968B;
  margin-bottom: 8px;
}

.hw-frame-buttons-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.hw-frame-btn {
  background: #FFFFFF;
  border: 1px solid #D9D0C3;
  border-radius: 0px !important;
  padding: 8px 12px;
  font-size: 11px;
  font-weight: 500;
  font-family: var(--hw-font-mono, monospace);
  letter-spacing: 1px;
  text-transform: uppercase;
  color: #561023;
  text-align: left;
  cursor: pointer;
  transition: all 0.25s ease;
  outline: none;
  width: 100%;
}

.hw-frame-btn.active {
  border: 1px solid #561023 !important;
  box-shadow: none !important;
  font-weight: 700;
}

.hw-photo-help-text {
  font-size: 9px;
  font-weight: 700;
  font-family: var(--hw-font-mono, monospace);
  letter-spacing: 0.5px;
  text-transform: uppercase;
  color: #A3968B;
  margin-top: 12px;
  margin-bottom: 8px;
  line-height: 1.25;
  width: 100%;
}

.hw-change-photo-btn {
  background: #FFFFFF;
  border: 1px solid #D9D0C3;
  border-radius: 0px !important;
  padding: 8px 0;
  font-size: 10px;
  font-weight: 700;
  font-family: var(--hw-font-mono, monospace);
  letter-spacing: 1px;
  text-transform: uppercase;
  color: #561023;
  cursor: pointer;
  width: 135px;
  text-align: center;
}

/* Format Switcher & Disabled State in Full Image Mode */
.hw-format-section {
  margin-top: 20px;
}

.hw-format-toggle-bar {
  display: grid;
  grid-template-columns: 1fr 1fr;
  background: transparent;
  gap: 0;
  border-radius: 0px !important;
}

.hw-format-btn {
  background: #FFFFFF;
  border: 1px solid #D9D0C3;
  border-radius: 0px !important;
  padding: 10px 0;
  font-size: 11px;
  font-weight: 500;
  font-family: var(--hw-font-mono, monospace);
  letter-spacing: 1px;
  text-transform: uppercase;
  color: #561023;
  cursor: pointer;
  transition: all 0.25s ease;
  box-sizing: border-box;
  text-align: center;
}

.hw-format-btn.active {
  background: #FFF0F0 !important;
  border: 1px solid #E45558 !important;
  color: #561023 !important;
  font-weight: 700;
}

.hw-format-btn.disabled,
.hw-format-btn[disabled] {
  opacity: 0.35;
  cursor: not-allowed;
  pointer-events: none;
}

/* Background Color Swatches */
.hw-color-section {
  margin-top: 20px;
}

.hw-color-swatches-grid {
  display: flex;
  gap: 8px;
  margin-top: 8px;
}

.hw-color-swatch {
  width: 32px;
  height: 32px;
  border-radius: 0px !important;
  cursor: pointer;
  position: relative;
  border: 1px solid rgba(0,0,0,0.12);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.2s;
  box-sizing: border-box;
}

.hw-color-swatch-check {
  position: absolute;
  top: 0;
  right: 0;
  width: 14px;
  height: 14px;
  background: #561023;
  color: #FFFFFF;
  font-size: 9px;
  font-weight: bold;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  border-radius: 0px !important;
}

.hw-color-swatch.active .hw-color-swatch-check {
  opacity: 1;
}

.hw-color-description {
  font-size: 12px;
  font-family: 'Nanum Myeongjo', serif;
  color: #5C5248;
  margin-top: 10px;
  line-height: 1.35;
}

/* Save Changes Button Footer (Pinned to Bottom) */
.hw-side-panel-footer {
  flex-shrink: 0;
  border-top: 1px solid #E0D8C6;
  padding-top: 14px;
  margin-top: auto;
  width: 100%;
  background: #EDE6DC;
}

.hw-save-btn {
  width: 100%;
  background: #084434;
  color: #FFFFFF;
  border: none;
  border-radius: 0px !important;
  padding: 13px 0;
  font-size: 12px;
  font-weight: 700;
  font-family: var(--hw-font-mono, monospace);
  letter-spacing: 2px;
  text-transform: uppercase;
  cursor: pointer;
}

/* ==========================================================================
   Animated Cursor & Ripple Effect
   ========================================================================== */

.walkthrough-cursor {
  position: absolute;
  top: 0;
  left: 0;
  width: 24px;
  height: 24px;
  z-index: 9999;
  pointer-events: none;
  transform: translate3d(200px, 150px, 0);
  transition: transform 0.8s cubic-bezier(0.22, 1, 0.36, 1);
  will-change: transform;
}

.walkthrough-cursor svg {
  width: 22px;
  height: 22px;
  filter: drop-shadow(0 2px 5px rgba(0, 0, 0, 0.35));
  transition: transform 0.15s ease;
}

.walkthrough-cursor.clicking svg {
  transform: scale(0.82) rotate(-4deg);
}

.cursor-ripple {
  position: absolute;
  top: 0;
  left: 0;
  width: 32px;
  height: 32px;
  margin-top: -16px;
  margin-left: -16px;
  border-radius: 50%;
  background: rgba(86, 16, 35, 0.35);
  border: 1px solid var(--hw-maroon);
  pointer-events: none;
  opacity: 0;
  transform: scale(0.2);
  z-index: 9998;
}

.cursor-ripple.animate {
  animation: hwRippleAnim 0.45s cubic-bezier(0, 0, 0.2, 1) forwards;
}

@keyframes hwRippleAnim {
  0% {
    opacity: 0.8;
    transform: scale(0.2);
  }
  100% {
    opacity: 0;
    transform: scale(1.6);
  }
}

/* Responsive Scaling */
@media (max-width: 900px) {
  .hw-app-body {
    grid-template-columns: 1fr;
  }
}
