/* ============================================
   PAGE TRANSITIONS GALLERY
   Single tabbed browser with unique themed layouts
   ============================================ */

/* ------------------------------------------
   CSS Variables
   ------------------------------------------ */
.demo-page--page-transitions {
  /* Base Palette */
  --pt-charcoal: #444143;
  --pt-charcoal-dark: #2a292a;
  --pt-charcoal-darker: #1a1919;
  --pt-silver: #A19E9D;
  --pt-silver-light: #c4c2c1;
  --pt-cream: #E2E2DA;
  --pt-white: #FFFFFF;

  /* Semantic Colors */
  --pt-bg: #1a1919;
  --pt-bg-card: #252424;
  --pt-text-primary: var(--pt-cream);
  --pt-text-secondary: var(--pt-silver-light);
  --pt-text-muted: var(--pt-silver);
  --pt-border: #3a3839;
  --pt-border-hover: #4a4849;

  /* Browser chrome */
  --pt-chrome-bg: #1e1d1d;
  --pt-chrome-border: #333232;

  /* Spacing */
  --pt-space-xs: 4px;
  --pt-space-sm: 8px;
  --pt-space-md: 16px;
  --pt-space-lg: 24px;
  --pt-space-xl: 32px;
  --pt-space-2xl: 48px;

  /* Typography */
  --pt-font: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;

  /* Borders */
  --pt-radius-sm: 4px;
  --pt-radius-md: 8px;
  --pt-radius-lg: 12px;
  --pt-radius-xl: 16px;
  --pt-radius-full: 9999px;

  /* Easing */
  --pt-ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --pt-ease-smooth: cubic-bezier(0.4, 0, 0.2, 1);

  /* Transition duration */
  --pt-duration: 0.6s;
}

/* ------------------------------------------
   Base Styles
   ------------------------------------------ */
.demo-page--page-transitions {
  min-height: 100vh;
  background: var(--pt-bg);
  color: var(--pt-text-primary);
  font-family: var(--pt-font);
  padding: var(--pt-space-lg);
  box-sizing: border-box;
}

.demo-page--page-transitions *,
.demo-page--page-transitions *::before,
.demo-page--page-transitions *::after {
  box-sizing: border-box;
}

/* ------------------------------------------
   Back Link (Pill Style)
   ------------------------------------------ */
.pt-back-link {
  position: fixed;
  top: var(--pt-space-lg);
  left: var(--pt-space-lg);
  z-index: 100;
  display: flex;
  align-items: center;
  gap: var(--pt-space-sm);
  padding: var(--pt-space-sm) var(--pt-space-md);
  background: rgba(42, 41, 42, 0.8);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid var(--pt-border);
  border-radius: var(--pt-radius-full);
  color: var(--pt-text-secondary);
  text-decoration: none;
  font-size: 14px;
  font-weight: 500;
  transition: all 0.25s var(--pt-ease-out);
}

.pt-back-link:hover {
  background: rgba(42, 41, 42, 0.95);
  border-color: var(--pt-border-hover);
  color: var(--pt-cream);
  transform: translateX(-4px);
}

.pt-back-link svg {
  width: 18px;
  height: 18px;
  transition: transform 0.25s var(--pt-ease-out);
}

.pt-back-link:hover svg {
  transform: translateX(-2px);
}

/* ------------------------------------------
   Header
   ------------------------------------------ */
.pt-header {
  text-align: center;
  max-width: 600px;
  margin: 0 auto var(--pt-space-xl);
  padding: var(--pt-space-2xl) var(--pt-space-lg) var(--pt-space-md);
}

.pt-eyebrow {
  display: inline-block;
  padding: var(--pt-space-xs) var(--pt-space-md);
  background: rgba(155, 168, 196, 0.15);
  border-radius: var(--pt-radius-full);
  color: #9ba8c4;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: var(--pt-space-md);
}

.pt-title {
  font-size: clamp(32px, 6vw, 48px);
  font-weight: 600;
  letter-spacing: -0.02em;
  margin: 0;
  background: linear-gradient(135deg, var(--pt-cream) 0%, var(--pt-silver) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* ------------------------------------------
   Browser Wrapper
   ------------------------------------------ */
.pt-browser-wrapper {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 var(--pt-space-md);
}

.pt-browser {
  background: var(--pt-bg-card);
  border: 1px solid var(--pt-border);
  border-radius: var(--pt-radius-xl);
  overflow: hidden;
  box-shadow:
    0 4px 24px rgba(0, 0, 0, 0.3),
    0 12px 48px rgba(0, 0, 0, 0.2);
}

/* ------------------------------------------
   Browser Chrome
   ------------------------------------------ */
.pt-browser-chrome {
  background: var(--pt-chrome-bg);
  border-bottom: 1px solid var(--pt-chrome-border);
}

.pt-chrome-top {
  display: flex;
  align-items: center;
  gap: var(--pt-space-md);
  padding: var(--pt-space-sm) var(--pt-space-md);
  border-bottom: 1px solid var(--pt-chrome-border);
}

.pt-traffic-lights {
  display: flex;
  gap: 6px;
  flex-shrink: 0;
}

.pt-traffic-lights span {
  width: 12px;
  height: 12px;
  border-radius: 50%;
}

.pt-traffic-lights span:nth-child(1) { background: #ff5f57; }
.pt-traffic-lights span:nth-child(2) { background: #ffbd2e; }
.pt-traffic-lights span:nth-child(3) { background: #28ca42; }

.pt-address-bar {
  flex: 1;
  display: flex;
  align-items: center;
  gap: var(--pt-space-sm);
  padding: 8px var(--pt-space-md);
  background: var(--pt-charcoal-darker);
  border-radius: var(--pt-radius-md);
  font-size: 13px;
  color: var(--pt-text-muted);
}

.pt-lock-icon {
  opacity: 0.5;
  flex-shrink: 0;
}

.pt-url-path {
  color: #DCE8E7;
  transition: color 0.3s ease;
}

/* ------------------------------------------
   Tab Bar
   ------------------------------------------ */
.pt-tab-bar {
  display: flex;
  padding: 0 var(--pt-space-sm);
  overflow-x: auto;
  scrollbar-width: none;
}

.pt-tab-bar::-webkit-scrollbar {
  display: none;
}

.pt-tab {
  position: relative;
  flex-shrink: 0;
  padding: var(--pt-space-sm) var(--pt-space-md);
  background: transparent;
  border: none;
  color: var(--pt-text-muted);
  font-family: var(--pt-font);
  font-size: 12px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s var(--pt-ease-out);
  white-space: nowrap;
}

.pt-tab::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: var(--pt-space-sm);
  right: var(--pt-space-sm);
  height: 2px;
  background: #DCE8E7;
  border-radius: 2px 2px 0 0;
  opacity: 0;
  transform: scaleX(0);
  transition: all 0.25s var(--pt-ease-out);
}

.pt-tab:hover {
  color: var(--pt-text-secondary);
}

.pt-tab--active {
  color: #DCE8E7;
}

.pt-tab--active::after {
  opacity: 1;
  transform: scaleX(1);
}

/* ------------------------------------------
   Viewport
   ------------------------------------------ */
.pt-viewport {
  position: relative;
  height: 520px;
  background: #f5f5f3;
  overflow: hidden;
  perspective: 1200px;
}

/* ------------------------------------------
   Base Page Styles
   ------------------------------------------ */
.pt-page {
  position: absolute;
  inset: 0;
  opacity: 0;
  pointer-events: none;
  transition: none;
  display: flex;
  flex-direction: column;
}

.pt-page--active {
  opacity: 1;
  pointer-events: auto;
}

.pt-page--hidden {
  display: none !important;
}

.pt-page-body {
  flex: 1;
  overflow: hidden;
}

/* ------------------------------------------
   Navigation Bar
   ------------------------------------------ */
.pt-nav {
  display: flex;
  align-items: center;
  padding: 12px 20px;
  background: rgba(255,255,255,0.95);
  border-bottom: 1px solid rgba(0,0,0,0.06);
}

.pt-nav--dark {
  background: rgba(30,30,30,0.95);
}

.pt-nav-logo {
  width: 28px;
  height: 28px;
  border-radius: 6px;
  background: currentColor;
  opacity: 0.15;
}

.pt-nav--dark .pt-nav-logo {
  background: #fff;
  opacity: 0.2;
}

.pt-nav-links {
  display: flex;
  gap: 16px;
  margin-left: 24px;
}

.pt-nav-links span {
  width: 48px;
  height: 8px;
  border-radius: 4px;
  background: currentColor;
  opacity: 0.1;
}

.pt-nav--dark .pt-nav-links span {
  background: #fff;
  opacity: 0.15;
}

.pt-nav-cta,
.pt-nav-cart {
  margin-left: auto;
  width: 60px;
  height: 28px;
  border-radius: 6px;
}

/* ============================================
   COLOR THEMES
   ============================================ */

/* FADE: Sage/Green */
.pt-theme--fade {
  --theme-bg: #f7f9f8;
  --theme-accent: #8fb5b0;
  --theme-accent-light: #dce8e7;
  --theme-block: #e8edec;
  --theme-block-dark: #d0dbd9;
  background: var(--theme-bg);
}

/* SLIDE-H: Blue */
.pt-theme--slide-h {
  --theme-bg: #f5f7fa;
  --theme-accent: #5b8dd9;
  --theme-accent-light: #e0eaf7;
  --theme-block: #e5eaf2;
  --theme-block-dark: #cdd5e3;
  background: var(--theme-bg);
}

/* SLIDE-V: Purple */
.pt-theme--slide-v {
  --theme-bg: #f8f6fa;
  --theme-accent: #9b7bc7;
  --theme-accent-light: #e8e0f3;
  --theme-block: #ebe6f2;
  --theme-block-dark: #d8cfe6;
  background: var(--theme-bg);
}

/* SCALE: Orange */
.pt-theme--scale {
  --theme-bg: #faf8f5;
  --theme-accent: #d4915c;
  --theme-accent-light: #f5e6d8;
  --theme-block: #f0ebe4;
  --theme-block-dark: #e2d8cb;
  background: var(--theme-bg);
}

/* FLIP: Pink */
.pt-theme--flip {
  --theme-bg: #faf6f8;
  --theme-accent: #d47a9e;
  --theme-accent-light: #f5dce7;
  --theme-block: #f2e8ed;
  --theme-block-dark: #e6d3dc;
  background: var(--theme-bg);
}

/* WIPE: Teal */
.pt-theme--wipe {
  --theme-bg: #f5fafa;
  --theme-accent: #4ca8a8;
  --theme-accent-light: #d4eded;
  --theme-block: #e2efef;
  --theme-block-dark: #c8dede;
  background: var(--theme-bg);
}

/* MORPH: Amber */
.pt-theme--morph {
  --theme-bg: #faf9f5;
  --theme-accent: #c9a355;
  --theme-accent-light: #f3ead4;
  --theme-block: #efe9dc;
  --theme-block-dark: #e2d8c4;
  background: var(--theme-bg);
}

/* BLUR: Indigo */
.pt-theme--blur {
  --theme-bg: #f6f6fa;
  --theme-accent: #7b7fc7;
  --theme-accent-light: #e0e1f3;
  --theme-block: #e6e6f2;
  --theme-block-dark: #d0d1e3;
  background: var(--theme-bg);
}

/* CUBE: Coral */
.pt-theme--cube {
  --theme-bg: #faf7f6;
  --theme-accent: #d47a6f;
  --theme-accent-light: #f5dcd9;
  --theme-block: #f2e8e6;
  --theme-block-dark: #e6d5d1;
  background: var(--theme-bg);
}

/* ============================================
   LAYOUT STYLES
   ============================================ */

/* ------------------------------------------
   Blog Layout (Fade)
   ------------------------------------------ */
.pt-layout--blog {
  padding: 20px;
}

.pt-hero-banner {
  height: 140px;
  border-radius: 12px;
  background: linear-gradient(135deg, var(--theme-accent-light) 0%, var(--theme-accent) 100%);
  margin-bottom: 20px;
}

.pt-content-area {
  max-width: 600px;
  margin: 0 auto;
}

.pt-article-title {
  height: 20px;
  width: 70%;
  background: var(--theme-block-dark);
  border-radius: 4px;
  margin-bottom: 12px;
}

.pt-article-meta {
  display: flex;
  gap: 12px;
  margin-bottom: 16px;
}

.pt-article-meta span {
  height: 10px;
  width: 60px;
  background: var(--theme-block);
  border-radius: 4px;
}

.pt-article-text {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.pt-article-text span {
  height: 10px;
  width: 100%;
  background: var(--theme-block);
  border-radius: 4px;
}

.pt-article-text span.short {
  width: 65%;
}

/* Blog List */
.pt-layout--blog-list {
  padding: 20px;
}

.pt-section-header {
  height: 24px;
  width: 180px;
  background: var(--theme-block-dark);
  border-radius: 6px;
  margin-bottom: 20px;
}

.pt-blog-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}

.pt-blog-card {
  background: #fff;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 2px 8px rgba(0,0,0,0.04);
}

.pt-card-img {
  height: 100px;
  background: linear-gradient(135deg, var(--theme-accent-light) 0%, var(--theme-block) 100%);
}

.pt-card-text {
  padding: 12px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.pt-card-text span {
  height: 8px;
  background: var(--theme-block);
  border-radius: 4px;
}

.pt-card-text span.short {
  width: 60%;
}

/* ------------------------------------------
   Dashboard Layout (Slide-H)
   ------------------------------------------ */
.pt-layout--dashboard {
  display: flex;
  height: 100%;
}

.pt-sidebar {
  width: 60px;
  background: var(--theme-accent);
  padding: 16px 12px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.pt-sidebar-item {
  height: 36px;
  background: rgba(255,255,255,0.15);
  border-radius: 8px;
}

.pt-sidebar-item.active {
  background: rgba(255,255,255,0.3);
}

.pt-main-content {
  flex: 1;
  padding: 20px;
}

.pt-stats-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  margin-bottom: 20px;
}

.pt-stat-card {
  background: #fff;
  border-radius: 10px;
  padding: 16px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.04);
}

.pt-stat-value {
  height: 24px;
  width: 60%;
  background: var(--theme-block-dark);
  border-radius: 4px;
  margin-bottom: 8px;
}

.pt-stat-label {
  height: 10px;
  width: 80%;
  background: var(--theme-block);
  border-radius: 4px;
}

.pt-chart-area {
  height: 180px;
  background: #fff;
  border-radius: 10px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.04);
}

/* Table */
.pt-table-header,
.pt-table-row {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 12px;
  padding: 12px 16px;
  background: #fff;
  border-radius: 8px;
  margin-bottom: 8px;
}

.pt-table-header {
  background: var(--theme-accent-light);
}

.pt-table-header span,
.pt-table-row span {
  height: 10px;
  background: var(--theme-block);
  border-radius: 4px;
}

.pt-table-header span {
  background: var(--theme-block-dark);
}

/* ------------------------------------------
   Magazine Layout (Slide-V)
   ------------------------------------------ */
.pt-layout--magazine {
  height: 100%;
}

.pt-mag-hero {
  height: 200px;
  background: linear-gradient(135deg, var(--theme-accent) 0%, var(--theme-accent-light) 100%);
  padding: 24px;
  display: flex;
  align-items: flex-end;
}

.pt-mag-hero-text {
  max-width: 400px;
}

.pt-mag-category {
  height: 10px;
  width: 60px;
  background: rgba(255,255,255,0.4);
  border-radius: 4px;
  margin-bottom: 10px;
}

.pt-mag-title {
  height: 20px;
  width: 280px;
  background: rgba(255,255,255,0.9);
  border-radius: 4px;
  margin-bottom: 10px;
}

.pt-mag-excerpt {
  height: 10px;
  width: 200px;
  background: rgba(255,255,255,0.5);
  border-radius: 4px;
}

.pt-mag-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
  padding: 20px;
}

.pt-mag-item {
  background: #fff;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 2px 8px rgba(0,0,0,0.04);
}

.pt-mag-thumb {
  height: 80px;
  background: var(--theme-accent-light);
}

.pt-mag-label {
  height: 10px;
  width: 70%;
  background: var(--theme-block);
  border-radius: 4px;
  margin: 12px;
}

/* Article */
.pt-layout--article {
  padding: 20px;
}

.pt-article-header {
  height: 100px;
  background: linear-gradient(135deg, var(--theme-accent) 0%, var(--theme-accent-light) 100%);
  border-radius: 12px;
  margin-bottom: 20px;
}

.pt-article-content {
  max-width: 500px;
  margin: 0 auto;
}

.pt-para {
  height: 10px;
  width: 100%;
  background: var(--theme-block);
  border-radius: 4px;
  margin-bottom: 10px;
}

.pt-para.short {
  width: 70%;
}

.pt-blockquote {
  height: 50px;
  background: var(--theme-accent-light);
  border-left: 4px solid var(--theme-accent);
  border-radius: 0 8px 8px 0;
  margin: 16px 0;
}

/* ------------------------------------------
   Portfolio Layout (Scale)
   ------------------------------------------ */
.pt-layout--portfolio {
  padding: 20px;
}

.pt-portfolio-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  grid-template-rows: repeat(2, 120px);
  gap: 12px;
}

.pt-portfolio-item {
  background: var(--theme-accent-light);
  border-radius: 10px;
}

.pt-portfolio-item.large {
  grid-column: span 2;
  grid-row: span 2;
  background: linear-gradient(135deg, var(--theme-accent) 0%, var(--theme-accent-light) 100%);
}

.pt-portfolio-item.wide {
  grid-column: span 2;
}

/* Project Detail */
.pt-layout--project {
  padding: 20px;
}

.pt-project-hero {
  height: 180px;
  background: linear-gradient(135deg, var(--theme-accent) 0%, var(--theme-accent-light) 100%);
  border-radius: 12px;
  margin-bottom: 20px;
}

.pt-project-info {
  max-width: 500px;
}

.pt-project-title {
  height: 20px;
  width: 60%;
  background: var(--theme-block-dark);
  border-radius: 4px;
  margin-bottom: 12px;
}

.pt-project-meta {
  display: flex;
  gap: 12px;
  margin-bottom: 16px;
}

.pt-project-meta span {
  height: 10px;
  width: 80px;
  background: var(--theme-block);
  border-radius: 4px;
}

.pt-project-desc {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.pt-project-desc span {
  height: 10px;
  background: var(--theme-block);
  border-radius: 4px;
}

.pt-project-desc span.short {
  width: 50%;
}

/* ------------------------------------------
   Shop Layout (Flip)
   ------------------------------------------ */
.pt-layout--shop {
  padding: 20px;
}

.pt-shop-filters {
  display: flex;
  gap: 12px;
  margin-bottom: 20px;
}

.pt-shop-filters span {
  height: 32px;
  width: 80px;
  background: var(--theme-block);
  border-radius: 6px;
}

.pt-product-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
}

.pt-product {
  background: #fff;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 2px 8px rgba(0,0,0,0.04);
}

.pt-product-img {
  height: 90px;
  background: var(--theme-accent-light);
}

.pt-product-name {
  height: 10px;
  width: 80%;
  background: var(--theme-block);
  border-radius: 4px;
  margin: 10px 10px 6px;
}

.pt-product-price {
  height: 12px;
  width: 40px;
  background: var(--theme-accent);
  border-radius: 4px;
  margin: 0 10px 10px;
}

/* Product Detail */
.pt-layout--product-detail {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
  padding: 20px;
}

.pt-product-gallery {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.pt-gallery-main {
  height: 200px;
  background: var(--theme-accent-light);
  border-radius: 12px;
}

.pt-gallery-thumbs {
  display: flex;
  gap: 8px;
}

.pt-gallery-thumbs span {
  flex: 1;
  height: 50px;
  background: var(--theme-block);
  border-radius: 8px;
}

.pt-product-info {
  padding-top: 20px;
}

.pt-product-title {
  height: 20px;
  width: 70%;
  background: var(--theme-block-dark);
  border-radius: 4px;
  margin-bottom: 12px;
}

.pt-product-price-lg {
  height: 24px;
  width: 80px;
  background: var(--theme-accent);
  border-radius: 6px;
  margin-bottom: 20px;
}

.pt-product-options {
  display: flex;
  gap: 8px;
  margin-bottom: 20px;
}

.pt-product-options span {
  width: 36px;
  height: 36px;
  background: var(--theme-block);
  border-radius: 8px;
}

.pt-product-btn {
  height: 44px;
  width: 160px;
  background: var(--theme-accent);
  border-radius: 8px;
}

/* ------------------------------------------
   Landing Layout (Wipe)
   ------------------------------------------ */
.pt-layout--landing {
  padding: 24px;
  height: 100%;
}

.pt-landing-hero {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 32px;
  align-items: center;
  height: 100%;
}

.pt-landing-text {
  padding-left: 20px;
}

.pt-landing-headline {
  height: 28px;
  width: 90%;
  background: var(--theme-block-dark);
  border-radius: 6px;
  margin-bottom: 12px;
}

.pt-landing-sub {
  height: 12px;
  width: 70%;
  background: var(--theme-block);
  border-radius: 4px;
  margin-bottom: 24px;
}

.pt-landing-buttons {
  display: flex;
  gap: 12px;
}

.pt-landing-buttons span:first-child {
  width: 120px;
  height: 40px;
  background: var(--theme-accent);
  border-radius: 8px;
}

.pt-landing-buttons span:last-child {
  width: 100px;
  height: 40px;
  background: var(--theme-block);
  border-radius: 8px;
}

.pt-landing-visual {
  height: 280px;
  background: linear-gradient(135deg, var(--theme-accent-light) 0%, var(--theme-accent) 100%);
  border-radius: 16px;
}

/* Features */
.pt-layout--features {
  padding: 24px;
}

.pt-features-header {
  height: 24px;
  width: 200px;
  background: var(--theme-block-dark);
  border-radius: 6px;
  margin: 0 auto 24px;
}

.pt-features-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

.pt-feature {
  background: #fff;
  border-radius: 12px;
  padding: 20px;
  text-align: center;
  box-shadow: 0 2px 8px rgba(0,0,0,0.04);
}

.pt-feature-icon {
  width: 48px;
  height: 48px;
  background: var(--theme-accent-light);
  border-radius: 12px;
  margin: 0 auto 12px;
}

.pt-feature-title {
  height: 12px;
  width: 60%;
  background: var(--theme-block-dark);
  border-radius: 4px;
  margin: 0 auto 8px;
}

.pt-feature-desc {
  height: 8px;
  width: 80%;
  background: var(--theme-block);
  border-radius: 4px;
  margin: 0 auto;
}

/* ------------------------------------------
   Cards Layout (Morph)
   ------------------------------------------ */
.pt-layout--cards {
  padding: 20px;
}

.pt-section-title {
  height: 20px;
  width: 160px;
  background: var(--theme-block-dark);
  border-radius: 4px;
  margin-bottom: 16px;
}

.pt-morph-card-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
  margin-bottom: 20px;
}

.pt-morph-card {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 16px;
  background: #fff;
  border-radius: 12px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.04);
}

.pt-morph-card.inactive {
  opacity: 0.5;
}

.pt-morph-thumb {
  width: 64px;
  height: 64px;
  background: var(--theme-accent);
  border-radius: 10px;
  flex-shrink: 0;
}

.pt-morph-meta {
  flex: 1;
}

.pt-morph-title {
  height: 12px;
  width: 80%;
  background: var(--theme-block-dark);
  border-radius: 4px;
  margin-bottom: 8px;
}

.pt-morph-sub {
  height: 8px;
  width: 50%;
  background: var(--theme-block);
  border-radius: 4px;
}

.pt-text-block {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.pt-text-block span {
  height: 10px;
  background: var(--theme-block);
  border-radius: 4px;
}

.pt-text-block span.short {
  width: 60%;
}

/* Detail */
.pt-layout--detail {
  padding: 20px;
}

.pt-morph-hero {
  height: 200px;
  background: linear-gradient(135deg, var(--theme-accent) 0%, var(--theme-accent-light) 100%);
  border-radius: 12px;
  margin-bottom: 20px;
}

.pt-detail-content {
  max-width: 500px;
}

.pt-morph-detail-title {
  height: 20px;
  width: 60%;
  background: var(--theme-block-dark);
  border-radius: 4px;
  margin-bottom: 12px;
}

.pt-detail-meta {
  display: flex;
  gap: 12px;
  margin-bottom: 16px;
}

.pt-detail-meta span {
  height: 24px;
  width: 70px;
  background: var(--theme-accent-light);
  border-radius: 6px;
}

.pt-detail-text {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.pt-detail-text span {
  height: 10px;
  background: var(--theme-block);
  border-radius: 4px;
}

.pt-detail-text span.short {
  width: 45%;
}

/* ------------------------------------------
   Gallery Layout (Blur)
   ------------------------------------------ */
.pt-layout--gallery {
  padding: 20px;
}

.pt-gallery-header {
  height: 24px;
  width: 140px;
  background: var(--theme-block-dark);
  border-radius: 6px;
  margin-bottom: 20px;
}

.pt-gallery-masonry {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  grid-auto-rows: 80px;
  gap: 12px;
}

.pt-gallery-item {
  background: var(--theme-accent-light);
  border-radius: 10px;
}

.pt-gallery-item.tall {
  grid-row: span 2;
  background: linear-gradient(135deg, var(--theme-accent) 0%, var(--theme-accent-light) 100%);
}

.pt-gallery-item.wide {
  grid-column: span 2;
}

/* Lightbox */
.pt-layout--lightbox {
  display: grid;
  grid-template-columns: 1.5fr 1fr;
  gap: 24px;
  padding: 24px;
  height: 100%;
  align-items: center;
}

.pt-lightbox-image {
  height: 300px;
  background: linear-gradient(135deg, var(--theme-accent) 0%, var(--theme-accent-light) 100%);
  border-radius: 12px;
}

.pt-lightbox-info {
  padding: 20px;
}

.pt-lightbox-title {
  height: 20px;
  width: 70%;
  background: var(--theme-block-dark);
  border-radius: 4px;
  margin-bottom: 12px;
}

.pt-lightbox-desc {
  height: 10px;
  width: 90%;
  background: var(--theme-block);
  border-radius: 4px;
  margin-bottom: 20px;
}

.pt-lightbox-actions {
  display: flex;
  gap: 12px;
}

.pt-lightbox-actions span {
  width: 36px;
  height: 36px;
  background: var(--theme-block);
  border-radius: 50%;
}

/* ------------------------------------------
   App Layout (Cube)
   ------------------------------------------ */
.pt-app-header {
  display: flex;
  align-items: center;
  padding: 14px 20px;
  background: var(--theme-accent);
}

.pt-app-back {
  width: 24px;
  height: 24px;
  background: rgba(255,255,255,0.2);
  border-radius: 6px;
  margin-right: 12px;
}

.pt-app-title {
  height: 14px;
  width: 100px;
  background: rgba(255,255,255,0.4);
  border-radius: 4px;
}

.pt-app-actions {
  margin-left: auto;
  display: flex;
  gap: 8px;
}

.pt-app-actions span {
  width: 24px;
  height: 24px;
  background: rgba(255,255,255,0.2);
  border-radius: 6px;
}

.pt-layout--app {
  padding: 12px;
  position: relative;
}

.pt-app-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.pt-app-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px;
  background: #fff;
  border-radius: 10px;
  box-shadow: 0 2px 6px rgba(0,0,0,0.04);
}

.pt-app-avatar {
  width: 44px;
  height: 44px;
  background: var(--theme-accent-light);
  border-radius: 50%;
  flex-shrink: 0;
}

.pt-app-text {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.pt-app-text span {
  height: 10px;
  width: 80%;
  background: var(--theme-block-dark);
  border-radius: 4px;
}

.pt-app-text span.sub {
  height: 8px;
  width: 60%;
  background: var(--theme-block);
}

.pt-app-time {
  width: 30px;
  height: 8px;
  background: var(--theme-block);
  border-radius: 4px;
}

.pt-app-fab {
  position: absolute;
  bottom: 20px;
  right: 20px;
  width: 52px;
  height: 52px;
  background: var(--theme-accent);
  border-radius: 50%;
  box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

/* Chat */
.pt-layout--chat {
  display: flex;
  flex-direction: column;
  height: 100%;
}

.pt-chat-messages {
  flex: 1;
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.pt-chat-bubble {
  max-width: 70%;
  padding: 12px 16px;
  border-radius: 16px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.pt-chat-bubble span {
  height: 10px;
  background: rgba(0,0,0,0.1);
  border-radius: 4px;
}

.pt-chat-bubble.received {
  background: #fff;
  align-self: flex-start;
  border-bottom-left-radius: 4px;
}

.pt-chat-bubble.received span {
  width: 140px;
}

.pt-chat-bubble.sent {
  background: var(--theme-accent);
  align-self: flex-end;
  border-bottom-right-radius: 4px;
}

.pt-chat-bubble.sent span {
  width: 120px;
  background: rgba(255,255,255,0.3);
}

.pt-chat-bubble.short span {
  width: 80px;
}

.pt-chat-input {
  display: flex;
  gap: 12px;
  padding: 12px 16px;
  background: #fff;
  border-top: 1px solid var(--theme-block);
}

.pt-chat-field {
  flex: 1;
  height: 40px;
  background: var(--theme-block);
  border-radius: 20px;
}

.pt-chat-send {
  width: 40px;
  height: 40px;
  background: var(--theme-accent);
  border-radius: 50%;
}

/* ------------------------------------------
   Browser Footer
   ------------------------------------------ */
.pt-browser-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: var(--pt-space-md) var(--pt-space-lg);
  background: var(--pt-chrome-bg);
  border-top: 1px solid var(--pt-chrome-border);
}

.pt-transition-info {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.pt-current-label {
  font-size: 14px;
  font-weight: 600;
  color: var(--pt-text-primary);
}

.pt-transition-hint {
  font-size: 12px;
  color: var(--pt-text-muted);
}

.pt-play-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  background: var(--pt-charcoal);
  border: 1px solid var(--pt-border);
  border-radius: 50%;
  color: #DCE8E7;
  cursor: pointer;
  transition: all 0.25s var(--pt-ease-out);
}

.pt-play-btn:hover {
  background: #DCE8E7;
  border-color: #DCE8E7;
  color: var(--pt-charcoal-dark);
  transform: scale(1.05);
}

.pt-play-icon,
.pt-replay-icon {
  width: 18px;
  height: 18px;
}

.pt-replay-icon {
  display: none;
}

.pt-browser--playing .pt-play-icon {
  display: none;
}

.pt-browser--playing .pt-replay-icon {
  display: block;
  animation: pt-spin 0.8s linear infinite;
}

@keyframes pt-spin {
  to { transform: rotate(360deg); }
}

/* ============================================
   SPECIAL CONTAINERS
   ============================================ */

.pt-flip-container,
.pt-cube-container,
.pt-morph-pages {
  position: absolute;
  inset: 0;
  display: none;
}

.pt-container--active {
  display: block;
}

/* Flip */
.pt-flip-container {
  transform-style: preserve-3d;
  transition: transform var(--pt-duration) var(--pt-ease-out);
}

.pt-flip-container .pt-page {
  position: absolute;
  inset: 0;
  backface-visibility: hidden;
  opacity: 1;
}

.pt-page--flip-a {
  z-index: 2;
}

.pt-page--flip-back {
  transform: rotateY(180deg);
}

.pt-flip--flipped {
  transform: rotateY(180deg);
}

/* Cube */
.pt-cube-container {
  transform-style: preserve-3d;
  transition: transform var(--pt-duration) var(--pt-ease-out);
}

.pt-cube-container .pt-page {
  position: absolute;
  inset: 0;
  opacity: 1;
  backface-visibility: hidden;
}

.pt-page--cube-front {
  transform: translateZ(260px);
}

.pt-page--cube-right {
  transform: rotateY(90deg) translateZ(260px);
}

.pt-cube--rotated {
  transform: translateZ(-260px) rotateY(-90deg);
}

/* Morph */
.pt-morph-pages .pt-page {
  position: absolute;
  inset: 0;
  opacity: 1;
  transition: opacity var(--pt-duration) var(--pt-ease-out);
}

.pt-page--morph-a {
  z-index: 2;
}

.pt-page--morph-b {
  z-index: 1;
  opacity: 0;
}

.pt-morph--showing-b .pt-page--morph-a {
  opacity: 0;
}

.pt-morph--showing-b .pt-page--morph-b {
  opacity: 1;
}

/* Wipe */
.pt-wipe-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, #4ca8a8, #6ec4c4);
  transform: translateX(-100%);
  z-index: 10;
  pointer-events: none;
}

.pt-wipe--active {
  animation: pt-wipe var(--pt-duration) var(--pt-ease-out) forwards;
}

@keyframes pt-wipe {
  0% { transform: translateX(-100%); }
  45%, 55% { transform: translateX(0); }
  100% { transform: translateX(100%); }
}

/* ============================================
   TRANSITION ANIMATIONS
   ============================================ */

/* Fade */
.pt-transition--fade .pt-page--standard {
  transition: opacity var(--pt-duration) var(--pt-ease-smooth);
}

/* Slide-H */
.pt-transition--slide-h .pt-page--standard {
  transition: transform var(--pt-duration) var(--pt-ease-out),
              opacity var(--pt-duration) var(--pt-ease-out);
}

.pt-transition--slide-h .pt-page--slide-h-a:not(.pt-page--active) {
  transform: translateX(-100%);
}

.pt-transition--slide-h .pt-page--slide-h-b:not(.pt-page--active) {
  transform: translateX(100%);
}

.pt-transition--slide-h .pt-page--active {
  transform: translateX(0);
}

/* Slide-V */
.pt-transition--slide-v .pt-page--standard {
  transition: transform var(--pt-duration) var(--pt-ease-out),
              opacity var(--pt-duration) var(--pt-ease-out);
}

.pt-transition--slide-v .pt-page--slide-v-a:not(.pt-page--active) {
  transform: translateY(-100%);
}

.pt-transition--slide-v .pt-page--slide-v-b:not(.pt-page--active) {
  transform: translateY(100%);
}

.pt-transition--slide-v .pt-page--active {
  transform: translateY(0);
}

/* Scale */
.pt-transition--scale .pt-page--standard {
  transition: transform var(--pt-duration) var(--pt-ease-out),
              opacity var(--pt-duration) var(--pt-ease-out);
}

.pt-transition--scale .pt-page--scale-a:not(.pt-page--active) {
  transform: scale(0.85);
  opacity: 0;
}

.pt-transition--scale .pt-page--scale-b:not(.pt-page--active) {
  transform: scale(1.15);
  opacity: 0;
}

.pt-transition--scale .pt-page--active {
  transform: scale(1);
}

/* Wipe */
.pt-transition--wipe .pt-page--standard {
  transition: opacity 0.01s linear 0.3s;
}

/* Blur */
.pt-transition--blur .pt-page--standard {
  transition: opacity var(--pt-duration) var(--pt-ease-smooth),
              filter var(--pt-duration) var(--pt-ease-smooth);
}

.pt-transition--blur .pt-page--blur-a:not(.pt-page--active),
.pt-transition--blur .pt-page--blur-b:not(.pt-page--active) {
  filter: blur(12px);
  opacity: 0;
}

.pt-transition--blur .pt-page--active {
  filter: blur(0);
}

/* ------------------------------------------
   Footer
   ------------------------------------------ */
.pt-footer {
  text-align: center;
  padding: var(--pt-space-xl) var(--pt-space-lg) var(--pt-space-2xl);
}

.pt-footer p {
  font-size: 14px;
  color: var(--pt-text-muted);
  margin: 0;
}

.pt-footer a {
  color: #DCE8E7;
  text-decoration: none;
  transition: color 0.2s ease;
}

.pt-footer a:hover {
  color: #b8d4d2;
}

/* ------------------------------------------
   Responsive
   ------------------------------------------ */
@media (max-width: 900px) {
  .pt-viewport {
    height: 450px;
  }

  .pt-blog-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .pt-blog-grid .pt-blog-card:last-child {
    display: none;
  }

  .pt-product-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .pt-product-grid .pt-product:nth-child(n+3) {
    display: none;
  }

  .pt-layout--product-detail {
    grid-template-columns: 1fr;
  }

  .pt-gallery-main {
    height: 160px;
  }

  .pt-portfolio-grid {
    grid-template-columns: repeat(3, 1fr);
  }

  .pt-portfolio-item.large {
    grid-column: span 2;
  }

  .pt-features-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .pt-features-grid .pt-feature:last-child {
    display: none;
  }

  .pt-landing-hero {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .pt-landing-visual {
    height: 180px;
  }

  .pt-layout--lightbox {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  .pt-lightbox-image {
    height: 200px;
  }
}

@media (max-width: 600px) {
  .demo-page--page-transitions {
    padding: var(--pt-space-md);
  }

  .pt-back-link {
    top: var(--pt-space-md);
    left: var(--pt-space-md);
    padding: var(--pt-space-xs) var(--pt-space-sm);
    font-size: 13px;
  }

  .pt-back-link span {
    display: none;
  }

  .pt-header {
    padding: var(--pt-space-xl) var(--pt-space-md) var(--pt-space-md);
  }

  .pt-browser-wrapper {
    padding: 0;
  }

  .pt-viewport {
    height: 400px;
  }

  .pt-tab {
    padding: var(--pt-space-xs) var(--pt-space-sm);
    font-size: 11px;
  }

  .pt-nav {
    padding: 10px 14px;
  }

  .pt-nav-links {
    display: none;
  }

  .pt-hero-banner {
    height: 100px;
  }

  .pt-blog-grid {
    grid-template-columns: 1fr;
  }

  .pt-stats-row {
    grid-template-columns: 1fr;
  }

  .pt-stat-card:nth-child(n+2) {
    display: none;
  }

  .pt-chart-area {
    height: 120px;
  }

  .pt-mag-hero {
    height: 140px;
  }

  .pt-mag-grid {
    grid-template-columns: 1fr;
  }

  .pt-portfolio-grid {
    grid-template-columns: repeat(2, 1fr);
    grid-auto-rows: 80px;
  }

  .pt-project-hero {
    height: 120px;
  }

  .pt-morph-card-grid {
    grid-template-columns: 1fr;
  }

  .pt-morph-card.inactive {
    display: none;
  }

  .pt-gallery-masonry {
    grid-template-columns: repeat(2, 1fr);
    grid-auto-rows: 60px;
  }

  .pt-browser-footer {
    padding: var(--pt-space-sm) var(--pt-space-md);
  }

  .pt-play-btn {
    width: 40px;
    height: 40px;
  }
}
