/* == inc-nav-10.css (v16cfddaf) == */
@media (max-width: 767px) {
      body[class*="hana-view-quote"] .hana-quote-main,
      body.hana-view-quote-request .hana-quote-main,
      body.hana-view-quote-board .hana-quote-main,
      body.hana-view-quote-lookup .hana-quote-main,
      body.hana-view-quotes .hana-quote-main,
      body.hana-view-quotes-manage .hana-quote-main,
      body.hana-view-quote-detail .hana-quote-main,
      body.hana-view-quote-detail-guest .hana-quote-main {
        padding-left: 12px !important;
        padding-right: 12px !important;
        box-sizing: border-box !important;
      }
    }

/* == inc-nav-12.css (v8c032d73) == */
/* 게시글 카드 안 미디어 컨테이너를 카드 전체 폭으로 확장 */
    .hana-card .v312-media-item,
    .hana-card .v314-item,
    .hana-card .hana-card__media {
      width: 100% !important;
      max-width: 100% !important;
      box-sizing: border-box !important;
    }
    
    /* 그 안의 이미지도 100% 폭 채우기 (object-fit: cover로 비율 유지) */
    .hana-card .v312-media-item > img,
    .hana-card .v314-item > img,
    .hana-card .hana-card__media > img {
      width: 100% !important;
      max-width: 100% !important;
      object-fit: cover !important;
    }
    
    /* 우측 빈 공간이 보일 경우 회색 → 투명 (이중 안전) */
    .hana-card .v312-media-item,
    .hana-card .v314-item {
      background-color: transparent !important;
    }

/* == inc-nav-13.css (v1f23ec30) == */
/* Grid container: align-items stretch (이미 default) */
    .hana-quote-type-cards {
      align-items: stretch !important;
    }
    
    /* LABEL 자체 flex column으로 → inner가 LABEL 전체 높이 채우게 */
    .hana-quote-type-cards .hana-quote-type-card {
      display: flex !important;
      flex-direction: column !important;
      height: 100% !important;
    }
    
    /* 카드 inner 높이 100% (두 카드 시각적 높이 통일) */
    .hana-quote-type-cards .hana-quote-type-card__inner {
      flex: 1 1 auto !important;
      height: 100% !important;
      min-height: 144px !important;
      display: flex !important;
      flex-direction: column !important;
      justify-content: center !important;
      box-sizing: border-box !important;
    }
    
    /* 자리 바꿈: 전문가 의뢰 (idx 1) → 왼쪽 (order 1), 전문업체 의뢰 (idx 0) → 오른쪽 (order 2) */
    .hana-quote-type-cards .hana-quote-type-card:nth-child(1) {
      order: 2 !important;
    }
    .hana-quote-type-cards .hana-quote-type-card:nth-child(2) {
      order: 1 !important;
    }

/* == inc-nav-14.css (vef4d84df) == */
/* 테이블 width 일치 */
    .hana-quote-item-add {
      width: 100% !important;
      box-sizing: border-box !important;
    }
    
    /* grid를 테이블 8 컬럼 + 액션 셀과 동일하게 설정 */
    .hana-quote-item-add .hqi-grid {
      display: grid !important;
      grid-template-columns: 
        minmax(50px, 0.55fr)     /* col 1: No (빈) */
        minmax(60px, 0.67fr)     /* col 2: 품명 */
        minmax(60px, 0.67fr)     /* col 3: 규격 */
        minmax(60px, 0.67fr)     /* col 4: 단위 */
        minmax(60px, 0.67fr)     /* col 5: 수량 */
        minmax(100px, 1.18fr)    /* col 6: 단가 */
        minmax(100px, 1.18fr)    /* col 7: 공급가액 (빈) */
        minmax(60px, 0.67fr)     /* col 8: 비고 */
        minmax(50px, 0.54fr)     /* col 9: + 추가 버튼 */
        !important;
      gap: 4px !important;
      width: 100% !important;
      box-sizing: border-box !important;
      align-items: end !important;
    }
    
    /* 각 hqi-field를 정확한 column에 매핑 */
    /* 6 input: 품명(col2) / 규격(col3) / 단위(col4) / 수량(col5) / 단가(col6) / 비고(col8) */
    .hana-quote-item-add .hqi-grid > .hqi-field:nth-of-type(1) {
      grid-column: 2 / 3 !important;  /* 품명 */
    }
    .hana-quote-item-add .hqi-grid > .hqi-field:nth-of-type(2) {
      grid-column: 3 / 4 !important;  /* 규격 */
    }
    .hana-quote-item-add .hqi-grid > .hqi-field:nth-of-type(3) {
      grid-column: 4 / 5 !important;  /* 단위 */
    }
    .hana-quote-item-add .hqi-grid > .hqi-field:nth-of-type(4) {
      grid-column: 5 / 6 !important;  /* 수량 */
    }
    .hana-quote-item-add .hqi-grid > .hqi-field:nth-of-type(5) {
      grid-column: 6 / 7 !important;  /* 단가 (공급가액 col 7은 자동 계산이라 비움) */
    }
    .hana-quote-item-add .hqi-grid > .hqi-field:nth-of-type(6) {
      grid-column: 8 / 9 !important;  /* 비고 */
    }
    .hana-quote-item-add .hqi-grid > .hqi-add-btn {
      grid-column: 9 / 10 !important;  /* + 추가 */
    }
    
    /* input들이 자기 column 폭을 다 채우게 */
    .hana-quote-item-add .hqi-grid > .hqi-field {
      min-width: 0 !important;
      width: 100% !important;
    }
    .hana-quote-item-add .hqi-grid > .hqi-field input {
      width: 100% !important;
      min-width: 0 !important;
      box-sizing: border-box !important;
    }
    
    /* 모바일에서는 grid 사용 안 함 (좁아 답답하므로 wrap) */
    @media (max-width: 767px) {
      .hana-quote-item-add .hqi-grid {
        display: flex !important;
        flex-wrap: wrap !important;
        grid-template-columns: none !important;
      }
      .hana-quote-item-add .hqi-grid > .hqi-field,
      .hana-quote-item-add .hqi-grid > .hqi-add-btn {
        grid-column: auto !important;
      }
    }

/* == inc-nav-15.css (ve13c37f0) == */
/* 활성 (canBid) 버튼: 모던한 그라데이션 + 그림자 */
    .hana-quote-bid-btn {
      background: linear-gradient(135deg, #10B981 0%, #059669 100%) !important;
      color: #ffffff !important;
      border: none !important;
      padding: 10px 20px !important;
      border-radius: 10px !important;
      font-size: 14px !important;
      font-weight: 600 !important;
      cursor: pointer !important;
      box-shadow: 0 2px 8px rgba(16, 185, 129, 0.25) !important;
      transition: all 0.2s ease !important;
      letter-spacing: -0.2px !important;
      display: inline-flex !important;
      align-items: center !important;
      justify-content: center !important;
      gap: 6px !important;
      min-width: 140px !important;
      line-height: 1.2 !important;
      white-space: nowrap !important;
    }
    
    .hana-quote-bid-btn:hover {
      background: linear-gradient(135deg, #059669 0%, #047857 100%) !important;
      box-shadow: 0 4px 14px rgba(16, 185, 129, 0.4) !important;
      transform: translateY(-1px) !important;
      color: #ffffff !important;
    }
    
    .hana-quote-bid-btn:active {
      transform: translateY(0) !important;
      box-shadow: 0 2px 6px rgba(16, 185, 129, 0.3) !important;
    }
    
    /* 비활성 (권한 없음) 버튼: 회색 톤 */
    .hana-quote-bid-btn[disabled],
    .hana-quote-bid-btn.is-disabled,
    .hana-quote-detail__head button.hana-quote-bid-btn[style*="9ca3af"] {
      background: #f3f4f6 !important;
      color: #9ca3af !important;
      border: 1px solid #d1d5db !important;
      box-shadow: none !important;
      cursor: not-allowed !important;
    }
    
    .hana-quote-bid-btn[disabled]:hover,
    .hana-quote-bid-btn.is-disabled:hover {
      background: #f3f4f6 !important;
      color: #9ca3af !important;
      transform: none !important;
      box-shadow: none !important;
    }
    
    /* 모바일에서 텍스트 크기 조정 */
    @media (max-width: 767px) {
      .hana-quote-bid-btn {
        padding: 8px 14px !important;
        font-size: 13px !important;
        min-width: auto !important;
      }
    }

/* == inc-nav-16.css (v1a30ce78) == */
/* 기존 별도 입력 grid 영구 hide (테이블 안 input row로 교체) */
    .hana-quote-item-add .hqi-grid,
    body .hana-quote-item-add .hqi-grid,
    .hana-quote-item-add > .hqi-grid {
    }
    /* hidden inputs는 form submit용으로 유지 (값 sync는 JS가 처리) */
    
    /* [+ 항목 추가] 버튼 (전문 견적서와 동일한 디자인) */
    .hana-simple-add-row-btn {
      display: inline-flex !important;
      align-items: center !important;
      justify-content: center !important;
      padding: 10px 20px !important;
      background: #FF6B00 !important;
      color: #ffffff !important;
      border: none !important;
      border-radius: 8px !important;
      font-size: 14px !important;
      font-weight: 600 !important;
      cursor: pointer !important;
      margin: 12px 0 !important;
      box-shadow: 0 2px 6px rgba(255, 107, 0, 0.2) !important;
      transition: all 0.2s ease !important;
    }
    .hana-simple-add-row-btn:hover {
      background: #E55A00 !important;
      transform: translateY(-1px) !important;
      box-shadow: 0 4px 10px rgba(255, 107, 0, 0.3) !important;
    }
    .hana-simple-add-row-btn:active { transform: translateY(0) !important; }
    
    /* 테이블 안 입력 row (전문 견적서 방식) */
    .hana-quote-items-table tr.hana-quote-input-row {
      background: #FFF8F0 !important;
    }
    .hana-quote-items-table tr.hana-quote-input-row td {
      padding: 6px 4px !important;
    }
    .hana-quote-items-table tr.hana-quote-input-row input {
      width: 100% !important;
      padding: 6px 8px !important;
      border: 1px solid #d1d5db !important;
      border-radius: 4px !important;
      font-size: 13px !important;
      box-sizing: border-box !important;
      min-width: 0 !important;
    }
    .hana-quote-items-table tr.hana-quote-input-row input:focus {
      border-color: #FF6B00 !important;
      outline: none !important;
      box-shadow: 0 0 0 2px rgba(255, 107, 0, 0.1) !important;
    }
    .hana-quote-items-table tr.hana-quote-input-row .row-amount {
      text-align: right !important;
      font-weight: 600 !important;
      color: #FF6B00 !important;
      font-size: 13px !important;
    }
    .hana-quote-items-table tr.hana-quote-input-row .row-confirm,
    .hana-quote-items-table tr.hana-quote-input-row .row-cancel {
      border: none !important;
      padding: 5px 10px !important;
      border-radius: 4px !important;
      font-size: 12px !important;
      font-weight: 600 !important;
      cursor: pointer !important;
      color: #ffffff !important;
    }
    .hana-quote-items-table tr.hana-quote-input-row .row-confirm {
      background: #10B981 !important;
      margin-right: 4px !important;
    }
    .hana-quote-items-table tr.hana-quote-input-row .row-confirm:hover { background: #059669 !important; }
    .hana-quote-items-table tr.hana-quote-input-row .row-cancel {
      background: #6b7280 !important;
    }
    .hana-quote-items-table tr.hana-quote-input-row .row-cancel:hover { background: #4b5563 !important; }
    
    /* 모바일: 입력 row의 input/버튼이 좁아 답답하므로 살짝 조정 */
    @media (max-width: 767px) {
      .hana-quote-items-table tr.hana-quote-input-row input {
        font-size: 12px !important;
        padding: 4px 6px !important;
      }
      .hana-quote-items-table tr.hana-quote-input-row .row-confirm,
      .hana-quote-items-table tr.hana-quote-input-row .row-cancel {
        font-size: 11px !important;
        padding: 4px 6px !important;
      }
    }

/* == inc-nav-18.css (v869134cc) == */
/* 1) 비고 컬럼 (8번째) 데스크탑/모바일 모두 숨김 */
    .hana-quote-items-table th:nth-child(8),
    .hana-quote-items-table td:nth-child(8) {
      display: none !important;
    }
    
    /* 2) 모바일 폼: 데스크탑에서는 숨김 */
    .hana-simple-mobile-form { display: none; }
    
    /* 3) 모바일에서만 폼 표시 */
    @media (max-width: 767px) {
      .hana-simple-mobile-form {
        display: block;
        margin: 12px 0;
        padding: 16px;
        background: #FFF8F0;
        border: 1px solid #FFE0C2;
        border-radius: 8px;
      }
      .hana-simple-mobile-form .mform-title {
        margin: 0 0 12px;
        padding: 8px 12px;
        background: #2563EB;
        color: #ffffff;
        border-radius: 4px;
        font-size: 14px;
        font-weight: 600;
      }
      .hana-simple-mobile-form .mform-row { margin-bottom: 10px; }
      .hana-simple-mobile-form .mform-row-pair {
        display: flex;
        gap: 8px;
        margin-bottom: 10px;
      }
      .hana-simple-mobile-form .mform-row-pair > div { flex: 1; }
      .hana-simple-mobile-form label {
        display: block;
        font-size: 12px;
        color: #6b7280;
        margin-bottom: 4px;
      }
      .hana-simple-mobile-form input {
        width: 100%;
        padding: 8px 10px;
        border: 1px solid #d1d5db;
        border-radius: 6px;
        font-size: 14px;
        box-sizing: border-box;
        background: #ffffff;
      }
      .hana-simple-mobile-form input:focus {
        border-color: #FF6B00;
        outline: none;
        box-shadow: 0 0 0 2px rgba(255, 107, 0, 0.1);
      }
      .hana-simple-mobile-form .mform-add-btn {
        display: block;
        width: 100%;
        padding: 12px;
        background: #FF6B00;
        color: #ffffff;
        border: none;
        border-radius: 8px;
        font-size: 14px;
        font-weight: 600;
        cursor: pointer;
        margin-top: 8px;
        box-shadow: 0 2px 6px rgba(255, 107, 0, 0.2);
        transition: all 0.2s ease;
      }
      .hana-simple-mobile-form .mform-add-btn:hover,
      .hana-simple-mobile-form .mform-add-btn:active {
        background: #E55A00;
      }
      /* 모바일에서 데스크탑 [+ 항목 추가] 버튼 + 테이블 안 input row 숨김 */
      .hana-simple-add-row-btn { display: none !important; }
      .hana-quote-items-table tr.hana-quote-input-row { display: none !important; }
      
      /* 좌우 스크롤바를 새 항목 추가 폼 위로 이동: 테이블을 별도 wrap에서만 스크롤 */
      .hana-quote-detail__section { overflow-x: visible !important; }
      .hana-table-scroll-wrap {
        overflow-x: auto !important;
        width: 100% !important;
        -webkit-overflow-scrolling: touch;
      }
    }

/* == inc-nav-20.css (v754c202e) == */
/* table-layout fixed로 컬럼 비율 강제 */
    .hana-quote-items-table {
      table-layout: fixed !important;
      width: 100% !important;
    }
    
    /* 컬럼별 폭 비율 (비고 hidden, 액션 컬럼 포함 8 visible 컬럼) */
    .hana-quote-items-table th:nth-child(1),
    .hana-quote-items-table td:nth-child(1) { width: 6% !important; }    /* No */
    .hana-quote-items-table th:nth-child(2),
    .hana-quote-items-table td:nth-child(2) { width: 28% !important; }   /* 품명 - 가장 크게 */
    .hana-quote-items-table th:nth-child(3),
    .hana-quote-items-table td:nth-child(3) { width: 16% !important; }   /* 규격 */
    .hana-quote-items-table th:nth-child(4),
    .hana-quote-items-table td:nth-child(4) { width: 7% !important; }    /* 단위 (축소) */
    .hana-quote-items-table th:nth-child(5),
    .hana-quote-items-table td:nth-child(5) { width: 7% !important; }    /* 수량 (축소) */
    .hana-quote-items-table th:nth-child(6),
    .hana-quote-items-table td:nth-child(6) { width: 14% !important; }   /* 단가 */
    .hana-quote-items-table th:nth-child(7),
    .hana-quote-items-table td:nth-child(7) { width: 14% !important; }   /* 공급가액 */
    .hana-quote-items-table th:nth-child(9),
    .hana-quote-items-table td:nth-child(9) { width: 8% !important; }    /* 액션 */
    
    /* 긴 텍스트 줄바꿈 - 잘리지 않도록 */
    .hana-quote-items-table th,
    .hana-quote-items-table td {
      word-break: break-word !important;
      overflow-wrap: anywhere !important;
      white-space: normal !important;
      vertical-align: middle !important;
      padding: 8px 6px !important;
      font-size: 13px !important;
      line-height: 1.4 !important;
    }
    
    /* 텍스트 정렬: 품명/규격은 좌측, 숫자는 우측, 나머지 중앙 */
    .hana-quote-items-table tbody td:nth-child(2),
    .hana-quote-items-table tbody td:nth-child(3) {
      text-align: left !important;
    }
    .hana-quote-items-table tbody td:nth-child(6),
    .hana-quote-items-table tbody td:nth-child(7) {
      text-align: right !important;
    }
    
    /* 모바일에서는 폰트와 패딩 더 작게 (이미 좌우 스크롤됨) */
    @media (max-width: 767px) {
      .hana-quote-items-table {
        min-width: 600px !important;
      }
      .hana-quote-items-table th,
      .hana-quote-items-table td {
        font-size: 12px !important;
        padding: 6px 4px !important;
      }
    }

/* == inc-nav-21.css (v0373a3ca) == */
/* 상단 컨테이너 - flex wrap + 적절한 gap + 카드 느낌 */
    .hana-quote-detail__head {
      display: flex !important;
      flex-wrap: wrap !important;
      align-items: center !important;
      gap: 12px !important;
      padding: 6px 0 !important;
      border-bottom: 1px solid #e5e7eb !important;
      margin-bottom: 12px !important;
    }
    
    /* [← 목록] 버튼 디자인 (단순 텍스트 → 버튼) */
    .hana-quote-detail__back {
      display: inline-flex !important;
      align-items: center !important;
      gap: 4px !important;
      padding: 8px 14px !important;
      background: #ffffff !important;
      color: #4b5563 !important;
      border: 1px solid #d1d5db !important;
      border-radius: 8px !important;
      font-size: 13px !important;
      font-weight: 500 !important;
      text-decoration: none !important;
      transition: all 0.2s ease !important;
      white-space: nowrap !important;
    }
    .hana-quote-detail__back:hover {
      background: #f3f4f6 !important;
      border-color: #9ca3af !important;
      color: #1f2937 !important;
      text-decoration: none !important;
    }
    
    /* 상태 컨트롤 그룹 - 카드 배경 + 둥근 모서리로 그룹감 */
    .hana-quote-status-ctrl {
      display: inline-flex !important;
      align-items: center !important;
      gap: 8px !important;
      padding: 6px 10px 6px 12px !important;
      background: #f9fafb !important;
      border: 1px solid #e5e7eb !important;
      border-radius: 8px !important;
      font-size: 13px !important;
      color: #6b7280 !important;
    }
    
    .hana-quote-status-ctrl select {
      padding: 5px 8px !important;
      border: 1px solid #d1d5db !important;
      border-radius: 6px !important;
      background: #ffffff !important;
      font-size: 13px !important;
      color: #1f2937 !important;
      cursor: pointer !important;
      min-width: 90px !important;
    }
    
    .hana-quote-status-ctrl select:focus {
      outline: none !important;
      border-color: #FF6B00 !important;
      box-shadow: 0 0 0 2px rgba(255, 107, 0, 0.1) !important;
    }
    
    /* "변경" 버튼 */
    .hana-quote-status-ctrl button {
      padding: 6px 14px !important;
      background: #FF6B00 !important;
      color: #ffffff !important;
      border: none !important;
      border-radius: 6px !important;
      font-size: 12px !important;
      font-weight: 600 !important;
      cursor: pointer !important;
      transition: all 0.2s !important;
    }
    .hana-quote-status-ctrl button:hover {
      background: #E55A00 !important;
    }
    
    /* 채팅 시작 버튼 - 우측으로 자동 정렬 (margin-left: auto) */
    .hana-quote-chat-btn {
      margin-left: auto !important;
      padding: 8px 16px !important;
      background: linear-gradient(135deg, #3B82F6 0%, #2563EB 100%) !important;
      color: #ffffff !important;
      border: none !important;
      border-radius: 10px !important;
      font-size: 14px !important;
      font-weight: 600 !important;
      cursor: pointer !important;
      display: inline-flex !important;
      align-items: center !important;
      justify-content: center !important;
      gap: 6px !important;
      box-shadow: 0 2px 8px rgba(59, 130, 246, 0.25) !important;
      transition: all 0.2s ease !important;
      min-width: 110px !important;
      line-height: 1.2 !important;
      white-space: nowrap !important;
    }
    .hana-quote-chat-btn:hover {
      background: linear-gradient(135deg, #2563EB 0%, #1D4ED8 100%) !important;
      box-shadow: 0 4px 14px rgba(59, 130, 246, 0.4) !important;
      transform: translateY(-1px) !important;
    }
    
    /* 일반 견적서 버튼은 이미 디자인 있음 (hana-quote-bid-btn) */
    /* 양 버튼 간격 */
    .hana-quote-chat-btn + .hana-quote-bid-btn,
    .hana-quote-bid-btn {
      margin-left: 0 !important;
    }
    
    /* 모바일 - 자동 줄바꿈 + 컴팩트 */
    @media (max-width: 767px) {
      .hana-quote-detail__head {
        gap: 8px !important;
        padding: 12px 0 !important;
        margin-bottom: 16px !important;
      }
      .hana-quote-detail__back {
        flex: 0 0 auto !important;
        font-size: 12px !important;
        padding: 6px 10px !important;
      }
      .hana-quote-status-ctrl {
        flex: 1 1 100% !important;       /* 모바일: 전체 폭, 한 줄 */
        justify-content: space-between !important;
        order: 3 !important;             /* 가장 아래로 */
      }
      .hana-quote-chat-btn {
        margin-left: auto !important;
        font-size: 12px !important;
        padding: 6px 12px !important;
        min-width: 90px !important;
      }
      .hana-quote-bid-btn {
        font-size: 12px !important;
        padding: 6px 12px !important;
        min-width: 110px !important;
      }
    }

/* == inc-nav-22.css (vfa3eb1d1) == */
/* 데스크탑: body 배경을 흰색으로 (회색 공간 제거) */
    @media (min-width: 768px) {
      body[class*="hana-view-quote"] {
        background: #ffffff !important;
      }
      body[class*="hana-view-quote"] .site-content,
      body[class*="hana-view-quote"] .hana-quote-main {
        background: #ffffff !important;
      }
    }
    
    /* .hana-quote-detail-wrap 위/아래 padding 축소 (24px → 12px) */
    .hana-quote-detail-wrap {
      padding-top: 12px !important;
      padding-bottom: 12px !important;
    }
    
    /* .hana-quote-main 위 margin 축소 (24px → 8px) */
    .hana-quote-main {
      margin-top: 8px !important;
    }

