/**
 * Duckwork Page Styles
 * Tier comparison layout, sticky headers, responsive design
 */

/* ===========================
   Tier Comparison Section
   =========================== */

.tier-comparison {
  position: relative;
  padding-top: 40px;
  padding-bottom: 80px;
  background: var(--color-background);
}

/* Sticky Headers (shown after scroll) */
.sticky-headers {
  position: sticky;
  top: 80px;
  z-index: 900;
  background: rgba(255, 255, 255, 0.98);
  backdrop-filter: blur(10px);
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
  max-height: 0;
  opacity: 0;
  overflow: hidden;
  transform: translateY(-20px);
  transition:
    max-height 0.3s ease,
    opacity 0.3s ease,
    transform 0.3s ease;
  pointer-events: none;
}

.sticky-headers.visible {
  max-height: 200px;
  opacity: 1;
  transform: translateY(0);
  pointer-events: all;
}

.tier-header-grid {
  display: grid;
  grid-template-columns:
    calc((100% - 48px) / 3 + 12px) calc((100% - 48px) / 3 + 24px)
    calc((100% - 48px) / 3 + 12px);
}

.tier-header-item {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 12px 16px;
  border-right: 1px solid #e0e0e0;
}

.tier-header-item:last-child {
  border-right: none;
}

.tier-header-item span {
  font-weight: 700;
  font-size: 16px;
  color: var(--color-text);
}

.tier-header-item .graphic-container {
  width: 40px;
  height: 40px;
  border-radius: 8px;
  background: #f9e9c4;
}

.duck-canvas-small {
  width: 100%;
  height: 100%;
  display: block;
}

/* Mobile Scroll Arrows */
.scroll-arrow {
  display: none;
  position: fixed;
  top: 50%;
  transform: translateY(-50%);
  z-index: 950;
  background: rgba(255, 255, 255, 0.95);
  border: 2px solid var(--color-accent);
  width: 48px;
  height: 48px;
  border-radius: 50%;
  font-size: 24px;
  color: var(--color-accent);
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.scroll-arrow:hover {
  background: var(--color-accent);
  color: #fff;
  transform: translateY(-50%) scale(1.1);
}

.scroll-left {
  left: 16px;
}

.scroll-right {
  right: 16px;
}

/* Tier Columns Wrapper */
.tier-columns-wrapper {
  padding: 0;
  margin: 0;
  overflow-x: auto;
  scroll-behavior: smooth;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}

.tier-columns-wrapper::-webkit-scrollbar {
  display: none;
}

.tier-columns {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
  align-items: start;
}

/* Individual Tier Column */
.tier-column {
  background: var(--color-card);
  border-radius: 16px;
  box-shadow: var(--shadow-base);
  padding: 32px 24px;
  min-width: 0;
  display: grid;
  grid-template-rows: auto auto auto auto auto;
  align-content: start;
}

/* Tier Intro Section */
.tier-intro {
  text-align: center;
  margin-bottom: 32px;
  padding-bottom: 32px;
  border-bottom: 2px solid #f0f0f0;
  grid-row: 1;
}

.tier-canvas-container {
  width: 100%;
  max-width: 300px;
  margin: 0 auto 24px;
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.tier-canvas-container.shrink {
  max-width: 80px;
  margin-bottom: 12px;
}

.tier-canvas-container .graphic-container {
  width: 100%;
  padding-bottom: 100%; /* 1:1 aspect ratio */
  position: relative;
  background: #f9e9c4;
  border-radius: 12px;
}

.tier-canvas-container .duck-canvas {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  display: block;
}

.tier-canvas-container canvas {
  width: 100%;
  height: auto;
  aspect-ratio: 1 / 1;
  background: #f9e9c4;
  border-radius: 16px;
  cursor: pointer;
}

.tier-column h2 {
  font-size: 28px;
  font-weight: 700;
  margin-bottom: 12px;
  color: var(--color-text);
}

.tier-tagline {
  font-size: 16px;
  line-height: 1.6;
  color: var(--color-muted);
  margin-bottom: 16px;
}

.tier-turnaround {
  font-size: 14px;
  font-weight: 600;
  color: var(--color-accent);
  background: rgba(25, 86, 245, 0.1);
  padding: 8px 16px;
  border-radius: 8px;
  display: inline-block;
}

/* Info Sections */
.info-section {
  margin-bottom: 32px;
  padding: 24px;
  background: #fafafa;
  border-radius: 12px;
}

.info-section h3 {
  font-size: 20px;
  font-weight: 700;
  margin-bottom: 16px;
  color: var(--color-text);
  padding-bottom: 12px;
  border-bottom: 2px solid var(--color-accent);
}

.info-section h4 {
  font-size: 16px;
  font-weight: 700;
  margin-bottom: 8px;
  margin-top: 16px;
  color: var(--color-text);
}

.info-section h4:first-of-type {
  margin-top: 0;
}

/* Pricing Section */
.pricing-section {
  grid-row: 2;
}

.pricing-group ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.pricing-group li {
  padding: 8px 0;
  font-size: 15px;
  color: var(--color-text);
}

.pricing-group li.disabled {
  color: #999;
  text-decoration: line-through;
}

.urgent-option {
  margin-top: 20px;
  padding: 16px;
  background: rgba(255, 193, 7, 0.1);
  border-radius: 8px;
  border: 2px solid #ffc107;
}

.urgent-option label {
  display: flex;
  align-items: center;
  gap: 12px;
  cursor: pointer;
  font-weight: 600;
}

.urgent-option input[type="checkbox"] {
  width: 20px;
  height: 20px;
  cursor: pointer;
}

.no-urgency,
.varies {
  font-size: 15px;
  color: var(--color-muted);
  font-style: italic;
  margin-top: 16px;
}

.varies {
  font-weight: 600;
  font-size: 16px;
  color: var(--color-accent);
}

/* Materials Section */
.materials-section {
  grid-row: 3;
}

/* Materials Table */
.materials-table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 16px;
}

.materials-table thead th {
  background: var(--color-accent);
  color: #fff;
  padding: 12px 8px;
  text-align: center;
  font-weight: 700;
  font-size: 14px;
}

.materials-table thead th:first-child {
  text-align: left;
  border-radius: 8px 0 0 0;
}

.materials-table thead th:last-child {
  border-radius: 0 8px 0 0;
}

.materials-table tbody tr {
  border-bottom: 1px solid #e0e0e0;
  transition: background 0.2s ease;
}

.materials-table tbody tr:hover {
  background: rgba(25, 86, 245, 0.05);
}

.materials-table tbody tr.disabled-row {
  background: #f5f5f5;
  opacity: 0.6;
}

.materials-table tbody tr.disabled-row td {
  color: #999;
}

.materials-table td {
  padding: 12px 8px;
  font-size: 14px;
  text-align: center;
}

.materials-table td:first-child {
  text-align: left;
  font-weight: 500;
  position: relative;
}

.materials-table .check {
  color: #2d7d2d;
  font-weight: 700;
  font-size: 18px;
}

.materials-table .cross {
  color: #b33939;
  font-weight: 700;
  font-size: 18px;
}

.materials-table .cross.disabled {
  color: #ccc;
}

.info-icon {
  background: var(--color-accent);
  color: #fff;
  border: none;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  font-size: 12px;
  font-weight: 700;
  cursor: help;
  margin-left: 6px;
  transition: transform 0.2s ease;
  vertical-align: middle;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
}

.info-icon:hover {
  transform: scale(1.15);
  background: #0d3fbf;
}

.custom-request {
  font-weight: 600;
  color: var(--color-accent);
  text-align: left !important;
  padding: 16px 8px !important;
}

/* Hourly Rate Row Styling */
.hourly-rate-row {
  background: rgba(25, 86, 245, 0.15);
  font-weight: 600;
  color: #1956f5;
}

.hourly-rate-row td {
  border-top: 2px solid #1956f5;
}

/* Enterprise Pricing Custom Content */
.enterprise-pricing-intro {
  font-size: 15px;
  line-height: 1.6;
  color: var(--color-text);
  margin: 16px 0 8px 0;
  padding: 12px 16px;
  background: rgba(25, 86, 245, 0.05);
  border-radius: 8px;
}

.custom-pricing {
  font-size: 16px;
  font-weight: 600;
  color: var(--color-accent);
  margin: 12px 0 0 0;
  padding: 20px 16px;
  background: rgba(240, 240, 240, 0.5);
  border-radius: 8px;
  text-align: center;
}

.custom-pricing-list {
  margin: 12px 0;
  padding: 16px 20px;
  background: rgba(240, 240, 240, 0.3);
  border-radius: 8px;
}

.custom-pricing-list p {
  font-size: 15px;
  line-height: 1.8;
  color: var(--color-text);
  margin: 4px 0;
}

.enterprise-pricing-footnote {
  font-size: 13px;
  line-height: 1.5;
  color: #666;
  margin-top: 20px;
  padding: 12px 16px;
  background: rgba(240, 240, 240, 0.3);
  border-radius: 6px;
  font-style: italic;
}

.materials-subtitle {
  font-size: 14px;
  font-weight: 600;
  color: var(--color-text);
  margin: 8px 0;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  opacity: 0.7;
}

/* Fee Sections */
.fee-section {
  grid-row: 4;
  text-align: center;
}

.delivery-section {
  grid-row: 5;
  text-align: center;
}

.fee-amount {
  font-size: 32px;
  font-weight: 700;
  color: var(--color-accent);
  margin-top: 8px;
}

.delivery-section p {
  font-size: 16px;
  color: var(--color-text);
  margin-top: 8px;
}

/* Tier Footnote */
.tier-footnote {
  text-align: center;
  padding: 24px;
  margin-top: 32px;
}

.tier-footnote p {
  font-size: 13px;
  color: var(--color-muted);
  font-style: italic;
}

/* ===========================
   Floating Submit Button
   =========================== */

.floating-submit-btn {
  position: fixed;
  bottom: 32px;
  right: 32px;
  z-index: 1000;
  background: var(--color-accent);
  color: #fff;
  border: none;
  padding: 16px 32px;
  border-radius: 50px;
  font-size: 16px;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 0 4px 20px rgba(25, 86, 245, 0.4);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.floating-submit-btn:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 30px rgba(25, 86, 245, 0.5);
  background: #0d3fbf;
}

.floating-submit-btn:active {
  transform: translateY(-2px);
}

/* ===========================
   Form Overlay & Popup
   =========================== */

.form-overlay {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.6);
  z-index: 2000;
  overflow-y: auto;
  backdrop-filter: blur(4px);
}

.form-overlay.active {
  display: flex;
  justify-content: center;
  align-items: flex-start;
}

.form-container {
  background: #fff;
  border-radius: 20px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
  max-width: 800px;
  width: 100%;
  margin: auto;
  position: relative;
  animation: slideUp 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

@keyframes slideUp {
  from {
    opacity: 0;
    transform: translateY(40px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.form-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 24px 32px;
  border-bottom: 2px solid #f0f0f0;
  background: linear-gradient(135deg, #f9d88c 0%, #ffeaa7 100%);
  border-radius: 20px 20px 0 0;
}

.form-header h2 {
  font-size: 24px;
  font-weight: 700;
  color: var(--color-text);
  margin: 0;
}

.form-actions {
  display: flex;
  gap: 12px;
}

.btn-reset,
.btn-close {
  border: none;
  width: 40px;
  height: 40px;
  border-radius: 8px;
  font-size: 18px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s ease;
  display: flex;
  align-items: center;
  justify-content: center;
}

.btn-reset {
  background: #ffc107;
  color: #fff;
}

.btn-reset svg {
  width: 20px;
  height: 20px;
  fill: #fff;
}

.btn-reset:hover {
  background: #ffb300;
  transform: scale(1.05);
}

.btn-close {
  background: #dc3545;
  color: #fff;
}

.btn-close:hover {
  background: #c82333;
  transform: scale(1.05);
}

/* Quote Form */
.quote-form {
  padding: 32px;
  max-height: calc(100dvh - 150px);
  overflow-y: auto;
}

.form-section {
  margin-bottom: 40px;
  padding-bottom: 32px;
  border-bottom: 1px solid #e0e0e0;
}

.form-section:last-child {
  border-bottom: none;
}

.form-section h3 {
  font-size: 20px;
  font-weight: 700;
  margin-bottom: 16px;
  color: var(--color-accent);
  display: flex;
  align-items: center;
  gap: 12px;
}

.form-section h3::before {
  content: attr(data-number);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  background: var(--color-accent);
  color: #fff;
  border-radius: 50%;
  font-size: 16px;
}

.form-group {
  margin-bottom: 20px;
}

.form-group label {
  display: block;
  font-weight: 700;
  margin-bottom: 8px;
  color: var(--color-text);
}

.form-group label.required::after {
  content: " *";
  color: #dc3545;
}

/* Option text should be normal weight */
.checkbox-label span,
.radio-label span {
  font-weight: 400;
}

/* Tier subtitle styling */
.tier-subtitle {
  font-size: 13px;
  color: #999;
  font-weight: 400;
  display: block;
  margin-top: 2px;
}

.form-input,
.form-textarea,
.form-select {
  width: 100%;
  padding: 12px 16px;
  border: 2px solid #e0e0e0;
  border-radius: 8px;
  font-size: 15px;
  font-family: "Aptos", sans-serif;
  transition: border-color 0.2s ease;
}

.form-input:focus,
.form-textarea:focus,
.form-select:focus {
  outline: none;
  border-color: var(--color-accent);
}

.form-input.error,
.form-textarea.error {
  border-color: #dc3545;
}

.form-textarea {
  resize: none;
  min-height: 120px;
}

.checkbox-group,
.radio-group {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.checkbox-label,
.radio-label {
  display: flex;
  align-items: center;
  gap: 12px;
  cursor: pointer;
  padding: 12px;
  border-radius: 8px;
  transition: background 0.2s ease;
}

.checkbox-label:hover,
.radio-label:hover {
  background: rgba(25, 86, 245, 0.05);
}

.checkbox-label input[type="checkbox"],
.radio-label input[type="radio"] {
  width: 20px;
  height: 20px;
  cursor: pointer;
}

.checkbox-label.disabled,
.radio-label.disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.checkbox-label.disabled input,
.radio-label.disabled input {
  cursor: not-allowed;
}

.nested-input {
  margin-left: 32px;
  margin-top: 12px;
}

.switch-container {
  display: flex;
  align-items: center;
  gap: 16px;
}

.switch {
  position: relative;
  width: 60px;
  height: 32px;
}

.switch input {
  opacity: 0;
  width: 0;
  height: 0;
}

.slider {
  position: absolute;
  cursor: pointer;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: #dc3545;
  transition: 0.3s;
  border-radius: 32px;
}

.slider:before {
  position: absolute;
  content: "";
  height: 24px;
  width: 24px;
  left: 4px;
  bottom: 4px;
  background-color: white;
  transition: 0.3s;
  border-radius: 50%;
}

input:checked + .slider {
  background-color: #28a745;
}

input:checked + .slider:before {
  transform: translateX(28px);
}

.switch-label {
  font-weight: 600;
  color: var(--color-text);
}

.file-upload-area {
  border: 2px dashed var(--color-accent);
  border-radius: 12px;
  padding: 32px;
  text-align: center;
  background: rgba(25, 86, 245, 0.03);
  transition: all 0.3s ease;
}

.file-upload-area:hover {
  background: rgba(25, 86, 245, 0.08);
  border-color: #0d3fbf;
}

.upload-btn {
  background: var(--color-accent);
  color: #fff;
  border: none;
  padding: 12px 24px;
  border-radius: 8px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s ease;
  margin-top: 12px;
}

.upload-btn:hover {
  background: #0d3fbf;
  transform: translateY(-2px);
}

.file-list {
  margin-top: 16px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.file-item {
  margin-bottom: 12px;
}

.file-item-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
  padding: 12px;
  background: #f5f5f5;
  border-radius: 6px;
}

.file-item-icon {
  font-size: 24px;
  flex-shrink: 0;
  text-align: center;
}

.file-item-info {
  flex: 1 1 200px;
  min-width: 150px;
}

.file-item-name {
  font-weight: 500;
  word-break: break-word;
}

.file-item-size {
  font-size: 12px;
  color: #666;
}

.file-item-quantity {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.file-item-quantity label {
  font-size: 14px;
  color: #666;
  white-space: nowrap;
}

.file-item-quantity-controls {
  display: flex;
  align-items: center;
  gap: 4px;
}

.quantity-btn-decrease,
.quantity-btn-increase {
  background: #6c757d;
  color: #fff;
  border: none;
  width: 32px;
  height: 32px;
  border-radius: 4px;
  cursor: pointer;
  font-size: 16px;
  font-weight: bold;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.quantity-btn-decrease:hover,
.quantity-btn-increase:hover {
  background: #5a6268;
}

.quantity-input {
  width: 50px;
  text-align: center;
  border: 1px solid #ddd;
  border-radius: 4px;
  padding: 6px 4px;
  font-size: 14px;
  flex-shrink: 0;
}

.remove-file-btn {
  background: #dc3545;
  color: #fff;
  border: none;
  padding: 8px 16px;
  border-radius: 4px;
  cursor: pointer;
  font-size: 14px;
  white-space: nowrap;
  flex-shrink: 0;
}

.remove-file-btn:hover {
  background: #c82333;
}

@media (max-width: 768px) {
  .file-item-row {
    gap: 8px;
    padding: 10px;
  }
  
  .file-item-info {
    flex: 1 1 100%;
    min-width: 0;
  }
  
  .file-item-quantity {
    flex: 1 1 100%;
    justify-content: space-between;
  }
  
  .remove-file-btn {
    flex: 1 1 100%;
    width: 100%;
  }
}

.slider-container {
  padding: 20px 0;
}

.slider-input {
  width: 100%;
  height: 8px;
  border-radius: 4px;
  background: linear-gradient(to right, #e0e0e0 0%, var(--color-accent) 100%);
  outline: none;
}

.slider-input::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: var(--color-accent);
  cursor: pointer;
  box-shadow: 0 2px 8px rgba(25, 86, 245, 0.3);
}

.slider-input::-moz-range-thumb {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: var(--color-accent);
  cursor: pointer;
  border: none;
  box-shadow: 0 2px 8px rgba(25, 86, 245, 0.3);
}

.slider-labels {
  display: flex;
  justify-content: space-between;
  margin-top: 8px;
  font-size: 13px;
  color: var(--color-muted);
}

.submit-buttons {
  display: flex;
  flex-direction: column;
  gap: 16px;
  margin-top: 32px;
}

.btn-submit {
  width: 100%;
  padding: 16px 32px;
  background: var(--color-accent);
  color: #fff;
  border: none;
  border-radius: 12px;
  font-size: 18px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.3s ease;
}

.btn-submit:hover {
  background: #0d3fbf;
  transform: translateY(-2px);
  box-shadow: 0 4px 16px rgba(25, 86, 245, 0.3);
}

.form-note {
  text-align: center;
  font-size: 14px;
  color: var(--color-muted);
  margin-top: 16px;
  font-style: italic;
}

/* Material Dropdown Container */
.material-dropdown-container {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.material-row {
  display: flex;
  align-items: center;
  gap: 12px;
}

.material-row label {
  min-width: 80px;
  font-weight: 400;
  color: #666;
  margin-bottom: 0;
}

.material-select {
  flex: 1;
}

/* Loading Spinner Animation */
@keyframes spin {
  from {
    transform: rotate(0deg);
  }
  to {
    transform: rotate(360deg);
  }
}

.loading-spinner {
  animation: spin 1s linear infinite;
  display: inline-block;
}

/* Instagram Profile Preview */
.instagram-preview {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  background: #f9f9f9;
  border: 1px solid #e0e0e0;
  border-radius: 8px;
  margin-top: 8px;
  transition: all 0.3s ease;
}

.instagram-preview img {
  border: 2px solid #e0e0e0;
  transition: border-color 0.3s ease;
}

.instagram-preview.verified img {
  border-color: #28a745;
}

.instagram-preview.error {
  background: #f9f9f9;
  border-color: #d0d0d0;
}

/* Disabled checkbox label styling */
.checkbox-label.disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.checkbox-label.disabled input[type="checkbox"] {
  cursor: not-allowed;
}

/* Nested input alignment */
.nested-input {
  margin-left: 32px;
  margin-top: 12px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

/* Info icon in tier selection */
.info-icon {
  margin-left: auto;
  background: #1956f5;
  color: #fff;
  border: none;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s ease;
}

.info-icon:hover {
  background: #0d47d1;
  transform: scale(1.1);
}

/* Disabled button state */
button:disabled,
button.disabled {
  opacity: 0.5;
  cursor: not-allowed !important;
}

/* Start Another Job button */
.btn-start-another {
  background: #ffc107;
  color: #000;
  font-weight: 700;
  padding: 14px 32px;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  font-size: 16px;
  transition: all 0.2s ease;
  width: 100%;
  max-width: 400px;
  margin-top: 16px;
}

.btn-start-another:hover {
  background: #ffb300;
  transform: scale(1.02);
}

/* Submit buttons container */
.submit-buttons {
  display: flex;
  flex-direction: column;
  gap: 12px;
  align-items: center;
}

.submit-buttons .btn-submit {
  width: 100%;
  max-width: 400px;
}

/* ===========================
   Responsive Design
   =========================== */

@media (max-width: 1023px) {
  .tier-columns {
    display: flex;
    flex-direction: row;
    gap: 24px;
    width: max-content;
    max-width: none;
    /* FULL RESET OF DESKTOP GRID BEHAVIOR */
    grid-template-columns: none;
    margin: 0;
    padding: 0 24px;
  }

  .tier-columns-wrapper {
    overflow-x: scroll;
    scroll-behavior: smooth;
    -webkit-overflow-scrolling: touch;
  }

  .tier-column {
    flex: 0 0 calc(100vw - 48px);
    padding: 24px;
    box-sizing: border-box;
  }

  /* Prevent canvas shrinking on mobile */
  .tier-canvas-container {
    max-width: 280px !important;
  }

  .tier-canvas-container.shrink {
    max-width: 280px !important;
    margin-bottom: 24px !important;
  }

  .scroll-arrow {
    display: flex;
    align-items: center;
    justify-content: center;
  }

  .sticky-headers {
    top: 60px;
    overflow: hidden;
  }

  .sticky-headers .container {
    max-width: none;
    padding: 0;
    overflow: visible;
  }

  .tier-header-grid {
    display: flex;
    flex-direction: row;
    gap: 24px;
    width: max-content;
    max-width: none;
    /* FULL RESET OF DESKTOP GRID BEHAVIOR */
    grid-template-columns: none;
    margin: 0;
    padding: 0 24px;
    transition: transform 0.1s ease-out;
  }

  .tier-header-item {
    flex: 0 0 calc(100vw - 48px);
    gap: 24px;
    padding: 24px 0;
    border-right: none;
    border-bottom: none;
  }

  .floating-submit-btn {
    bottom: 16px;
    right: 16px;
    padding: 14px 24px;
    font-size: 14px;
  }

  .form-container {
    margin: 20px;
    max-width: none;
    height: calc(100dvh - 40px);
  }

  .form-header {
    padding: 20px;
  }

  .form-header h2 {
    font-size: 18px;
  }

  .quote-form {
    padding: 20px;
  }
    
  .file-item-icon {
    width: 100%;
  }
}

@media (max-width: 767px) {
  .tier-comparison {
    padding-top: 20px;
  }

  .tier-canvas-container {
    max-width: 240px;
  }

  .info-section {
    padding: 16px;
  }

  .materials-table {
    font-size: 13px;
  }

  .materials-table td,
  .materials-table th {
    padding: 8px 4px;
  }

  .form-actions {
    gap: 8px;
  }

  .btn-reset,
  .btn-close {
    width: 36px;
    height: 36px;
    font-size: 16px;
  }
}
