@import url('https://fonts.googleapis.com/css2?family=Dancing+Script&display=swap');

:root {
  --bg-color: #ffffff;
  --text-color: #111111;
  --accent-color: #ff1493;
  --transition-speed: 0.3s;
}

[data-theme="ocean"] {
  --bg-color: #0f3057;
  --text-color: #e0fbfc;
  --accent-color: #3caea3;
}

[data-theme="sunset"] {
  --bg-color: #ff6b6b;
  --text-color: #fff5e1;
  --accent-color: #ffcc5c;
}

[data-theme="forest"] {
  --bg-color: #2e8b57;
  --text-color: #f4f4f4;
  --accent-color: #ffd700;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 3.6rem;
}

body {
  margin: 0;
  padding: 0;
  font-family: 'Segoe UI', sans-serif;
  background-color: var(--bg-color);
  color: var(--text-color);
  transition: background-color var(--transition-speed), color var(--transition-speed);
  min-height: 100vh;
  box-sizing: border-box;
}

/* Hero Animation */
#hero {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  height: 70vh;
  text-align: center;
  animation: fadeOutHero 0s ease-out 3.75s forwards;
  background-color: var(--bg-color);
}

.intro-text {
    font-family: 'Segoe UI', sans-serif;
    font-size: 2rem;
    white-space: nowrap;
    overflow: hidden;
    visibility: hidden;
    animation: 
      revealIntro 0s linear 0.02s forwards,  
      typing 2s steps(13, end) 0.05s forwards,
      fadeOutText 0.5s ease-out 2.5s forwards;
}

.name-text {
  font-family: 'Dancing Script', cursive;
  font-size: 4rem;
  color: var(--accent-color);
  opacity: 0;
  animation: fadeInName 1s ease-out 2s forwards,
             moveOutName 1.2s ease-out 3s forwards;
}

.name-static {
  font-family: 'Dancing Script', cursive;
  font-size: 2rem;
  color: var(--accent-color);
  opacity: 0;
  animation: fadeInSoft 0.4s ease-in 3s forwards;
  transform: none
}

.site-header,
.bottom-nav {
  opacity: 0;
  animation: fadeInSoft 0.4s ease-in 3.8s forwards;
}

main {
  opacity: 0;
  animation: fadeInSoft 0.4s ease-in 4s forwards;
}

@keyframes revealIntro {
  to {visibility: visible; }
}

@keyframes typing {
  from { width: 0 }
  to { width: 13ch }
}

@keyframes fadeOutText {
  to { opacity: 0; }
}

@keyframes fadeOutHero {
  to {
    opacity: 0;
    height: 0;
    visibility: hidden;
    overflow: hidden;
  }
}

@keyframes fadeInName {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes moveOutName {
  to {
    transform: translateY(-400px) scale(0.5);
    opacity: .2;
  }
}

@keyframes fadeInSoft {
  from { opacity: 0; }
  to { opacity: 1; }
}

.site-header {
  position: sticky;
  top: 0;
  padding: 1rem 2rem;
  background-color: var(--bg-color);
  border-bottom: 1px solid var(--bg-color);
  box-shadow: 0 1px 5px var(--accent-color);
  text-align: center;
  z-index: 900;
}

.name-static {
  font-family: 'Dancing Script', cursive;
  font-size: 2rem;
  color: var(--accent-color);
}

main {
  max-width: 800px;
  margin: auto;
  padding: 5rem 4rem;
  padding-right: 4rem;
  padding-bottom: 5rem;
}

h1, h2 {
  font-family: 'Dancing Script', cursive;
}

h4.focused {
  font-size: 2rem;
  color: var(--accent-color);
  text-align: center;
  margin-top: 4rem;
}

.bottom-nav {
  position: fixed;
  bottom: 0;
  left: 0;
  width: 100%;
  background-color: var(--bg-color);
  border-top: 1px solid var(--bg-color);
  box-shadow: 0 -1px 5px var(--accent-color);
  z-index: 1000;
}

.bottom-nav ul {
  list-style: none;
  display: flex;
  justify-content: space-around;
  align-items: center;
  margin: 0;
  padding: 0.5rem 1rem;
}

.bottom-nav li {
  display: flex;
  align-items: center;
}

.bottom-nav a {
  text-decoration: none;
  color: var(--accent-color);
  font-weight: 500;
  transition: color var(--transition-speed);
}

.bottom-nav a.active,
.bottom-nav a:hover,
.bottom-nav a:focus {
  text-decoration: underline;
  color: var(--accent-color);
}

.theme-switcher {
  display: flex;
  align-items: center;
  justify-content: center;
}

.theme-switcher button {
  background: none;
  border: none;
  font-size: 1.5rem;
  cursor: pointer;
  transition: transform var(--transition-speed);
}

.theme-switcher button:hover {
  transform: scale(1.2);
}

#section-nav ul {
  list-style: none;
  padding: 0;
  margin: 0;
  position: fixed;
  right: 1rem;
  top: 50%;
  transform: translateY(-50%);
  z-index: 1001;
}

#section-nav a {
  font-size: 1.5rem;
  display: inline-block;
  padding: 0.5rem;
  text-decoration: none;
  color: var(--accent-color);
  transition: transform 0.2s ease;
}

#section-nav li.active a {
  transform: scale(1.5);
  color: var(--accent-color);
}

.menu-icon, #menu-toggle {
  display:none;
}

#contact-form {
  max-width: 600px;
  margin: 2rem auto;
  padding: 2rem;
  background: var(--bg-color);
  border-radius: 1rem;
  box-shadow: 0 8px 16px rgba(0,0,0,0.1);
  color: var(--text-color);
  display: flex;
  flex-direction: column;
  gap: 1rem;
  font-family: inherit;
}

#contact-form input,
#contact-form textarea {
  width: 100%;
  padding: 0.75rem;
  background-color: #fff;
  color: #111;
  border: 1px solid #ccc;
  border-radius: 0.5rem;
  font-size: 1rem;
}

#contact-form input::placeholder,
#contact-form textarea::placeholder {
  color: #777;
}

#contact-form input:focus,
#contact-form textarea:focus {
  border-color: var(--accent-color);
  outline: none;
  box-shadow: 0 0 0 3px rgba(255, 20, 147, 0.2);
}

#contact-form button[type="submit"] {
  background-color: var(--accent-color);
  color: #fff;
  padding: 0.75rem 1.5rem;
  border: none;
  border-radius: 0.5rem;
  cursor: pointer;
  transition: background 0.3s;
  align-self: flex-end;
}

#contact-form button[type="submit"]:hover {
  background-color: #e01384;
}

/* Theme-specific overrides */
[data-theme="ocean"] #contact-form {
  background-color: #1e4a5f;
  color: #e0fbfc;
}

[data-theme="ocean"] #contact-form input,
[data-theme="ocean"] #contact-form textarea {
  background-color: #d9f3f9;
  color: #002b36;
  border-color: #3caea3;
}

[data-theme="ocean"] #contact-form input::placeholder,
[data-theme="ocean"] #contact-form textarea::placeholder {
  color: #007e8a;
}

[data-theme="sunset"] #contact-form,
[data-theme="forest"] #contact-form {
  background-color: #fffaf3;
  color: #111;
}

[data-theme="sunset"] #contact-form input,
[data-theme="sunset"] #contact-form textarea,
[data-theme="forest"] #contact-form input,
[data-theme="forest"] #contact-form textarea {
  background-color: #fff9f0;
  color: #111;
  border-color: #cc8400;
}

[data-theme="sunset"] #contact-form input::placeholder,
[data-theme="sunset"] #contact-form textarea::placeholder,
[data-theme="forest"] #contact-form input::placeholder,
[data-theme="forest"] #contact-form textarea::placeholder {
  color: #555;
}



@media (max-width: 600px) {
  .bottom-nav {
    display:flex;
    flex-direction: column;
    align-items: flex-end;
  }

  .bottom-nav ul {
    display: none;
    flex-direction: column;
    width: 100%;
    margin: 0;
    padding: 1rem;
    background-color: var(--bg-color);
  }

  #menu-toggle {
    display: none;
  }

  #menu-toggle:checked + .menu-icon + ul {
    display: flex;
  }

  .menu-icon {
    display: block;
    padding: 0.5rem 1rem;
    font-size: 1.8rem;
    color: var(--accent-color);
    cursor: pointer;
    text-align:right;
    width: 100%;
    margin: 0.5rem;
  }

  .bottom-nav ul li {
    margin: 0.5rem 0;
    text-align: right;
  }
}

.hidden {
  opacity: 0;
  transition: opacity var(--transition-speed);
}

.status-message {
  font-size: 0.95rem;
  margin-top: 1rem;
  text-align: center;
  display: none;
}

.status-message.success { color: green; }
.status-message.error { color: red; }