/* ==========================================================================
   TURRUS KULE VİNÇ - MAIN STYLESHEET
   Brand Design Language & UI System
   ========================================================================== */

:root {
  --t-purple-primary: #5641A2;
  --t-purple-hover: #3E2E7A;
  --t-purple-deep: #2E2260;
  --t-purple-dark: #231A4A;
  --t-purple-accent: #8C78E0;
  --t-purple-light: #B9AEE6;
  --t-purple-soft: #EDEAF8;
  --t-yellow-gold: #F2B705;
  --t-yellow-light: #FFE68A;
  --t-yellow-dark: #8A6400;
  --t-dark-primary: #100E0D;
  --t-dark-bg: #15111F;
  --t-dark-card: #1F1B2B;
  --t-bg-light: #F5F5FA;
  --t-text-muted: #55535E;
  --t-border-subtle: #D9D7E3;
  --t-font-main: 'Jost', Arial, sans-serif;
  --t-font-display: 'Saira Condensed', 'Jost', Arial, sans-serif;
}

*, *::before, *::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: #FFFFFF;
  color: var(--t-dark-primary);
  font-family: var(--t-font-main);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

#turrus-root {
  font-family: var(--t-font-main);
  color: var(--t-dark-primary);
  background: #FFFFFF;
  overflow-x: hidden;
  position: relative;
  min-height: 100vh;
}

/* Typography Helpers */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--t-font-main);
  color: inherit;
  font-weight: 600;
  letter-spacing: -0.02em;
}

.t-font-display {
  font-family: var(--t-font-display);
  letter-spacing: 0.04em;
}

a {
  color: var(--t-purple-primary);
  text-decoration: none;
  transition: color 0.2s ease;
}

a:hover {
  color: var(--t-purple-hover);
}

/* Navigation Links */
.t-nav a {
  color: #FFFFFF;
  text-decoration: none;
  opacity: 0.82;
  font-size: 15px;
  font-weight: 400;
  transition: opacity 0.2s ease, color 0.2s ease;
}

.t-nav a:hover,
.t-nav a.current-menu-item,
.t-nav a:focus {
  opacity: 1;
  color: #FFFFFF;
}

/* Button Variants */
.t-btn-w {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  min-height: 54px;
  padding: 0 32px;
  background: #FFFFFF;
  color: var(--t-purple-primary);
  font-size: 15px;
  font-weight: 500;
  text-decoration: none;
  border-radius: 0;
  border: none;
  cursor: pointer;
  transition: background 0.25s ease, transform 0.25s ease, color 0.25s ease, box-shadow 0.25s ease;
}

.t-btn-w:hover {
  background: var(--t-purple-soft);
  color: var(--t-purple-hover);
  transform: translateY(-2px);
  box-shadow: 0 10px 24px rgba(46, 34, 96, 0.18);
}

.t-btn-o {
  display: inline-flex;
  align-items: center;
  min-height: 46px;
  padding: 0 24px;
  border: 1.5px solid #FFFFFF;
  color: #FFFFFF;
  font-size: 14px;
  font-weight: 500;
  letter-spacing: 0.04em;
  text-decoration: none;
  background: transparent;
  cursor: pointer;
  transition: background 0.25s ease, color 0.25s ease, border-color 0.25s ease;
}

.t-btn-o:hover {
  background: rgba(255, 255, 255, 0.14);
  color: #FFFFFF;
}

.t-btn-p {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  min-height: 54px;
  padding: 0 32px;
  background: var(--t-purple-primary);
  color: #FFFFFF;
  font-size: 15px;
  font-weight: 500;
  text-decoration: none;
  border: none;
  cursor: pointer;
  transition: background 0.25s ease, transform 0.25s ease;
}

.t-btn-p:hover {
  background: var(--t-purple-hover);
  color: #FFFFFF;
  transform: translateY(-2px);
}

.t-ghost {
  color: rgba(255, 255, 255, 0.75);
  font-size: 15px;
  text-decoration: none;
  border-bottom: 1px solid rgba(255, 255, 255, 0.3);
  padding-bottom: 4px;
  transition: color 0.2s ease, border-color 0.2s ease;
}

.t-ghost:hover {
  color: #FFFFFF;
  border-bottom-color: #FFFFFF;
}

/* Card Styling & Hover Effects */
.t-card {
  transition: transform 0.6s cubic-bezier(0.2, 0.7, 0.2, 1), box-shadow 0.6s ease;
}

.t-card:hover {
  transform: scale(1.025);
  box-shadow: 0 40px 70px -40px rgba(40, 25, 110, 0.45);
}

.t-more {
  transition: color 0.25s ease, background 0.25s ease;
}

.t-card:hover .t-more {
  background: var(--t-purple-primary);
  color: #FFFFFF;
}

.t-more:hover {
  background: var(--t-purple-hover) !important;
  color: #FFFFFF !important;
}

/* Image zoom in cards */
.t-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scale(var(--z, 1));
  transition: transform 1.2s cubic-bezier(0.2, 0.7, 0.2, 1);
}

.t-card:hover .t-img {
  transform: scale(calc(var(--z, 1) * 1.07));
}

/* Crane Vertical Mast (Tower Body) */
.t-mast {
  position: absolute;
  left: 10px;
  top: 88px;
  bottom: 0;
  width: 76px;
  z-index: 6;
  pointer-events: none;
  opacity: 0.4;
}

@media (max-width: 1439px) {
  .t-mast {
    left: 2px;
    bottom: auto;
    height: calc((100% - 88px) / 0.58);
    transform: scale(0.58);
    transform-origin: 0 0;
  }
}

@media (max-width: 1279px) {
  .t-mast {
    display: none;
  }
}

/* Scroll Reveal Animations */
.js-reveal [data-reveal] {
  opacity: 0;
  transform: translateY(64px);
  transition: opacity 1s ease, transform 1.1s cubic-bezier(0.2, 0.7, 0.2, 1);
  will-change: opacity, transform;
}

.js-reveal [data-reveal="left"] {
  transform: translateX(-90px);
}

.js-reveal [data-reveal="right"] {
  transform: translateX(90px);
}

.js-reveal [data-reveal].is-in {
  opacity: 1 !important;
  transform: none !important;
}

/* ==========================================================================
   ELEMENTOR EDITOR MODE FIXES:
   Ensure everything is 100% visible and interactive inside Elementor editor preview
   ========================================================================== */
body.elementor-editor-active [data-reveal],
body.elementor-editor-active .js-reveal [data-reveal],
.elementor-editor-active [data-reveal],
.elementor-edit-mode [data-reveal],
.elementor-editor-preview [data-reveal],
.elementor-element-edit-mode [data-reveal] {
  opacity: 1 !important;
  transform: none !important;
  visibility: visible !important;
  transition: none !important;
}

/* Crane Hook & Animation */
.t-crane {
  transition: transform 1.2s cubic-bezier(0.2, 0.7, 0.2, 1);
}

.t-hook {
  transform-origin: 50% 0;
  animation: t-sway 4.5s ease-in-out infinite alternate;
}

@keyframes t-sway {
  from {
    transform: rotate(-2.5deg);
  }
  to {
    transform: rotate(2.5deg);
  }
}

/* Hero Section */
.t-hero-img {
  position: absolute;
  inset: 0;
  background-color: #15111F;
  background-position: 30% 25%;
  background-size: cover;
  background-repeat: no-repeat;
  transition: transform 6.5s ease-out;
}

.t-dot {
  transition: width 0.35s ease, background 0.35s ease;
}

/* Interactive Chat / Crane Advisor Panel */
.t-chat-panel {
  width: min(390px, calc(100vw - 32px));
  background: #FFFFFF;
  box-shadow: 0 30px 70px -20px rgba(30, 20, 70, 0.4), 0 0 0 1px rgba(16, 14, 13, 0.06);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  opacity: 0;
  transform: translateY(16px) scale(0.98);
  transform-origin: bottom right;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.3s ease, transform 0.35s cubic-bezier(0.2, 0.7, 0.2, 1), visibility 0s 0.35s;
}

.t-chat-panel.is-open {
  opacity: 1;
  transform: none;
  visibility: visible;
  pointer-events: auto;
  transition: opacity 0.3s ease, transform 0.35s cubic-bezier(0.2, 0.7, 0.2, 1);
}

.t-chat-toggle {
  transition: transform 0.25s ease, box-shadow 0.25s ease;
  border: none;
  background: transparent;
  cursor: pointer;
  padding: 0;
}

.t-chat-toggle:hover {
  transform: translateY(-3px);
  box-shadow: 0 26px 50px -18px rgba(30, 20, 70, 0.5);
}

.t-chat-q {
  transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

.t-chat-q:hover {
  background: var(--t-purple-primary) !important;
  color: #FFFFFF !important;
}

.t-chat-q:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.t-typing span {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--t-purple-accent);
  display: inline-block;
  animation: t-blink 1.2s infinite ease-in-out;
}

.t-typing span:nth-child(2) {
  animation-delay: 0.15s;
}

.t-typing span:nth-child(3) {
  animation-delay: 0.3s;
}

@keyframes t-blink {
  0%, 80%, 100% {
    opacity: 0.25;
    transform: translateY(0);
  }
  40% {
    opacity: 1;
    transform: translateY(-3px);
  }
}

.t-pulse {
  animation: t-pulse 2.6s ease-out infinite;
}

@keyframes t-pulse {
  0% {
    box-shadow: 0 0 0 0 rgba(86, 65, 162, 0.45);
  }
  70% {
    box-shadow: 0 0 0 14px rgba(86, 65, 162, 0);
  }
  100% {
    box-shadow: 0 0 0 0 rgba(86, 65, 162, 0);
  }
}

/* Mobile Nav Toggle */
.t-mobile-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 6px;
  width: 44px;
  height: 44px;
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 8px;
}

.t-mobile-toggle span {
  display: block;
  width: 100%;
  height: 2px;
  background: #FFFFFF;
  transition: transform 0.2s ease, opacity 0.2s ease;
}

@media (max-width: 1024px) {
  .t-mobile-toggle {
    display: flex;
  }

  .t-header-nav {
    display: none !important;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--t-purple-primary);
    flex-direction: column;
    padding: 24px 32px;
    gap: 16px !important;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.25);
    border-top: 1px solid rgba(255, 255, 255, 0.15);
  }

  .t-header-nav.is-active {
    display: flex !important;
  }
}

/* Reduced Motion */
@media (prefers-reduced-motion: reduce) {
  .t-hook {
    animation: none;
  }
  .js-reveal [data-reveal] {
    opacity: 1;
    transform: none;
    transition: none;
  }
  .t-hero-img {
    transition: none;
  }
}

/* WordPress Defaults & Gutenberg Elements */
.alignwide {
  max-width: 1280px;
  margin-left: auto;
  margin-right: auto;
}

.alignfull {
  max-width: 100%;
  width: 100vw;
  margin-left: calc(50% - 50vw);
  margin-right: calc(50% - 50vw);
}

.screen-reader-text {
  border: 0;
  clip: rect(1px, 1px, 1px, 1px);
  clip-path: inset(50%);
  height: 1px;
  margin: -1px;
  overflow: hidden;
  padding: 0;
  position: absolute !important;
  width: 1px;
  word-wrap: normal !important;
}

/* Page Hero Subpage Header */
.t-subpage-hero {
  position: relative;
  background: #15111F;
  color: #FFFFFF;
  padding: 160px 0 90px;
  overflow: hidden;
}

.t-subpage-hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 80% 40%, rgba(86, 65, 162, 0.3) 0%, transparent 60%);
  pointer-events: none;
}

/* Technical Specification Table */
.t-specs-table {
  width: 100%;
  border-collapse: collapse;
  background: #FFFFFF;
}

.t-specs-table th {
  background: var(--t-bg-light);
  color: var(--t-purple-primary);
  font-weight: 600;
  font-size: 13px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding: 16px 20px;
  text-align: left;
  border-bottom: 2px solid var(--t-border-subtle);
}

.t-specs-table td {
  padding: 16px 20px;
  font-size: 15px;
  border-bottom: 1px solid #ECEAF2;
  color: #2D2A38;
}

.t-specs-table tr:hover td {
  background: #FAF9FD;
}
