* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue',
    Arial, 'Noto Sans', 'PingFang SC', 'Microsoft YaHei', sans-serif;
  background: #f3e9dc;
  color: #3c2a20;
}

.layout {
  min-height: 100vh;
  padding: 32px 24px 48px;
  max-width: 1200px;
  margin: 0 auto;
}

.hero {
  margin-bottom: 24px;
  background: linear-gradient(135deg, #d9a87a, #b87a4b);
  color: #fff7e6;
  border-radius: 16px;
  padding: 24px;
  box-shadow: 0 14px 35px rgba(97, 63, 36, 0.25);
}

.hero-content {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 20px;
}

.eyebrow {
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #f8e8ce;
  font-size: 12px;
  margin: 0 0 8px;
}

h1 {
  margin: 0 0 10px;
  font-size: 28px;
}

.subtitle {
  margin: 0;
  color: #fbead2;
}

.tabs {
  background: #fff7e6;
  border: 1px solid #d8bfa3;
  border-radius: 12px;
  padding: 12px;
  box-shadow: 0 10px 24px rgba(97, 63, 36, 0.12);
}

.tab-bar {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 12px;
}

.tab {
  border: 1px solid #c69c6c;
  background: #f0d2aa;
  color: #3c2a20;
  padding: 10px 14px;
  border-radius: 10px;
  cursor: pointer;
  transition: all 0.15s ease;
  box-shadow: 0 6px 14px rgba(97, 63, 36, 0.14);
}

.tab:hover {
  background: #e8c38f;
  border-color: #b68557;
}

.tab.active {
  background: linear-gradient(135deg, #8bcf8b, #6ea66e);
  border-color: #5f8c5f;
  color: #1f120c;
  font-weight: 700;
}

.frames {
  position: relative;
}

.flow-frame {
  width: 100%;
  min-height: 70vh;
  border: 1px solid #d8bfa3;
  border-radius: 10px;
  overflow: hidden;
  background: #fffaf0;
  display: none;
  box-shadow: 0 10px 24px rgba(97, 63, 36, 0.12);
}

.flow-frame.active {
  display: block;
}

.footer {
  margin-top: 24px;
  color: #7a5a45;
  text-align: center;
  font-size: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  flex-wrap: wrap;
}

.github-link-hero {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: #fff7e6;
  text-decoration: none;
  padding: 10px 16px;
  border-radius: 10px;
  border: 2px solid rgba(255, 247, 230, 0.3);
  transition: all 0.15s ease;
  font-weight: 600;
  white-space: nowrap;
  background: rgba(255, 255, 255, 0.1);
}

.github-link-hero:hover {
  background: rgba(255, 255, 255, 0.2);
  border-color: rgba(255, 247, 230, 0.5);
  transform: translateY(-2px);
}

.github-link-hero svg {
  flex-shrink: 0;
}

@media (max-width: 768px) {
  .hero-content {
    flex-direction: column;
    align-items: stretch;
  }
  
  .github-link-hero {
    justify-content: center;
  }
}

.clipboard-panel {
  position: fixed;
  bottom: 20px;
  right: 20px;
  width: 320px;
  max-height: 400px;
  background: #fff7e6;
  border: 2px solid #d8bfa3;
  border-radius: 12px;
  box-shadow: 0 10px 30px rgba(97, 63, 36, 0.25);
  z-index: 1000;
  display: flex;
  flex-direction: column;
  transition: all 0.3s ease;
}

.clipboard-panel.collapsed .clipboard-content {
  display: none;
}

.clipboard-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 14px;
  background: #f7e6cf;
  border-bottom: 1px solid #d8bfa3;
  border-radius: 10px 10px 0 0;
  cursor: pointer;
  user-select: none;
}

.clipboard-header strong {
  font-size: 14px;
  color: #3c2a20;
}

.clipboard-actions {
  display: flex;
  gap: 6px;
}

.clipboard-btn {
  background: transparent;
  border: none;
  font-size: 16px;
  cursor: pointer;
  padding: 4px;
  border-radius: 4px;
  transition: background 0.15s ease;
}

.clipboard-btn:hover {
  background: rgba(60, 42, 32, 0.1);
}

.clipboard-content {
  flex: 1;
  overflow-y: auto;
  padding: 8px;
  max-height: 340px;
}

.clipboard-items {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.clipboard-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px;
  background: #fffaf0;
  border: 1px solid #e7d6bd;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.15s ease;
}

.clipboard-item:hover {
  background: #fff;
  border-color: #d8bfa3;
  transform: translateX(-2px);
}

.clipboard-item-thumb {
  width: 50px;
  height: 50px;
  object-fit: cover;
  border-radius: 6px;
  background: #fff;
  border: 1px solid #e7d6bd;
  flex-shrink: 0;
}

.clipboard-item-info {
  flex: 1;
  min-width: 0;
}

.clipboard-item-name {
  font-size: 13px;
  font-weight: 600;
  color: #3c2a20;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.clipboard-item-meta {
  font-size: 11px;
  color: #7a5a45;
  margin-top: 2px;
}

.clipboard-item-remove {
  background: rgba(239, 68, 68, 0.1);
  border: none;
  color: #ef4444;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  cursor: pointer;
  font-size: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: all 0.15s ease;
}

.clipboard-item-remove:hover {
  background: rgba(239, 68, 68, 0.2);
}

.clipboard-empty {
  text-align: center;
  color: #7a5a45;
  font-size: 13px;
  padding: 20px;
  margin: 0;
}

.clipboard-items:not(:empty) + .clipboard-empty {
  display: none;
}

@media (max-width: 768px) {
  .clipboard-panel {
    width: calc(100% - 40px);
    max-width: 320px;
  }
}
