/*
Theme Name: TikiDownload
Theme URI: https://tikidownload.com/
Author: TikiDownload Team
Author URI: https://tikidownload.com/
Description: A professional, dark-themed WordPress video downloader for TikTok, Facebook, Instagram, and X.
Version: 1.0.1
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Tags: black, dark, responsive-layout, translation-ready
Text Domain: wptt
*/

:root {
  --primary-color: #00f2fe;
  /* TikTok Cyan */
  --secondary-color: #fe2c55;
  /* TikTok Red */
  --text-main: #ffffff;
  --text-muted: #aaaaaa;
  --bg-color: #010101;
  /* TikTok Dark */
  --card-bg: #121212;
  --border-radius: 12px;
  --box-shadow: 0 10px 25px rgba(0, 0, 0, 0.3);
  --error-color: #fe2c55;
  --success-color: #00f2fe;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  background-color: var(--bg-color);
  color: var(--text-main);
  line-height: 1.6;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.container {
  width: 100%;
  max-width: 1000px;
  margin: 0 auto;
  padding: 0 20px;
}

/* Header */
.site-header {
  background: var(--bg-color);
  padding: 15px 0;
  border-bottom: 1px solid #111;
  position: sticky;
  top: 0;
  z-index: 1000;
}

.header-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.header-menu {
  list-style: none;
  display: flex;
  gap: 25px;
  margin: 0;
  padding: 0;
}

.header-menu a {
  color: #fff;
  text-decoration: none;
  font-weight: 500;
  font-size: 0.95rem;
  transition: color 0.3s ease;
}

.header-menu a:hover {
  color: var(--primary-color);
}

.menu-toggle {
  display: none;
  background: none;
  border: none;
  color: #fff;
  font-size: 1.5rem;
  cursor: pointer;
  padding: 5px;
  z-index: 1001;
}

.site-branding {
  display: flex;
  align-items: center;
}

.site-title {
  font-size: 1.2rem;
  font-weight: 800;
  margin: 0;
  color: #fff;
  text-decoration: none;
  text-transform: none;
  /* Changed from uppercase to natural branding */
  letter-spacing: -0.5px;
}

.site-title a {
  display: flex;
  align-items: center;
  gap: 8px;
  color: #fff;
  text-decoration: none;
}

.header-logo-icon {
  height: 36px;
  width: 36px;
  object-fit: contain;
  border-radius: 50%;
}

.site-title a {
  text-decoration: none;
  color: inherit;
  display: flex;
  align-items: center;
  gap: 6px;
}

.header-logo-icon {
  height: 1.1em;
  width: auto;
  object-fit: contain;
}

/* Main Content */
.site-content {
  flex: 1;
  padding: 60px 0;
}

/* Hero Section */
.hero-section {
  text-align: center;
  margin-bottom: 50px;
  background-color: transparent;
  color: var(--text-main);
  padding: 60px 20px;
  border-radius: var(--border-radius);
  position: relative;
  overflow: hidden;
  box-shadow: none;
  /* Removed shadow for cleaner look */
}



.hero-title {
  font-size: 2rem;
  font-weight: 800;
  margin-bottom: 15px;
  color: var(--text-main);
}

.hero-subtitle {
  margin: 0 auto;
}

/* Downloader Area */
.downloader-box {
  background: #141414;
  border: 1px solid #222;
  border-radius: 24px;
  padding: 40px;
  max-width: 760px;
  margin: 0 auto 50px;
  box-shadow: 0 30px 60px rgba(0, 0, 0, 0.6);
}

/* Platform Tabs */
.platform-tabs {
  display: flex;
  background: #0a0a0a;
  border: 1px solid #222;
  border-radius: 16px;
  padding: 6px;
  margin-bottom: 25px;
  gap: 6px;
}

.platform-tab {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  height: 48px;
  border-radius: 12px;
  background: transparent;
  border: none;
  color: #888;
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  font-family: inherit;
  transition: all 0.3s ease;
}

.platform-tab:hover {
  color: #fff;
  background: rgba(255, 255, 255, 0.03);
}

.platform-tab.active {
  background: #222;
  color: #fff;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

.platform-tab .tab-icon {
  font-size: 1.1rem;
}

.platform-tab.active.tab-tiktok .tab-icon {
  color: #fe2c55;
}

.platform-tab.active.tab-facebook .tab-icon {
  color: #1877f2;
}

.platform-tab.active.tab-instagram .tab-icon {
  color: #e4405f;
}

.platform-tab.active.tab-x .tab-icon {
  color: #fff;
}

/* Input Field */
.url-input-wrap {
  position: relative;
  margin-bottom: 25px;
}

.url-input-wrap i {
  position: absolute;
  left: 20px;
  top: 50%;
  transform: translateY(-50%);
  color: #666;
  font-size: 1.2rem;
}

.url-input {
  width: 100%;
  height: 64px;
  padding: 0 20px 0 54px;
  background: #0a0a0a;
  border: 1px solid #333;
  border-radius: 16px;
  color: #fff;
  font-size: 1.1rem;
  font-family: inherit;
  outline: none;
  transition: border-color 0.3s;
}

.url-input::placeholder {
  color: #555;
}

.url-input:focus {
  border-color: var(--primary-color);
  box-shadow: 0 0 0 3px rgba(0, 242, 254, 0.1);
}

.download-btn-large {
  width: 100%;
  height: 64px;
  background: var(--primary-color);
  color: #000;
  border: none;
  border-radius: 16px;
  font-size: 1.15rem;
  font-weight: 800;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  transition: all 0.3s ease;
}

.download-btn-large:hover {
  opacity: 0.9;
}

.download-btn-large:active {
  transform: translateY(1px);
}

/* Results Area */
.result-area {
  display: none;
  margin-top: 30px;
  border-top: 1px solid #333;
  padding-top: 30px;
}

.result-card {
  display: flex;
  flex-direction: column;
  gap: 30px;
}

@media (min-width: 768px) {
  .result-card {
    flex-direction: row;
  }
}

.video-thumb-container {
  position: relative;
  width: 100%;
  max-width: 300px;
  margin: 0 auto;
  border-radius: var(--border-radius);
  overflow: hidden;
  background: #000;
  cursor: pointer;
}

.video-thumb,
.video-player {
  width: 100%;
  height: auto;
  display: block;
}

.play-overlay {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 60px;
  height: 60px;
  background: rgba(255, 255, 255, 0.8);
  /* Glassy White */
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  color: #010101;
  /* Dark icon for contrast */
  transition: all 0.3s ease;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
  z-index: 10;
}

.video-thumb-container:hover .play-overlay {
  background: rgba(255, 255, 255, 1);
  transform: translate(-50%, -50%) scale(1.1);
}

.video-info {
  flex: 1;
  display: flex;
  flex-direction: column;
}

.video-title {
  font-size: 1.2rem;
  margin-bottom: 5px;
  font-weight: 600;
  word-break: break-all;
  color: var(--text-main);
}

.video-author {
  color: var(--text-muted);
  margin-bottom: 20px;
  font-size: 0.95rem;
  display: flex;
  align-items: center;
  gap: 8px;
}

.video-author img {
  width: 24px;
  height: 24px;
  border-radius: 50%;
}

.download-options {
  display: flex;
  flex-direction: column;
  gap: 15px;
  margin-top: auto;
}

.btn-download-option {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 15px 20px;
  background: #1a1a1a;
  border: 1px solid #333;
  color: var(--text-main);
  text-decoration: none;
  border-radius: 10px;
  font-weight: 600;
  transition: all 0.3s ease;
  text-align: center;
}

.btn-download-option:hover {
  background: #1a1a1a;
  border-color: #333;
  color: var(--text-main);
}

.btn-download-option.primary {
  background: #1a1a1a;
  color: #ccc;
  border-color: #333;
}

.btn-download-option.primary:hover {
  background: #222;
  color: #fff;
  border-color: #444;
  transform: none;
  box-shadow: none;
}

/* Alerts */
.alert {
  padding: 15px 20px;
  border-radius: 10px;
  margin-bottom: 20px;
  display: none;
  font-weight: 500;
}

.alert-error {
  background-color: rgba(254, 44, 85, 0.1);
  color: var(--error-color);
  border-left: 4px solid var(--error-color);
}

/* Custom Validation Message */
.validation-error {
  color: #fe2c55;
  font-size: 0.9rem;
  font-weight: 500;
  margin-top: 10px;
  display: flex;
  align-items: center;
  gap: 6px;
  animation: fadeIn 0.3s ease;
}

.validation-error::before {
  content: '\f06a';
  font-family: 'Font Awesome 6 Free';
  font-weight: 900;
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(-5px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* How to Download Section */
.how-to-section {
  padding: 60px 0;
  max-width: 900px;
  margin: 0 auto;
}

.how-to-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 30px;
  margin-top: 40px;
}

.how-to-step {
  position: relative;
  background: var(--card-bg);
  padding: 40px 30px;
  border-radius: var(--border-radius);
  text-align: center;
  border: 1px solid #222;
  transition: all 0.3s ease;
}

.how-to-step:hover {
  border-color: var(--primary-color);
  transform: translateY(-5px);
}

.step-number {
  position: absolute;
  top: -15px;
  left: 50%;
  transform: translateX(-50%);
  width: 40px;
  height: 40px;
  background: var(--secondary-color);
  color: #fff;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 1.2rem;
  box-shadow: 0 4px 10px rgba(254, 44, 85, 0.3);
}

.step-icon {
  font-size: 2.5rem;
  color: var(--primary-color);
  margin-bottom: 20px;
}

.step-title {
  font-size: 1.3rem;
  margin-bottom: 10px;
  font-weight: 700;
}

.step-desc {
  color: var(--text-muted);
  font-size: 0.95rem;
}

/* Features grid */
.features-section {
  padding: 60px 0;
  background: var(--bg-color);
}

.section-title {
  text-align: center;
  font-size: 2rem;
  margin-bottom: 50px;
  color: var(--text-main);
  font-weight: 300;
}

.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 30px;
}

.feature-card {
  text-align: center;
  padding: 30px;
  background: transparent;
  border-radius: var(--border-radius);
  box-shadow: none;
  transition: transform 0.3s ease;
  border: 1px solid #222;
}

.feature-card:hover {
  transform: translateY(-5px);
  border-color: #444;
}

.feature-icon {
  font-size: 2.5rem;
  color: var(--primary-color);
  margin-bottom: 20px;
}

.feature-title {
  font-size: 1.2rem;
  margin-bottom: 15px;
  font-weight: 600;
  color: var(--text-main);
}

.feature-desc {
  color: var(--text-muted);
  font-size: 0.95rem;
}

/* FAQ Section */
.faq-section {
  padding: 60px 0;
  max-width: 800px;
  margin: 0 auto;
}

.faq-accordion {
  display: flex;
  flex-direction: column;
  gap: 15px;
}

.faq-item {
  background: transparent;
  border: 1px solid #222;
  border-radius: var(--border-radius);
  overflow: hidden;
  transition: all 0.3s ease;
}

.faq-item:hover {
  border-color: #444;
}

.faq-question {
  width: 100%;
  text-align: left;
  padding: 20px 25px;
  background: transparent;
  border: none;
  color: var(--text-main);
  font-size: 1.1rem;
  font-weight: 600;
  display: flex;
  justify-content: space-between;
  align-items: center;
  cursor: pointer;
  transition: all 0.3s ease;
}

.faq-question i {
  color: var(--primary-color);
  transition: transform 0.3s ease;
}

.faq-item.active .faq-question i {
  transform: rotate(180deg);
}

.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease-out, padding 0.3s ease;
  background: #1a1a1a;
}

.faq-item.active .faq-answer {
  max-height: 500px;
  padding: 20px 25px;
  border-top: 1px solid #222;
}

.faq-answer p {
  color: var(--text-muted);
  font-size: 0.95rem;
  line-height: 1.8;
}

/* Footer */
.footer-navigation {
  margin-bottom: 20px;
}

.footer-menu {
  list-style: none;
  display: flex;
  justify-content: center;
  gap: 20px;
  flex-wrap: wrap;
}

.footer-menu a {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 0.9rem;
  transition: color 0.3s ease;
}

.footer-menu a:hover {
  color: var(--primary-color);
}

.site-footer {
  background: #000000;
  color: #fff;
  padding: 50px 0;
  text-align: center;
  margin-top: auto;
  border-top: 1px solid #111;
}

.footer-text {
  color: #666;
  font-size: 0.9rem;
}

/* Animations */
@keyframes spin {
  0% {
    transform: rotate(0deg);
  }

  100% {
    transform: rotate(360deg);
  }
}

/* Responsive */
@media (max-width: 768px) {
  .site-content {
    padding: 40px 0;
  }

  .hero-section {
    padding: 40px 20px;
    margin-bottom: 30px;
  }

  .downloader-box {
    padding: 20px 16px;
  }

  .platform-tabs {
    flex-wrap: wrap;
  }

  .platform-tab {
    flex: 1 1 40%;
    height: 44px;
    font-size: 0.9rem;
  }

  .downloader-box {
    padding: 25px 20px;
    border-radius: 16px;
  }

  .url-input {
    font-size: 1rem;
    height: 56px;
    padding-left: 50px;
  }

  .url-input-wrap i {
    left: 16px;
  }

  .download-btn-large {
    height: 56px;
    font-size: 1.05rem;
  }
}

@media (max-width: 600px) {
  .header-container {
    flex-direction: row;
    /* Keep logo and hamburger on one line */
    justify-content: space-between;
    text-align: left;
    flex-wrap: wrap;
  }

  .menu-toggle {
    display: block;
  }

  .main-navigation {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    width: 100%;
    height: auto;
    background: var(--bg-color);
    padding: 0;
    transition: all 0.3s ease;
    z-index: 1000;
    border-top: 1px solid #111;
    border-bottom: 1px solid #111;
    border-left: none;
    max-height: 0;
    overflow: hidden;
    opacity: 0;
    visibility: hidden;
  }

  .main-navigation.active {
    max-height: 400px;
    padding: 20px 0;
    opacity: 1;
    visibility: visible;
  }

  .header-menu {
    display: flex;
    flex-direction: row;
    justify-content: center;
    flex-wrap: wrap;
    gap: 15px;
    padding: 20px;
    list-style: none;
  }

  .header-menu li {
    width: auto;
  }

  .header-menu a {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    background: transparent;
    border: none;
    padding: 10px 15px;
    font-size: 1.05rem;
    font-weight: 500;
  }

  .download-form {
    flex-direction: column;
  }

  .download-input {
    padding: 15px;
    height: auto;
  }

  .download-btn {
    padding: 15px;
    width: 100%;
  }

  .hero-title {
    font-size: 1.5rem;
  }

  .site-title {
    font-size: 1.2rem;
  }

  .hero-subtitle {
    font-size: 1rem;
  }

  .section-title {
    font-size: 1.6rem;
    margin-bottom: 30px;
  }

  .features-grid {
    grid-template-columns: 1fr;
  }
}