/*
Theme Name: Folio
Theme URI: https://github.com/yourname/folio
Author: Your Name
Description: A clean, minimal portfolio theme for freelance web designers. Showcases work, builds trust, and converts visitors into clients.
Version: 1.0.0
Requires at least: 6.0
Requires PHP: 8.0
License: GNU General Public License v2 or later
Text Domain: folio
*/

:root {
  --f-white:    #FFFFFF;
  --f-off:      #FAFAF9;
  --f-black:    #0D0D0D;
  --f-ink:      #1A1A1A;
  --f-muted:    #6B7280;
  --f-subtle:   #F3F4F6;
  --f-border:   #E5E7EB;
  --f-accent:   #2563EB;
  --f-accent-h: #1D4ED8;
  --f-font-head: 'DM Sans', system-ui, sans-serif;
  --f-font-body: 'DM Sans', system-ui, sans-serif;
  --f-font-mono: 'DM Mono', monospace;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  background: var(--f-white);
  color: var(--f-ink);
  font-family: var(--f-font-body);
  font-size: 1rem;
  line-height: 1.7;
  margin: 0;
  -webkit-font-smoothing: antialiased;
}

h1,h2,h3,h4,h5,h6 {
  font-family: var(--f-font-head);
  font-weight: 600;
  line-height: 1.2;
  letter-spacing: -.02em;
  color: var(--f-ink);
}

a { color: var(--f-accent); text-decoration: none; transition: color .2s; }
a:hover { color: var(--f-accent-h); }
img { max-width: 100%; height: auto; display: block; }

/* ── Layout ── */
.f-section { padding: 6rem 0; }
.f-container { width: 90%; max-width: 1060px; margin: 0 auto; }
.f-container--narrow { width: 90%; max-width: 680px; margin: 0 auto; }

/* ── Nav ── */
#f-nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  background: rgba(255,255,255,.85);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid transparent;
  padding: 1.25rem 0;
  transition: border-color .3s, padding .3s;
}
#f-nav.scrolled { border-bottom-color: var(--f-border); padding: .9rem 0; }
.f-nav__inner { display: flex; align-items: center; justify-content: space-between; }
.f-nav__logo {
  font-family: var(--f-font-head);
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--f-ink);
  letter-spacing: -.03em;
  display: flex; align-items: center; gap: .4rem;
}
.f-nav__logo-dot { width: 7px; height: 7px; background: var(--f-accent); border-radius: 50%; display: inline-block; }
.f-nav__logo:hover { color: var(--f-accent); }
.f-nav__links { display: flex; align-items: center; gap: 2.5rem; list-style: none; margin: 0; padding: 0; }
.f-nav__links a { font-size: .875rem; font-weight: 500; color: var(--f-muted); transition: color .2s; }
.f-nav__links a:hover { color: var(--f-ink); }
.f-nav__cta {
  padding: .55rem 1.25rem;
  background: var(--f-ink);
  color: var(--f-white) !important;
  border-radius: 6px;
  font-weight: 600 !important;
  font-size: .875rem !important;
  transition: background .2s, transform .15s !important;
}
.f-nav__cta:hover { background: var(--f-accent) !important; transform: translateY(-1px); }
.f-nav__toggle { display: none; background: none; border: none; cursor: pointer; flex-direction: column; gap: 5px; padding: 4px; }
.f-nav__toggle span { display: block; width: 22px; height: 1.5px; background: var(--f-ink); transition: all .3s; }
@media(max-width:768px){
  .f-nav__toggle{display:flex;}
  .f-nav__links{display:none;position:absolute;top:100%;left:0;right:0;background:var(--f-white);flex-direction:column;padding:1.5rem 5%;gap:1.25rem;border-bottom:1px solid var(--f-border);}
  .f-nav__links.open{display:flex;}
}

/* ── Hero ── */
#f-hero {
  min-height: 100vh;
  display: flex; align-items: center;
  padding-top: 5rem;
  background: var(--f-white);
  position: relative;
  overflow: hidden;
}
.f-hero__bg-line {
  position: absolute;
  top: 0; right: 0;
  width: 55%;
  height: 100%;
  background: var(--f-off);
  z-index: 0;
  clip-path: polygon(8% 0, 100% 0, 100% 100%, 0% 100%);
}
.f-hero__content { position: relative; z-index: 1; max-width: 600px; }
.f-hero__eyebrow {
  display: inline-flex; align-items: center; gap: .6rem;
  font-size: .8rem; font-weight: 600; color: var(--f-muted);
  margin-bottom: 1.75rem;
}
.f-hero__eyebrow-dot { width: 6px; height: 6px; background: var(--f-accent); border-radius: 50%; }
.f-hero__title {
  font-size: clamp(2.75rem, 6vw, 4.5rem);
  font-weight: 600;
  letter-spacing: -.04em;
  line-height: 1.05;
  color: var(--f-ink);
  margin-bottom: 1.5rem;
}
.f-hero__title em { color: var(--f-accent); font-style: normal; }
.f-hero__sub { font-size: 1.1rem; color: var(--f-muted); max-width: 480px; margin-bottom: 2.5rem; }
.f-hero__actions { display: flex; align-items: center; gap: 1.25rem; flex-wrap: wrap; }
.f-hero__scroll-hint { display: flex; align-items: center; gap: .5rem; font-size: .75rem; color: var(--f-muted); font-weight: 500; margin-top: 4rem; }
.f-hero__scroll-hint::before { content: ''; display: block; width: 24px; height: 1px; background: var(--f-border); }

/* ── Buttons ── */
.f-btn {
  display: inline-flex; align-items: center; gap: .5rem;
  padding: .7rem 1.5rem;
  font-family: var(--f-font-body);
  font-size: .875rem; font-weight: 600;
  border-radius: 6px; border: none; cursor: pointer;
  transition: transform .15s, background .2s, box-shadow .2s;
  text-decoration: none;
}
.f-btn:hover { transform: translateY(-2px); }
.f-btn--primary { background: var(--f-ink); color: var(--f-white); }
.f-btn--primary:hover { background: var(--f-accent); color: var(--f-white); box-shadow: 0 6px 20px rgba(37,99,235,.25); }
.f-btn--ghost { background: transparent; color: var(--f-muted); border: 1.5px solid var(--f-border); }
.f-btn--ghost:hover { border-color: var(--f-ink); color: var(--f-ink); }

/* ── Section labels ── */
.f-label {
  display: inline-flex; align-items: center; gap: .6rem;
  font-size: .75rem; font-weight: 600; color: var(--f-muted);
  letter-spacing: .05em; text-transform: uppercase;
  margin-bottom: 1rem;
}
.f-label::before { content: ''; display: block; width: 20px; height: 1.5px; background: var(--f-accent); }

.f-section-title { font-size: clamp(1.75rem, 4vw, 2.5rem); font-weight: 600; letter-spacing: -.03em; margin-bottom: 1rem; }

/* ── Portfolio ── */
#f-portfolio { background: var(--f-off); }
.f-portfolio__grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 1.5rem; margin-top: 3rem; }
.f-portfolio-card {
  background: var(--f-white);
  border-radius: 10px;
  overflow: hidden;
  border: 1px solid var(--f-border);
  transition: transform .25s, box-shadow .25s;
  display: block; color: inherit;
}
.f-portfolio-card:hover { transform: translateY(-5px); box-shadow: 0 20px 50px rgba(0,0,0,.08); color: inherit; }
.f-portfolio-card__img { aspect-ratio: 16/10; overflow: hidden; background: var(--f-subtle); position: relative; }
.f-portfolio-card__img img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s; }
.f-portfolio-card:hover .f-portfolio-card__img img { transform: scale(1.04); }
.f-portfolio-card__overlay {
  position: absolute; inset: 0;
  background: rgba(37,99,235,0); display: flex; align-items: center; justify-content: center;
  transition: background .3s;
}
.f-portfolio-card:hover .f-portfolio-card__overlay { background: rgba(37,99,235,.07); }
.f-portfolio-card__body { padding: 1.5rem; }
.f-portfolio-card__tags { display: flex; gap: .5rem; flex-wrap: wrap; margin-bottom: .75rem; }
.f-portfolio-card__tag {
  font-size: .7rem; font-weight: 600; letter-spacing: .06em; text-transform: uppercase;
  padding: .2rem .6rem; background: var(--f-subtle); color: var(--f-muted); border-radius: 4px;
}
.f-portfolio-card__name { font-size: 1.05rem; font-weight: 600; color: var(--f-ink); margin-bottom: .35rem; }
.f-portfolio-card__desc { font-size: .875rem; color: var(--f-muted); }
.f-portfolio-card__link { display: inline-flex; align-items: center; gap: .35rem; font-size: .8rem; font-weight: 600; color: var(--f-accent); margin-top: 1rem; }

/* ── About ── */
#f-about { background: var(--f-white); }
.f-about__inner { display: grid; grid-template-columns: auto 1fr; gap: 4rem; align-items: start; }
.f-about__photo-wrap { width: 260px; }
.f-about__photo {
  width: 260px; height: 320px; object-fit: cover;
  border-radius: 10px;
  border: 1px solid var(--f-border);
}
.f-about__photo-placeholder {
  width: 260px; height: 320px; border-radius: 10px;
  background: var(--f-subtle); border: 1px solid var(--f-border);
  display: flex; align-items: center; justify-content: center;
  font-size: 4rem; color: var(--f-border);
}
.f-about__text p { color: var(--f-muted); margin-bottom: 1.25rem; }
.f-about__skills { display: flex; flex-wrap: wrap; gap: .6rem; margin-top: 1.75rem; }
.f-about__skill { font-size: .75rem; font-weight: 600; letter-spacing: .04em; padding: .35rem .85rem; background: var(--f-subtle); color: var(--f-ink); border-radius: 100px; }
@media(max-width:680px){ .f-about__inner{grid-template-columns:1fr;} .f-about__photo-wrap,.f-about__photo{width:100%;} .f-about__photo{height:280px;} }

/* ── Contact ── */
#f-contact { background: var(--f-off); }
.f-contact__inner { display: grid; grid-template-columns: 1fr 1.5fr; gap: 4rem; align-items: start; }
.f-contact__intro p { color: var(--f-muted); margin-bottom: 1.5rem; }
.f-contact__link { display: flex; align-items: center; gap: .75rem; font-size: .9rem; color: var(--f-muted); margin-bottom: 1rem; }
.f-contact__link a { color: var(--f-ink); font-weight: 500; }
.f-contact__link a:hover { color: var(--f-accent); }
.f-contact__link-icon { width: 32px; height: 32px; background: var(--f-white); border: 1px solid var(--f-border); border-radius: 6px; display: flex; align-items: center; justify-content: center; flex-shrink: 0; color: var(--f-muted); }
.f-form { background: var(--f-white); border: 1px solid var(--f-border); border-radius: 10px; padding: 2.25rem; display: grid; gap: 1.25rem; }
.f-form__row { display: grid; grid-template-columns: 1fr 1fr; gap: 1.25rem; }
.f-form__group { display: flex; flex-direction: column; gap: .4rem; }
.f-form__label { font-size: .75rem; font-weight: 600; color: var(--f-muted); }
.f-form__input, .f-form__textarea, .f-form__select {
  background: var(--f-off); border: 1.5px solid var(--f-border);
  color: var(--f-ink); padding: .65rem .9rem; border-radius: 6px;
  font-family: var(--f-font-body); font-size: .9rem;
  transition: border-color .2s, background .2s; width: 100%;
}
.f-form__input:focus, .f-form__textarea:focus, .f-form__select:focus { outline: none; border-color: var(--f-accent); background: var(--f-white); }
.f-form__textarea { resize: vertical; min-height: 120px; }
.f-form__notice { font-size: .85rem; padding: .75rem 1rem; border-radius: 6px; display: none; }
.f-form__notice--success { background: #ecfdf5; color: #065f46; border: 1px solid #a7f3d0; }
.f-form__notice--error   { background: #fef2f2; color: #991b1b; border: 1px solid #fecaca; }
@media(max-width:768px){ .f-contact__inner{grid-template-columns:1fr;} .f-form__row{grid-template-columns:1fr;} }

/* ── Footer ── */
#f-footer {
  padding: 2.5rem 0;
  border-top: 1px solid var(--f-border);
  background: var(--f-white);
}
.f-footer__inner { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 1rem; }
.f-footer__logo { font-size: .95rem; font-weight: 600; color: var(--f-ink); display: flex; align-items: center; gap: .4rem; }
.f-footer__copy { font-size: .8rem; color: var(--f-muted); }
.f-footer__links { display: flex; gap: 1.5rem; list-style: none; margin: 0; padding: 0; }
.f-footer__links a { font-size: .8rem; color: var(--f-muted); }
.f-footer__links a:hover { color: var(--f-ink); }

/* ── Animations ── */
.f-fade-up { opacity: 0; transform: translateY(24px); transition: opacity .65s ease, transform .65s ease; }
.f-fade-up.visible { opacity: 1; transform: translateY(0); }
.f-fade-up:nth-child(2) { transition-delay: .1s; }
.f-fade-up:nth-child(3) { transition-delay: .2s; }
.f-fade-up:nth-child(4) { transition-delay: .3s; }
