:root {
  --primary-color: #2c3e50; /* Professional Dark Blue/Slate */
  --primary-dark: #1a2533;
  --secondary-color: #f4f6f8;
  --text-color: #333;
  --white-color: #fff;
  --border-color: #d1d8e0;
  --shadow-light: rgba(0, 0, 0, 0.07);
  --link-color: #3498db;
}

body {
  font-family: 'Poppins', sans-serif; margin: 0;
  background-color: var(--secondary-color); color: var(--text-color); line-height: 1.6;
}

.container { max-width: 1200px; margin: auto; padding: 20px; }

header {
  background-color: var(--white-color); box-shadow: 0 2px 8px var(--shadow-light);
  padding: 15px 20px; position: sticky; top: 0; z-index: 1000;
  display: flex; justify-content: space-between; align-items: center;
}

.logo { font-weight: 700; text-decoration: none; color: var(--primary-color); font-size: 22px; }
nav a { margin-left: 20px; text-decoration: none; color: var(--primary-color); font-weight: 500; }
.breadcrumb { margin: 15px 0; color: #555; font-size: 14px; }

.tool-box {
  background-color: var(--white-color); padding: 30px;
  border-radius: 12px; box-shadow: 0 4px 15px var(--shadow-light);
}
.main-header { display: flex; align-items: center; gap: 20px; text-align: left; margin-bottom: 20px; }
.tool-icon { width: 60px; height: 60px; flex-shrink: 0; }
.main-header h1 { margin: 0; }
.description { margin: 5px 0 0; color: #718096; }

/* Toolbar */
.toolbar {
  background-color: #f9fafb;
  border: 1px solid var(--border-color);
  border-bottom: none;
  border-radius: 8px 8px 0 0;
  padding: 8px;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.toolbar button {
  background-color: #fff; border: 1px solid #d1d8e0; border-radius: 5px;
  padding: 6px 10px; font-size: 14px; cursor: pointer;
  font-family: inherit; color: #4a5568;
  transition: background-color 0.2s, border-color 0.2s;
}
.toolbar button:hover { background-color: #f4f6f8; border-color: #aeb9c5; }

/* Live Editor */
.live-editor {
  display: grid; grid-template-columns: 1fr 1fr;
  border: 1px solid var(--border-color);
  border-radius: 0 0 8px 8px;
  overflow: hidden; height: 70vh; min-height: 500px;
}

.panel { display: flex; flex-direction: column; }
.panel-header {
  display: flex; justify-content: space-between; align-items: center;
  padding: 10px 15px; background-color: #f9fafb;
  border-bottom: 1px solid var(--border-color); flex-shrink: 0;
}
.panel-header h3 { margin: 0; font-size: 16px; color: #4a5568; }
.panel-btn {
  background-color: #fff; border: 1px solid var(--border-color);
  padding: 4px 10px; border-radius: 5px; cursor: pointer; font-size: 12px;
  font-weight: 500; transition: background-color 0.2s;
}
.panel-btn:hover { background-color: #f4f6f8; }

/* CodeMirror Editor */
.CodeMirror {
  flex-grow: 1;
  height: 100%;
  font-size: 15px;
}

/* HTML Preview */
#html-preview {
  flex-grow: 1; padding: 15px 20px; overflow-y: auto; text-align: left;
}
.prose { line-height: 1.7; }
.prose > *:first-child { margin-top: 0; }
.prose h1, .prose h2, .prose h3 { border-bottom: 1px solid #e2e8f0; padding-bottom: 0.3em; margin-top: 24px; margin-bottom: 16px; }
.prose h1 { font-size: 2em; } .prose h2 { font-size: 1.5em; }
.prose p { margin-bottom: 16px; }
.prose a { color: var(--link-color); text-decoration: none; }
.prose a:hover { text-decoration: underline; }
.prose code { background-color: #f4f6f8; padding: 0.2em 0.4em; margin: 0; font-size: 85%; border-radius: 3px; border: 1px solid #e2e8f0; }
.prose pre { padding: 16px; border-radius: 6px; overflow-x: auto; }
.prose pre code { background: none; padding: 0; border: none; }
.prose blockquote { padding: 0 1em; color: #718096; border-left: 0.25em solid var(--border-color); }
.prose ul, .prose ol { padding-left: 2em; }
.prose table { border-collapse: collapse; width: 100%; }
.prose th, .prose td { border: 1px solid var(--border-color); padding: 8px; }
.prose th { background-color: #f7fafc; }

/* General Sections */
section { margin-top: 40px; }
.grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 25px; }
.card {
    background: #fff; padding: 25px; border-radius: 10px; text-align: center;
    box-shadow: 0 2px 8px var(--shadow-light); transition: all 0.3s ease;
}
.card:hover { transform: translateY(-5px); box-shadow: 0 6px 15px var(--shadow-light); }
.card img { width: 50px; margin-bottom: 15px; }
.card button { background: var(--primary-color); color: #fff; border: none; padding: 10px 18px; border-radius: 6px; cursor: pointer; }

footer { text-align: center; padding: 20px; background-color: var(--white-color); margin-top: 40px; border-top: 1px solid var(--border-color); }

@media (max-width: 992px) {
  .live-editor { grid-template-columns: 1fr; height: auto; min-height: 600px; }
  .panel { min-height: 300px; }
}
/* style.css */

/* --- Global Styles & Variables --- */
:root {
  --primary: #0056ff;
  --secondary: linear-gradient(135deg, #00E0FF, #00FFFF); /* Bright Cyan Gradient */
  --text: #222;
}

body {
  font-family: Poppins, sans-serif;
  margin: 0;
  background: var(--secondary);
  color: var(--text);
}

.container {
  max-width: 1200px;
  margin: auto;
  padding: 20px;
}

/* --- Header Styles --- */
header {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: linear-gradient(90deg, #0056ff, #00aaff);
  padding: 15px 30px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.2);
  border-bottom-left-radius: 12px;
  border-bottom-right-radius: 12px;
}

.header-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  max-width: 1200px;
  margin: auto;
}

/* Logo */
.logo-link {
  display: flex;
  align-items: center;
  text-decoration: none;
  transition: transform 0.3s ease;
}

.logo-img {
  margin-right: 12px;
  filter: brightness(1) invert(0.9) sepia(0.8) saturate(3) hue-rotate(45deg);
}

.logo-text {
  font-size: 24px;
  color: #fff;
  text-shadow: 1px 1px 5px rgba(0,0,0,0.3);
  font-weight: 700;
}

/* Navbar links */
#navbar {
  display: flex;
  align-items: center;
  gap: 20px;
}

#navbar a {
  color: #fff;
  font-weight: 600;
  font-size: 16px;
  text-decoration: none;
  transition: all 0.3s ease;
  padding: 5px 0;
}

#navbar a:hover {
  color: #fffa;
  transform: scale(1.1);
}

/* Hamburger Icon */
#hamburger {
  display: none;
  flex-direction: column;
  cursor: pointer;
  gap: 5px;
  z-index: 1002;
}

#hamburger span {
  width: 25px;
  height: 3px;
  background: #fff;
  border-radius: 3px;
  transition: all 0.3s ease;
}

/* Dropdown styles */
.dropdown {
  position: relative;
}

.dropbtn {
  background: none;
  border: none;
  color: #fff;
  font-weight: 600;
  cursor: pointer;
  font-size: 16px;
  font-family: Poppins, sans-serif;
}

.dropdown-content {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  background: #0056ff;
  border-radius: 8px;
  box-shadow: 0 4px 10px rgba(0,0,0,0.2);
  min-width: 180px;
  z-index: 999;
  border: 1px solid #004acb;
}

.dropdown-content a {
  display: block;
  padding: 10px 15px;
  color: #ffffff;
  text-decoration: none;
  transition: background-color 0.2s ease;
}

.dropdown-content a:hover {
  background-color: #004acb;
}

.dropdown:hover .dropdown-content {
  display: block;
}

/* --- Mobile Responsive Menu --- */
@media screen and (max-width: 768px) {
  #hamburger {
    display: flex;
  }

  #navbar {
    position: fixed;
    top: 80px;
    right: 15px;
    width: 250px;
    background: linear-gradient(180deg, #0056ff, #00399d);
    flex-direction: column;
    align-items: flex-start;
    padding: 10px 0;
    gap: 0;
    box-shadow: -5px 5px 15px rgba(0,0,0,0.25);
    z-index: 1001;
    border-radius: 12px;
    transform: translateX(110%);
    transition: transform 0.3s ease-in-out;
  }

  #navbar.show {
    display: flex;
    transform: translateX(0);
  }

  #navbar a, .dropdown {
    padding: 15px 25px;
    text-align: left;
    width: 100%;
    box-sizing: border-box;
  }

  .dropdown-content {
    position: static;
    display: none;
    background: rgba(0, 0, 0, 0.2);
    box-shadow: none;
    border-radius: 0;
    border: none;
    min-width: 100%;
  }

  .dropdown-content a {
    color: #e0f7ff;
    font-weight: normal;
    padding-left: 40px;
  }

  .dropdown.active .dropdown-content {
    display: block;
  }
}

/* --- Footer Styles --- */
footer a {
  text-decoration: none;
  color: var(--primary);
  margin-right: 15px;
}

footer a:hover {
  color: #0039c1;
}

/* Social media icon hover effect */
.footer-social a:hover {
    transform: scale(1.15);
}