
*,
*::before,
*::after {
  box-sizing: border-box;
}

body {
  margin: 0;
  padding: 0;
  overflow-x: hidden;
}

.container,
.main,
.section,
.wrapper {
  max-width: 100%;
  overflow-x: hidden;


}

html, body {
  width: 100%;
  overflow-x: hidden;
}

img, table, pre, code, iframe {
  max-width: 100%;
  overflow-x: auto;
  display: block;
}



:root {
  --primary: #2563eb;
  --primary-hover: #1d4ed8;
  --text: #1e293b;
  --muted: #64748b;
  --border: #94a3b8;
  --bg: #f8fafc;
  --input-bg: #fff;
}

body.dark {
  --primary: #3b82f6;
  --primary-hover: #2563eb;
  --text: #f5f5f5;
  --muted: #cbd5e1;
  --border: #64748b;
  --bg: #121212;
  --input-bg: #1e1e1e;
}

body {
  font-family: 'Inter', sans-serif;
  line-height: 1.5;
  color: var(--text);
  background-color: var(--bg);
  margin: 0;
  
  transition: background-color 0.3s ease, color 0.3s ease;
  margin: 0;
  padding: 0;
  overflow-x: hidden;
}

.main-container {
  display: flex;
  flex-wrap: wrap;
  gap: 1.5rem;
  max-width: 1100px;
  margin: 0 auto;
  width: 100%;


}

.form-section, .preview-section {


  flex: 1 1 400px; 
  min-width: 300px; 
  padding: 1rem;
  max-width: 100%;
  overflow-wrap: break-word;
  word-break: break-word;


  
}

.form-section {
  flex: 1 1 350px;
  max-width: 450px;
}

.preview-section {
  flex: 2 1 500px;
  font-size: 13px;
}

.form-group {
  margin-bottom: 1.2rem;
}

label {
  display: block;
  margin-bottom: 0.4rem;
  font-weight: 500;
  font-size: 0.9rem;
  color: var(--text);
}

input, textarea {
  /* width: 90%; */
  padding: 0.5rem 0.7rem;
  border: 1px solid var(--border);
  border-radius: 6px;
  font-size: 13px;
  margin-bottom: 0.4rem;
  background-color: var(--input-bg);
  color: var(--text);
  transition: border 0.2s ease;
   width: 100%;
  max-width: 100%;
  box-sizing: border-box;
}

input:focus, textarea:focus {
  border-color: var(--primary);
  outline: 2px solid rgba(37, 99, 235, 0.2);
}

textarea {
  min-height: 80px;
}

.add-btn, .download-btn {
  background-color: var(--primary);
  color: #fff;
  border: none;
  padding: 0.5rem 1rem;
  border-radius: 6px;
  font-size: 13px;
  margin-top: 0.5rem;
  cursor: pointer;
  transition: background-color 0.2s ease;
}

.add-btn:hover, .download-btn:hover {
  background-color: var(--primary-hover);
}

.education-inputs, .experience-inputs, .certifications-inputs, .project-input {
  margin-bottom: 0.8rem;
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 0.8rem;
  background-color: var(--bg);
}

.skills-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.8rem;
  margin-bottom: 0.8rem;
}

.skills-grid div {
  margin-bottom: 0.5rem;
}

.skills-grid label {
  font-size: 0.85rem;
  margin-bottom: 0.3rem;
}

.header h1 {
  font-size: 1.4rem;
  color: var(--primary);
  margin-bottom: 0.3rem;
}

.contact-info {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.5rem;
  color: var(--muted);
  font-size: 12px;
  margin-bottom: 0.8rem;
}

.section {
  margin-bottom: 1rem;
}

.section h2 {
  font-size: 1rem;
  color: var(--primary);
  border-bottom: 1px solid var(--border);
  padding-bottom: 0.2rem;
  margin-bottom: 0.5rem;
}

ul {
  padding-left: 1.2rem;
  margin: 0.5rem 0;
}

ul li {
  margin-bottom: 0.3rem;
  position: relative;
}

ul li::before {
  content: "•";
  color: var(--primary);
  position: absolute;
  left: -1.2rem;
}

.project-links a {
  color: var(--primary);
  text-decoration: none;
  font-size: 12px;
  margin-right: 0.8rem;
}

.project-links a::before {
  content: "🌐";
  margin-right: 0.3rem;
}

.fade-in {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.6s ease-out, transform 0.6s ease-out;
  will-change: opacity, transform;
}

.fade-in.show {
  opacity: 1;
  transform: translateY(0);
}

.scroll-up-btn {
  position: fixed;
  bottom: 10px;
  right: 10px;
  z-index: 999;
  padding: 6px 12px;
  cursor: pointer;
  border: 2px solid var(--border);
  background-color: var(--input-bg);
  color: var(--text);
  border-radius: 20%;
}


@media (max-width: 900px) {
  .main-container {
    flex-direction: column;
    gap: 1rem;
    padding: 0 0.5rem;
  }

  .form-section, .preview-section {
    max-width: 100%;
    min-width: 0;
    padding: 1rem;
  }

  .skills-grid {
    grid-template-columns: 1fr;
  }
}


.footer-actions {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.2rem;
  padding: 2rem 1rem;
  background: #f9f9f9;
  color: #333;
  font-size: 0.95rem;
  border-top: 1px solid #ddd;
  margin-top: 2rem;
}

.footer-actions .footer-buttons {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
  justify-content: center;
}

.footer-actions button {
  padding: 12px 24px;
  font-size: 1rem;
  border-radius: 8px;
  border: 1px solid #ccc;
  /* background-color: white;  */
  cursor: pointer;
  transition: all 0.2s ease;
}

.footer-actions button:hover {
  /* background-color: #f0f0f0; */
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
}

.footer-info {
  text-align: center;
}

.footer-links {
  margin-top: 0.5rem;
}

.footer-links a {
  margin: 0 0.5rem;
  text-decoration: none;
  color: #0073e6;
  font-weight: 500;
}

.footer-links a:hover {
  text-decoration: underline;
}




.btn-refresh,
.btn-autofill {
  background-color: var(--bg);
  border: 1px solid var(--border);
  color: var(--text);
  padding: 10px 16px;
  border-radius: 8px;
  font-family: 'Inter', sans-serif;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: background-color 0.2s ease, box-shadow 0.2s ease;
}

.btn-refresh:hover,
.btn-autofill:hover {
  background-color: var(--input-bg);
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.1);
}

.btn-refresh:active,
.btn-autofill:active {
  transform: scale(0.98);
}

#themeToggle {
  position: fixed;
  top: 10px;
  right: 10px;
  z-index: 999;
  padding: 6px 12px;
  cursor: pointer;
  border: none;
  background-color: var(--input-bg);
  color: var(--text);
  border-radius: 4px;
}
#themeToggle {
  position: fixed;
  top: 10px;
  right: 10px;
  background: none;
  border: none;
  font-size: 32px; /* Increased size */
  cursor: pointer;
  z-index: 1000;
  color: inherit;
  transition: transform 0.2s ease;
}

html, body {
  height: 100%;
  display: flex;
  flex-direction: column;
  margin: 0;
  padding: 0;
}

main {
  flex: 1;
  display: flex;
  flex-direction: column;
}


/* Resume action buttons container */
.resume-actions {
  display: flex;
  justify-content: center;
  gap: 20px;
  margin: 20px 0;
}

/* Resume action buttons */
.btn-refresh,
.btn-autofill {
  padding: 10px 20px;
  font-size: 16px;
  cursor: pointer;
  border-radius: 6px;
  border: none;
  background-color: #007bff;
  color: white;
  transition: background-color 0.3s ease;
}

.btn-refresh:hover,
.btn-autofill:hover {
  background-color: #0056b3;
}

/* Footer actions styled as normal div */
.footer-actions {
  background-color: #f1f1f1;
  padding: 20px;
  text-align: center;
  margin-top: 30px;
  border-top: 1px solid #ccc;
}

.footer-links {
  margin-top: 10px;
}

.footer-links a {
  margin: 0 10px;
  text-decoration: none;
  color: #333;
  font-weight: bold;
  transition: color 0.3s ease;
}

.footer-links a:hover {
  color: #007bff;
}

/* Light/Dark mode support for footer */
.footer {
  background-color: #f1f1f1;
  color: #333;
}

.footer-link {
  color: #333;
  text-decoration: none;
}

body.dark .footer {
  background-color: #1a1a1a;
  color: #eee;
  border-top: 1px solid #444;
  box-shadow: 0 -2px 5px rgba(255, 255, 255, 0.05);
}

body.dark .footer-link {
  color: #ffcc00;
}


/* Hide footer area in print mode */
.no-print {
  display: block;
}

@media print {
  .no-print {
    display: none;
  }
}



@media(max-width:768px){
  footer{
    flex-direction: column;
    text-align:center;
    align-items:center;
    padding: 1rem;
    gap:1.5rem;
  }
#themeToggle i.fa-sun {
  color: #FFD700 !important;
}
.char-count {
  font-size: 0.75rem; 
  color: var(--muted); 
  display: block;
  margin-top: -0.2rem; 
  text-align: right; 
  padding-right: 0.7rem; 
}

.error-message {
  color: #dc2626;
  font-size: 0.8rem;
  margin-top: -0.2rem;
  margin-bottom: 0.5rem;
  display: block;
}

@media print {
  .no-print{
  display: none !important;
 }
}
}
/* Highlight the section being dragged */
.section.dragging {
  opacity: 0.5;
  background-color: #f0f0f0;
  border: 2px dashed #007bff;
  cursor: grabbing;
  transform: scale(1.02);
  transition: all 0.2s ease-in-out;
}

/* animate section positions */
.section {
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}





@media (width<=40rem){
  #themeToggle{
    font-size: 20px; 
  padding: 4px;
  
  }
}



@media (max-width: 640px) {
  * {
    box-sizing: border-box;
  }

  body {
    font-size: 14.5px;
    padding: 1rem;
    margin: 0;
    overflow-x: hidden;
  }

  .form-section,
  .preview-section,
  .main-container {
    padding: 1rem;
    margin: 0 auto;
    gap: 1rem;
  }

  .header h1 {
    font-size: 1.3rem;
    margin-bottom: 0.6rem;
  }

  .section h2 {
    font-size: 1rem;
  }

  .skills-grid {
    grid-template-columns: 1fr;
    gap: 0.6rem;
  }

  footer {
    padding: 1rem 1.2rem;
    font-size: 1rem;
    flex-direction: column;
    align-items: center;
    gap: 1.2rem;
  }

  .footer-right {
    margin-right: 0;
    justify-content: center;
    gap: 1rem;
  }

  .btn-refresh,
  .btn-autofill {
    padding: 12px 20px;
    font-size: 15px;
    border-radius: 8px;
  }
}
@media screen and (max-width: 480px) {
  .footer-actions {
    padding: 10px;
    margin-bottom: 10px;
    display: flex;
    flex-direction: column;
    align-items: center;
  }

  .footer-actions button {
    font-size: 14px;
    padding: 8px 16px;
    margin: 6px 0;
    width: 80%;
  }
}




















